Extends
- Service
Methods
getBuilding(id, argsopt) → {Promise.<Building>}
Get a building by it's id.
Parameters:
Name | Type | Attributes | Description |
---|---|---|---|
id |
string | A building id | |
args |
object |
<optional> |
|
lr |
object |
<optional> |
Sets the preferred language that the result should be returned in. |
Promise.<Building>
Examples
mapsindoors.VenuesService.getBuilding('5548c6583eb3c3080c4a92da').then(building => { ... });
mapsindoors.VenuesService.getBuilding('5548c6583eb3c3080c4a92da', { lr: 'en' }).then(building => { ... });
getBuildingInView(viewport, argsopt) → {string}
Gets the id of the current building in "focus"
Parameters:
Name | Type | Attributes | Description |
---|---|---|---|
viewport |
object | Limits the result to inside the boundingbox. `{east: number, north: number, south: number, west: number}` | |
east |
number | Max longitude of the bounds in degrees. | |
north |
number | Max latitude of the bounds in degrees. | |
south |
number | Min latitude of the bounds in degrees. | |
west |
number | Min longitude of the bounds in degrees. | |
args |
object |
<optional> |
|
lr |
object |
<optional> |
Sets the preferred language that the result should be returned in. |
- A building id.
string
getBuildings(venueIdopt) → {Promise.<Array.<Building>>}
Get all buildings for the solution or limit the result to only buildings form a specific venue.
Parameters:
Name | Type | Attributes | Default | Description |
---|---|---|---|---|
venueId |
string |
<optional> |
all | A venue id to limit the result to. |
Promise.<Array.<Building>>
Examples
mapsindoors.VenuesService.getBuildings().then(buildings => { ... });
mapsindoors.VenuesService.getBuildings('550c286964617400a4100000').then(buildings => { ... });