AdministrativeUnitName

data class AdministrativeUnitName(val id: Long = 0, val locality: String?, val subAdminArea: String?, val adminArea: String?, val countryName: String?)

Represents the name of an administrative unit, providing flexibility for different regional structures.

Constructors

Link copied to clipboard
constructor(id: Long = 0, locality: String?, subAdminArea: String?, adminArea: String?, countryName: String?)

Properties

Link copied to clipboard

The name of a higher administrative level for some countries (e.g., state in USA). Can be null (optional).

Link copied to clipboard

The name of the country. Can be null (optional).

Link copied to clipboard
val id: Long = 0

The database ID of the administrative unit name (defaults to 0).

Link copied to clipboard

The name of the first administrative level (e.g., city). Can be null (optional).

Link copied to clipboard

The name of the second administrative level for some countries (e.g., county in USA). Can be null (optional).

Functions

Link copied to clipboard

Converts the AdministrativeUnitName into its corresponding entity AdministrativeUnitNameEntity using the existing ID from the AdministrativeUnitName object.

Converts the AdministrativeUnitName into its corresponding entity AdministrativeUnitNameEntity with a specified ID.

Link copied to clipboard
open override fun toString(): String

The stringified version of the administrative unit name.

fun toString(administrativeLevel: AdministrativeLevel): String