Class java.security.KeyPair
All Packages Class Hierarchy This Package Previous Next Index
Class java.security.KeyPair
Object
|
+----java.security.KeyPair
- public final class KeyPair
- extends Object
This class is a simple holder for a key pair (a public key and a
private key). It does not enforce any security, and, when initialized,
should be treated like a PrivateKey.
- Version:
- 1.4 98/10/05
- Author:
- Benjamin Renaud
- See Also:
- PublicKey, PrivateKey
-
java.security.KeyPair(PublicKey, PrivateKey)
- Constructs a key with the specified public key and private key.
-
getPrivate()
- Returns the private key from this key pair.
-
getPublic()
- Returns the public key from this key pair.
KeyPair
public KeyPair(PublicKey publicKey,
PrivateKey privateKey)
- Constructs a key with the specified public key and private key.
- Parameters:
- publicKey - the public key.
- privateKey - the private key.
getPrivate
public java.security.PrivateKey getPrivate()
- Returns the private key from this key pair.
- Returns:
- the private key.
getPublic
public java.security.PublicKey getPublic()
- Returns the public key from this key pair.
- Returns:
- the public key.
All Packages Class Hierarchy This Package Previous Next Index