Last updated

API / geotoolkit / map / features / converters / CompositeConverter / CompositeConverter

Class: CompositeConverter

converters.CompositeConverter.CompositeConverter

Provides feature converters store for centralized control and processing

Hierarchy

Table of contents

Constructors
Methods

Contents

Constructors

new CompositeConverter(converters)

new CompositeConverter(converters?)

Parameters

Name Type Description
Optional convertersBaseConverter | BaseConverter[]converter(s) for storing

Overrides

BaseConverter.constructor

Methods

addFeatureConverter

addFeatureConverter(converter): CompositeConverter

Adds converter to the end of the list for storing features

Parameters

Name Type Description
converterBaseConverterconverter to add

Returns

CompositeConverter

this


clear

clear(): CompositeConverter

Clears all the features from the store

Returns

CompositeConverter

this

Inherited from

BaseConverter.clear


dispose

dispose(): void

Dispose.

Returns

void

Inherited from

BaseConverter.dispose


getClassName

getClassName(): string

Returns

string

Inherited from

BaseConverter.getClassName


getFeatures

getFeatures(options): Iterator<AbstractFeature>

Returns saved features corresponded to the options

Parameters

Name Type Description
optionsFeaturesOptionsrequest options

Returns

Iterator<AbstractFeature>

features stored

Overrides

BaseConverter.getFeatures


hasEventListener

hasEventListener(type, callback?): boolean

Check if a list of event listeners for this type contains this listener

Parameters

Name Type Description
typestringtype of event or property
Optional callbackFunctionto be called, if null, check if any callback is registered

Returns

boolean

Inherited from

BaseConverter.hasEventListener


isDisposed

isDisposed(): boolean

Returns whether this object has been disposed

Returns

boolean

Inherited from

BaseConverter.isDisposed


isSilent

isSilent(): boolean

Return true if the event dispatcher doesn't notify any events

Returns

boolean

Inherited from

BaseConverter.isSilent


notify

notify<E>(type, source, args?): CompositeConverter

Notify listeners

Type parameters

NameType
Eextends string

Parameters

Name Type Description
typeEevent types
sourceBaseConverterof the event
Optional argsEventMap[E]arguments of the event

Returns

CompositeConverter

this

Inherited from

BaseConverter.notify


off

off<E>(type?, callback?): CompositeConverter

Detach listener on event. Calling .off() with no arguments removes all attached listeners. Calling .off(type) with no callback removes all attached listeners for specific type.

Type parameters

NameType
Eextends string

Parameters

Name Type Description
Optional typeEtype of the event
Optional callback(eventType: E, sender: CompositeConverter, args: EventMap[E]) => voidfunction to be called

Returns

CompositeConverter

this

Inherited from

BaseConverter.off


on

on<E>(type, callback): CompositeConverter

Attach listener on event that will be called whenever the specified event is delivered to the target

If the callback function is already in the list of event listeners for this target, the function is not added a second time.

If a particular anonymous function is in the list of event listeners registered for a certain target, and then later in the code, an identical anonymous function is given in an "on" call, the second function will also be added to the list of event listeners for that target.

Type parameters

NameType
Eextends string

Parameters

Name Type Description
typeEtype of event or property
callback(eventType: E, sender: CompositeConverter, args: EventMap[E]) => voidto be called

Returns

CompositeConverter

this

Inherited from

BaseConverter.on


removeFeatureConverter

removeFeatureConverter(converter): CompositeConverter

Removes converter from the converters list

Parameters

Name Type Description
converterBaseConverterconverter to remove

Returns

CompositeConverter

this


removeFeatures

removeFeatures(features): CompositeConverter

Removes feature(s) from the store

Parameters

Name Type Description
featuresAbstractFeature | Iterator<AbstractFeature>feature(s) to remove

Returns

CompositeConverter

this

Inherited from

BaseConverter.removeFeatures


saveConvertedFeatures

saveConvertedFeatures(features): AbstractFeature[]

Converts and saves new features in array. All features are supported.

Parameters

Name Type Description
featuresAbstractFeature[]new features to add

Returns

AbstractFeature[]

features that were not processed

Inherited from

BaseConverter.saveConvertedFeatures


setSilent

setSilent(bool): CompositeConverter

Set silent mode

Parameters

Name Type Description
boolbooleanflag to enable silent mode

Returns

CompositeConverter

this

Inherited from

BaseConverter.setSilent


getClassName

Static getClassName(): string

Returns

string

Inherited from

BaseConverter.getClassName