janino.net

org.codehaus.janino
Class Java.Modifiers

java.lang.Object
  extended by org.codehaus.janino.Java.Modifiers
Enclosing class:
Java

public static class Java.Modifiers
extends Object

Representation of the modifier flags and annotations that are associated with a declaration.


Field Summary
 Java.Annotation[] annotations
          The annotations.
 short flags
          The or'ed constants declared in Mod.
 
Constructor Summary
Java.Modifiers()
          A 'blank' Java.Modifiers object: No flags, no annotations.
Java.Modifiers(short modifiers)
           
Java.Modifiers(short modifiers, Java.Annotation[] annotations)
           
 
Method Summary
 Java.Modifiers add(int modifiersToAdd)
           
 Java.Modifiers changeAccess(int newAccess)
           
 Java.Modifiers remove(int modifiersToRemove)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

flags

public final short flags
The or'ed constants declared in Mod.


annotations

public final Java.Annotation[] annotations
The annotations.

Constructor Detail

Java.Modifiers

public Java.Modifiers()
A 'blank' Java.Modifiers object: No flags, no annotations.


Java.Modifiers

public Java.Modifiers(short modifiers)

Java.Modifiers

public Java.Modifiers(short modifiers,
                      Java.Annotation[] annotations)
Method Detail

add

public Java.Modifiers add(int modifiersToAdd)
Returns:
This object, with the given modifiersToAdd added.

remove

public Java.Modifiers remove(int modifiersToRemove)
Returns:
This object, with the given modifiersToRemove removed.

changeAccess

public Java.Modifiers changeAccess(int newAccess)
Parameters:
newAccess - One of Mod.PUBLIC, Mod.PRIVATE, Mod.PROTECTED, Mod.PACKAGE
Returns:
This object, with the access changed to newAccess

janino.net