Inherits from NMCore : NSObject
Declared in NMService.h
NMService.m

Overview

NMService class is used to perform regarding query operations over NMContent objects saved on cloud. This class also contains the relevant methods configure the settings about query issues.

Tasks

Properties

__deprecated

Identifier of the NMService object that is equal to the identifier of created NMContent objects.

@property (nonatomic, strong) NSString *__deprecated

Discussion

Identifier of the NMService object that is equal to the identifier of created NMContent objects.

Declared In

NMService.h

identifier

Identifier of the NMService object that is equal to the identifier of created NMContent objects.

@property (nonatomic, strong) NSString *identifier

Discussion

Identifier of the NMService object that is equal to the identifier of created NMContent objects.

Declared In

NMService.h

max

Maximum number of the NMContent objects returned from calling query method.

@property (nonatomic, setter=setMax:) int max

Discussion

Maximum number of the NMContent objects returned from calling query method.

Declared In

NMService.h

page

Number of the page that returns the NMContent objects for calling query method.

@property (nonatomic, setter=setPage:) int page

Discussion

Number of the page that returns the NMContent objects for calling query method.

If the number of the NMContent objects returned from the calling query method is bigger than ‘max’ property of caller NMService object, contents are divided into the pages. In order to access all the contents, you should enumerate all of the pages. The first page is zero.

Declared In

NMService.h

searchText

String value for full-text search over string attributes of a pile of NMContent objects.

@property (nonatomic, strong) NSString *searchText

Discussion

String value for full-text search over string attributes of a pile of NMContent objects.

Declared In

NMService.h

sortBy

Name of the key which holds the value used to sort a pile of contents.

@property (nonatomic, strong) NSString *sortBy

Discussion

Name of the key which holds the value used to sort a pile of contents.

Declared In

NMService.h

sortOrder

Enum type of order to use while sorting a pile of contents.

@property (nonatomic) enum NMSortOrder sortOrder

Discussion

Enum type of order to use while sorting a pile of contents.

Warning: Available enum options for sort order

SortOrderAscending, sorts contents by increasing order

SortOrderDescending, sorts contents by decreasing order

Declared In

NMService.h

Class Methods

cacheExpirationInterval

Returns the interval value when the contents will be deleted from the cache.

+ (NSTimeInterval)cacheExpirationInterval

Return Value

returns the cache expiration value.

Discussion

Returns the interval value when the contents will be deleted from the cache.

Declared In

NMService.h

cacheType

Returns the type of the Cache to use while searching.

+ (enum NMCacheType)cacheType

Return Value

Current cache type for search methods.

Discussion

Returns the type of the Cache to use while searching.

Warning: Available enum options to set cache type:

CacheTypeNoCache, Queries does not add and retrieve results to cache.

CacheTypeFromCache, Queries retrieve results from the cache.

CacheTypeFromNetwork, Queries retrieve results from the network and add results into the cache.

CacheTypeFirstCacheThenNetwork, Queries first tries to get results from cache, if it cannot find then tries to get from network.

CacheTypeFirstNetworkThenCache, Queries first tries to get results from network, if it cannot find then tries to get from cache.

Declared In

NMService.h

clearCache

Removes all data saved in the cache.

+ (void)clearCache

Discussion

Removes all data saved in the cache.

Declared In

NMService.h

setCacheExpirationInterval:

Sets the expiration value for the time interval when the cached contents will be deleted.

+ (void)setCacheExpirationInterval:(NSTimeInterval)interval

Parameters

interval

The expiration value for cache mechanism.

Discussion

Sets the expiration value for the time interval when the cached contents will be deleted.

Declared In

NMService.h

setCacheType:

Sets the enum value for cache type of search methods.

+ (void)setCacheType:(enum NMCacheType)cacheType

Parameters

cacheType

The enum value for the cache type.

Discussion

Sets the enum value for cache type of search methods.

Warning: Available enum options to set cache type:

CacheTypeNoCache, Queries does not add and retrieve results to cache.

CacheTypeFromCache, Queries retrieve results from the cache.

CacheTypeFromNetwork, Queries retrieve results from the network and add results into the cache.

CacheTypeFirstCacheThenNetwork, Queries first tries to get results from cache, if it cannot find then tries to get from network.

CacheTypeFirstNetworkThenCache, Queries first tries to get results from network, if it cannot find then tries to get from cache.

Declared In

NMService.h

Instance Methods

addSearchText:

Adds a value for full-text search over string attributes of a pile of NMContent objects into the query.

- (void)addSearchText:(NSString *)searchText

Parameters

searchText

String value for full-text search.

Discussion

Adds a value for full-text search over string attributes of a pile of NMContent objects into the query.

Declared In

NMService.h

boxSearchInBackgroundFirstLocation:secondLocation:locationSearchField:completionHandler:

