public class DoubleDPFacade extends Object implements DeviationProvider
This class is a facade for the use of double precision real numbers. This should be used instead of the simple double to add the computeDeviationTo method. This way, the double numbers can be treated as any other type.
DeviationProvider
Constructor and Description |
---|
DoubleDPFacade(double toBeStoredValue)
Simple constructor that store the given double value.
|
Modifier and Type | Method and Description |
---|---|
double |
computeDeviationTo(boolean absolute,
DeviationProvider obj,
boolean positive)
computes the relative deviation between the stored double value and the given one.
|
double |
getValue() |
public DoubleDPFacade(double toBeStoredValue)
toBeStoredValue
- the value to store.public final double computeDeviationTo(boolean absolute, DeviationProvider obj, boolean positive)
computeDeviationTo
in interface DeviationProvider
absolute
- absolute or relative deviationobj
- the DeviationProvider that should be a DoubleDPFacadepositive
- true if absolute value of deviations, false otherwiseEphemerisComparatorRuntimeException
- if the DeviationProvider is not of the correct typeDeviationProvider.computeDeviationTo(boolean,
DeviationProvider, boolean)
public final double getValue()
Copyright © 2019 CNES. All Rights Reserved.