com.sun.identity.saml.protocol
Class AuthenticationQuery
java.lang.Object
|
+--com.sun.identity.saml.protocol.Query
|
+--com.sun.identity.saml.protocol.SubjectQuery
|
+--com.sun.identity.saml.protocol.AuthenticationQuery
- public class AuthenticationQuery
- extends SubjectQuery
This concrete class extends from the abstract base class
SubjectQuery
.
It represents the query for an authentication assertion. It corresponds
to the <samlp:AuthenticationQueryType>
in the SAML
protocol schema.
Method Summary |
java.lang.String |
getAuthenticationMethod()
Returns the AuthenticationMethod . |
int |
getQueryType()
Returns the type of this query. |
java.lang.String |
toString()
Translates the AuthenticationQuery to an XML document
String based on the AuthenticationQuery schema described
above. |
java.lang.String |
toString(boolean includeNS,
boolean declareNS)
Creates a String representation of the
element. |
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
AuthenticationQuery
public AuthenticationQuery(org.w3c.dom.Element element)
throws SAMLException
- This constructor is used to build an Authentication Query from a DOM
tree that was built from the XML string.
- Parameters:
element
- the DOM tree element which contains an Authentication
Query.- Throws:
SAMLException
- when an error occurs.
AuthenticationQuery
public AuthenticationQuery(Subject subject,
java.lang.String authMethod)
throws SAMLException
- Constructor.
- Parameters:
subject
- the Subject of the AuthenticationQuery
.authMethod
- the AuthenticationMethod
in string
format. It could be null.- Throws:
SAMLException
-
AuthenticationQuery
public AuthenticationQuery(Subject subject)
throws SAMLException
- Constructor.
- Parameters:
subject
- The Subject of the AuthenticationQuery
.- Throws:
SAMLException
-
getAuthenticationMethod
public java.lang.String getAuthenticationMethod()
- Returns the
AuthenticationMethod
.
- Returns:
AuthenticationMethod
in string format; or null
if there is none.
getQueryType
public int getQueryType()
- Returns the type of this query.
- Overrides:
getQueryType
in class Query
- Returns:
Query.AUTHENTICATION_QUERY
.
toString
public java.lang.String toString()
- Translates the
AuthenticationQuery
to an XML document
String based on the AuthenticationQuery
schema described
above.
- Overrides:
toString
in class java.lang.Object
- Returns:
- An XML String representing the
AuthenticationQuery
.
toString
public java.lang.String toString(boolean includeNS,
boolean declareNS)
- Creates a String representation of the
element.
- Overrides:
toString
in class Query
- Parameters:
includeNS
- Determines whether or not the namespace qualifier
is prepended to the Element when converteddeclareNS
- Determines whether or not the namespace is declared
within the Element.- Returns:
- A string containing the valid XML for this element
Copyright 2005 Sun Microsystems, Inc. All rights reserved. Use is subject to license terms.