org.glite.voms.contact

Class PathNamingScheme


public class PathNamingScheme
extends java.lang.Object

This class provides utility methods that are used for parsing, matching voms FQANs (Fully Qualified Attribute Names).

Field Summary

static Pattern
capabilityPattern
static String
capabilitySyntax
static Pattern
containerPattern
static String
containerSyntax
static Pattern
groupPattern
static String
groupSyntax
static Logger
log
static Pattern
qualifiedRolePattern
static String
qualifiedRoleSyntax
static Pattern
rolePattern
static String
roleSyntax

Method Summary

static void
checkGroup(String groupName)
This methods checks that the string passed as argument complies with the syntax used by voms to identify groups.
static void
checkRole(String roleName)
This methods checks that the string passed as argument complies with the syntax used by voms to identify roles.
static void
checkSyntax(String containerName)
This methods checks that the string passed as argument complies with the voms FQAN syntax.
static String
getGroupName(String containerName)
This method extracts group name information from the FQAN passed as argument.
static String
getRoleName(String containerName)
This method extracts the role name information from the FQAN passed as argument.
static boolean
isGroup(String groupName)
This methods checks that the FQAN passed as argument identifies a voms group.
static boolean
isQualifiedRole(String roleName)
This methods checks that the FQAN passed as argument identifies a qualified voms role, i.e., a role defined in the context of a voms group.
static boolean
isRole(String roleName)
This methods checks that the FQAN passed as argument identifies a voms role.
static String
toOldQualifiedRoleSyntax(String qualifiedRole)

Field Details

capabilityPattern

public static final Pattern capabilityPattern

capabilitySyntax

public static final String capabilitySyntax

containerPattern

public static final Pattern containerPattern

containerSyntax

public static final String containerSyntax

groupPattern

public static final Pattern groupPattern

groupSyntax

public static final String groupSyntax

log

public static final Logger log

qualifiedRolePattern

public static final Pattern qualifiedRolePattern

qualifiedRoleSyntax

public static final String qualifiedRoleSyntax

rolePattern

public static final Pattern rolePattern

roleSyntax

public static final String roleSyntax

Method Details

checkGroup

public static void checkGroup(String groupName)
This methods checks that the string passed as argument complies with the syntax used by voms to identify groups.
Parameters:
groupName - the string that has to be checked.

checkRole

public static void checkRole(String roleName)
This methods checks that the string passed as argument complies with the syntax used by voms to identify roles.
Parameters:
roleName -

checkSyntax

public static void checkSyntax(String containerName)
This methods checks that the string passed as argument complies with the voms FQAN syntax.
Parameters:
containerName - the string that must be checked for compatibility with FQAN syntax.

getGroupName

public static String getGroupName(String containerName)
This method extracts group name information from the FQAN passed as argument.
Parameters:
containerName - the FQAN
Returns:
  • A string containing the group name, if found
  • null, if no group information is contained in the FQAN passed as argument

getRoleName

public static String getRoleName(String containerName)
This method extracts the role name information from the FQAN passed as argument.
Parameters:
containerName - the FQAN
Returns:
  • A string containing the role name, if found
  • null, if no role information is contained in the FQAN passed as argument

isGroup

public static boolean isGroup(String groupName)
This methods checks that the FQAN passed as argument identifies a voms group.
Parameters:
groupName - the string to check.
Returns:
  • true, if the string passed as argument identifies a voms group.
  • false, otherwise.

isQualifiedRole

public static boolean isQualifiedRole(String roleName)
This methods checks that the FQAN passed as argument identifies a qualified voms role, i.e., a role defined in the context of a voms group.
Parameters:
roleName - the string to check.
Returns:
  • true, if the string passed as argument identifies a qualified voms role.
  • false, otherwise.

isRole

public static boolean isRole(String roleName)
This methods checks that the FQAN passed as argument identifies a voms role.
Parameters:
roleName - the string to check.
Returns:
  • true, if the string passed as argument identifies a voms role.
  • false, otherwise.

toOldQualifiedRoleSyntax

public static String toOldQualifiedRoleSyntax(String qualifiedRole)