Fetches a list of NMContent objects which are placed within the box area created with the given location coordinates on the background thread.

- (void)boxSearchInBackgroundFirstLocation:(NMGeolocation *)firstPoint secondLocation:(NMGeolocation *)secondPoint locationSearchField:(NSString *)alocationSearchField completionHandler:(void ( ^ ) ( NSArray *contentArray , NSError *error ))handler

Parameters

firstPoint

Any of the locations which is one of the corners of the box area.

secondPoint

Diagonal location of the one given as the firstPoint paramater.

handler

The block to execute when fetch of the content(s) within the box area is completed.

locationSearchField

The name of the key which value is the location data.

Discussion

Fetches a list of NMContent objects which are placed within the box area created with the given location coordinates on the background thread.

As background methods does not block your main thread, it is recommended to use boxSearchInBackgroundWithStartLocation:diagonalLocation:key:completionHandler: over boxSearchWithFirstLocation:andSecondLocation:andlocationSearchField:withError:.

Declared In

NMService.h

boxSearchInBackgroundWithStartLocation:diagonalLocation:key:completionHandler:

Fetches a list of NMContent objects which are placed within the box area created with the given location coordinates on the background thread.

- (void)boxSearchInBackgroundWithStartLocation:(NMGeolocation *)startLocation diagonalLocation:(NMGeolocation *)diagonalLocation key:(NSString *)key completionHandler:(void ( ^ ) ( NSArray *contentArray , NSError *error ))handler

Parameters

startLocation

Any of the locations which is one of the corners of the box area.

diagonalLocation

Diagonal location of the one given as the firstPoint paramater.

key

The name of the key which value is the location data.

handler

The block to execute when fetch of the content(s) within the box area is completed.

Discussion

Fetches a list of NMContent objects which are placed within the box area created with the given location coordinates on the background thread.

As background methods does not block your main thread, it is recommended to use boxSearchInBackgroundWithStartLocation:diagonalLocation:key:completionHandler: over boxSearchWithStartLocation:diagonalLocation:key:error:.

Declared In

NMService.h

boxSearchWithFirstLocation:andSecondLocation:andlocationSearchField:withError:

Fetches a list of NMContent objects which are placed within the box area created with the given location coordinates.

- (NSArray *)boxSearchWithFirstLocation:(NMGeolocation *)firstPoint andSecondLocation:(NMGeolocation *)secondPoint andlocationSearchField:(NSString *)locationSearchField withError:(NSError **)error

Parameters

firstPoint

Any of the locations which is one of the corners of the box area.

secondPoint

Diagonal location of the one given as the firstPoint paramater.

locationSearchField

The name of the key which value is the location data.

error

On input, a pointer to an error object. If an error occurs, this pointer is set to an actual error object containing the error information. You may specify nil for this parameter if you do not want the error information.

Return Value

The list of the content(s) located within the given area.

Discussion

Fetches a list of NMContent objects which are placed within the box area created with the given location coordinates.

Declared In

NMService.h

boxSearchWithStartLocation:diagonalLocation:key:error:

Fetches a list of NMContent objects which are placed within the box area created with the given location coordinates.

- (NSArray *)boxSearchWithStartLocation:(NMGeolocation *)startLocation diagonalLocation:(NMGeolocation *)diagonalLocation key:(NSString *)key error:(NSError **)error

Parameters

startLocation

Any of the locations which is one of the corners of the box area.

diagonalLocation

Diagonal location of the one given as the startLocation paramater.

key

The name of the key which value is the location data.

error

On input, a pointer to an error object. If an error occurs, this pointer is set to an actual error object containing the error information. You may specify nil for this parameter if you do not want the error information.

Return Value

The list of the content(s) located within the given area.

Discussion

Fetches a list of NMContent objects which are placed within the box area created with the given location coordinates.

Declared In

NMService.h

circleSearchInBackgroundStartLocation:distance:locationSearchField:completionHandler:

Fetches a list of NMContent objects which are placed within the range of the given distance around the specified center location on the background thread.

- (void)circleSearchInBackgroundStartLocation:(NMGeolocation *)startLocation distance:(double)distance locationSearchField:(NSString *)alocationSearchField completionHandler:(void ( ^ ) ( NSArray *contentArray , NSError *error ))handler

Parameters

startLocation

Center location to search the contents around it.

distance

Radius of the search area.

handler

The block to execute when fetch of the content(s) within the circle area is completed.

locationSearchField

Alphanumeric string that represents the key value which contains the location data.

Discussion

Fetches a list of NMContent objects which are placed within the range of the given distance around the specified center location on the background thread.

As background methods does not block your main thread, it is recommended to use circleSearchInBackgroundWithLocation:radius:key:completionHandler over circleSearchWithStartLocation:andDistance:andLocationSearchField:error.

