public class UnsignedLongType extends GenericLongType<UnsignedLongType>
dataAccess, img
Constructor and Description |
---|
UnsignedLongType() |
UnsignedLongType(BigInteger value) |
UnsignedLongType(long value) |
UnsignedLongType(LongAccess access) |
UnsignedLongType(NativeImg<?,? extends LongAccess> img) |
Modifier and Type | Method and Description |
---|---|
void |
add(UnsignedLongType c) |
static int |
compare(long a,
long b)
Deprecated.
Use
Long.compareUnsigned(long, long) instead. |
int |
compareTo(UnsignedLongType other) |
UnsignedLongType |
copy()
|
UnsignedLongType |
createVariable()
Creates a new
Type variable which can only store one value. |
void |
dec() |
void |
div(UnsignedLongType c) |
static long |
divide(long d1,
long d2)
Unsigned division of
d1 by d2 . |
UnsignedLongType |
duplicateTypeOnSameNativeImg()
Creates a new
NativeType which stores in the same physical array. |
long |
get()
This method returns the value of the UnsignedLongType as a signed long.
|
BigInteger |
getBigInteger()
This method returns the unsigned representation of this UnsignedLongType
as a
BigInteger . |
int |
getInteger() |
long |
getIntegerLong() |
BigInteger |
getMaxBigIntegerValue()
Returns the true maximum value as a BigInteger, since it cannot be
precisely represented as a
double . |
double |
getMaxValue()
The maximum value that can be stored is
Math.pow( 2, 64 ) - 1 ,
which can't be represented with exact precision using a double |
double |
getMinValue() |
NativeTypeFactory<UnsignedLongType,LongAccess> |
getNativeTypeFactory() |
double |
getRealDouble() |
float |
getRealFloat() |
void |
inc() |
void |
mul(double c) |
void |
mul(float c) |
void |
mul(UnsignedLongType c) |
void |
set(BigInteger bi) |
void |
set(long value) |
void |
setBigInteger(BigInteger b) |
void |
setInteger(int f) |
void |
setInteger(long f) |
void |
setOne() |
void |
setReal(double real) |
void |
setReal(float real) |
void |
setZero() |
void |
sub(UnsignedLongType c) |
String |
toString() |
equals, getBitsPerPixel, getEntitiesPerPixel, getLong, getValue, hashCode, index, set, setLong, setValue, updateContainer, valueEquals
getMinIncrement
getImaginaryDouble, getImaginaryFloat, getPhaseDouble, getPhaseFloat, getPowerDouble, getPowerFloat, pow, pow, setImaginary, setImaginary
complexConjugate, setComplexNumber, setComplexNumber
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
decIndex, decIndex, getIndex, incIndex, incIndex, updateIndex
complexConjugate, getImaginaryDouble, getImaginaryFloat, getPhaseDouble, getPhaseFloat, getPowerDouble, getPowerFloat, setComplexNumber, setComplexNumber, setImaginary, setImaginary
pow
public UnsignedLongType(NativeImg<?,? extends LongAccess> img)
public UnsignedLongType(long value)
public UnsignedLongType(BigInteger value)
public UnsignedLongType(LongAccess access)
public UnsignedLongType()
public UnsignedLongType duplicateTypeOnSameNativeImg()
NativeType
NativeType
which stores in the same physical array.
This is only used internally.NativeType
instance working on the same
NativeImg
public NativeTypeFactory<UnsignedLongType,LongAccess> getNativeTypeFactory()
getNativeTypeFactory
in interface NativeType<UnsignedLongType>
getNativeTypeFactory
in class GenericLongType<UnsignedLongType>
public void mul(float c)
mul
in interface MulFloatingPoint
mul
in class GenericLongType<UnsignedLongType>
public void mul(double c)
mul
in interface MulFloatingPoint
mul
in class GenericLongType<UnsignedLongType>
public void add(UnsignedLongType c)
add
in interface Add<UnsignedLongType>
add
in class GenericLongType<UnsignedLongType>
public void div(UnsignedLongType c)
div
in interface Div<UnsignedLongType>
div
in class GenericLongType<UnsignedLongType>
divide(long, long)
public static final long divide(long d1, long d2)
d1
by d2
.
See "Division by Invariant Integers using Multiplication", by Torbjorn
Granlund and Peter L. Montgomery, 1994. http://gmplib.org/~tege/divcnst-pldi94.pdfArithmeticException
- when c equals zero.public void mul(UnsignedLongType c)
mul
in interface Mul<UnsignedLongType>
mul
in class GenericLongType<UnsignedLongType>
public void sub(UnsignedLongType c)
sub
in interface Sub<UnsignedLongType>
sub
in class GenericLongType<UnsignedLongType>
public void setOne()
setOne
in interface SetOne
setOne
in class GenericLongType<UnsignedLongType>
public void setZero()
setZero
in interface SetZero
setZero
in class GenericLongType<UnsignedLongType>
public void inc()
inc
in interface RealType<UnsignedLongType>
inc
in class GenericLongType<UnsignedLongType>
public void dec()
dec
in interface RealType<UnsignedLongType>
dec
in class GenericLongType<UnsignedLongType>
public String toString()
toString
in class GenericLongType<UnsignedLongType>
public long get()
getBigInteger()
.public BigInteger getBigInteger()
BigInteger
.public void set(long value)
public int getInteger()
public long getIntegerLong()
public void setInteger(int f)
public void setInteger(long f)
public void setBigInteger(BigInteger b)
public void setReal(double real)
setReal
in interface ComplexType<UnsignedLongType>
setReal
in class AbstractIntegerType<UnsignedLongType>
public void setReal(float real)
setReal
in interface ComplexType<UnsignedLongType>
setReal
in class AbstractIntegerType<UnsignedLongType>
public void set(BigInteger bi)
public double getMaxValue()
Math.pow( 2, 64 ) - 1
,
which can't be represented with exact precision using a doublepublic BigInteger getMaxBigIntegerValue()
double
.public double getMinValue()
@Deprecated public static final int compare(long a, long b)
Long.compareUnsigned(long, long)
instead.public UnsignedLongType createVariable()
Type
Type
variable which can only store one value.Type
variablepublic UnsignedLongType copy()
Type
Type
variablepublic float getRealFloat()
getRealFloat
in interface ComplexType<UnsignedLongType>
getRealFloat
in class AbstractIntegerType<UnsignedLongType>
public double getRealDouble()
getRealDouble
in interface ComplexType<UnsignedLongType>
getRealDouble
in class AbstractIntegerType<UnsignedLongType>
public int compareTo(UnsignedLongType other)
compareTo
in interface Comparable<UnsignedLongType>
compareTo
in class GenericLongType<UnsignedLongType>
Copyright © 2015–2022 ImgLib2. All rights reserved.