kotcity4 / kotcity.data / Location

Location

data class Location

Represents a pair of a building and its location in the city.

Parameters

cityMap - map to use

coordinate - (top left) coordinate of building

building - building we are referring to

Constructors

<init>

Location(cityMap: CityMap, coordinate: BlockCoordinate, building: Building)

Represents a pair of a building and its location in the city.

Properties

building

val building: Building

building we are referring to

cityMap

val cityMap: CityMap

map to use

coordinate

val coordinate: BlockCoordinate

(top left) coordinate of building

Functions

blocks

fun blocks(): List<BlockCoordinate>

Returns the "footprint" of the building in BlockCoordinates