Declared In

NMService.h

circleSearchInBackgroundWithLocation:radius:key:completionHandler:

Fetches a list of NMContent objects which are placed within the range of the given distance around the specified center location on the background thread.

- (void)circleSearchInBackgroundWithLocation:(NMGeolocation *)centerLocation radius:(double)radius key:(NSString *)key completionHandler:(void ( ^ ) ( NSArray *contentArray , NSError *error ))handler

Parameters

centerLocation

Center location to search the contents around it.

radius

Radius of the search area.

key

Alphanumeric string that represents the key value which contains the location data.

handler

The block to execute when fetch of the content(s) within the circle area is completed.

Discussion

Fetches a list of NMContent objects which are placed within the range of the given distance around the specified center location on the background thread.

As background methods does not block your main thread, it is recommended to use circleSearchInBackgroundWithLocation:radius:key:completionHandler over circleSearchWithStartLocation:andDistance:andLocationSearchField:error.

Declared In

NMService.h

circleSearchWithLocation:radius:key:error:

Fetches a list of NMContent objects which are placed within the range of the given distance around the specified center location.

- (NSArray *)circleSearchWithLocation:(NMGeolocation *)centerLocation radius:(double)radius key:(NSString *)key error:(NSError **)error

Parameters

centerLocation

Center location to search the contents around it.

radius

Radius of the search area.

key

Alphanumeric string that represents the key value which contains the location data.

error

On input, a pointer to an error object. If an error occurs, this pointer is set to an actual error object containing the error information. You may specify nil for this parameter if you do not want the error information.

Return Value

The list of the content(s) located within the given area.

Discussion

Fetches a list of NMContent objects which are placed within the range of the given distance around the specified center location.

Declared In

NMService.h

circleSearchWithStartLocation:andDistance:andlocationSearchField:withError:

Fetches a list of NMContent objects which are placed within the range of the given distance around the specified center location.

- (NSArray *)circleSearchWithStartLocation:(NMGeolocation *)startLocation andDistance:(double)distance andlocationSearchField:(NSString *)locationSearchField withError:(NSError **)error

Parameters

startLocation

Center location to search the contents around it.

distance

Radius of the search area.

locationSearchField

Alphanumeric string that represents the key value which contains the location data.

error

On input, a pointer to an error object. If an error occurs, this pointer is set to an actual error object containing the error information. You may specify nil for this parameter if you do not want the error information.

Return Value

The list of the content(s) which meet the location search criterias.

Discussion

Fetches a list of NMContent objects which are placed within the range of the given distance around the specified center location.

Declared In

NMService.h

count:

Returns the total number of the NMContent objects matching the search query.

- (long)count:(NSError **)error

Parameters

error

On input, a pointer to an error object. If an error occurs, this pointer is set to an actual error object containing the error information. You may specify nil for this parameter if you do not want the error information.

Return Value

The number of the contents for the relevant query.

Discussion

Returns the total number of the NMContent objects matching the search query.

Declared In

NMService.h

countContentsInBackgroundWithCompletionHandler:

Returns the total number of the NMContent objects matching the search query on the background thread.

- (void)countContentsInBackgroundWithCompletionHandler:(void ( ^ ) ( long , NSError *error ))handler

Parameters

handler

The block to execute when fetch of the count of the content(s) is completed.

Discussion

Returns the total number of the NMContent objects matching the search query on the background thread.

As background methods does not block your main thread, it is recommended to use countContentsInBackgroundWithCompletionHandler: over countContentsWithError:.

Declared In

NMService.h

countContentsWithError:

Returns the total number of the NMContent objects matching the search query.

- (long)countContentsWithError:(NSError **)error

Parameters

error

On input, a pointer to an error object. If an error occurs, this pointer is set to an actual error object containing the error information. You may specify nil for this parameter if you do not want the error information.

Return Value

The number of the contents for the relevant query.

Discussion

Returns the total number of the NMContent objects matching the search query.

Declared In

NMService.h

countInBackgroundWithCompletionHandler:

Returns the total number of the NMContent objects matching the search query on the background thread.

- (void)countInBackgroundWithCompletionHandler:(void ( ^ ) ( NSNumber *count , NSError *error ))handler

Parameters

handler

The block to execute when fetch of the count of the content(s) is completed.

Discussion

Returns the total number of the NMContent objects matching the search query on the background thread.

As background methods does not block your main thread, it is recommended to use countContentsInBackgroundWithCompletionHandler: over count:.

Declared In

NMService.h

get:

Fetches the single NMContent object which path is equal to the value set to path property of the caller object.

- (id)get:(NSError **)error

Parameters

error

On input, a pointer to an error object. If an error occurs, this pointer is set to an actual error object containing the error information. You may specify nil for this parameter if you do not want the error information.

