Skip to main content

MapObject

geovisto-mapReadme | API


geovisto-map / MapObject

Class: MapObject

This class provide functions for using map object which can be identified by uniquie string.

Author

Jiri Hynek

Extended by

Implements

Constructors

new MapObject()

new MapObject(props?): MapObject

It creates a map object.

Parameters

props?: IMapObjectProps

Returns

MapObject

Source

model/internal/object/MapObject.ts:22

Properties

defaults

private defaults: IMapObjectDefaults\<IMapObjectProps, IMapObjectConfig>

Source

model/internal/object/MapObject.ts:16


props

private props: IMapObjectProps

Source

model/internal/object/MapObject.ts:15


state

private state: IMapObjectState\<IMapObjectProps, IMapObjectDefaults\<IMapObjectProps, IMapObjectConfig>, IMapObjectConfig, IMapObjectInitProps\<IMapObjectConfig>>

Source

model/internal/object/MapObject.ts:17

Methods

createDefaults()

protected createDefaults(): IMapObjectDefaults\<IMapObjectProps, IMapObjectConfig>

It creates new defaults of the object.

This function can be overriden.

Returns

IMapObjectDefaults\<IMapObjectProps, IMapObjectConfig>

Source

model/internal/object/MapObject.ts:61


createState()

protected createState(): IMapObjectState\<IMapObjectProps, IMapObjectDefaults\<IMapObjectProps, IMapObjectConfig>, IMapObjectConfig, IMapObjectInitProps\<IMapObjectConfig>>

It creates new state if the object.

This function can be overriden.

Returns

IMapObjectState\<IMapObjectProps, IMapObjectDefaults\<IMapObjectProps, IMapObjectConfig>, IMapObjectConfig, IMapObjectInitProps\<IMapObjectConfig>>

Source

model/internal/object/MapObject.ts:79


getDefaults()

getDefaults(): IMapObjectDefaults\<IMapObjectProps, IMapObjectConfig>

It returns default values of the state properties.

Returns

IMapObjectDefaults\<IMapObjectProps, IMapObjectConfig>

Implementation of

IMapObject.getDefaults

Source

model/internal/object/MapObject.ts:52


getId()

getId(): string

Help function which returns the id of the object.

Returns

string

Implementation of

IMapObject.getId

Source

model/internal/object/MapObject.ts:93


getProps()

getProps(): IMapObjectProps

It returns the props given by the programmer.

Returns

IMapObjectProps

Implementation of

IMapObject.getProps

Source

model/internal/object/MapObject.ts:45


getState()

getState(): IMapObjectState\<IMapObjectProps, IMapObjectDefaults\<IMapObjectProps, IMapObjectConfig>, IMapObjectConfig, IMapObjectInitProps\<IMapObjectConfig>>

It returns the tool state.

This function should not be overriden.

Returns

IMapObjectState\<IMapObjectProps, IMapObjectDefaults\<IMapObjectProps, IMapObjectConfig>, IMapObjectConfig, IMapObjectInitProps\<IMapObjectConfig>>

Implementation of

IMapObject.getState

Source

model/internal/object/MapObject.ts:70


getType()

getType(): string

Help function which returns the type of the object.

Returns

string

Implementation of

IMapObject.getType

Source

model/internal/object/MapObject.ts:86


initialize()

initialize(initProps): this

It initializes the state of the object. It processes the serialized config and sets further objects.

This cannot be done in the object constructor since the object can be created before the Geovisto map is created.

Parameters

initProps: IMapObjectInitProps

Returns

this

Implementation of

IMapObject.initialize

Source

model/internal/object/MapObject.ts:106


setProps()

protected setProps(props): void

It updates the props.

Parameters

props: IMapObjectProps

Returns

void

Source

model/internal/object/MapObject.ts:38