title: Realm Results object type
body: <p>This is really basic but I just can't find how to get all objects of a type from a Realm database using Swift. Yes, yes:</p>
  
  <pre><code>var dogs = try! Realm().objects(Dog)
  </code></pre>
  
  <p>but what if I want to declare and initialize the dogs variable beforehand and load objects into it later? Like:</p>
  
  <pre><code>var dogs = ???
  dogs = realm.objects(Dog)
  </code></pre>
  
  <p>What should the type of variable dogs be in this case?</p>