Save This Page
Home » openjdk-7 » java » security » spec » [javadoc | source]
java.security.spec
abstract public class: EncodedKeySpec [javadoc | source]
java.lang.Object
   java.security.spec.EncodedKeySpec

All Implemented Interfaces:
    KeySpec

Direct Known Subclasses:
    X509EncodedKeySpec, PKCS8EncodedKeySpec

This class represents a public or private key in encoded format.
Constructor:
 public EncodedKeySpec(byte[] encodedKey) 
Method from java.security.spec.EncodedKeySpec Summary:
getEncoded,   getFormat
Methods from java.lang.Object:
clone,   equals,   finalize,   getClass,   hashCode,   notify,   notifyAll,   toString,   wait,   wait,   wait
Method from java.security.spec.EncodedKeySpec Detail:
 public byte[] getEncoded() 
    Returns the encoded key.
 abstract public String getFormat()
    Returns the name of the encoding format associated with this key specification.

    If the opaque representation of a key (see Key ) can be transformed (see KeyFactory ) into this key specification (or a subclass of it), getFormat called on the opaque key returns the same value as the getFormat method of this key specification.