JavaBuilder Class

com.bea.ide.sourceeditor.compiler
JavaBuilder Class

public class JavaBuilder

    extends Object
    implements ILanguageBuilder

The builder class for java document types. This builder will handle construction of IDE-side parse trees for document types made up of java and java annotation languages.

The parse tree constructed is made up of DefaultSourceElement derivations, and contains most frequently needed parse information. Parse trees constructed by this class do not contain any parse information for java method bodies. This is is done intentionally, for performance reasons.

Construction of the parse tree takes place through calls into the builder methods from the compiler framework. See the ICompilerDriver for information on how to specify a builder for a different document type.


Hierarchy
Object
  JavaBuilder
All Implemented Interfaces

ILanguageBuilder, IStructureFeature.IStructureBuilder
Direct Known Subclasses

ControlBuilder, ControlContainerBuilder

Constructor Summary

JavaBuilder()

 

Method Summary

public void
addChild(IStructureFeature.IStructureNode parent, IStructureFeature.IStructureNode child)
Adds a child to a source element as part of compiler parse tree construction.
public IStructureFeature.IStructureNode
createNode(IStructureFeature.StructureCode typeCode, Object structureCookie)
Creates a new source element as part of compiler construction of a new parse tree.
public void
setProperty(IStructureFeature.IStructureNode node, IStructureFeature.StructureCode typeCode, Object o)
Sets a property on a newly created source element as part of compiler construction of a new parse tree.
 
Methods from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
   
Methods from interface com.bea.compiler.feature.IStructureFeature.IStructureBuilder
addChild, createNode, setProperty
 

Constructor Detail

JavaBuilder

public JavaBuilder()
 

Method Detail

addChild(IStructureFeature.IStructureNode, IStructureFeature.IStructureNode) Method

public void addChild(IStructureFeature.IStructureNode parent, 
                     IStructureFeature.IStructureNode child)
Adds a child to a source element as part of compiler parse tree construction.

Parameters

parent
The parent element
child
The child element

createNode(IStructureFeature.StructureCode, Object) Method

public IStructureFeature.IStructureNode createNode(IStructureFeature.StructureCode typeCode, 
                                                   Object structureCookie)
Creates a new source element as part of compiler construction of a new parse tree.

Parameters

typeCode
The type of the new element
structureCookie
The cookie that should be retrievable from the element.

Returns

The newly created source element.

setProperty(IStructureFeature.IStructureNode, IStructureFeature.StructureCode, Object) Method

public void setProperty(IStructureFeature.IStructureNode node, 
                        IStructureFeature.StructureCode typeCode, 
                        Object o)
Sets a property on a newly created source element as part of compiler construction of a new parse tree.

Parameters

node
The source element upon which the property should be set
typeCode
The property to set
o
The new value of the property