LockError

sealed class LockError : Throwable

To provide specific error to the outcome of any lock functions (unlock, lock, prepareEndRental)

Parameters

code

String value of the error code

message

formatted String value that is translated into more languages to display on the UI

logMessage

String value to display in Logcat

detail

optional String value to determine deeper cause of the error. Usually null, but in cases like FatalError it will provide more info.

Types

Link copied to clipboard
object BluetoothOff : LockError

Bluetooth is turned off on the phone device, notify user to enable it in order to perform the action.

Link copied to clipboard
object BluetoothUnauthorized : LockError

The app does not have bluetooth permission, notify user to allow using bluetooth in order to perform the action.

Link copied to clipboard
object Companion

Helper String values for detail

Link copied to clipboard
class ConnectionError(detail: String?) : LockError

The app could not establish connection to the bluetooth device due to an error. Check detail to find out more information.

Link copied to clipboard
object ConnectionTimeout : LockError

The app could not establish connection to the bluetooth device due to it taking too long. Notify user to keep the phone close to the bluetooth device and try again.

Link copied to clipboard
data class ExtraLockCheckFailed(timeSinceStart: Millisecond) : LockError
Link copied to clipboard
class FatalError(detail: String?) : LockError

When unexpected error shows up during processes not related to establishing connection. Check detail to find out more information.

Link copied to clipboard
object LocationOff : LockError

Location Services are turned off on the phone device, notify user to enable it in order to perform the action.

Link copied to clipboard
object LocationPermission : LockError

The app does not have location permission, notify user to allow using of location in order to perform the action.

Link copied to clipboard
data class LockCommandError(originalCause: Throwable) : LockError

When unexpected error show ups during sending lock command to bluetooth device

Link copied to clipboard
object LockTimeout : LockError

The bluetooth device wasn't locked in specified time. Notify the user to physically push the lock to lock it when trying to perform lock again.

Link copied to clipboard
object OfflineDuringPickup : LockError

During the first unlock for the eKey, the app should be online to determine whether it was properly picked up. If not, this error gets thrown.

Link copied to clipboard
object OutOfKeys : LockError

When eKey has run out of the available commands for performing action on the lock. Please use new eKey if this occurs.

Link copied to clipboard
object PostConnectionLockCheckFailed : LockError

During special conditions, this error can be thrown upon reading characteristics when lock isn't properly locked.

Link copied to clipboard
object SearchTimeout : LockError

The app could not find the advertisement of the searched bluetooth device

Link copied to clipboard
data class UnlockCommandError(originalCause: Throwable) : LockError

When unexpected error show ups during sending unlock command to bluetooth device

Link copied to clipboard
object UnlockTimeout : LockError

The bluetooth device didn't unlock in specified time

Properties

Link copied to clipboard
val code: String
Link copied to clipboard
val detail: String? = null
Link copied to clipboard
val logMessage: String
Link copied to clipboard
open override val message: String

Inheritors

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard