Package gda.util.converters
Interface IQuantitiesConverter<S extends javax.measure.Quantity<S>,T extends javax.measure.Quantity<T>>
- All Superinterfaces:
IConverter<javax.measure.Quantity<S>,,javax.measure.Quantity<T>> IQuantityConverter<S,T>
- All Known Subinterfaces:
IReloadableQuantitiesConverter<S,T>
- All Known Implementing Classes:
AutoRenameableConverter,CoupledConverterHolder,JEPConverterHolder,LookupTableConverterHolder,RenameableConverter,SplitConverterHolder
public interface IQuantitiesConverter<S extends javax.measure.Quantity<S>,T extends javax.measure.Quantity<T>>
extends IQuantityConverter<S,T>
-
Method Summary
Modifier and TypeMethodDescriptionjavax.measure.Quantity<T>[]calculateMoveables(javax.measure.Quantity<S>[] sources, Object[] moveables) Calculates an array of values in units of the source given an array of quantities in units of the sourceReturns the units in which the targets quantities passed into ToSource can be expressedReturns the units in which the sources quantities passed into calculateMoveables can be expressedjavax.measure.Quantity<S>[]Calculates an array of values in units of the source given an array of quantities in units of the moveablesMethods inherited from interface gda.util.converters.IConverter
sourceMinIsTargetMax, toSource, toTargetMethods inherited from interface gda.util.converters.IQuantityConverter
getAcceptableSourceUnits, getAcceptableTargetUnits, handlesStoT, handlesTtoS
-
Method Details
-
toSource
javax.measure.Quantity<S>[] toSource(javax.measure.Quantity<T>[] targets, Object[] moveables) throws Exception Calculates an array of values in units of the source given an array of quantities in units of the moveables- Parameters:
targets- Array of values in units of the moveables to be converted.moveables- Array ofMoveable- Returns:
- Array of calculated values in units of the source
- Throws:
Exception
-
calculateMoveables
javax.measure.Quantity<T>[] calculateMoveables(javax.measure.Quantity<S>[] sources, Object[] moveables) throws Exception Calculates an array of values in units of the source given an array of quantities in units of the source- Parameters:
sources- Array of values in units of the sources to be converted.moveables- Array ofMoveable- Returns:
- Array of calculated values in units of the moveables
- Throws:
Exception
-
getAcceptableUnits
Returns the units in which the sources quantities passed into calculateMoveables can be expressed- Returns:
- Each element of the array is an array of units that is acceptable for the corresponding source in calls to calculateMoveables
-
getAcceptableMoveableUnits
Returns the units in which the targets quantities passed into ToSource can be expressed- Returns:
- Each element of the array is an array of units that is acceptable for the corresponding target in calls to ToSource
-