Return Value

The NMContent object requested for the setting path.

Discussion

Fetches the single NMContent object which path is equal to the value set to path property of the caller object.

The relevant path value is obtained from ‘Content Browser’ segment of your application on Netmera website.

Declared In

NMService.h

getContentAtPath:error:

Fetches the single NMContent object which path is equal to the value set to path parameter.

- (id)getContentAtPath:(NSString *)path error:(NSError **)error

Parameters

path

The unique string id for the requested NMContent object.

error

On input, a pointer to an error object. If an error occurs, this pointer is set to an actual error object containing the error information. You may specify nil for this parameter if you do not want the error information.

Return Value

The NMContent object requested for the relevant path.

Discussion

Fetches the single NMContent object which path is equal to the value set to path parameter.

The relevant path value is obtained from ‘Content Browser’ segment of your application on Netmera website.

Declared In

NMService.h

getContentAtPathInBackground:completionHandler:

Fetches the single NMContent object which path is equal to the value set to path parameter on the background thread.

- (void)getContentAtPathInBackground:(NSString *)path completionHandler:(void ( ^ ) ( id content , NSError *error ))handler

Parameters

path

The unique string id for the requested NMContent object.

handler

The block to execute when fetch of the content is completed.

Discussion

Fetches the single NMContent object which path is equal to the value set to path parameter on the background thread.

As background methods does not block your main thread, it is recommended to use getContentAtPathInBackground:completionHandler: over getContentAtPath:error:.

Declared In

NMService.h

getContentsAtPaths:error:

Fetches a list of NMContent objects with the given path list.

- (NSArray *)getContentsAtPaths:(NSArray *)pathList error:(NSError **)error

Parameters

pathList

The array of the paths for requested NMContent objects.

error

On input, a pointer to an error object. If an error occurs, this pointer is set to an actual error object containing the error information. You may specify nil for this parameter if you do not want the error information.

Return Value

The list of the NMContent objects for the requested path list.

Discussion

Fetches a list of NMContent objects with the given path list.

Warning: Default values for the ‘max’ property is 10 and ‘page’ property 0. This means this method returns 10 result in each page. It skips page * max in each iteration.

The relevant path values are obtained from ‘Content Browser’ segment of your application on Netmera website.

Declared In

NMService.h

getContentsAtPathsInBackground:completionHandler:

Fetches a list of NMContent objects with the given path list.

- (void)getContentsAtPathsInBackground:(NSArray *)pathList completionHandler:(void ( ^ ) ( NSArray *contentArray , NSError *error ))handler

Parameters

pathList

The array of the paths for requested NMContent objects.

handler

The block to execute when fetch of the content(s) is completed.

Discussion

Fetches a list of NMContent objects with the given path list.

Warning: Default values for the ‘max’ property is 10 and ‘page’ property 0. This means this method returns 10 result in each page. It skips page * max in each iteration.

As background methods does not block your main thread, it is recommended to use getContentsAtPathsInBackground:completionHandler: over getContentsAtPaths:error:.

Declared In

NMService.h

getCustomCondition

Returns the single query formed by merging all query options.

- (NSString *)getCustomCondition

Return Value

NSString representation of the list of the query options added as a search criteria.

Discussion

Returns the single query formed by merging all query options.

Declared In

NMService.h

getInBackgroundWithCompletionHandler:

Fetches the single NMContent object which path is equal to the value set to path property of the caller object on the background thread.

- (void)getInBackgroundWithCompletionHandler:(void ( ^ ) ( NMContent *content , NSError *error ))handler

Parameters

handler

The block to execute when fetch of the content is completed.

Discussion

Fetches the single NMContent object which path is equal to the value set to path property of the caller object on the background thread.

As background methods does not block your main thread, it is recommended to use getContentAtPathInBackground:completionHandler: over get:.

Declared In

NMService.h

getUsersWithError:

Fetches a list of NMUser objects matching the search query.

- (NSArray *)getUsersWithError:(NSError **)error

Parameters

error

On input, a pointer to an error object. If an error occurs, this pointer is set to an actual error object containing the error information. You may specify nil for this parameter if you do not want the error information.

Return Value

The list of the NMUser object(s) for the specified query.

Discussion

Fetches a list of NMUser objects matching the search query.

Declared In

NMService.h

initWithIdentifier:

Initializes the newly allocated NMService object with the specified identifier value.

- (id)initWithIdentifier:(NSString *)identifier

Parameters

identifier

Identifier of the NMService object.

Return Value

An initialized NMService object.

Discussion

Initializes the newly allocated NMService object with the specified identifier value.

Declared In

NMService.h

initWithName:

Initializes the newly allocated NMService object with the specified identifier value.

- (id)initWithName:(NSString *)objectName

