Package net.i2p.crypto.eddsa.math.bigint
Class BigIntegerFieldElement
- java.lang.Object
-
- net.i2p.crypto.eddsa.math.FieldElement
-
- net.i2p.crypto.eddsa.math.bigint.BigIntegerFieldElement
-
- All Implemented Interfaces:
Serializable
public class BigIntegerFieldElement extends FieldElement implements Serializable
A particular element of the field \Z/(2^255-19).- Author:
- str4d
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description (package private) BigInteger
bi
Variable is package private for encoding.-
Fields inherited from class net.i2p.crypto.eddsa.math.FieldElement
f
-
-
Constructor Summary
Constructors Constructor Description BigIntegerFieldElement(Field f, BigInteger bi)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description FieldElement
add(FieldElement val)
FieldElement
addOne()
FieldElement
cmov(FieldElement val, int b)
FieldElement
divide(BigInteger val)
FieldElement
divide(FieldElement val)
boolean
equals(Object obj)
int
hashCode()
FieldElement
invert()
boolean
isNonZero()
FieldElement
mod(FieldElement m)
FieldElement
modPow(FieldElement e, FieldElement m)
FieldElement
multiply(FieldElement val)
FieldElement
negate()
FieldElement
pow(FieldElement e)
FieldElement
pow22523()
FieldElement
square()
FieldElement
squareAndDouble()
FieldElement
subtract(FieldElement val)
FieldElement
subtractOne()
String
toString()
-
Methods inherited from class net.i2p.crypto.eddsa.math.FieldElement
isNegative, toByteArray
-
-
-
-
Field Detail
-
bi
final BigInteger bi
Variable is package private for encoding.
-
-
Constructor Detail
-
BigIntegerFieldElement
public BigIntegerFieldElement(Field f, BigInteger bi)
-
-
Method Detail
-
isNonZero
public boolean isNonZero()
- Specified by:
isNonZero
in classFieldElement
-
add
public FieldElement add(FieldElement val)
- Specified by:
add
in classFieldElement
-
addOne
public FieldElement addOne()
- Overrides:
addOne
in classFieldElement
-
subtract
public FieldElement subtract(FieldElement val)
- Specified by:
subtract
in classFieldElement
-
subtractOne
public FieldElement subtractOne()
- Overrides:
subtractOne
in classFieldElement
-
negate
public FieldElement negate()
- Specified by:
negate
in classFieldElement
-
divide
public FieldElement divide(FieldElement val)
- Overrides:
divide
in classFieldElement
-
divide
public FieldElement divide(BigInteger val)
-
multiply
public FieldElement multiply(FieldElement val)
- Specified by:
multiply
in classFieldElement
-
square
public FieldElement square()
- Specified by:
square
in classFieldElement
-
squareAndDouble
public FieldElement squareAndDouble()
- Specified by:
squareAndDouble
in classFieldElement
-
invert
public FieldElement invert()
- Specified by:
invert
in classFieldElement
-
mod
public FieldElement mod(FieldElement m)
-
modPow
public FieldElement modPow(FieldElement e, FieldElement m)
-
pow
public FieldElement pow(FieldElement e)
-
pow22523
public FieldElement pow22523()
- Specified by:
pow22523
in classFieldElement
-
cmov
public FieldElement cmov(FieldElement val, int b)
- Specified by:
cmov
in classFieldElement
- Since:
- 0.9.36
-
-