Interface IConverter<Source,Target>

Type Parameters:
Source - Can be of any type.
Target - Can be of any type.
All Known Subinterfaces:
IQuantitiesConverter<S,T>, IQuantityConverter<S,T>, IReloadableQuantitiesConverter<S,T>
All Known Implementing Classes:
AutoRenameableConverter, CoupledConverterHolder, EnergyPositionConverter, JEPConverterHolder, LookupTableConverterHolder, LookupTableQuantityConverter, RenameableConverter, SimpleConverter, SimpleConverterBase, SplitConverterHolder

public interface IConverter<Source,Target>
Converts forward and back between a source and a target
  • Method Summary

    Modifier and Type
    Method
    Description
    boolean
    Returns true is the conversion reverses the sense.
    toSource(Target target)
    Calculates a value for Source given the value of the target
    toTarget(Source source)
    Calculates a value for Target given the value of the source
  • Method Details

    • toSource

      Source toSource(Target target) throws Exception
      Calculates a value for Source given the value of the target
      Parameters:
      target -
      Returns:
      The value calculated from the value of the target *
      Throws:
      Exception
    • toTarget

      Target toTarget(Source source) throws Exception
      Calculates a value for Target given the value of the source
      Parameters:
      source -
      Returns:
      The value calculated from the value of the source
      Throws:
      Exception
    • sourceMinIsTargetMax

      boolean sourceMinIsTargetMax()
      Returns true is the conversion reverses the sense. So that to get the max of the source you convert the min of the target and vice versa
      Returns:
      true is the conversion reverses the sense.