com.sun.identity.federation.message.common
Class EncryptableNameIdentifier

java.lang.Object
  extended by com.sun.identity.federation.message.common.EncryptableNameIdentifier

public class EncryptableNameIdentifier
extends Object

This class contains methods for encrypting the NameIdentifier object.


Constructor Summary
protected EncryptableNameIdentifier()
          Default Constructor.
  EncryptableNameIdentifier(Element nameIdentifier)
          Constructs a EncryptedNameIdentifer element from the Document Element.
  EncryptableNameIdentifier(NameIdentifier ni)
          Constructor creates EncryptableNameIdentifier object.
  EncryptableNameIdentifier(String name, String nameQualifier, String format, Date issueInstant, String nonce)
          Consturctor creates EncryptableNameIdentifier object.
 
Method Summary
 String getFormat()
          Returns value of the Format attribute.
 Date getIssueInstant()
          Returns the Issue Instant.
 String getName()
          Returns the name from NameQualifier.
 String getNameQualifier()
          Returns the NameQualifier attribute.
 String getNonce()
          Retunrs the nounce.
 boolean setFormat(String format)
          Sets the Format attribute.
protected  boolean setName(String name)
          Sets the name attribute.
 boolean setNameQualifier(String nameQualifier)
          Sets nameQualifier attribute.
 String toString()
          Returns a String representation of the element.
 String toString(boolean includeNS, boolean declareNS)
          Returns String representation of the <EncryptableNameIdentifier> element.
 

Constructor Detail

EncryptableNameIdentifier

protected EncryptableNameIdentifier()
Default Constructor.


EncryptableNameIdentifier

public EncryptableNameIdentifier(NameIdentifier ni)
Constructor creates EncryptableNameIdentifier object.

Parameters:
ni - the NameIdentifier object to be encrypted.
Throws:
FSException - if there is an error.

EncryptableNameIdentifier

public EncryptableNameIdentifier(String name,
                                 String nameQualifier,
                                 String format,
                                 Date issueInstant,
                                 String nonce)
Consturctor creates EncryptableNameIdentifier object.

Parameters:
name -
nameQualifier -
format -
issueInstant - the Issue Instant
nonce -
Throws:
FSException - if there is an error.

EncryptableNameIdentifier

public EncryptableNameIdentifier(Element nameIdentifier)
Constructs a EncryptedNameIdentifer element from the Document Element.

Parameters:
nameIdentifier - a org.w3c.dom.Element representing DOM tree for EncryptableNameIdentifier object
Throws:
FSException - if it could not process the org.w3c.dom.Element properly, implying that there is an error in the sender or in the element definition.
Method Detail

getFormat

public String getFormat()
Returns value of the Format attribute.

Returns:
value of the Format attribute.

setFormat

public boolean setFormat(String format)
Sets the Format attribute.

Parameters:
format - the value of the Format attribute.
Returns:
true if the operation succeeds.

getNameQualifier

public String getNameQualifier()
Returns the NameQualifier attribute.

Returns:
the nameQualifier.

setNameQualifier

public boolean setNameQualifier(String nameQualifier)
Sets nameQualifier attribute.

Parameters:
nameQualifier - the nameQualifier attribute.
Returns:
true if operation succeeds.

setName

protected boolean setName(String name)
Sets the name attribute.

Parameters:
name - name of the nameQualifier.
Returns:
true if operation succeeds.

getName

public String getName()
Returns the name from NameQualifier.

Returns:
the name from NameQualifier.

getNonce

public String getNonce()
Retunrs the nounce.

Returns:
the nounce.

getIssueInstant

public Date getIssueInstant()
Returns the Issue Instant.

Returns:
the Issue Instant.

toString

public String toString()
Returns a String representation of the element.

Overrides:
toString in class Object
Returns:
A string containing the valid XML for this element By default name space name is prepended to the element name example <saml:EncryptableNameIdentifier>.

toString

public String toString(boolean includeNS,
                       boolean declareNS)
Returns String representation of the <EncryptableNameIdentifier> element.

Parameters:
includeNS - Determines whether or not the namespace qualifier is prepended to the Element when converted.
declareNS - Determines whether or not the namespace is declared within the Element.
Returns:
A string containing the valid XML for this element