Parameters

identifier

Identifier of the NMService object.

Return Value

An initialized NMService object.

Discussion

Initializes the newly allocated NMService object with the specified identifier value.

Declared In

NMService.h

search:

Fetches a list of NMContent objects matching the search query.

- (NSArray *)search:(NSError **)error

Parameters

error

On input, a pointer to an error object. If an error occurs, this pointer is set to an actual error object containing the error information. You may specify nil for this parameter if you do not want the error information.

Discussion

Fetches a list of NMContent objects matching the search query.

Warning: Default values for the ‘max’ property is 10 and ‘page’ property 0. This means this method returns 10 result in each page. It skips page * max in each iteration.

Declared In

NMService.h

searchContentsInBackgroundWithCompletionHandler:

Fetches a list of NMContent objects matching the search query on the background thread.

- (void)searchContentsInBackgroundWithCompletionHandler:(void ( ^ ) ( NSArray *contentArray , NSError *error ))handler

Parameters

handler

The block to execute when fetch of the content(s) is completed.

Discussion

Fetches a list of NMContent objects matching the search query on the background thread.

Warning: Default values for the ‘max’ property is 10 and ‘page’ property 0. This means this method returns 10 result in each page. It skips page * max in each iteration.

As background methods does not block your main thread, it is recommended to use searchContentsInBackgroundWithCompletionHandler: over searchContentsWithError:.

Declared In

NMService.h

searchContentsWithError:

Fetches a list of NMContent objects matching the search query.

- (NSArray *)searchContentsWithError:(NSError **)error

Parameters

error

On input, a pointer to an error object. If an error occurs, this pointer is set to an actual error object containing the error information. You may specify nil for this parameter if you do not want the error information.

Discussion

Fetches a list of NMContent objects matching the search query.

Warning: Default values for the ‘max’ property is 10 and ‘page’ property 0. This means this method returns 10 result in each page. It skips page * max in each iteration.

Declared In

NMService.h

searchInBackgroundWithCompletionHandler:

Fetches a list of NMContent objects matching the search query on the background thread.

- (void)searchInBackgroundWithCompletionHandler:(void ( ^ ) ( NSArray *contentArray , NSError *error ))handler

Parameters

handler

The block to execute when fetch of the content(s) is completed.

Discussion

Fetches a list of NMContent objects matching the search query on the background thread.

Warning: Default values for the ‘max’ property is 10 and ‘page’ property 0. This means this method returns 10 result in each page. It skips page * max in each iteration.

As background methods does not block your main thread, it is recommended to use searchContentsInBackgroundWithCompletionHandler: over search:.

Declared In

NMService.h

searchUser:

Fetches a list of NMUser objects matching the search query.

- (NSArray *)searchUser:(NSError **)error

Parameters

error

On input, a pointer to an error object. If an error occurs, this pointer is set to an actual error object containing the error information. You may specify nil for this parameter if you do not want the error information.

Return Value

The list of the NMUser object(s) for the specified query.

Discussion

Fetches a list of NMUser objects matching the search query.

Declared In

NMService.h

whereAllContainedInWithKey:andValues:

Adds an option into the query where filters the contents which values of the given key match all of the values in the given collection.

- (NMService *)whereAllContainedInWithKey:(NSString *)key andValues:(NSArray *)values

Parameters

key

Alphanumeric string that represents the key value for the query.

values

The array of values associated with the specified key to filter the NMContent objects.

Return Value

Caller NMService object.

Discussion

Adds an option into the query where filters the contents which values of the given key match all of the values in the given collection.

Declared In

NMService.h

whereContainAllValuesIn:forKey:

Adds an option into the query where filters the contents which values of the given key match all of the values in the given collection.

- (NMService *)whereContainAllValuesIn:(NSArray *)values forKey:(NSString *)key

Parameters

values

The array of values associated with the specified key to filter the NMContent objects.

key

Alphanumeric string that represents the key value for the query.

Return Value

Caller NMService object.

Discussion

Adds an option into the query where filters the contents which values of the given key match all of the values in the given collection.

Declared In

NMService.h

whereContainAnyValueIn:forKey:

Adds an option into the query where filters the contents which values of the given key match any of the values in the given collection.

- (NMService *)whereContainAnyValueIn:(NSArray *)values forKey:(NSString *)key

Parameters

values

The array of values associated with the specified key to filter the NMContent objects.

key

Alphanumeric string that represents the key value for the query.

Return Value

Caller NMService object.

Discussion

Adds an option into the query where filters the contents which values of the given key match any of the values in the given collection.

Declared In

NMService.h

whereContainedInWithKey:andValues:

Adds an option into the query where filters the contents which values of the given key match any of the values in the given collection.

- (NMService *)whereContainedInWithKey:(NSString *)key andValues:(NSArray *)values

