org.openpermis.editor.policy.gui.icon
Enum IconAnnotation

java.lang.Object
  extended by java.lang.Enum<IconAnnotation>
      extended by org.openpermis.editor.policy.gui.icon.IconAnnotation
All Implemented Interfaces:
Serializable, Comparable<IconAnnotation>

public enum IconAnnotation
extends Enum<IconAnnotation>

Annotations for icons.

Since:
0.3.0

Enum Constant Summary
ADD
          Add annotation.
DELETE
          Delete annotation.
EDIT
          Edit annotation.
EXCLUDE
          Exclude annotation.
MOVEDOWN
          Move down annotation.
MOVEUP
          Move up annotation.
WARNING
          Warning sign annotation.
 
Method Summary
 String annotate(String iconKey)
          Annotates the specified icon key with this annotation.
static String[] decompose(String iconKey)
          Decomposes an annotated key into its parts.
 String getKey()
          Returns the lower case key of the icon annotation.
static String getKey(String iconKey)
          Returns the key portion of a possibly annotated icon key.
static boolean isAnnotated(String iconKey)
          Tests if an icon key is annotated.
 String toString()
           
static IconAnnotation valueOf(String name)
          Returns the enum constant of this type with the specified name.
static IconAnnotation[] values()
          Returns an array containing the constants of this enum type, in the order they are declared.
 
Methods inherited from class java.lang.Enum
clone, compareTo, equals, finalize, getDeclaringClass, hashCode, name, ordinal, valueOf
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Enum Constant Detail

ADD

public static final IconAnnotation ADD
Add annotation.

Since:
0.3.0

DELETE

public static final IconAnnotation DELETE
Delete annotation.

Since:
0.3.0

EDIT

public static final IconAnnotation EDIT
Edit annotation.

Since:
0.3.0

WARNING

public static final IconAnnotation WARNING
Warning sign annotation.

Since:
0.3.0

MOVEUP

public static final IconAnnotation MOVEUP
Move up annotation.

Since:
0.9.0

MOVEDOWN

public static final IconAnnotation MOVEDOWN
Move down annotation.

Since:
0.9.0

EXCLUDE

public static final IconAnnotation EXCLUDE
Exclude annotation.

Since:
0.9.0
Method Detail

values

public static IconAnnotation[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:
for (IconAnnotation c : IconAnnotation.values())
    System.out.println(c);

Returns:
an array containing the constants of this enum type, in the order they are declared

valueOf

public static IconAnnotation valueOf(String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)

Parameters:
name - the name of the enum constant to be returned.
Returns:
the enum constant with the specified name
Throws:
IllegalArgumentException - if this enum type has no constant with the specified name
NullPointerException - if the argument is null

isAnnotated

public static boolean isAnnotated(String iconKey)
Tests if an icon key is annotated.

Parameters:
iconKey - the icon key to test.
Returns:
true if the key is annotated, false otherwise.
Since:
0.3.0

getKey

public static String getKey(String iconKey)
Returns the key portion of a possibly annotated icon key.

Parameters:
iconKey - the icon key for which to retrieve the key portion.
Returns:
the key requested.
Since:
0.3.0

decompose

public static String[] decompose(String iconKey)
Decomposes an annotated key into its parts.

Parameters:
iconKey - the icon key to decompose.
Returns:
an array of individual keys.
Throws:
IllegalArgumentException - if an unknown annotation is encountered.
Since:
0.3.0

annotate

public String annotate(String iconKey)
Annotates the specified icon key with this annotation.

Parameters:
iconKey - the icon key to annotate, must not be null.
Returns:
the annotated icon key.
Since:
0.3.0

getKey

public String getKey()
Returns the lower case key of the icon annotation.

Returns:
the lower case key of the icon annotation.
Since:
0.3.0

toString

public String toString()
Overrides:
toString in class Enum<IconAnnotation>
Since:
0.3.0


OpenPermis Role Based Access Control 0.9.0 (Build 16)
2009/08/13 07:17:21
Copyright (c) 2002-2007 Ergon Informatik AG