Synchronization

Synchronization

NAOSDK services need ressources for the SDK to provide users with a location. The services inputs (e.g. positioning database) can either be stored in your application assets or downloaded from NAO Cloud at runtime in a synchronization step. You can be notified of the synchronization result with a NAOSyncListener on Android or a NAOSyncDelegate on iOS.

This page shows the different available synchronization method.

Standard synchronization

  • On the NAOSDK service handle object you’ve created you can call the synchronization methods

Android

 public void synchronizeData(final NAOSyncListener listener)

iOS

(void)synchronizeData:(id<NAOSyncDelegate>)delegate;

Periodic synchronization

  • Since NAO® SDK V4.11.3, applications can now use the auto periodic synchronization.

How to configure on NAOCloud

Go to ‘Developer’ → ‘API Keys’ and click on your current apikey

 

You can now ‘Edit’ to configure the period in seconds

How to use with NAOSDK

The application must do a first synchronization to retrieve the configuration file, and each time the location service is started, the synchronization will automatically run with the period configured in the apikey.

Multisite synchronization

NAOSDK has a multisite mode, that works by combining several NAOCloud sites ressources under the same Apikey.

Using the standard synchronization with a multisite Apikey will download all the related ressources of all sites.

This can be an issue when the ressources total size is large.

Site list synchronization

  • You can choose the list of sites ressources you need to download (ex: ressource of a user favorite or user selected sites from your application)

Android

 public void synchronizeData(final NAOSyncListener listener, final ArrayList<String> siteIdsList)

iOS

(void)synchronizeData:(id<NAOSyncDelegate>)delegate forSites:(NSArray*)siteIds;

Auto synchronization

  • When the total size of the different sites ressources is large, you can let NAOSDK dynamically manage the download of the resources based on the user location.

Android

 public void synchronizeData(final NAOSyncListener listener, final Boolean auto)

iOS

(void)synchronizeData:(id<NAOSyncDelegate>)delegate withAutoSync:(bool)autoSync;
    • Related Articles

    • Release 21.09 (NAO SDK 4.11)

      Versions Component Version Hotfix Hotfix 21.09.01 NAO® Cloud 21.09.0 21.09.01 NAO® SDK iOS 4.11.3 4.11.4 4.11.5 NAO® SDK Android 4.11.3 4.11.4 4.11.5 NAO® Logger iOS 4.11.3 4.11.4 4.11.5 NAO® Logger Android 4.11.3 4.11.4 4.11.5 New Features NAO® SDK ...
    • Release 4.7

      Release V4.7.3 Date: 7 October 2019 Build: V4.7.3-R12788c6 New Features Bitcode support Improve rooftop indoor/outdoor transitions Fixed Issues Fix some crashes from crashlytics Release V4.7.2 Date: 24 June 2019 Build: V4.7.2-R549d3f1 New Features ...
    • Quick Start: Location Service

      The integration principle is the same accross all SDK services, so only the integration of the Location Service is detailed hereafter. Please refer to the API Reference Guide for details about other services. Initialize Location Service Import the ...
    • Flutter

      NAOSDK Flutter Plugin In the context of helping our customers and partners who want to develop their application with Flutter and use NAOSDK indoor location-based use cases, we have developed a version of a flutter plugin that makes it easy to embed ...
    • Integration workflow

      This page gives useful information for the project management aspect of the integration of the SDK. Planning and effort estimation for the integration of the SDK: Coding effort: 1 staff day per OS, integration support : 1 staff day Testing effort: 1 ...