org.jboss.identity.federation.api.wstrust
Class WSTrustUtil

java.lang.Object
  extended by org.jboss.identity.federation.api.wstrust.WSTrustUtil

public class WSTrustUtil
extends java.lang.Object

Utility class that provides methods for parsing/creating WS-Trust elements.

Author:
Stefan Guilhen

Constructor Summary
WSTrustUtil()
           
 
Method Summary
static LifetimeType createDefaultLifetime(long tokenTimeout)
           Creates a LifetimeType instance that specifies a range of time that starts at the current GMT time and has the specified duration in milliseconds.
static long getCurrentGMTTime()
           Obtains the current GMT time in milliseconds.
static java.lang.String parseAppliesTo(AppliesTo appliesTo)
           Parses the contents of the AppliesTo element and returns the address the uniquely identify the service provider.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

WSTrustUtil

public WSTrustUtil()
Method Detail

parseAppliesTo

public static java.lang.String parseAppliesTo(AppliesTo appliesTo)

Parses the contents of the AppliesTo element and returns the address the uniquely identify the service provider.

Parameters:
appliesTo - the AppliesTo instance to be parsed.
Returns:
the address of the service provider.

createDefaultLifetime

public static LifetimeType createDefaultLifetime(long tokenTimeout)

Creates a LifetimeType instance that specifies a range of time that starts at the current GMT time and has the specified duration in milliseconds.

Parameters:
tokenTimeout - the token timeout value (in milliseconds).
Returns:
the constructed LifetimeType instance.

getCurrentGMTTime

public static long getCurrentGMTTime()

Obtains the current GMT time in milliseconds.

Returns:
a long representing the current GMT time in milliseconds.


Copyright © 2009 JBoss Inc.. All Rights Reserved.