java.lang.Object | |
↳ | com.kinvey.java.AppData<T> |
![]()
LinkedData<T extends LinkedGenericJson>
|
Class for managing appData access to the Kinvey backend.
Nested Classes | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
class | AppData.Aggregate | Generic Aggregate |
|||||||||
class | AppData.Delete | Generic Delete class. | |||||||||
class | AppData.Get | Generic Get class. | |||||||||
class | AppData.GetEntity | Generic Get class. | |||||||||
class | AppData.Save | Generic Save |
Constants | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
String | GEOLOC_FIELD_NAME | static final String representing universal "_geoloc" value, used for geoqueries | |||||||||
String | ID_FIELD_NAME | static final String representing universal "_id" value, used to uniquely identify entites |
Public Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Aggregate |
aggregate(ArrayList<String> fields, AggregateEntity.AggregateType type, String aggregateField, Query query)
public helper method to create AggregateEntity and return an intialize Aggregate Request Object@return
| ||||||||||
Aggregate |
averageBlocking(ArrayList<String> fields, String averageField, Query query)
Retrieve a group by AVERAGE on a collection or filtered collection@return
| ||||||||||
AppDataOperation.BlockingDeleteBuilder |
blockingDeleteBuilder()
Create and return a new synchronous App Data Request Builder associated with *this* instance of AppData.
| ||||||||||
AppDataOperation.BlockingGetBuilder |
blockingGetBuilder()
Create and return a new synchronous App Data Request Builder associated with *this* instance of AppData.
| ||||||||||
AppDataOperation.BlockingSaveBuilder |
blockingSaveBuilder()
Create and return a new synchronous App Data Request Builder associated with *this* instance of AppData.
| ||||||||||
Aggregate |
countBlocking(ArrayList<String> fields, Query query)
Retrieve a group by COUNT on a collection or filtered collection
| ||||||||||
Delete |
deleteBlocking(Query query)
Delete an entity from a collection by Query.
| ||||||||||
Delete |
deleteBlocking(String entityID)
Delete an entity from a collection by ID.
| ||||||||||
Get |
getBlocking(Query query)
Method to get a query of entities.
| ||||||||||
Get |
getBlocking()
Method to get all entities in a collection.
| ||||||||||
Get |
getBlocking(Query query, String[] resolves)
Convenience wrapper method to execute a query and resolve KinveyReferences in the entities
| ||||||||||
Get |
getBlocking(String[] ids)
Method to get a query of entities.
| ||||||||||
Get |
getBlocking(Query query, String[] resolves, int resolve_depth, boolean retain)
Method to execute a query and resolve KinveyReferences in the entities
| ||||||||||
String |
getCollectionName()
Gets the current collectionName
| ||||||||||
Class<T> |
getCurrentClass()
Gets current class that this AppData instance references.
| ||||||||||
GetEntity |
getEntityBlocking(String entityID)
Method to get an entity or entities.
| ||||||||||
GetEntity |
getEntityBlocking(String entityID, String[] resolves, int resolve_depth, boolean retain)
Method to get an entity or entities.
| ||||||||||
GetEntity |
getEntityBlocking(String id, String[] resolves)
Convenience wrapper method to get an entity and resolve KinveyReferences
| ||||||||||
boolean | isOnline() | ||||||||||
Aggregate |
maxBlocking(ArrayList<String> fields, String maxField, Query query)
Retrieve a group by MAX on a collection or filtered collection@return
| ||||||||||
Aggregate |
minBlocking(ArrayList<String> fields, String minField, Query query)
Retrieve a group by MIN on a collection or filtered collection@return
| ||||||||||
Query |
query()
Creates a new instance of
Query | ||||||||||
Save |
saveBlocking(T entity)
Save (create or update) an entity to a collection.
| ||||||||||
void |
setCache(Cache cache, CachePolicy policy)
Define a cache as well as the policy to use when interacting with the cache
| ||||||||||
void |
setCollectionName(String collectionName)
Sets the collectionName
| ||||||||||
void |
setOffline(OfflinePolicy policy, OfflineStore store)
Define the policy for Offline sync to use when performing operations in the background
| ||||||||||
Aggregate |
sumBlocking(ArrayList<String> fields, String sumField, Query query)
Retrieve a group by SUM on a collection or filtered collection@return
|
[Expand]
Inherited Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
![]() |
static final String representing universal "_geoloc" value, used for geoqueries
static final String representing universal "_id" value, used to uniquely identify entites
public helper method to create AggregateEntity and return an intialize Aggregate Request Object@return
fields | fields to group by |
---|---|
type | Type of aggregation |
aggregateField | Field to aggregate on |
query | optional query to filter by (null for all records in a collection) |
IOException |
---|
Retrieve a group by AVERAGE on a collection or filtered collection@return
fields | fields to group by |
---|---|
averageField | field to average |
query | optional query to filter by (null for all records in a collection) |
IOException |
---|
Create and return a new synchronous App Data Request Builder associated with *this* instance of AppData.
Create and return a new synchronous App Data Request Builder associated with *this* instance of AppData.
Create and return a new synchronous App Data Request Builder associated with *this* instance of AppData.
Retrieve a group by COUNT on a collection or filtered collection
fields | fields to group by |
---|---|
query | optional query to filter by (null for all records in a collection) |
IOException |
---|
Delete an entity from a collection by Query.
query | query for entities to delete |
---|
IOException |
---|
Delete an entity from a collection by ID.
entityID | entityID to delete |
---|
IOException |
---|
Method to get a query of entities. Pass an empty query to return all entities in a collection.
query | Query to get |
---|
IOException |
---|
Method to get all entities in a collection.
IOException |
---|
Convenience wrapper method to execute a query and resolve KinveyReferences in the entities
query | - Query to get |
---|---|
resolves | list of KinveyReference fields to resolve |
IOException |
---|
Method to get a query of entities. Pass an array of entity _ids to return the entites.
ids | array of _ids to query for |
---|
IOException |
---|
Method to execute a query and resolve KinveyReferences in the entities
query | Query to get |
---|---|
resolves | list of KinveyReference fields to resolve |
resolve_depth | the depth of KinveyReferences fields to resolve |
retain | should resolved KinveyReferences be retained |
IOException |
---|
Gets the current collectionName
Gets current class that this AppData instance references.
Method to get an entity or entities. Pass null to entityID to return all entities in a collection.
entityID | entityID to get |
---|
IOException |
---|
Method to get an entity or entities. Pass null to entityID to return all entities in a collection.
entityID | entityID to get |
---|---|
resolves | list of KinveyReference fields to resolve |
resolve_depth | the depth of KinveyReferences fields to resolve |
retain | should resolved KinveyReferences be retained |
IOException |
---|
Convenience wrapper method to get an entity and resolve KinveyReferences
id | the id of the entity to query for |
---|---|
resolves | list of KinveyReference fields to resolve |
IOException |
---|
Retrieve a group by MAX on a collection or filtered collection@return
fields | fields to group by |
---|---|
maxField | field to obtain max value from |
query | optional query to filter by (null for all records in a collection) |
IOException |
---|
Retrieve a group by MIN on a collection or filtered collection@return
fields | fields to group by |
---|---|
minField | field to obtain MIN value from |
query | optional query to filter by (null for all records in a collection) |
IOException |
---|
Save (create or update) an entity to a collection.
entity | Entity to Save |
---|
IOException |
---|
Define a cache as well as the policy to use when interacting with the cache
cache | an implementation of the Cache interface, the cache itself |
---|---|
policy | the policy defining behavior of the cache. |
Sets the collectionName
collectionName | Name of the appData collection. |
---|
Define the policy for Offline sync to use when performing operations in the background
policy | the policy defining behavior of offline sync |
---|
Retrieve a group by SUM on a collection or filtered collection@return
fields | fields to group by |
---|---|
sumField | field to sum |
query | optional query to filter by (null for all records in a collection) |
IOException |
---|