Packagecom.yworks.support
Interfacepublic interface IMapper
Implementors TagOwnerMapper

A simple interface for a dictionary-like implementation.



Public Methods
 MethodDefined By
  
lookupValue(key:Object):Object
Finds the associated value for the given key in the map.
IMapper
  
mapValue(key:Object, value:Object):void
Associates the given key with the value provided, removing previous associations.
IMapper
  
unMapValue(key:Object):void
Removes a previously created association with the given key.
IMapper
Method Detail
lookupValue()method
public function lookupValue(key:Object):Object

Finds the associated value for the given key in the map.

Implementations normally should not throw an error if there was no association found for the key provided. Instead they should return a default value depending on the context they are used in.

Parameters

key:Object — The key to find the value for.

Returns
Object — The value of an association or a default value if no such association exists.
mapValue()method 
public function mapValue(key:Object, value:Object):void

Associates the given key with the value provided, removing previous associations.

Parameters

key:Object — The key to associate with a value.
 
value:Object — The value to associate the key with.

unMapValue()method 
public function unMapValue(key:Object):void

Removes a previously created association with the given key.

Parameters

key:Object — The key to remove from the mapping.