Skip to main content

HierarchyDomain

geovisto-map β€’ Readme | API


geovisto-map / HierarchyDomain

Class: HierarchyDomain

Holds everything about domais hierarchy

Author​

VojtΔ›ch MalΓ½

Implements​

Constructors​

new HierarchyDomain()​

new HierarchyDomain(name): HierarchyDomain

Parameters​

β€’ name: string

Returns​

HierarchyDomain

Source​

tools/hierarchy/model/internal/tool/HierarchyDomain.ts:28

Properties​

aggregationEnabled​

aggregationEnabled: boolean = false

Source​

tools/hierarchy/model/internal/tool/HierarchyDomain.ts:24


cached​

private cached: boolean = false

Source​

tools/hierarchy/model/internal/tool/HierarchyDomain.ts:22


levelsMap​

private levelsMap: Map\<number, HierarchyZoomLevel>

Source​

tools/hierarchy/model/internal/tool/HierarchyDomain.ts:13


lowestChildMap​

lowestChildMap: Map\<string, string[]>

Source​

tools/hierarchy/model/internal/tool/HierarchyDomain.ts:20


name​

private name: string

Source​

tools/hierarchy/model/internal/tool/HierarchyDomain.ts:11


nodes​

nodes: [string, string | boolean, number][] = []

Source​

tools/hierarchy/model/internal/tool/HierarchyDomain.ts:26


parentChild​

private parentChild: [string, string][] = []

Source​

tools/hierarchy/model/internal/tool/HierarchyDomain.ts:16


parentChildMap​

private parentChildMap: Map\<string, string[]>

Source​

tools/hierarchy/model/internal/tool/HierarchyDomain.ts:15


zoomLevels​

private zoomLevels: number[] = []

Source​

tools/hierarchy/model/internal/tool/HierarchyDomain.ts:18

Methods​

addToLevel()​

addToLevel(level, id): void

Adds new object to certain zoom level

Parameters​

β€’ level: number

Zoom level

β€’ id: string | number

Id of added object.

Returns​

void

Implementation of​

IHierarchyToolDomain.addToLevel

Source​

tools/hierarchy/model/internal/tool/HierarchyDomain.ts:77


getHierarchyMap()​

getHierarchyMap(): Map\<string, string[]>

Returnes lowest child map.

Returns​

Map\<string, string[]>

Implementation of​

IHierarchyToolDomain.getHierarchyMap

Source​

tools/hierarchy/model/internal/tool/HierarchyDomain.ts:93


getLevelByZoom()​

getLevelByZoom(zoom): undefined | HierarchyZoomLevel

Based on zoom level returns object of hierarchyZoomLevel

Parameters​

β€’ zoom: number

Returns​

undefined | HierarchyZoomLevel

Implementation of​

IHierarchyToolDomain.getLevelByZoom

Source​

tools/hierarchy/model/internal/tool/HierarchyDomain.ts:39


getName()​

getName(): string

Returns name of a domain.

Returns​

string

Implementation of​

IHierarchyToolDomain.getName

Source​

tools/hierarchy/model/internal/tool/HierarchyDomain.ts:176


getNodes()​

getNodes(): [string, string | boolean, number][]

Return node array where: [childID, parentID or True if parent, ZoomLevel of change]

Returns​

[string, string | boolean, number][]

Implementation of​

IHierarchyToolDomain.getNodes

Source​

tools/hierarchy/model/internal/tool/HierarchyDomain.ts:32


getParentChild()​

getParentChild(): [string, string][]

Get parent child array

Returns​

[string, string][]

Implementation of​

IHierarchyToolDomain.getParentChild

Source​

tools/hierarchy/model/internal/tool/HierarchyDomain.ts:160


mapResolveGet()​

private mapResolveGet(toResolve): string[]

Resolve and get all lowest childrens of passed objects.

Parameters​

β€’ toResolve: string[]

Ids of objects to resolve

Returns​

string[]

Source​

tools/hierarchy/model/internal/tool/HierarchyDomain.ts:114


setParentChild()​

setParentChild(parentChild): void

Set parentChild array

Parameters​

β€’ parentChild: [string, string][]

Returns​

void

Implementation of​

IHierarchyToolDomain.setParentChild

Source​

tools/hierarchy/model/internal/tool/HierarchyDomain.ts:144


setParentChildMap()​

setParentChildMap(map): void

Set parentChild Map

Parameters​

β€’ map: Map\<string, string[]>

Returns​

void

Implementation of​

IHierarchyToolDomain.setParentChildMap

Source​

tools/hierarchy/model/internal/tool/HierarchyDomain.ts:152


setZoomLevels()​

setZoomLevels(zoomLevels): void

Sets level of all defined zoom levels

Parameters​

β€’ zoomLevels: number[]

Returns​

void

Implementation of​

IHierarchyToolDomain.setZoomLevels

Source​

tools/hierarchy/model/internal/tool/HierarchyDomain.ts:168