GemUtil

object GemUtil

Public sdk util methods.

Functions

Link copied to clipboard
fun copyFile(srcPath: String, dstPath: String): Boolean

Copy file

Link copied to clipboard
fun fillLandmarkAddressInfo(mapView: MapView?, landmark: Landmark, fillCountryInfo: Boolean = false)

Fill landmark address info

Link copied to clipboard
fun formatLandmarkDetails(landmark: Landmark, excludeCountry: Boolean = false): String

Format landmark details

Link copied to clipboard
fun formatName(landmark: Landmark): String

Format landmark name

Link copied to clipboard
fun formatSizeAsText(inSizeInBytes: Long): String

Formats given bytes size as text

Link copied to clipboard

Get path inside app external files dir folder

Link copied to clipboard

Calculates distance Between 2 points. If any provided point is null 0.0 will be returned

Link copied to clipboard
fun getDistText(meters: Int, unitsSystem: EUnitSystem, bHighResolution: Boolean = false, bCapitalizeUnit: Boolean = false): Pair<String, String>

Formats the given meters distance as pair of (value, unit).

Link copied to clipboard
Link copied to clipboard
fun getLandmarkDescription(landmark: Landmark, excludeCountry: Boolean = false): String

Get landmark description

Link copied to clipboard

Returns first largest area area found in the provided list.

Link copied to clipboard
fun getSpeedText(speedInMPS: Double, unitsSystem: EUnitSystem): Pair<String, String>

Formats the given meters per seconds speed as pair of (value, unit).

Link copied to clipboard
fun getTimeText(timeInSeconds: Int, bForceHours: Boolean = false, bCapitalizeResult: Boolean = false): Pair<String, String>

Formats the given time seconds as pair of (value, unit).

Link copied to clipboard
fun getTrafficEventsDelay(route: Route, bCheckUserRoadblocks: Boolean = false): Int

Calculates traffic events delay for given route.

Link copied to clipboard
fun getTrafficIcon(route: Route): Image?

Return ball image based on given route's traffic delay.

Link copied to clipboard

Retrieve a TTS string from LocalizationManager based on given string id.

Link copied to clipboard

Retrieve an UI string from LocalizationManager based on given string id.

Link copied to clipboard
fun pairFormatLandmarkDetails(landmark: Landmark?, excludeCountry: Boolean = false): Pair<String, String>