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

org.bouncycastle.asn1.crmf

## Class EncryptedKey

- java.lang.Object
- - org.bouncycastle.asn1.ASN1Object
  - - org.bouncycastle.asn1.crmf.EncryptedKey

- All Implemented Interfaces:
    ASN1Choice, ASN1Encodable, Encodable

      public class EncryptedKey
      extends ASN1Object
      implements ASN1Choice

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `EncryptedKey(EncryptedValue encryptedValue)`
    `EncryptedKey(EnvelopedData envelopedData)`

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `static EncryptedKey` | `getInstance(java.lang.Object o)`
    `ASN1Encodable` | `getValue()`
    `boolean` | `isEncryptedValue()`
    `ASN1Primitive` | `toASN1Primitive()` EncryptedKey ::= CHOICE { encryptedValue EncryptedValue, -- deprecated envelopedData [0] EnvelopedData } -- The encrypted private key MUST be placed in the envelopedData -- encryptedContentInfo encryptedContent OCTET STRING.

    - ### Methods inherited from class org.bouncycastle.asn1.ASN1Object

      `equals, getEncoded, getEncoded, hasEncodedTagValue, hashCode, toASN1Object`

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

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

- - ### Constructor Detail

    - #### EncryptedKey

          public EncryptedKey(EnvelopedData envelopedData)

    - #### EncryptedKey

          public EncryptedKey(EncryptedValue encryptedValue)

  - ### Method Detail

    - #### getInstance

          public static EncryptedKey getInstance(java.lang.Object o)

    - #### isEncryptedValue

          public boolean isEncryptedValue()

    - #### getValue

          public ASN1Encodable getValue()

    - #### toASN1Primitive

          public ASN1Primitive toASN1Primitive()

              EncryptedKey ::= CHOICE {
                  encryptedValue        EncryptedValue, -- deprecated
                  envelopedData     [0] EnvelopedData }
                  -- The encrypted private key MUST be placed in the envelopedData
                  -- encryptedContentInfo encryptedContent OCTET STRING.

      Specified by:
        `toASN1Primitive` in interface `ASN1Encodable`
      Specified by:
        `toASN1Primitive` in class `ASN1Object`
      Returns:
        a primitive representation of this object.