Package com.mapfactor.sdk.imports
Interface ImportsManager
public interface ImportsManager
Imports manager
- Since:
- 1.5
-
Nested Class Summary
Modifier and TypeInterfaceDescriptionstatic interface
Incremental import data adding listenerstatic interface
Incremental import category creation listenerstatic enum
Creating incremental import category resultstatic interface
Incremental import category deletion listenerstatic interface
Incremental import data deleting listenerstatic interface
Import categories list ready listenerstatic interface
Incremental import data updating listener -
Method Summary
Modifier and TypeMethodDescriptionvoid
addIncrementalImportData
(String categoryName, List<ImportData> importDataList, ImportsManager.AddIncrementalImportDataListener listener) Add data to specified incremental importvoid
createIncrementalImportCategory
(String categoryName, String icon, float hotSpotX, float hotSpotY, ImportsManager.CreateIncrementalImportCategoryListener listener) Create incremental import category.void
deleteIncrementalImportCategory
(String categoryName, ImportsManager.DeleteIncrementalImportCategoryListener listener) Delete incremental import category and all data in itvoid
deleteIncrementalImportData
(long[] importDataIds, ImportsManager.DeleteIncrementalImportDataListener listener) Delete incremental import datavoid
getImportCategories
(ImportCategory.Type importType, ImportsManager.ImportCategoriesListener listener) Get imported categoriesvoid
importFile
(List<android.net.Uri> sourceUris, boolean overwriteExisting, FileImportListener importListener) Import app data from specified source.void
updateIncrementalImportData
(List<android.util.Pair<Long, ImportData>> importIdAndDataList, ImportsManager.UpdateIncrementalImportDataListener listener) Update incremental import data
-
Method Details
-
importFile
void importFile(@NonNull List<android.net.Uri> sourceUris, boolean overwriteExisting, @Nullable FileImportListener importListener) Import app data from specified source. This is a one-time import and cannot be modified later. Data is deleted viaAppDataManager.deleteAppData(List, DataDeleteListener)
.- Parameters:
sourceUris
- list pf source URIs to import data fromoverwriteExisting
- true to overwrite files that already exists in SDK data directoryimportListener
- listener called on import status change- Since:
- 1.5
-
createIncrementalImportCategory
void createIncrementalImportCategory(@NonNull String categoryName, @Nullable String icon, @FloatRange(from=0.0,to=1.0) float hotSpotX, @FloatRange(from=0.0,to=1.0) float hotSpotY, @Nullable ImportsManager.CreateIncrementalImportCategoryListener listener) Create incremental import category. UseaddIncrementalImportData(String, List, AddIncrementalImportDataListener)
to add data to it.- Parameters:
categoryName
- category nameicon
- category map icon. PNG file is required, 64x64 pixels recommended.hotSpotX
- icon hot spot in horizontal dimension defining precise icon placement. Value of 0.0 means that left side of the icon will be on the icon coordinate, 0.5 middle of the icon and 1.0 right side of the icon. Ignored when icon parameter is null.hotSpotY
- icon hot spot in vertical dimension defining precise icon placement. Value of 0.0 means that top side of the icon will be on the icon coordinate, 0.5 middle of the icon and 1.0 bottom side of the icon. Ignored when icon parameter is null.listener
- listener called when category creation is finished- Since:
- 1.5
-
deleteIncrementalImportCategory
void deleteIncrementalImportCategory(@NonNull String categoryName, @Nullable ImportsManager.DeleteIncrementalImportCategoryListener listener) Delete incremental import category and all data in it- Parameters:
categoryName
- category namelistener
- listener called when category deletion is finished- Since:
- 3.16
-
getImportCategories
void getImportCategories(@Nullable ImportCategory.Type importType, @NonNull ImportsManager.ImportCategoriesListener listener) Get imported categories- Parameters:
importType
- import type. All import types if null.listener
- listener to receive imported categories list- Since:
- 1.5
-
addIncrementalImportData
void addIncrementalImportData(@NonNull String categoryName, @NonNull List<ImportData> importDataList, @Nullable ImportsManager.AddIncrementalImportDataListener listener) Add data to specified incremental import- Parameters:
categoryName
- import category previously created bycreateIncrementalImportCategory(String, String, float, float,CreateIncrementalImportCategoryListener)
importDataList
- list of data to importlistener
- listener called when adding data is finished- Since:
- 1.5
-
deleteIncrementalImportData
void deleteIncrementalImportData(@NonNull long[] importDataIds, @Nullable ImportsManager.DeleteIncrementalImportDataListener listener) Delete incremental import data- Parameters:
importDataIds
- list of data IDs to delete from import (data ID returned via AddIncrementalImportDataListener)listener
- listener called when deleting data is finished- Since:
- 3.16
-
updateIncrementalImportData
void updateIncrementalImportData(@NonNull List<android.util.Pair<Long, ImportData>> importIdAndDataList, @Nullable ImportsManager.UpdateIncrementalImportDataListener listener) Update incremental import data- Parameters:
importIdAndDataList
- list of pairs of data IDs and new values to update (data ID returned via AddIncrementalImportDataListener)*listener
- called when updating data is finished- Since:
- 3.19
-