org.simantics.databoard.bindingscheme
Class GenericBindingScheme

java.lang.Object
  extended by org.simantics.databoard.bindingscheme.GenericBindingScheme
All Implemented Interfaces:
BindingScheme

public class GenericBindingScheme
extends java.lang.Object
implements BindingScheme

GenericBinding is a binding that binds any DataType to an Object. Generinc binding binds to completely mutable java classes. DataType | Class of the bound instance ===================|================== BooleanType | MutableBoolean.class ByteType | MutableByte.class FloatType | MutableFloat.class DoubleType | MutableDouble.class IntegerType | MutableInt.class LongType | MutableLong.class StringType | MutableString.class UnionType | GenericBinding.TaggedObject.class OptionType | ValueContainer.class RecordType | Object[].class ArrayType | ArrayList.class MapType | TreeMap.class VariantType | MutableVariant.class

Author:
Toni Kalajainen

Constructor Summary
GenericBindingScheme()
           
 
Method Summary
 Binding getBinding(DataType type)
          Get binding of a data type
 boolean supportsType(DataType type)
          Tests if the scheme supports a type
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

GenericBindingScheme

public GenericBindingScheme()
Method Detail

getBinding

public Binding getBinding(DataType type)
Description copied from interface: BindingScheme
Get binding of a data type

Specified by:
getBinding in interface BindingScheme
Parameters:
type - data type
Returns:
binding

supportsType

public boolean supportsType(DataType type)
Description copied from interface: BindingScheme
Tests if the scheme supports a type

Specified by:
supportsType in interface BindingScheme
Returns:
true if the type is with in the scheme