Parameters

key

Alphanumeric string that represents the key value for the query.

values

The array of values associated with the specified key to filter the NMContent objects.

Return Value

Caller NMService object.

Discussion

Adds an option into the query where filters the contents which values of the given key match any of the values in the given collection.

Declared In

NMService.h

whereEndWithValue:forKey:

Adds an option into the query which filters the contents which values of given key end with the given suffix.

- (NMService *)whereEndWithValue:(NSString *)suffix forKey:(NSString *)key

Parameters

key

Alphanumeric string that represents the key value for the query.

value

Suffix associated with the specified key to filter the NMContent objects.

Return Value

Caller NMService object.

Discussion

Adds an option into the query which filters the contents which values of given key end with the given suffix.

Declared In

NMService.h

whereEndWithValue:forKey:caseInsensitive:

Adds an option into the query which filters the contents which values of given key end with the given suffix.

- (NMService *)whereEndWithValue:(NSString *)suffix forKey:(NSString *)key caseInsensitive:(BOOL)flag

Parameters

key

Alphanumeric string that represents the key value for the query.

flag

The boolean value that determines whether the given suffix is case sensitive or not while filtering the NMContent objects.

value

Suffix associated with the specified key to filter the NMContent objects.

Return Value

Caller NMService object.

Discussion

Adds an option into the query which filters the contents which values of given key end with the given suffix.

Declared In

NMService.h

whereEndsWithKey:andSuffix:

Adds an option into the query which filters the contents which values of given key end with the given suffix.

- (NMService *)whereEndsWithKey:(NSString *)key andSuffix:(id)suffix

Parameters

key

Alphanumeric string that represents the key value for the query.

value

Suffix associated with the specified key to filter the NMContent objects.

Return Value

Caller NMService object.

Discussion

Adds an option into the query which filters the contents which values of given key end with the given suffix.

Declared In

NMService.h

whereEndsWithKey:suffix:caseInsensitive:

Adds an option into the query which filters the contents which values of given key end with the given suffix.

- (NMService *)whereEndsWithKey:(NSString *)key suffix:(id)suffix caseInsensitive:(BOOL)flag

Parameters

key

Alphanumeric string that represents the key value for the query.

flag

The boolean value that determines whether the given suffix is case sensitive or not while filtering the NMContent objects.

value

Suffix associated with the specified key to filter the NMContent objects.

Return Value

Caller NMService object.

Discussion

Adds an option into the query which filters the contents which values of given key end with the given suffix.

Declared In

NMService.h

whereEqualToOwner:

This is used to get the contents of the logged user.

- (NMService *)whereEqualToOwner:(NMUser *)user

Parameters

user

Current logged user.

Return Value

Caller NMService object.

Discussion

This is used to get the contents of the logged user.

Declared In

NMService.h

whereEqualToValue:forKey:

Adds an option into the query which filters the contents which values of given key are equal to the given value.

- (NMService *)whereEqualToValue:(id)value forKey:(NSString *)key

Parameters

value

Object value associated with the specified key to filter the NMContent objects.

key

Alphanumeric string that represents the key value for the query.

Return Value

Caller NMService object.

Discussion

Adds an option into the query which filters the contents which values of given key are equal to the given value.

Declared In

NMService.h

whereEqualWithKey:andValue:

Adds an option into the query which filters the contents which values of given key are equal to the given value.

- (NMService *)whereEqualWithKey:(NSString *)key andValue:(id)value

Parameters

key

Alphanumeric string that represents the key value for the query.

value

Object value associated with the specified key to filter the NMContent objects.

Return Value

Caller NMService object.

Discussion

Adds an option into the query which filters the contents which values of given key are equal to the given value.

Declared In

NMService.h

whereExist:forKey:

Adds an option into the query which filters the contents which contain the given key or not.

- (NMService *)whereExist:(BOOL)value forKey:(NSString *)key

Parameters

value

The boolean value to check the existance of the given key or not. If the value is YES then this filters the contents for the existance of the key; otherwise, it checks for the non-existance of the given key.

key

Alphanumeric string that represents the key value for the query.

Return Value

Caller NMService object.

Discussion

Adds an option into the query which filters the contents which contain the given key or not.

Declared In

NMService.h

whereExistsWithKey:andValue:

Adds an option into the query which filters the contents which contain the given key or not.

- (NMService *)whereExistsWithKey:(NSString *)key andValue:(BOOL)value

Parameters

key

Alphanumeric string that represents the key value for the query.

value

The boolean value to check the existance of the given key or not. If the value is YES then this filters the contents for the existance of the key; otherwise, it checks for the non-existance of the given key.

Return Value

Caller NMService object.

Discussion

Adds an option into the query which filters the contents which contain the given key or not.

Declared In

NMService.h

