MapsIndoors iOS SDK V3
Loading...
Searching...
No Matches
Instance Methods | Class Methods | Protected Types | Properties | List of all members
MPAppDataProvider Class Reference

#include <MPAppDataProvider.h>

Inheritance diagram for MPAppDataProvider:

Instance Methods

(void) - getAppDataWithCompletion:
 
(void) - getAppData
 

Class Methods

(BOOL) + isOfflineDataAvailableForSolutionId:language:
 

Protected Types

typedef void(^ mpAppDataHandlerBlockType) (MPAppData *_Nullable appData, NSError *_Nullable error)
 

Properties

id< MPAppDataProviderDelegatedelegate
 

Detailed Description

The app data provider acts as a service for the metadata (MPAppData) of a MapsIndoors app solution.

Member Typedef Documentation

◆ mpAppDataHandlerBlockType

- (typedef void(^ mpAppDataHandlerBlockType) (MPAppData *_Nullable appData, NSError *_Nullable error))
protected

Callback block for getting app data or handling error in doing so.

Parameters
appDataApp metadata object. Will be nil if an error occurred
errorError object. Will be nil if fetching was complete

Method Documentation

◆ getAppData

- (void) getAppData

Get app metadata. Assign a delegate object to this instance in order to handle the data fetch.

◆ getAppDataWithCompletion:

- (void) getAppDataWithCompletion: (nullable mpAppDataHandlerBlockType) handler

Get app metadata and handle the data with a callback block

Parameters
handlerData fetch and error callback handler block

◆ isOfflineDataAvailableForSolutionId:language:

+ (BOOL) isOfflineDataAvailableForSolutionId: (NSString *) solutionId
language: (NSString *) language 

Determine if cached or preloaded data is available for the given solutionId.

Parameters
solutionIdSolutionId to check for offline data availability.
languageLanguage to check for offline data availability.
Returns
YES if offline or preloaded data is available, else NO,

Property Documentation

◆ delegate

- (id<MPAppDataProviderDelegate>) delegate
readwritenonatomicweak

Delegate object. This is another way of handling data fetching. Using completionHandler block instead is recommended.