Logo
Developer

VisioWeb 1.17.2

Class

visioweb.POICluster

VisioWeb's POICluster class.
Helps dealing with large number of POIs by grouping them into a hierarchy of clusters.

Constructor

new POICluster()

See:

Members summary


Name Description
id the cluster's identifier, also used to identify its associated POI
level the cluster's level in the hierarchy
nbChildren the cluster's number of immediate children, cluster or "leaf" POIs.
position the cluster's position in scene {x,y,z} coordinates
properties the cluster's properties as accumulated from the input point properties. Only used if a reducer was provided.

Methods summary


Name Description
getParent Returns the parent cluster for intermediate level clusters, null for level 0 clusters.
getViewpointPosition Computes and returns the associated viewpoint position based on the zone covered by the children.
hide Hides the associated POI object.
hideChildren Recursively calls hideChildren on all children, animates them back to parent's position and finally hides them.
remove Removes the associated POI from the scene.
show Shows the associated POI object.
showChildren Calls show method on all children, animates them from parent's position to their own.

Members detail

id :string

the cluster's identifier, also used to identify its associated POI

level :number

the cluster's level in the hierarchy

nbChildren :number

the cluster's number of immediate children, cluster or "leaf" POIs.

position :Object

the cluster's position in scene {x,y,z} coordinates

properties :Object

the cluster's properties as accumulated from the input point properties. Only used if a reducer was provided.

Methods detail

getParent() → {visioweb.POICluster}

Returns the parent cluster for intermediate level clusters, null for level 0 clusters.
Since:
  • 1.9.1
Returns:
Type
visioweb.POICluster

getViewpointPosition() → {Object}

Computes and returns the associated viewpoint position based on the zone covered by the children.
Since:
  • 1.9.1
See:
Returns:
camera position object (Attributes .x, .y and .radius)
Type
Object

hide() → {Promise}

Hides the associated POI object.
Since:
  • 1.9.1
Returns:
Type
Promise

hideChildren() → {Promise}

Recursively calls hideChildren on all children, animates them back to parent's position and finally hides them.
Since:
  • 1.9.1
Returns:
Type
Promise

remove()

Removes the associated POI from the scene.
Since:
  • 1.9.1

show() → {Promise}

Shows the associated POI object.
Since:
  • 1.9.1
Returns:
Type
Promise

showChildren() → {Promise}

Calls show method on all children, animates them from parent's position to their own.
Since:
  • 1.9.1
Returns:
Type
Promise