com.uwyn.rife.authentication
Interface SessionAttributes

All Known Implementing Classes:
Authenticated, DatabaseAuthenticated, FactoryPropertyAuthenticated, MemoryAuthenticated, MixedAuthenticated, PurgingDatabaseAuthenticated, PurgingMemoryAuthenticated, PurgingMixedAuthenticated, RoleUserAuthenticated

public interface SessionAttributes

This interface defines the methods that classes with SessionAttributes functionalities have to implement.

A SessionAttributes class defines the context in which a session is being validated. The presence and the value of certain attributes can influence whether the access to a secured resource is authorized or prohibited for a particular user.

For example, regular users have access to everything besides ithe administration interface. Resources that are restricted to administrators can for example have a role attribute that is set to admin. A SessionValidator instance can detect the presence of this attribute and act accordingly to verify if the user has the authorities of the required role (in this case, administrator rights).

Since:
1.0
Version:
$Revision: 3643 $
Author:
Geert Bevin (gbevin[remove] at uwyn dot com)
See Also:
SessionValidator

Method Summary
 String getAttribute(String key)
          Retrieves the value of a particular attribute.
 boolean hasAttribute(String key)
          Checks if a certain attribute is present.
 

Method Detail

hasAttribute

boolean hasAttribute(String key)
Checks if a certain attribute is present.

Parameters:
key - The key that identifies the attribute.
Returns:
true if the attribute was present; or

false otherwise.

Since:
1.0
See Also:
getAttribute(String)

getAttribute

String getAttribute(String key)
Retrieves the value of a particular attribute.

Parameters:
key - The key that identifies the attribute.
Returns:
A String instance with the value of the requested attribute; or

null if the attribute couldn't be found.

Since:
1.0
See Also:
hasAttribute(String)


Copyright © 2001-2007 Uwyn sprl/bvba. All Rights Reserved.