QueryResult Class Reference

Inherits from NSObject
Declared in QueryResult.h

Result

– getResult

Get array of entries returned by Query.

 //Obj-C
 [blogQuery execInBackground:^(ResponseType type, QueryResult *result, NSError *error) {
    NSArray *result = [result getResult];// get all result in array
 }];

 //Swift
 blogQuery.execInBackground { (responseType, result!, error!) -> Void in
    var results:Array  =  result.getResult()
 }
- (BUILT_NULLABLE NSArray<Entry*> *)getResult

Return Value

Returns an array of entries returned by Query.

Declared In

QueryResult.h

– schema

Gets the schema of objects returned by Query alongwith objects themselves.

 //Obj-C
 [projectQuery execInBackground:^(ResponseType type, QueryResult *result, NSError *error) {
    NSArray *result = [result schema];
 }];

 //Swift
 projectQuery.execInBackground { (ResponseType, QueryResult!, NSError!) -> Void in
    var schema:Array  =  QueryResult.schema()
 }
- (BUILT_NULLABLE NSArray *)schema

Return Value

Returns schemas.

Declared In

QueryResult.h

– content_type

Gets the content type of objects returned by Query alongwith objects themselves.

 //Obj-C
 [projectQuery execInBackground:^(ResponseType type, QueryResult *result, NSError *error) {
     NSDictionary *result = [result content_type];
 }];

 //Swift
 projectQuery.execInBackground { (ResponseType, QueryResult!, NSError!) -> Void in
     var schema:NSDictionary  =  QueryResult.content_type()
 }
- (BUILT_NULLABLE NSDictionary *)content_type

Return Value

Returns content type.

Declared In

QueryResult.h

Count

– totalCount

Count of number of entries returned by Query alongwith entries themselves.

 //Obj-C
 [blogQuery execInBackground:^(ResponseType type, QueryResult *result, NSError *error) {
    NSInteger totalCount = [result totalCount];// totalcount
 }];

 //Swift
 blogQuery.execInBackground { (responseType, result!, error!) -> Void in
    var total:Int  =  result.totalCount()
 }
- (NSInteger)totalCount

Return Value

Returns the count of number of object returned by Query.

Declared In

QueryResult.h