whereGreaterThanValue:forKey:

Adds an option into the query which filters the contents which values of given key are greater than the given value.

- (NMService *)whereGreaterThanValue:(id)value forKey:(NSString *)key

Parameters

value

Object value associated with the specified key to filter the NMContent objects.

key

Alphanumeric string that represents the key value for the query.

Return Value

Caller NMService object.

Discussion

Adds an option into the query which filters the contents which values of given key are greater than the given value.

Declared In

NMService.h

whereGreaterThanWithKey:andValue:

Adds an option into the query which filters the contents which values of given key are greater than the given value.

- (NMService *)whereGreaterThanWithKey:(NSString *)key andValue:(id)value

Parameters

key

Alphanumeric string that represents the key value for the query.

value

Object value associated with the specified key to filter the NMContent objects.

Return Value

Caller NMService object.

Discussion

Adds an option into the query which filters the contents which values of given key are greater than the given value.

Declared In

NMService.h

whereGreatherThanOrEqualToValue:forKey:

Adds an option into the query which filters the contents which values of given key are greater than or equal to the given value.

- (NMService *)whereGreatherThanOrEqualToValue:(id)value forKey:(NSString *)key

Parameters

value

Object value associated with the specified key to filter the NMContent objects.

key

Alphanumeric string that represents the key value for the query.

Return Value

Caller NMService object.

Discussion

Adds an option into the query which filters the contents which values of given key are greater than or equal to the given value.

Declared In

NMService.h

whereGreatherThanOrEqualWithKey:andValue:

Adds an option into the query which filters the contents which values of given key are greater than or equal to the given value.

- (NMService *)whereGreatherThanOrEqualWithKey:(NSString *)key andValue:(id)value

Parameters

key

Alphanumeric string that represents the key value for the query.

value

Object value associated with the specified key to filter the NMContent objects.

Return Value

Caller NMService object.

Discussion

Adds an option into the query which filters the contents which values of given key are greater than or equal to the given value.

Declared In

NMService.h

whereLessThanOrEqualToValue:forKey:

Adds an option into the query which filters the contents which values of given key are less than or equal to the given value.

- (NMService *)whereLessThanOrEqualToValue:(id)value forKey:(NSString *)key

Parameters

value

Object value associated with the specified key to filter the NMContent objects.

key

Alphanumeric string that represents the key value for the query.

Return Value

Caller NMService object.

Discussion

Adds an option into the query which filters the contents which values of given key are less than or equal to the given value.

Declared In

NMService.h

whereLessThanOrEqualWithKey:andValue:

Adds an option into the query which filters the contents which values of given key are less than or equal to the given value.

- (NMService *)whereLessThanOrEqualWithKey:(NSString *)key andValue:(id)value

Parameters

key

Alphanumeric string that represents the key value for the query.

value

Object value associated with the specified key to filter the NMContent objects.

Return Value

Caller NMService object.

Discussion

Adds an option into the query which filters the contents which values of given key are less than or equal to the given value.

Declared In

NMService.h

whereLessThanValue:forKey:

Adds an option into the query which filters the contents which values of given key are less than the given value.

- (NMService *)whereLessThanValue:(id)value forKey:(NSString *)key

Parameters

value

Object value associated with the specified key to filter the NMContent objects.

key

Alphanumeric string that represents the key value for the query.

Return Value

Caller NMService object.

Discussion

Adds an option into the query which filters the contents which values of given key are less than the given value.

Declared In

NMService.h

whereLessThanWithKey:andValue:

Adds an option into the query which filters the contents which values of given key are less than the given value.

- (NMService *)whereLessThanWithKey:(NSString *)key andValue:(id)value

Parameters

key

Alphanumeric string that represents the key value for the query.

value

Object value associated with the specified key to filter the NMContent objects.

Return Value

Caller NMService object.

Discussion

Adds an option into the query which filters the contents which values of given key are less than the given value.

Declared In

NMService.h

whereMatchWithRegex:forKey:

Adds an option into the query which filters the contents which values of given key match the given regex.

- (NMService *)whereMatchWithRegex:(NSString *)regex forKey:(NSString *)key

Parameters

key

Alphanumeric string that represents the key value for the query.

value

Regex associated with the specified key to filter the NMContent objects.

Return Value

Caller NMService object.

Discussion

Adds an option into the query which filters the contents which values of given key match the given regex.

Declared In

NMService.h

whereMatchWithRegex:forKey:caseInsensitive:

Adds an option into the query which filters the contents which values of given key match the given regex.

- (NMService *)whereMatchWithRegex:(NSString *)regex forKey:(NSString *)key caseInsensitive:(BOOL)flag

Parameters

key

Alphanumeric string that represents the key value for the query.

flag

The boolean value that determines whether regex is case sensitive or not while filtering the NMContent objects.

