Package net.imglib2.type.volatiles
Class AbstractVolatileNumericType<N extends NumericType<N>,T extends AbstractVolatileNumericType<N,T>>
- java.lang.Object
-
- net.imglib2.Volatile<N>
-
- net.imglib2.type.volatiles.AbstractVolatileNumericType<N,T>
-
- Type Parameters:
N- wrappedNumericType.T- type of derived concrete class.
- All Implemented Interfaces:
NumericType<T>,Add<T>,Div<T>,Mul<T>,MulFloatingPoint,Pow<T>,PowFloatingPoint,SetOne,SetZero,Sub<T>,ValueEquals<T>,Type<T>
- Direct Known Subclasses:
AbstractVolatileNativeNumericType,VolatileNumericType
public abstract class AbstractVolatileNumericType<N extends NumericType<N>,T extends AbstractVolatileNumericType<N,T>> extends Volatile<N> implements NumericType<T>
Abstract base class forVolatileNumericTypes that wrap aNumericTypethat is either VALID or INVALID.
-
-
Constructor Summary
Constructors Constructor Description AbstractVolatileNumericType(N t)AbstractVolatileNumericType(N t, boolean valid)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidadd(T c)voiddiv(T c)booleanequals(java.lang.Object obj)inthashCode()voidmul(double c)voidmul(float c)voidmul(T c)voidpow(double power)voidpow(T c)voidset(T c)Sets the value of anotherType.voidsetOne()voidsetZero()voidsub(T c)booleanvalueEquals(T other)-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface net.imglib2.type.Type
copy, createVariable
-
-
-
-
Method Detail
-
set
public void set(T c)
Description copied from interface:TypeSets the value of anotherType.- Specified by:
setin interfaceType<N extends NumericType<N>>- Parameters:
c- the new value
-
pow
public void pow(double power)
- Specified by:
powin interfacePowFloatingPoint
-
mul
public void mul(float c)
- Specified by:
mulin interfaceMulFloatingPoint
-
mul
public void mul(double c)
- Specified by:
mulin interfaceMulFloatingPoint
-
valueEquals
public boolean valueEquals(T other)
- Specified by:
valueEqualsin interfaceValueEquals<N extends NumericType<N>>
-
equals
public boolean equals(java.lang.Object obj)
- Overrides:
equalsin classjava.lang.Object
-
hashCode
public int hashCode()
- Overrides:
hashCodein classjava.lang.Object
-
-