gnu.crypto.key
public class KeyPairCodecFactory extends Object
A Factory class to instantiate key encoder/decoder instances.
Version: $Revision: 1.2 $
Method Summary | |
---|---|
static IKeyPairCodec | getInstance(String name) Returns an instance of a keypair codec given its name. |
static IKeyPairCodec | getInstance(byte[] buffer) Returns an instance of a keypair codec given a byte array that is assumed to contain a previously encoded key (public or private). |
static IKeyPairCodec | getInstance(Key key) Returns an instance of a keypair codec given a key. |
static Set | getNames() Returns a Set of keypair codec names supported by this Factory. |
Returns an instance of a keypair codec given its name.
Parameters: name the case-insensitive key codec name.
Returns: an instance of the keypair codec, or null
if none
found.
Returns an instance of a keypair codec given a byte array that is assumed to contain a previously encoded key (public or private).
Parameters: buffer a byte array containing a previously encoded key.
Returns: an instance of the keypair codec, or null
if none
found.
Returns an instance of a keypair codec given a key.
Parameters: key the key to encode.
Returns: an instance of the keypair codec, or null
if none
found.
Returns a Set of keypair codec names supported by this Factory.
Returns: a Set of keypair codec names (Strings).