PrivateKeyInfoFactory (Bouncy Castle Library 1.54 API Specification)
Date: 2015-12-29

org.bouncycastle.crypto.util

## Class PrivateKeyInfoFactory

- java.lang.Object
- - org.bouncycastle.crypto.util.PrivateKeyInfoFactory

-     public class PrivateKeyInfoFactory
      extends java.lang.Object

  Factory to create ASN.1 private key info objects from lightweight private keys.

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `PrivateKeyInfoFactory()`

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `static PrivateKeyInfo` | `createPrivateKeyInfo(AsymmetricKeyParameter privateKey)` Create a PrivateKeyInfo representation of a private key.

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### PrivateKeyInfoFactory

          public PrivateKeyInfoFactory()

  - ### Method Detail

    - #### createPrivateKeyInfo

          public static PrivateKeyInfo createPrivateKeyInfo(AsymmetricKeyParameter privateKey)
                                                     throws java.io.IOException

      Create a PrivateKeyInfo representation of a private key.
      Parameters:
        `privateKey` - the SubjectPublicKeyInfo encoding
      Returns:
        the appropriate key parameter
      Throws:
        `java.io.IOException` - on an error encoding the key