Getting ObjectStore
You can use static methods on the Factory inner classes to create instances of ObjectStore.
Use createInstance to create a new instance of an ObjectStore object.
The pattern for getting an ObjectStore is as follows -
ObjectStore
- Get a Connection object.
- Get a Domain object.
- Get an ObjectStore object.
- Connection Object : Get to the Connection code
- Get the Domain Object as shown in 3 rd step.
- The Below code is to Create Object for Object Store,
The difference between these two methods is that getInstance does not verify the existence of the requested object on the server; it returns a local reference to the object, which is not affiliated with a server object until you perform a function on the object.
The fetchInstance method, however, immediately makes a round trip to the server to retrieve the property values of the ObjectStore object.