org.bitcoin.x6763.crypto.ecdsa
Class KeyPair

java.lang.Object
  extended by org.bitcoin.x6763.crypto.ecdsa.KeyPair

public class KeyPair
extends java.lang.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 private key.

Author:
x6763

Constructor Summary
KeyPair(PublicKey publicKey, PrivateKey privateKey)
          Constructs a key pair from the given public key and private key
 
Method Summary
 PrivateKey getPrivate()
          Returns the private key component of this key pair
 PublicKey getPublic()
          Returns the public key component of this key pair
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

KeyPair

public KeyPair(PublicKey publicKey,
               PrivateKey privateKey)
Constructs a key pair from the given public key and private key

Parameters:
publicKey - the public key
privateKey - the private key
Method Detail

getPublic

public PublicKey getPublic()
Returns the public key component of this key pair

Returns:
the public key

getPrivate

public PrivateKey getPrivate()
Returns the private key component of this key pair

Returns:
the private key