Class TLcdObjectTransformationProvider

java.lang.Object
com.luciad.datamodel.transformation.TLcdObjectTransformationProvider

public class TLcdObjectTransformationProvider extends Object

The responsibility of this class is to provide ILcdObjectTransformation instances to transform from a source TLcdDataType to a target TLcdDataType.

Objects of this class are thread-safe.

Since:
11.0
  • Constructor Details

    • TLcdObjectTransformationProvider

      public TLcdObjectTransformationProvider()
      Creates a new transformation provider.
  • Method Details

    • getObjectTransformation

      public ILcdObjectTransformation getObjectTransformation(TLcdDataType aSourceType, TLcdDataType aTargetType)

      Returns the object transformation that can transform instances of the given source type to instances of the given target type. Returns null if no such transformation can be found.

      The implementation first looks for transformation that have been registered on this instance for the given source and target type. If no such transformation can be found, it tries to find an appropriate default transformation.

      Parameters:
      aSourceType - the source type
      aTargetType - the target type
      Returns:
      an object transformation that transforms from source type to target type
    • getTargetTypes

      public Collection<TLcdDataType> getTargetTypes(TLcdDataType aType)
      Returns a collection of target data types for which transformations have been registered for the given source type.
      Parameters:
      aType - the source type
      Returns:
      the collection of target types for which a transformation has been registered for the given source type
    • register

      public void register(TLcdDataType aSourceType, TLcdDataType aTargetType, ILcdObjectTransformation aTransformation)
      Registers a transformation from the given source type to the given target type. If the transformation has an inverse, the inverse will be available on this object's inverse (see getInverse().
      Parameters:
      aSourceType - the source type
      aTargetType - the target type
      aTransformation - the transformation to register
    • getInverse

      public TLcdObjectTransformationProvider getInverse()
      Returns the inverse of this provider. Typically, each transformation that is registered on this instance and that has an inverse, will be available on the returned inverse.
      Returns:
      the inverse of this provider