value

Regex associated with the specified key to filter the NMContent objects.

Return Value

Caller NMService object.

Discussion

Adds an option into the query which filters the contents which values of given key match the given regex.

Declared In

NMService.h

whereMatchesWithKey:andRegex:

Adds an option into the query which filters the contents which values of given key match the given regex.

- (NMService *)whereMatchesWithKey:(NSString *)key andRegex:(NSString *)regex

Parameters

key

Alphanumeric string that represents the key value for the query.

value

Regex associated with the specified key to filter the NMContent objects.

Return Value

Caller NMService object.

Discussion

Adds an option into the query which filters the contents which values of given key match the given regex.

Declared In

NMService.h

whereMatchesWithKey:regex:caseInsensitive:

Adds an option into the query which filters the contents which values of given key match the given regex.

- (NMService *)whereMatchesWithKey:(NSString *)key regex:(NSString *)regex caseInsensitive:(BOOL)flag

Parameters

key

Alphanumeric string that represents the key value for the query.

flag

The boolean value that determines whether regex is case sensitive or not while filtering the NMContent objects.

value

Regex associated with the specified key to filter the NMContent objects.

Return Value

Caller NMService object.

Discussion

Adds an option into the query which filters the contents which values of given key match the given regex.

Declared In

NMService.h

whereNotEqualToValue:forKey:

Adds an option into the query which filters the contents which values of given key are not equal to the given value.

- (NMService *)whereNotEqualToValue:(id)value forKey:(NSString *)key

Parameters

value

Object value associated with the specified key to filter the NMContent objects.

key

Alphanumeric string that represents the key value for the query.

Return Value

Caller NMService object.

Discussion

Adds an option into the query which filters the contents which values of given key are not equal to the given value.

Declared In

NMService.h

whereNotEqualWithKey:andValue:

Adds an option into the query which filters the contents which values of given key are not equal to the given value.

- (NMService *)whereNotEqualWithKey:(NSString *)key andValue:(id)value

Parameters

key

Alphanumeric string that represents the key value for the query.

value

Object value associated with the specified key to filter the NMContent objects.

Return Value

Caller NMService object.

Discussion

Adds an option into the query which filters the contents which values of given key are not equal to the given value.

Declared In

NMService.h

whereOwnerEqual:

This is used to get the contents of the logged user.

- (NMService *)whereOwnerEqual:(NMUser *)user

Parameters

user

Current logged user.

Return Value

Caller NMService object.

Discussion

This is used to get the contents of the logged user.

Declared In

NMService.h

whereStartWithValue:forKey:

Adds an option into the query which filters the contents which values of given key begin with the given prefix.

- (NMService *)whereStartWithValue:(NSString *)prefix forKey:(NSString *)key

Parameters

key

Alphanumeric string that represents the key value for the query.

value

Prefix associated with the specified key to filter the NMContent objects.

Return Value

Caller NMService object.

Discussion

Adds an option into the query which filters the contents which values of given key begin with the given prefix.

Declared In

NMService.h

whereStartWithValue:forKey:caseInsensitive:

Adds an option into the query which filters the contents which values of given key begin with the given prefix.

- (NMService *)whereStartWithValue:(NSString *)prefix forKey:(NSString *)key caseInsensitive:(BOOL)flag

Parameters

key

Alphanumeric string that represents the key value for the query.

flag

The boolean value that determines whether the given prefix is case sensitive or not while filtering the NMContent objects.

value

Prefix associated with the specified key to filter the NMContent objects.

Return Value

Caller NMService object.

Discussion

Adds an option into the query which filters the contents which values of given key begin with the given prefix.

Declared In

NMService.h

whereStartsWithKey:andPrefix:

Adds an option into the query which filters the contents which values of given key begin with the given prefix.

- (NMService *)whereStartsWithKey:(NSString *)key andPrefix:(id)prefix

Parameters

key

Alphanumeric string that represents the key value for the query.

value

Prefix associated with the specified key to filter the NMContent objects.

Return Value

Caller NMService object.

Discussion

Adds an option into the query which filters the contents which values of given key begin with the given prefix.

Declared In

NMService.h

whereStartsWithKey:prefix:caseInsensitive:

Adds an option into the query which filters the contents which values of given key begin with the given prefix.

- (NMService *)whereStartsWithKey:(NSString *)key prefix:(id)prefix caseInsensitive:(BOOL)flag

Parameters

key

Alphanumeric string that represents the key value for the query.

flag

The boolean value that determines whether the given prefix is case sensitive or not while filtering the NMContent objects.

value

Prefix associated with the specified key to filter the NMContent objects.

Return Value

Caller NMService object.

Discussion

Adds an option into the query which filters the contents which values of given key begin with the given prefix.

Declared In

NMService.h