org.jboss.security.acl
Class Util

java.lang.Object
  extended by org.jboss.security.acl.Util

public class Util
extends Object

Utility class used by the ACL implementation.

Author:
Stefan Guilhen

Constructor Summary
Util()
           
 
Method Summary
static String getIdentityAsString(org.jboss.security.identity.Identity identity)
           Returns a String representation of the specified identity.
static org.jboss.security.identity.Identity getIdentityFromString(String identityString)
           Builds and returns an identity from the specified String representation.
static String getResourceAsString(org.jboss.security.authorization.Resource resource)
           Returns a String representation of the specified resource.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Util

public Util()
Method Detail

getResourceAsString

public static String getResourceAsString(org.jboss.security.authorization.Resource resource)

Returns a String representation of the specified resource. The format of this representation is as follows: resource_fqn:resource_id, where resource_fqn is the fully-qualified name of the resource class, and resource_id is the unique identifier of the resource.

Parameters:
resource - the Resource to be converted.
Returns:
a String representation of the resource.

getIdentityAsString

public static String getIdentityAsString(org.jboss.security.identity.Identity identity)

Returns a String representation of the specified identity. The format of this representation is as follows: identity_fqn:identity_name, where identity_fqn is the fully-qualified name of the identity class, and identity_name is a String representing the name of the identity.

Parameters:
identity - the Identity to be converted.
Returns:
a String representation of the identity.

getIdentityFromString

public static org.jboss.security.identity.Identity getIdentityFromString(String identityString)

Builds and returns an identity from the specified String representation. It parses the identityString argument, and passes the parsed identity class, and identity name to the IdentityFactory to retrieve an instance of Identity.

Parameters:
identityString - a String representation of the identity to be created.
Returns:
the constructed Identity instance.


Copyright © 2009 JBoss Inc.. All Rights Reserved.