edu.internet2.middleware.grouper.permissions.limits
Class PermissionLimitUtils

java.lang.Object
  extended by edu.internet2.middleware.grouper.permissions.limits.PermissionLimitUtils

public class PermissionLimitUtils
extends Object

utils for permission limits


Field Summary
static String CALENDAR
          name of variable in the env map
static String DAY_OF_WEEK
          name of variable in the env map
static String HOUR_OF_DAY
          name of variable in the env map
static String LIMIT_AMOUNT_LESS_THAN
           
static String LIMIT_AMOUNT_LESS_THAN_OR_EQUAL
           
static String LIMIT_DEF
          limits def extension
static String LIMIT_DEF_INT
          limits def extension
static String LIMIT_DEF_MARKER
          limits def extension
static String LIMIT_EL
           
static String LIMIT_IP_ON_NETWORK_REALM
           
static String LIMIT_IP_ON_NETWORKS
           
static String LIMIT_LABELS_CONTAIN
           
static String LIMIT_WEEKDAY_9_TO_5
           
static String MINUTE_OF_HOUR
          name of variable in the env map
static String MONTH_OF_YEAR
          name of variable in the env map
 
Constructor Summary
PermissionLimitUtils()
           
 
Method Summary
static void addStandardLimitVariablesIfNotExist(Map<String,Object> limitEnvVarsObject)
          add standard limit variables
static String attributeLimitStemName()
          return the stem name where the limit attributes go, without colon on end
static void clearLimitLogicMap()
          for testing, clear this to put things in the api test config
static AttributeDefName limitAmountLessThanAttributeDefName()
          amount less than
static String limitAmountLessThanName()
          limit amount less than
static AttributeDefName limitAmountLessThanOrEqualAttributeDefName()
          amount less than or equal
static String limitAmountLessThanOrEqualName()
          limit amount less than or equal
static AttributeDef limitAttributeDef()
          return the limit type attribute def this throws exception if cant find
static AttributeDef limitAttributeDefInt()
          return the limit type attribute def this throws exception if cant find
static AttributeDef limitAttributeDefMarker()
          return the limit type attribute def this throws exception if cant find
static AttributeDefName limitElAttributeDefName()
          regex limit
static Map<String,Object> limitElClasses()
          custom el instances to add to the variable map for limit EL
static String limitElName()
          limit el name
static AttributeDefName limitIpOnNetworkRealmAttributeDefName()
          amount less than or equal
static String limitIpOnNetworkRealmName()
          limit ip on network realm
static AttributeDefName limitIpOnNetworksAttributeDefName()
          amount less than or equal
static String limitIpOnNetworksName()
          limit ip on networks
static AttributeDefName limitLabelsContainAttributeDefName()
          amount labels contain
static String limitLabelsContainName()
          limit labels contain a label
static Set<String> limitRealms()
          get a logic instance based on attributeDefName of the limit
static AttributeDefName limitWeekday9to5AttributeDefName()
          weekday 9 to 5
static String limitWeekday9to5Name()
          limit el name
static PermissionLimitInterface logicInstance(String limitName)
          get a logic instance based on attributeDefName of the limit
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

MONTH_OF_YEAR

public static final String MONTH_OF_YEAR
name of variable in the env map

See Also:
Constant Field Values

MINUTE_OF_HOUR

public static final String MINUTE_OF_HOUR
name of variable in the env map

See Also:
Constant Field Values

HOUR_OF_DAY

public static final String HOUR_OF_DAY
name of variable in the env map

See Also:
Constant Field Values

DAY_OF_WEEK

public static final String DAY_OF_WEEK
name of variable in the env map

See Also:
Constant Field Values

CALENDAR

public static final String CALENDAR
name of variable in the env map

See Also:
Constant Field Values

LIMIT_DEF

public static final String LIMIT_DEF
limits def extension

See Also:
Constant Field Values

LIMIT_DEF_INT

public static final String LIMIT_DEF_INT
limits def extension

See Also:
Constant Field Values

LIMIT_DEF_MARKER

public static final String LIMIT_DEF_MARKER
limits def extension

See Also:
Constant Field Values

LIMIT_EL

public static final String LIMIT_EL
See Also:
Constant Field Values

