I have been testing using Arrays of objects (classes?), rather than Parse Relations to create this relationship, taken again from the iOS documentation.
The pinning recursion seems to function as I had originally expected from the documentation in this way. It was a simple test with 2 classes:
TestClass1 - created 2 objects
TestClass2 - created 1 object, with a “Linked” field of type Array
Query for the first (single) TestClass2 object, to assign it as a PFObject.
testClass2.add(linkedClass, forKey: "Linked")
Now if I query for this object again AND pin it, when I view this in the SQLite browser I can see both classes having been pinned (TestClass2 has 1 row / object, TestClass1 has 2 rows / objects). Nothing else was required.
Should this pinning of related classes / objects work with Relations or Pointers as well? Or will I need to perform additional sub-queries of the linked items? Is this the reason for the following statement in the documentation?
In general, using arrays will lead to higher performance and require fewer queries