com.sun.identity.federation.message
Class FSLogoutNotification

java.lang.Object
  extended by com.sun.identity.saml.protocol.AbstractRequest
      extended by com.sun.identity.federation.message.FSLogoutNotification

public class FSLogoutNotification
extends AbstractRequest

This class contains methods to construct a LogoutRequest object.


Field Summary
protected  String id
           
protected  Date notOnOrAfter
           
protected  String sessionIndex
           
protected  String signatureString
           
protected  String xmlString
           
 
Fields inherited from class com.sun.identity.saml.protocol.AbstractRequest
issueInstant, majorVersion, minorVersion, requestID, respondWiths, signature, signed, valid
 
Constructor Summary
FSLogoutNotification()
          Default Constructor.
FSLogoutNotification(Element root)
          Constructor creates FSLogoutNotification object from Document Element.
FSLogoutNotification(String requestId, String providerID, NameIdentifier nameId, String relayState)
          Consturctor creates FSLogoutNotification object.
 
Method Summary
 String getID()
          Returns the value of id attribute.
 int getMinorVersion()
          Returns the value of MinorVersion attribute.
 NameIdentifier getNameIdentifier()
          Returns the NameIdentifier object.
 String getProviderId()
          Returns value of ProviderID attribute.
 String getRelayState()
          Returns the value of RelayState attribute.
 String getSessionIndex()
          Returns value of SessionIndex attribute.
 String getSignatureString()
          Returns a signed XML string.
static FSLogoutNotification parseURLEncodedRequest(HttpServletRequest request)
          Returns FSLogoutNotification object.
static FSLogoutNotification parseXML(String xml)
          Constructor create FSLogoutNotification from a XML string.
 void setID(String id)
          Sets the value of id attribute.
 void setMinorVersion(int version)
          Sets the value of MinorVersion attribute.
 void setNameIdentifier(NameIdentifier nameId)
          Sets the NameIdentifier object.
 void setProviderId(String providerID)
          Sets value of ProviderID attribute.
 void setRelayState(String relayState)
          Sets the value of RelayState attribute.
 void setSessionIndex(String sessionIndex)
          Sets value of SessionIndex attribute.
 boolean setSignature(Element elem)
          Sets the Element signature.
 void signXML()
          Unsupported operation.
 void signXML(String certAlias)
          Signs the FSLogoutNotification object.
 String toBASE64EncodedString()
          Returns a Base64 Encoded String.
 String toURLEncodedQueryString()
          Returns an URL Encoded String.
 String toXMLString()
          Returns the string representation of this object.
 String toXMLString(boolean includeNS, boolean declareNS)
          Returns the string representation of this object.
 String toXMLString(boolean includeNS, boolean declareNS, boolean includeHeader)
          Returns the string representation of this object.
 
Methods inherited from class com.sun.identity.saml.protocol.AbstractRequest
addRespondWith, getIssueInstant, getMajorVersion, getRequestID, getRespondWith, getSignature, isSignatureValid, isSigned, setIssueInstant, setMajorVersion, setRequestID
 

Field Detail

sessionIndex

protected String sessionIndex

xmlString

protected String xmlString

signatureString

protected String signatureString

id

protected String id

notOnOrAfter

protected Date notOnOrAfter
Constructor Detail

FSLogoutNotification

public FSLogoutNotification()
Default Constructor.


FSLogoutNotification

public FSLogoutNotification(Element root)
                     throws FSMsgException
Constructor creates FSLogoutNotification object from Document Element.

Parameters:
root - the Document Element object.
Throws:
FSMsgException - if there is an error creating this object.

FSLogoutNotification

public FSLogoutNotification(String requestId,
                            String providerID,
                            NameIdentifier nameId,
                            String relayState)
                     throws FSMsgException
Consturctor creates FSLogoutNotification object.

Parameters:
requestId - the RequestId attribute.
providerID - the ProviderID attribute.
nameId - the NameIdentifier object.
relayState - the RelayState attribute.
Throws:
FSMsgException - if there is an error creating this object.
Method Detail

getID

public String getID()
Returns the value of id attribute.

Returns:
the value of id attribute.
See Also:
FSLogoutNotification.setID(String)

setID

public void setID(String id)
Sets the value of id attribute.

Parameters:
id - the value of id attribute.
See Also:
FSLogoutNotification.getID()

setRelayState

public void setRelayState(String relayState)
Sets the value of RelayState attribute.

Parameters:
relayState - the value of RelayState attribute.

getRelayState

