org.extendj.ast
node type ResourceModifiers

General Info

Production
ResourceModifiers : Modifiers;
Type Hierarchy:
java.lang.Object
  extended by beaver.Symbol
      extended by org.extendj.ast.ASTNode<ASTNode>
          extended by org.extendj.ast.Modifiers
              extended by org.extendj.ast.ResourceModifiers
All Implemented Interfaces:
java.lang.Cloneable, java.lang.Iterable<ASTNode>, org.jastadd.util.PrettyPrintable

Description

Subclass of Modifiers for resource declarations. This subclass is added as a convenient method of making resource declarations implicitly final.
Source
Declared in /home/jesper/git/extendj/java7/grammar/TryWithResources.ast at line 16

Member Filters

API level:

Aspect:

Constructors

public ResourceModifiers()
 
Source
Declared in /home/jesper/git/extendj/ASTNode at line 1
public ResourceModifiers(List<Modifier> p0)
 
Source
Declared in /home/jesper/git/extendj/ASTNode at line 14

Attributes

Overrides:isFinal in class Modifiers
Source
Declared in /home/jesper/git/extendj/java4/frontend/Modifiers.jrag at line 435
Aspect
Modifiers

Methods

public void init$Children()
Initializes the child array to the correct size. Initializes List and Opt nta children.
Overrides:init$Children in class Modifiers
Source
Declared in /home/jesper/git/extendj/ASTNode at line 10
protected int numChildren()
Overrides:numChildren in class Modifiers
Source
Declared in /home/jesper/git/extendj/ASTNode at line 20
public boolean mayHaveRewrite()
Overrides:mayHaveRewrite in class Modifiers
Source
Declared in /home/jesper/git/extendj/ASTNode at line 26
public void flushAttrCache()
Overrides:flushAttrCache in class Modifiers
Source
Declared in /home/jesper/git/extendj/ASTNode at line 32
public void flushCollectionCache()
Overrides:flushCollectionCache in class Modifiers
Source
Declared in /home/jesper/git/extendj/ASTNode at line 39
public void flushRewriteCache()
Overrides:flushRewriteCache in class Modifiers
Source
Declared in /home/jesper/git/extendj/ASTNode at line 45
public ResourceModifiers clone()
                        throws java.lang.CloneNotSupportedException
Overrides:clone in class Modifiers
Throws:
java.lang.CloneNotSupportedException
Source
Declared in /home/jesper/git/extendj/ASTNode at line 51
public ResourceModifiers copy()
Overrides:copy in class Modifiers
Source
Declared in /home/jesper/git/extendj/ASTNode at line 58
@Deprecated
public ResourceModifiers fullCopy()
Deprecated. Please use treeCopy or treeCopyNoTransform instead

Create a deep copy of the AST subtree at this node. The copy is dangling, i.e. has no parent.

Overrides:fullCopy in class Modifiers
Returns:
dangling copy of the subtree at this node
Source
Declared in /home/jesper/git/extendj/ASTNode at line 77
public ResourceModifiers treeCopyNoTransform()
Create a deep copy of the AST subtree at this node. The copy is dangling, i.e. has no parent.
Overrides:treeCopyNoTransform in class Modifiers
Returns:
dangling copy of the subtree at this node
Source
Declared in /home/jesper/git/extendj/ASTNode at line 87
public ResourceModifiers treeCopy()
Create a deep copy of the AST subtree at this node. The subtree of this node is traversed to trigger rewrites before copy. The copy is dangling, i.e. has no parent.
Overrides:treeCopy in class Modifiers
Returns:
dangling copy of the subtree at this node
Source
Declared in /home/jesper/git/extendj/ASTNode at line 107
protected boolean is$Equal(ASTNode node)
Overrides:is$Equal in class Modifiers
Source
Declared in /home/jesper/git/extendj/ASTNode at line 114
public void setModifierList(List<Modifier> list)
Replaces the Modifier list.
Overrides:setModifierList in class Modifiers
Parameters:
list - The new list node to be used as the Modifier list.
public int getNumModifier()
Retrieves the number of children in the Modifier list.
Overrides:getNumModifier in class Modifiers
Returns:
Number of children in the Modifier list.
Retrieves the number of children in the Modifier list. Calling this method will not trigger rewrites.
Overrides:getNumModifierNoTransform in class Modifiers
Returns:
Number of children in the Modifier list.
public Modifier getModifier(int i)
Retrieves the element at index i in the Modifier list.
Overrides:getModifier in class Modifiers
Parameters:
i - Index of the element to return.
Returns:
The element at position i in the Modifier list.
public boolean hasModifier()
Check whether the Modifier list has any children.
Overrides:hasModifier in class Modifiers
Returns:
true if it has at least one child, false otherwise.
public void addModifier(Modifier node)
Append an element to the Modifier list.
Overrides:addModifier in class Modifiers
Parameters:
node - The element to append to the Modifier list.
public void addModifierNoTransform(Modifier node)
Overrides:addModifierNoTransform in class Modifiers
public void setModifier(Modifier node,
                        int i)
Replaces the Modifier list element at index i with the new node node.
Overrides:setModifier in class Modifiers
Parameters:
node - The new node to replace the old list element.
i - The list index of the node to be replaced.
Retrieves the Modifier list.
Overrides:getModifierList in class Modifiers
Returns:
The node representing the Modifier list.
Retrieves the Modifier list.

This method does not invoke AST transformations.

Overrides:getModifierListNoTransform in class Modifiers
Returns:
The node representing the Modifier list.
Retrieves the Modifier list.
Overrides:getModifiers in class Modifiers
Returns:
The node representing the Modifier list.
Retrieves the Modifier list.

This method does not invoke AST transformations.

Overrides:getModifiersNoTransform in class Modifiers
Returns:
The node representing the Modifier list.
Overrides:rewriteTo in class Modifiers

Fields

protected boolean isFinal_computed
protected boolean isFinal_value

Inherited Members

Attributes inherited from org.extendj.ast.Modifiers

Attributes inherited from org.extendj.ast.ASTNode

Methods inherited from class org.extendj.ast.Modifiers

Methods inherited from class org.extendj.ast.ASTNode

Methods inherited from class beaver.Symbol

getColumn
getEnd
getId
getLine
getStart
makePosition

Methods inherited from class java.lang.Object

equals
finalize
getClass
hashCode
notify
notifyAll
wait
wait
wait

Fields inherited from org.extendj.ast.Modifiers

Fields inherited from org.extendj.ast.ASTNode

Fields inherited from beaver.Symbol

end
id
start
value