edu.internet2.middleware.shibboleth.idp.session.impl
Class AuthenticationMethodInformationImpl

java.lang.Object
  extended by edu.internet2.middleware.shibboleth.idp.session.impl.AuthenticationMethodInformationImpl
All Implemented Interfaces:
AuthenticationMethodInformation, Serializable

public class AuthenticationMethodInformationImpl
extends Object
implements AuthenticationMethodInformation

Information about an authentication method employed by a user.

See Also:
Serialized Form

Field Summary
private  long authenticationDuration
          The lifetime of the authentication method.
private  long authenticationInstant
          The timestamp at which authentication occurred.
private  String authenticationMethod
          The authentication method (a URI).
private  Principal authenticationPrincipal
          Principal created by the authentication method.
private  Subject authenticationSubject
          Subject created by this authentication mechanism.
private  long expirationInstant
          Time when this method expires.
private static long serialVersionUID
          Serial version UID.
 
Constructor Summary
AuthenticationMethodInformationImpl(Subject subject, Principal principal, String method, org.joda.time.DateTime instant, long duration)
          Default constructor.
 
Method Summary
 boolean equals(Object obj)
          
 long getAuthenticationDuration()
          Gets the duration of this authentication method.
 org.joda.time.DateTime getAuthenticationInstant()
          Gets the time the user authenticated with this member.
 String getAuthenticationMethod()
          Gets the unique identifier for the authentication method.
 Principal getAuthenticationPrincipal()
          Gets the principal, for the Subject of the session, created by this authentication method.
 Subject getAuthenticationSubject()
          Gets the Subject created by this authentication method.
 int hashCode()
          
 boolean isExpired()
          Gets whether this authentication method has expired and is not longer valid for use in constructing new sessions.
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

serialVersionUID

private static final long serialVersionUID
Serial version UID.

See Also:
Constant Field Values

authenticationSubject

private Subject authenticationSubject
Subject created by this authentication mechanism.


authenticationPrincipal

private Principal authenticationPrincipal
Principal created by the authentication method.


authenticationMethod

private String authenticationMethod
The authentication method (a URI).


authenticationInstant

private long authenticationInstant
The timestamp at which authentication occurred.


authenticationDuration

private long authenticationDuration
The lifetime of the authentication method.


expirationInstant

private long expirationInstant
Time when this method expires.

Constructor Detail

AuthenticationMethodInformationImpl

public AuthenticationMethodInformationImpl(Subject subject,
                                           Principal principal,
                                           String method,
                                           org.joda.time.DateTime instant,
                                           long duration)
Default constructor. This constructor does NOT add the given principal to the given subject.

Parameters:
subject - subject associated with the user's session
principal - principal created by the authentication method
method - The unique identifier for the authentication method
instant - The time the user authenticated with this member
duration - The duration of this authentication method
Method Detail

getAuthenticationSubject

public Subject getAuthenticationSubject()
Gets the Subject created by this authentication method.

Specified by:
getAuthenticationSubject in interface AuthenticationMethodInformation
Returns:
subject created by this authentication method

getAuthenticationPrincipal

public Principal getAuthenticationPrincipal()
Gets the principal, for the Subject of the session, created by this authentication method.

Specified by:
getAuthenticationPrincipal in interface AuthenticationMethodInformation
Returns:
principal created by this authentication method

getAuthenticationMethod

public String getAuthenticationMethod()
Gets the unique identifier for the authentication method.

Specified by:
getAuthenticationMethod in interface AuthenticationMethodInformation
Returns:
unique identifier for the authentication method

getAuthenticationInstant

public org.joda.time.DateTime getAuthenticationInstant()
Gets the time the user authenticated with this member.

Specified by:
getAuthenticationInstant in interface AuthenticationMethodInformation
Returns:
time the user authenticated with this member

getAuthenticationDuration

public long getAuthenticationDuration()
Gets the duration of this authentication method.

Specified by:
getAuthenticationDuration in interface AuthenticationMethodInformation
Returns:
duration of this authentication method

isExpired

public boolean isExpired()
Gets whether this authentication method has expired and is not longer valid for use in constructing new sessions.

Specified by:
isExpired in interface AuthenticationMethodInformation
Returns:
whether this authentication method has expired

hashCode

public int hashCode()

Overrides:
hashCode in class Object

equals

public boolean equals(Object obj)

Overrides:
equals in class Object


Copyright © 1999-2012. All Rights Reserved.