LIMIT_WEEKDAY_9_TO_5

public static final String LIMIT_WEEKDAY_9_TO_5
See Also:
Constant Field Values

LIMIT_AMOUNT_LESS_THAN

public static final String LIMIT_AMOUNT_LESS_THAN
See Also:
Constant Field Values

LIMIT_AMOUNT_LESS_THAN_OR_EQUAL

public static final String LIMIT_AMOUNT_LESS_THAN_OR_EQUAL
See Also:
Constant Field Values

LIMIT_IP_ON_NETWORKS

public static final String LIMIT_IP_ON_NETWORKS
See Also:
Constant Field Values

LIMIT_IP_ON_NETWORK_REALM

public static final String LIMIT_IP_ON_NETWORK_REALM
See Also:
Constant Field Values

LIMIT_LABELS_CONTAIN

public static final String LIMIT_LABELS_CONTAIN
See Also:
Constant Field Values
Constructor Detail

PermissionLimitUtils

public PermissionLimitUtils()
Method Detail

limitAttributeDef

public static AttributeDef limitAttributeDef()
return the limit type attribute def this throws exception if cant find

Returns:
the attribute def

limitAttributeDefInt

public static AttributeDef limitAttributeDefInt()
return the limit type attribute def this throws exception if cant find

Returns:
the attribute def

limitAttributeDefMarker

public static AttributeDef limitAttributeDefMarker()
return the limit type attribute def this throws exception if cant find

Returns:
the attribute def

attributeLimitStemName

public static String attributeLimitStemName()
return the stem name where the limit attributes go, without colon on end

Returns:
stem name

limitElName

public static String limitElName()
limit el name

Returns:
name

limitElAttributeDefName

public static AttributeDefName limitElAttributeDefName()
regex limit

Returns:
the attribute def name

limitWeekday9to5Name

public static String limitWeekday9to5Name()
limit el name

Returns:
name

limitWeekday9to5AttributeDefName

public static AttributeDefName limitWeekday9to5AttributeDefName()
weekday 9 to 5

Returns:
the attribute def name

limitAmountLessThanName

public static String limitAmountLessThanName()
limit amount less than

Returns:
name

limitAmountLessThanAttributeDefName

public static AttributeDefName limitAmountLessThanAttributeDefName()
amount less than

Returns:
the attribute def name

limitAmountLessThanOrEqualName

public static String limitAmountLessThanOrEqualName()
limit amount less than or equal

Returns:
name

limitAmountLessThanOrEqualAttributeDefName

public static AttributeDefName limitAmountLessThanOrEqualAttributeDefName()
amount less than or equal

Returns:
the attribute def name

limitIpOnNetworksName

public static String limitIpOnNetworksName()
limit ip on networks

Returns:
name

limitIpOnNetworksAttributeDefName

public static AttributeDefName limitIpOnNetworksAttributeDefName()
amount less than or equal

Returns:
the attribute def name

limitIpOnNetworkRealmName

public static String limitIpOnNetworkRealmName()
limit ip on network realm

Returns:
name

limitIpOnNetworkRealmAttributeDefName

public static AttributeDefName limitIpOnNetworkRealmAttributeDefName()
amount less than or equal

Returns:
the attribute def name

limitLabelsContainName

public static String limitLabelsContainName()
limit labels contain a label

Returns:
name

limitLabelsContainAttributeDefName

public static AttributeDefName limitLabelsContainAttributeDefName()
amount labels contain

Returns:
the attribute def name

addStandardLimitVariablesIfNotExist

public static void addStandardLimitVariablesIfNotExist(Map<String,Object> limitEnvVarsObject)
add standard limit variables

Parameters:
limitEnvVarsObject -

limitRealms

public static Set<String> limitRealms()
get a logic instance based on attributeDefName of the limit

Returns:
an instance of the interface

clearLimitLogicMap

public static void clearLimitLogicMap()
for testing, clear this to put things in the api test config


logicInstance

public static PermissionLimitInterface logicInstance(String limitName)
get a logic instance based on attributeDefName of the limit

Parameters:
limitName - name of the attribute def name
Returns:
an instance of the interface

limitElClasses

public static Map<String,Object> limitElClasses()
custom el instances to add to the variable map for limit EL

Returns:
the map