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 Summary
Fields Modifier and Type Field Description private java.lang.StringcarriedNameprivate java.lang.StringkeyRecipientprivate ReferenceListreferenceList
-
Constructor Summary
Constructors Constructor Description EncryptedKeyImpl(CipherData data)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.StringgetCarriedName()Returns a user readable name with the key value.java.lang.StringgetRecipient()Returns a hint as to which recipient this encrypted key value is intended for.ReferenceListgetReferenceList()Returns pointers to data and keys encrypted using this key.voidsetCarriedName(java.lang.String name)Sets the carried name.voidsetRecipient(java.lang.String recipient)Sets the recipient for thisEncryptedKey.voidsetReferenceList(ReferenceList list)Sets theReferenceListto theEncryptedKey.(package private) org.w3c.dom.ElementtoElement()-
Methods inherited from class org.apache.xml.security.encryption.XMLCipher.Factory.EncryptedTypeImpl
getCipherData, getEncoding, getEncryptionMethod, getEncryptionProperties, getId, getKeyInfo, getMimeType, getType, setEncoding, setEncryptionMethod, setEncryptionProperties, setId, setKeyInfo, setMimeType, setType
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.apache.xml.security.encryption.EncryptedType
getCipherData, getEncoding, getEncryptionMethod, getEncryptionProperties, getId, getKeyInfo, getMimeType, getType, setEncoding, setEncryptionMethod, setEncryptionProperties, setId, setKeyInfo, setMimeType, setType
-
-
-
-
Field Detail
-
keyRecipient
private java.lang.String keyRecipient
-
referenceList
private ReferenceList referenceList
-
carriedName
private java.lang.String carriedName
-
-
Constructor Detail
-
EncryptedKeyImpl
public EncryptedKeyImpl(CipherData data)
- Parameters:
data-
-
-
Method Detail
-
getRecipient
public java.lang.String getRecipient()
Returns a hint as to which recipient this encrypted key value is intended for.- Specified by:
getRecipientin interfaceEncryptedKey- Returns:
- the recipient of the
EncryptedKey.
-
setRecipient
public void setRecipient(java.lang.String recipient)
Sets the recipient for thisEncryptedKey.- Specified by:
setRecipientin interfaceEncryptedKey- Parameters:
recipient- the recipient for thisEncryptedKey.
-
getReferenceList
public ReferenceList getReferenceList()
Returns pointers to data and keys encrypted using this key. The reference list may contain multiple references toEncryptedKeyandEncryptedDataelements. This is done usingKeyReferenceandDataReferenceelements respectively.- Specified by:
getReferenceListin interfaceEncryptedKey- Returns:
- an
Iteratorover all theReferenceLists contained in thisEncryptedKey.
-
setReferenceList
public void setReferenceList(ReferenceList list)
Sets theReferenceListto theEncryptedKey.- Specified by:
setReferenceListin interfaceEncryptedKey- Parameters:
list- a list of pointers to data elements encrypted using this key.
-
getCarriedName
public java.lang.String getCarriedName()
Returns a user readable name with the key value. This may then be used to reference the key using theds:KeyNameelement withinds:KeyInfo. The sameCarriedKeyNamelabel, unlike an ID type, may occur multiple times within a single document. The value of the key is to be the same in allEncryptedKeyelements identified with the sameCarriedKeyNamelabel within a single XML document.
Note that because whitespace is significant in the value of theds:KeyNameelement, whitespace is also significant in the value of theCarriedKeyNameelement.- Specified by:
getCarriedNamein interfaceEncryptedKey- Returns:
- over all the carried names contained in
this
EncryptedKey.
-
setCarriedName
public void setCarriedName(java.lang.String name)
Sets the carried name.- Specified by:
setCarriedNamein interfaceEncryptedKey- Parameters:
name- the carried name.
-
toElement
org.w3c.dom.Element toElement()
-
-