HERE iOS SDK Developer's Guide

NMACLE2Request

Class Summary

class NMACLE2Request

Derived from: NSObject

Represents a base interface for a search request.

Include: NMAKit.framework/headers/NMACLE2Request.h

Inheritance Diagrams

Figure 1. Public inheritance diagram for NMACLE2Request

[For complete information, see the section Class Details]

Public Property Summary

Table 1. Public Properties
Public Properties

[readable, writable, assign] BOOL  cachingEnabled

Set if received geometries should be stored locally

[readable, writable, assign] NMACLE2ConnectivityMode   connectivityMode

Set or get how the query should be performed

[readable, writable, assign] NMACLE2GeometryType   geometryType

Specifies the geometry type given in the result

[readable, writable, assign] NSString *  query

Specifies the filter(s) to be used for a custom location request

Instance Method Summary

Table 2. Instance Methods
Instance Method Summary

-(void) cancel

Cancels a previously triggered request execution

-(nullable NSError *) startWithBlock:( NMACLE2RequestCompletionBlock _Nonnull) block

Invokes an asynchronous query request with a specified block

-(nullable NSError *) startWithListener:(nonnull id< NMACLE2ResultListener >) listener

Invokes an asynchronous query request with a specified listener

Class Details

Represents a base interface for a search request.

Public Property Details

[readable, writable, assign] BOOL cachingEnabled

Set if received geometries should be stored locally. Default is NO.

[readable, writable, assign] NMACLE2ConnectivityMode  connectivityMode

Set or get how the query should be performed. See NMACLE2ConnectivityMode. If not set, the default is NMACLE2ConnectivityModeOnline

[readable, writable, assign] NMACLE2GeometryType  geometryType

Specifies the geometry type given in the result. If the request was executed in offline mode, this parameter will be ignored. Caching (if enabled) is not performed if geometryType is "local".

[readable, writable, assign] NSString * query

Specifies the filter(s) to be used for a custom location request. When specified, only geometries where expression evaluates to true will be returned.

The string should be a JavaScript expression which will be evaluated for each geometry.

Note:

An example query is: "RATING > 3 &amp;amp;&amp;amp; NAME != 'MyPlace23'" where RATING and NAME are column/field names.

Instance Method Details

-(void) cancel

Cancels a previously triggered request execution. Cancelled requests will have their completion handler or listener called with the respective NMACLE2Error.

-(nullable NSError *) startWithBlock:( NMACLE2RequestCompletionBlock _Nonnull) block

Invokes an asynchronous query request with a specified block.

Note:

NMARequestErrorOperationNotAllowed indicates access to this operation is denied. Contact your HERE representative for more information.

Parameters:

  • block

    A block to be executed upon completion of the request (runs by default on main queue).

Returns:

NMACLE2ErrorInvalidParameter if no listener is passed, nil otherwise

See also:

NMACLE2RequestCompletionBlock

startWithListener:

-(nullable NSError *) startWithListener:(nonnull id< NMACLE2ResultListener >) listener

Invokes an asynchronous query request with a specified listener.

Note:

NMARequestErrorOperationNotAllowed indicates access to this operation is denied. Contact your HERE representative for more information.

Parameters:

  • listener

    A listener to listen for search results

Returns:

NMACLE2ErrorInvalidParameter if no listener is passed, nil otherwise

See also:

startWithBlock: