Top Description Fields Constructors Methods
java.security.spec

public Class ECFieldFp

extends Object
implements ECField
Class Inheritance
All Implemented Interfaces
java.security.spec.ECField
Imports
java.math.BigInteger

This immutable class defines an elliptic curve (EC) prime finite field.
Author
Valerie Peng
Since
1.5
See Also
ECField

Field Summary

Modifier and TypeField and Description
private final BigInteger
p

Constructor Summary

AccessConstructor and Description
public
ECFieldFp(BigInteger
the prime.
p
)

Creates an elliptic curve prime finite field with the specified prime p.

Method Summary

Modifier and TypeMethod and Description
public boolean

Returns:

true if obj is an instance of ECFieldFp and the prime value match, false otherwise.
equals
(Object
the object to be compared.
obj
)

Overrides java.lang.Object.equals.

Compares this prime finite field for equality with the specified object.

public int

Returns:

the field size in bits.
getFieldSize
()

Implements java.security.spec.ECField.getFieldSize.

Returns the field size in bits which is size of prime p for this prime finite field.

public BigInteger

Returns:

the prime.
getP
()

Returns the prime p of this prime finite field.

public int

Returns:

a hash code value for this prime finite field
hashCode
()

Overrides java.lang.Object.hashCode.

Returns a hash code value for this prime finite field.

Inherited from java.lang.Object:
clonefinalizegetClassnotifynotifyAlltoStringwaitwaitwait

Field Detail

pback to summary
private final BigInteger p

Constructor Detail

ECFieldFpback to summary
public ECFieldFp(BigInteger p)

Creates an elliptic curve prime finite field with the specified prime p.

Parameters
p:BigInteger

the prime.

Exceptions
NullPointerException:
if p is null.
IllegalArgumentException:
if p is not positive.

Method Detail

equalsback to summary
public boolean equals(Object obj)

Overrides java.lang.Object.equals.

Compares this prime finite field for equality with the specified object.

Parameters
obj:Object

the object to be compared.

Returns:boolean

true if obj is an instance of ECFieldFp and the prime value match, false otherwise.

Annotations
@Override
getFieldSizeback to summary
public int getFieldSize()

Implements java.security.spec.ECField.getFieldSize.

Returns the field size in bits which is size of prime p for this prime finite field.

Returns:int

the field size in bits.

getPback to summary
public BigInteger getP()

Returns the prime p of this prime finite field.

Returns:BigInteger

the prime.

hashCodeback to summary
public int hashCode()

Overrides java.lang.Object.hashCode.

Returns a hash code value for this prime finite field.

Returns:int

a hash code value for this prime finite field

Annotations
@Override