Package org.apache.harmony.security.x509
Class X509PublicKey
java.lang.Object
org.apache.harmony.security.x509.X509PublicKey
- All Implemented Interfaces:
Serializable,Key,PublicKey
public final class X509PublicKey extends Object implements PublicKey
- See Also:
- Serialized Form
-
Field Summary
Fields inherited from interface java.security.PublicKey
serialVersionUID -
Constructor Summary
Constructors Constructor Description X509PublicKey(String algorithm, byte[] encoded, byte[] keyBytes) -
Method Summary
Modifier and Type Method Description StringgetAlgorithm()Returns the name of the algorithm of this key.byte[]getEncoded()Returns the encoded form of this key, ornullif encoding is not supported by this key.StringgetFormat()Returns the name of the format used to encode this key, ornullif it can not be encoded.StringtoString()Returns a string containing a concise, human-readable description of this object.
-
Constructor Details
-
X509PublicKey
-
-
Method Details
-
getAlgorithm
Description copied from interface:KeyReturns the name of the algorithm of this key. If the algorithm is unknown,nullis returned.- Specified by:
getAlgorithmin interfaceKey- Returns:
- the name of the algorithm of this key or
nullif the algorithm is unknown.
-
getFormat
Description copied from interface:KeyReturns the name of the format used to encode this key, ornullif it can not be encoded. -
getEncoded
public byte[] getEncoded()Description copied from interface:KeyReturns the encoded form of this key, ornullif encoding is not supported by this key.- Specified by:
getEncodedin interfaceKey- Returns:
- the encoded form of this key, or
nullif encoding is not supported by this key.
-
toString
Description copied from class:ObjectReturns a string containing a concise, human-readable description of this object. Subclasses are encouraged to override this method and provide an implementation that takes into account the object's type and data. The default implementation is equivalent to the following expression:getClass().getName() + '@' + Integer.toHexString(hashCode())
See Writing a useful
toStringmethod if you intend implementing your owntoStringmethod.
-