java.lang.Object | |
↳ | com.mapsted.positioning.FilerRepository |
Nested Classes | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
interface | FilerRepository.Callback | ||||||||||
interface | FilerRepository.ProgressListener |
Constants | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
String | PRESET_PARENT_DIR_MAP_STYLE | a preset subfolder name for map style files | |||||||||
String | PRESET_PARENT_DIR_MAP_TILES | a preset subfolder name for map tile files |
Public Constructors | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
FilerRepository(Context context, WebApiClient webApiClient) |
Public Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
File |
findFile(String filerId)
finds the file for this filerId in the local repository.
| ||||||||||
void | getFile(String filerId, FilerRepository.Callback callback) | ||||||||||
void |
getFile(String filerId, String parentDir, FilerRepository.Callback callback, FilerRepository.ProgressListener progressListener)
retrieves the file in background thread with the given filerId.
| ||||||||||
void | onDestroy() | ||||||||||
boolean | removeFile(String filerId) |
[Expand]
Inherited Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
![]() |
a preset subfolder name for map style files
a preset subfolder name for map tile files
finds the file for this filerId in the local repository. If not found, returns null;
callback | callback with path to the file. If the file is not found, it will be downloaded. |
---|
retrieves the file in background thread with the given filerId. If the file is not found in local repository, then it is downloaded from the filer remote server. The downloaded file is stored in the parentDir.
filerId | filerId of file. |
---|---|
parentDir | subdirectory to store in. The file downloaded is stored in a dedicated folder for filer files.
If parentDir is given, it will be stored in following folder structure `$filerRoot/$parentDir/$downloaded_file`.
To get reference to the downloaded file use the callback. If parentDir is null `$filerRoo/$downloaded_file`
see also PRESET_PARENT_DIR_MAP_STYLE PRESET_PARENT_DIR_MAP_TILES |
callback | callback with the file. To get the path to file, use this file. |