public String getRelayState()
Returns the value of RelayState attribute.

Returns:
the value of RelayState attribute.

getSignatureString

public String getSignatureString()
Returns a signed XML string.

Returns:
a signed XML string.

getMinorVersion

public int getMinorVersion()
Returns the value of MinorVersion attribute.

Overrides:
getMinorVersion in class AbstractRequest
Returns:
the value of MinorVersion attribute.
See Also:
FSLogoutNotification.setMinorVersion(int)

setMinorVersion

public void setMinorVersion(int version)
Sets the value of MinorVersion attribute.

Overrides:
setMinorVersion in class AbstractRequest
Parameters:
version - the value of MinorVersion attribute.
See Also:
FSLogoutNotification.getMinorVersion()

toXMLString

public String toXMLString(boolean includeNS,
                          boolean declareNS)
                   throws FSMsgException
Returns the string representation of this object.

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
Throws:
FSMsgException - if there is an error creating XML string from this object.

toXMLString

public String toXMLString(boolean includeNS,
                          boolean declareNS,
                          boolean includeHeader)
                   throws FSMsgException
Returns the string representation of this object.

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.
includeHeader - Determines whether the output include the xml declaration header.
Returns:
a string containing the valid XML for this element
Throws:
FSMsgException - if there is an error creating XML string from this object.

toXMLString

public String toXMLString()
                   throws FSMsgException
Returns the string representation of this object.

Returns:
a string containing the valid XML for this element
Throws:
FSMsgException - if there is an error creating XML string from this object.

parseXML

public static FSLogoutNotification parseXML(String xml)
                                     throws FSMsgException
Constructor create FSLogoutNotification from a XML string.

Parameters:
xml - the XML string.
Throws:
FSMsgException - if there is an error creating this object.

getProviderId

public String getProviderId()
Returns value of ProviderID attribute.

Returns:
value of ProviderID attribute.
See Also:
FSLogoutNotification.setProviderId(String)

setProviderId

public void setProviderId(String providerID)
Sets value of ProviderID attribute.

Parameters:
providerID - value of ProviderID attribute.
See Also:
FSLogoutNotification.getProviderId()

getSessionIndex

public String getSessionIndex()
Returns value of SessionIndex attribute.

Returns:
value of SessionIndex attribute.
See Also:
FSLogoutNotification.setSessionIndex(String)

setSessionIndex

public void setSessionIndex(String sessionIndex)
Sets value of SessionIndex attribute.

Parameters:
sessionIndex - value of SessionIndex attribute.
See Also:
FSLogoutNotification.getSessionIndex()

getNameIdentifier

public NameIdentifier getNameIdentifier()
Returns the NameIdentifier object.

Returns:
the NameIdentifier object.
See Also:
FSLogoutNotification.setNameIdentifier(NameIdentifier)

setNameIdentifier

public void setNameIdentifier(NameIdentifier nameId)
Sets the NameIdentifier object.

Parameters:
nameId - the NameIdentifier object.
See Also:
FSLogoutNotification.getNameIdentifier()

toURLEncodedQueryString

public String toURLEncodedQueryString()
                               throws FSMsgException
Returns an URL Encoded String.

Returns:
a url encoded query string.
Throws:
FSMsgException - if there is an error.

toBASE64EncodedString

public String toBASE64EncodedString()
                             throws FSMsgException
Returns a Base64 Encoded String.

Returns:
a Base64 Encoded String.
Throws:
FSMsgException - if there is an error encoding the string.

parseURLEncodedRequest

public static FSLogoutNotification parseURLEncodedRequest(HttpServletRequest request)
                                                   throws FSMsgException
Returns FSLogoutNotification object. The object is created by parsing the HttpServletRequest object.

Parameters:
request - the HttpServletRequest object.
Returns:
FSLogoutNotification object.
Throws:
FSMsgException - if there is an error creating FSAuthnRequest object.

signXML

public void signXML()
             throws SAMLException
Unsupported operation.

Specified by:
signXML in class AbstractRequest
Throws:
SAMLException - If could not sign the object.

signXML

public void signXML(String certAlias)
             throws SAMLException
Signs the FSLogoutNotification object.

Parameters:
certAlias - the Certificate Alias
Throws:
SAMLException - if FSFederationTerminationNotification cannot be signed.

setSignature

public boolean setSignature(Element elem)
Sets the Element signature.

Overrides:
setSignature in class AbstractRequest
Parameters:
elem - the Element object
Returns:
true if signature is set otherwise false