com.entrust.toolkit.security.crypto.ec insteadpublic class GFp extends java.lang.Object implements Field
GFp class implements the Field interface.
Use this class to create finite prime fields GF(p) Galois fields of order p, where p is prime.
| Constructor and Description |
|---|
GFp(java.math.BigInteger prime)
Deprecated.
Creates an instance of the
GFp class. |
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(java.lang.Object object)
Deprecated.
Returns
true if and only if the calling field and the given
field (object argument) are the same. |
int |
getFieldSize()
Deprecated.
Returns the field size in bits.
|
java.lang.String |
getFieldType()
Deprecated.
Returns the field type.
|
java.math.BigInteger |
getNumberOfElements()
Deprecated.
Returns the number of elements in the calling field.
|
FieldElement |
getOneElement()
Deprecated.
Returns the One Element.
|
FieldElement |
getZeroElement()
Deprecated.
Returns the Zero Element.
|
ASN1Object |
toASN1Object()
Deprecated.
Returns the ASN1 encoding of the calling field as described in X9.62.
|
java.lang.String |
toString()
Deprecated.
Returns the
String representation of the calling field. |
public GFp(java.math.BigInteger prime)
GFp class.prime - a prime number represented as a BigInteger
public FieldElement getZeroElement()
The Zero Element is the BigInteger.ZERO wrapped as an instance
of GFpElement.
getZeroElement in interface FieldGFpElement objectpublic FieldElement getOneElement()
The One Element is the BigInteger.ONE wrapped as an instance
of GFpElement.
getOneElement in interface FieldGFpElement objectpublic java.math.BigInteger getNumberOfElements()
The number of elements in the field is the prime number argument of the standard constructor.
getNumberOfElements in interface FieldBigInteger representing the number of elements in
the calling fieldpublic java.lang.String getFieldType()
The field type is a String that describes
the field in human readable form. The String is
"prime field".
getFieldType in interface FieldString
"prime field"public ASN1Object toASN1Object()
toASN1Object in interface FieldASN1Object. It is a SEQUENCE with
components PRIME_FIELD_OID and the prime as
an INTEGER.FieldFactorypublic boolean equals(java.lang.Object object)
true if and only if the calling field and the given
field (object argument) are the same.
public java.lang.String toString()
String representation of the calling field.
public int getFieldSize()
For prime finite field Fp, size of prime p in bits is returned.
getFieldSize in interface Field