Class XMLCipher.Factory.EncryptedKeyImpl

java.lang.Object
org.apache.xml.security.encryption.XMLCipher.Factory.EncryptedTypeImpl
org.apache.xml.security.encryption.XMLCipher.Factory.EncryptedKeyImpl
All Implemented Interfaces:
EncryptedKey, EncryptedType
Enclosing class:
XMLCipher.Factory

private class XMLCipher.Factory.EncryptedKeyImpl extends XMLCipher.Factory.EncryptedTypeImpl implements EncryptedKey
  • Field Details

    • keyRecipient

      private String keyRecipient
    • referenceList

      private ReferenceList referenceList
    • carriedName

      private String carriedName
  • Constructor Details

    • EncryptedKeyImpl

      public EncryptedKeyImpl(CipherData data)
      Parameters:
      data -
  • Method Details

    • getRecipient

      public String getRecipient()
      Returns a hint as to which recipient this encrypted key value is intended for.
      Specified by:
      getRecipient in interface EncryptedKey
      Returns:
      the recipient of the EncryptedKey.
    • setRecipient

      public void setRecipient(String recipient)
      Sets the recipient for this EncryptedKey.
      Specified by:
      setRecipient in interface EncryptedKey
      Parameters:
      recipient - the recipient for this EncryptedKey.
    • getReferenceList

      public ReferenceList getReferenceList()
      Returns pointers to data and keys encrypted using this key. The reference list may contain multiple references to EncryptedKey and EncryptedData elements. This is done using KeyReference and DataReference elements respectively.
      Specified by:
      getReferenceList in interface EncryptedKey
      Returns:
      an Iterator over all the ReferenceLists contained in this EncryptedKey.
    • setReferenceList

      public void setReferenceList(ReferenceList list)
      Sets the ReferenceList to the EncryptedKey.
      Specified by:
      setReferenceList in interface EncryptedKey
      Parameters:
      list - a list of pointers to data elements encrypted using this key.
    • getCarriedName

      public String getCarriedName()
      Returns a user readable name with the key value. This may then be used to reference the key using the ds:KeyName element within ds:KeyInfo. The same CarriedKeyName label, unlike an ID type, may occur multiple times within a single document. The value of the key is to be the same in all EncryptedKey elements identified with the same CarriedKeyName label within a single XML document.
      Note that because whitespace is significant in the value of the ds:KeyName element, whitespace is also significant in the value of the CarriedKeyName element.
      Specified by:
      getCarriedName in interface EncryptedKey
      Returns:
      over all the carried names contained in this EncryptedKey.
    • setCarriedName

      public void setCarriedName(String name)
      Sets the carried name.
      Specified by:
      setCarriedName in interface EncryptedKey
      Parameters:
      name - the carried name.
    • toElement

      Element toElement()