Klasse DOMFactory
java.lang.Object
org.aspectj.org.eclipse.jdt.core.jdom.DOMFactory
- Alle implementierten Schnittstellen:
IDOMFactory
Veraltet.
The JDOM was made obsolete by the addition in 2.0 of the more
powerful, fine-grained DOM/AST API found in the
org.aspectj.org.eclipse.jdt.core.dom package.
Standard implementation of
IDOMFactory, and the only means
of creating JDOMs and document fragments.
This class may be instantiated.
-
Konstruktorübersicht
Konstruktoren -
Methodenübersicht
Modifizierer und TypMethodeBeschreibungVeraltet.Creates a default type document fragment.Veraltet.Creates and return an empty JDOM.createCompilationUnit(char[] sourceCode, String name) Veraltet.Creates a JDOM on the given source code.createCompilationUnit(String sourceCode, String name) Veraltet.Creates a JDOM on the given source code.Veraltet.Creates a default field document fragment.createField(String sourceCode) Veraltet.Creates a field document fragment on the given source code.Veraltet.Creates an empty import document fragment.createImport(String sourceCode) Veraltet.Creates an import document fragment on the given source code.Veraltet.Creates an empty initializer document fragment.createInitializer(String sourceCode) Veraltet.Creates an initializer document fragment from the given source code.Veraltet.Creates a default type document fragment.Veraltet.Creates a default method document fragment.createMethod(String sourceCode) Veraltet.Creates a method document fragment on the given source code.Veraltet.Creates an empty package document fragment.createPackage(String sourceCode) Veraltet.Creates a package document fragment on the given source code.Veraltet.Creates a default type document fragment.createType(String sourceCode) Veraltet.Creates a type document fragment on the given source code.
-
Konstruktordetails
-
DOMFactory
public DOMFactory()Veraltet.Creates a new DOM factory.
-
-
Methodendetails
-
createCompilationUnit
Veraltet.Beschreibung aus Schnittstelle kopiert:IDOMFactoryCreates and return an empty JDOM. The initial content is an empty string.- Angegeben von:
createCompilationUnitin SchnittstelleIDOMFactory- Gibt zurück:
- the new compilation unit
-
createCompilationUnit
Veraltet.Beschreibung aus Schnittstelle kopiert:IDOMFactoryCreates a JDOM on the given source code. The syntax for the given source code corresponds to CompilationUnit (JLS2 7.3).- Angegeben von:
createCompilationUnitin SchnittstelleIDOMFactory- Parameter:
sourceCode- the source code character array, ornullname- the name of the compilation unit- Gibt zurück:
- the new compilation unit, or
nullif unable to recognize the source code, or if the source code isnull
-
createCompilationUnit
Veraltet.Beschreibung aus Schnittstelle kopiert:IDOMFactoryCreates a JDOM on the given source code. The syntax for the given source code corresponds to CompilationUnit (JLS2 7.3).- Angegeben von:
createCompilationUnitin SchnittstelleIDOMFactory- Parameter:
sourceCode- the source code string, ornullname- the name of the compilation unit- Gibt zurück:
- the new compilation unit, or
nullif unable to recognize the source code, or if the source code isnull
-
createField
Veraltet.Beschreibung aus Schnittstelle kopiert:IDOMFactoryCreates a default field document fragment. Initially the field will have default protection, type"Object", name"aField", no comment, and no initializer.- Angegeben von:
createFieldin SchnittstelleIDOMFactory- Gibt zurück:
- the new field
-
createField
Veraltet.Beschreibung aus Schnittstelle kopiert:IDOMFactoryCreates a field document fragment on the given source code. The given source string corresponds to FieldDeclaration (JLS2 8.3) and ConstantDeclaration (JLS2 9.3) restricted to a single VariableDeclarator clause.- Angegeben von:
createFieldin SchnittstelleIDOMFactory- Parameter:
sourceCode- the source code- Gibt zurück:
- the new field, or
nullif unable to recognize the source code, if the source code isnull, or when the source contains more than one VariableDeclarator clause
-
createImport
Veraltet.Beschreibung aus Schnittstelle kopiert:IDOMFactoryCreates an empty import document fragment. Initially the import will have name"java.lang.*"and be non-static.- Angegeben von:
createImportin SchnittstelleIDOMFactory- Gibt zurück:
- the new import
-
createImport
Veraltet.Beschreibung aus Schnittstelle kopiert:IDOMFactoryCreates an import document fragment on the given source code. The syntax for the given source string corresponds to ImportDeclaration (JLS2 7.5).- Angegeben von:
createImportin SchnittstelleIDOMFactory- Parameter:
sourceCode- the source code- Gibt zurück:
- the new import, or
nullif unable to recognize the source code, or if the source code isnull
-
createInitializer
Veraltet.Beschreibung aus Schnittstelle kopiert:IDOMFactoryCreates an empty initializer document fragment. Initially the initializer will be static and have no body or comment.- Angegeben von:
createInitializerin SchnittstelleIDOMFactory- Gibt zurück:
- the new initializer
-
createInitializer
Veraltet.Beschreibung aus Schnittstelle kopiert:IDOMFactoryCreates an initializer document fragment from the given source code. The syntax for the given source string corresponds to InstanceInitializer (JLS2 8.6) and StaticDeclaration (JLS2 8.7).- Angegeben von:
createInitializerin SchnittstelleIDOMFactory- Parameter:
sourceCode- the source code- Gibt zurück:
- the new initializer, or
nullif unable to recognize the source code, or if the source code isnull
-
createMethod
Veraltet.Beschreibung aus Schnittstelle kopiert:IDOMFactoryCreates a default method document fragment. Initially the method will have public visibility, return type"void", be named"newMethod", have no parameters, no comment, and an empty body.- Angegeben von:
createMethodin SchnittstelleIDOMFactory- Gibt zurück:
- the new method
-
createMethod
Veraltet.Beschreibung aus Schnittstelle kopiert:IDOMFactoryCreates a method document fragment on the given source code. The syntax for the given source string corresponds to MethodDeclaration (JLS2 8.4), ConstructorDeclaration (JLS2 8.8), and AbstractMethodDeclaration (JLS2 9.4).- Angegeben von:
createMethodin SchnittstelleIDOMFactory- Parameter:
sourceCode- the source code- Gibt zurück:
- the new method, or
nullif unable to recognize the source code, or if the source code isnull
-
createPackage
Veraltet.Beschreibung aus Schnittstelle kopiert:IDOMFactoryCreates an empty package document fragment. Initially the package declaration will have no name.- Angegeben von:
createPackagein SchnittstelleIDOMFactory- Gibt zurück:
- the new package
-
createPackage
Veraltet.Beschreibung aus Schnittstelle kopiert:IDOMFactoryCreates a package document fragment on the given source code. The syntax for the given source string corresponds to PackageDeclaration (JLS2 7.4).- Angegeben von:
createPackagein SchnittstelleIDOMFactory- Parameter:
sourceCode- the source code- Gibt zurück:
- the new package, or
nullif unable to recognize the source code, or if the source code isnull
-
createType
Veraltet.Beschreibung aus Schnittstelle kopiert:IDOMFactoryCreates a default type document fragment. Initially the type will be a public class named"AClass", with no members or comment.- Angegeben von:
createTypein SchnittstelleIDOMFactory- Gibt zurück:
- the new type
-
createClass
Veraltet.Beschreibung aus Schnittstelle kopiert:IDOMFactoryCreates a default type document fragment. Initially the type will be a public class named"AClass", with no members or comment.- Angegeben von:
createClassin SchnittstelleIDOMFactory- Gibt zurück:
- the new class
-
createInterface
Veraltet.Beschreibung aus Schnittstelle kopiert:IDOMFactoryCreates a default type document fragment. Initially the type will be a public interface named"AnInterface", with no members or comment.- Angegeben von:
createInterfacein SchnittstelleIDOMFactory- Gibt zurück:
- the new interface
-
createType
Veraltet.Beschreibung aus Schnittstelle kopiert:IDOMFactoryCreates a type document fragment on the given source code. The syntax for the given source string corresponds to ClassDeclaration (JLS2 8.1) and InterfaceDeclaration (JLS2 9.1).- Angegeben von:
createTypein SchnittstelleIDOMFactory- Parameter:
sourceCode- the source code- Gibt zurück:
- the new type, or
nullif unable to recognize the source code, or if the source code isnull
-