Class SecurityContextToken
- java.lang.Object
-
- org.apache.ws.security.message.token.SecurityContextToken
-
public class SecurityContextToken extends java.lang.Object- Version:
- 1.0
- Author:
- Ruchith Fernando
-
-
Field Summary
Fields Modifier and Type Field Description protected org.w3c.dom.ElementelementSecurity context token elementprotected org.w3c.dom.ElementelementIdentifierIdentifier element
-
Constructor Summary
Constructors Constructor Description SecurityContextToken(int version, org.w3c.dom.Document doc)Constructor to create the SCTSecurityContextToken(int version, org.w3c.dom.Document doc, java.lang.String uuid)Constructor to create the SCT with a given uuidSecurityContextToken(org.w3c.dom.Document doc)Constructor to create the SCTSecurityContextToken(org.w3c.dom.Document doc, java.lang.String uuid)Constructor to create the SCT with a given uuidSecurityContextToken(org.w3c.dom.Element elem)This is used to create a SecurityContestToken using a DOM Element
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description org.w3c.dom.ElementgetElement()Returns the dom element of thisSecurityContextTokenobject.java.lang.StringgetID()Gets the id.java.lang.StringgetIdentifier()Get the identifier.voidsetElement(org.w3c.dom.Element elem)voidsetID(java.lang.String id)Set the id of this security context token.voidsetIdentifier(org.w3c.dom.Document doc, java.lang.String uuid)Set the identifier.java.lang.StringtoString()Returns the string representation of the token.
-
-
-
Constructor Detail
-
SecurityContextToken
public SecurityContextToken(org.w3c.dom.Document doc) throws org.apache.ws.security.conversation.ConversationExceptionConstructor to create the SCT- Parameters:
doc-- Throws:
org.apache.ws.security.conversation.ConversationException
-
SecurityContextToken
public SecurityContextToken(org.w3c.dom.Document doc, java.lang.String uuid) throws org.apache.ws.security.conversation.ConversationExceptionConstructor to create the SCT with a given uuid- Parameters:
doc-- Throws:
org.apache.ws.security.conversation.ConversationException
-
SecurityContextToken
public SecurityContextToken(int version, org.w3c.dom.Document doc) throws org.apache.ws.security.conversation.ConversationExceptionConstructor to create the SCT- Parameters:
doc-- Throws:
org.apache.ws.security.conversation.ConversationException
-
SecurityContextToken
public SecurityContextToken(int version, org.w3c.dom.Document doc, java.lang.String uuid) throws org.apache.ws.security.conversation.ConversationExceptionConstructor to create the SCT with a given uuid- Parameters:
doc-- Throws:
org.apache.ws.security.conversation.ConversationException
-
SecurityContextToken
public SecurityContextToken(org.w3c.dom.Element elem) throws WSSecurityExceptionThis is used to create a SecurityContestToken using a DOM Element- Parameters:
elem- The DOM element: The security context token- Throws:
WSSecurityException- If the element passed in in not a security context token
-
-
Method Detail
-
setIdentifier
public void setIdentifier(org.w3c.dom.Document doc, java.lang.String uuid)Set the identifier.- Parameters:
name- sets a text node containing the identifier into the identifier element.
-
getIdentifier
public java.lang.String getIdentifier()
Get the identifier.- Returns:
- the data from the identifier element.
-
setElement
public void setElement(org.w3c.dom.Element elem)
-
getElement
public org.w3c.dom.Element getElement()
Returns the dom element of thisSecurityContextTokenobject.- Returns:
- the
wsse:UsernameTokenelement
-
toString
public java.lang.String toString()
Returns the string representation of the token.- Overrides:
toStringin classjava.lang.Object- Returns:
- a XML string representation
-
getID
public java.lang.String getID()
Gets the id.- Returns:
- the value of the
wsu:Idattribute of this SecurityContextToken
-
setID
public void setID(java.lang.String id)
Set the id of this security context token.- Parameters:
id- the value for thewsu:Idattribute of this SecurityContextToken
-
-