This package contains the Java model classes, which implement Java specific behaviour for resources and further decompose Java resources into model elements.
Note that a lot of Java model operations require a Java project's classpath resolution. For example IJavaProject#getResolvedClasspath(boolean) or JavaCore#setClasspathContainer() will require to resolve the classpath of one or more projects. Client should be aware that this resolution may require to take project modification rule (see IResourceRuleFactory#modifyRule(IResource)).
Interface Summary Interface Description IAccessRuleDescribes an access rule to source and class files on a classpath entry. IAnnotatableCommon protocol for Java elements that can be annotated. IAnnotationRepresents an annotation on a package declaration, a type, a method, a field or a local variable in a compilation unit or a class file. IBufferA buffer contains the text contents of a resource. IBuffer.ITextEditCapability IBufferChangedListenerA listener, which gets notified when the contents of a specific buffer have changed, or when the buffer is closed. IBufferFactory Deprecated.Use
IClassFileRepresents a single
.classfile, holding the binary form of either a type or a module: A class file of type
IOrdinaryClassFilehas a single child of type
IType, a class file of type
IModularClassFilehas a single child of type
IModuleDescription. Class file elements need to be opened before they can be navigated.
IClasspathAttributeA classpath attribute defines a name/value pair that can be persisted with a classpath entry. IClasspathContainerInterface of a classpath container. IClasspathEntryAn entry on a Java project classpath identifying one or more package fragment roots. ICodeAssistCommon protocol for Java elements that support source code assist and code resolve. ICodeCompletionRequestor Deprecated.Use
CodeFormatterinstead (note: options have changed)
ICompilationUnitRepresents an entire Java compilation unit (source file with one of the
ICorrectionRequestorA callback interface for receiving java problem correction. IElementChangedListenerAn element changed listener receives notification of changes to Java elements maintained by the Java model. IFieldRepresents a field declared in a type. IImportContainerRepresents an import container is a child of a Java compilation unit that contains all (and only) the import declarations. IImportDeclarationRepresents an import declaration in Java compilation unit. IInitializerRepresents a stand-alone instance or class (static) initializer in a type. IJarEntryResource IJavaElementCommon protocol for all elements provided by the Java model. IJavaElementDeltaA Java element delta describes changes in Java element between two discrete points in time. IJavaModelRepresent the root Java element corresponding to the workspace. IJavaModelMarkerMarkers used by the Java model. IJavaModelStatusRepresents the outcome of an Java model operation. IJavaModelStatusConstantsStatus codes used with Java model status objects. IJavaProjectA Java project represents a view of a project resource in terms of Java elements such as package fragments, types, methods and fields. ILocalVariableRepresents a local variable declared in a method or an initializer. IMemberCommon protocol for Java elements that can be members of types. IMemberValuePairRepresents a member-value pair of an annotation. IMethodRepresents a method (or constructor) declared in a type. IModularClassFileRepresents the class file of a module description ("module-info.class"). IModuleDescriptionRepresents a Java module descriptor. IOpenableCommon protocol for Java elements that must be opened before they can be navigated or modified. IOrdinaryClassFileOrdinary form of a
IClassFilewhich holds exactly one
IPackageDeclarationRepresents a package declaration in Java compilation unit. IPackageFragmentA package fragment is a portion of the workspace corresponding to an entire package, or to a portion thereof. IPackageFragmentRootA package fragment root contains a set of package fragments. IParentCommon protocol for Java elements that contain other Java elements. IProblemRequestorA callback interface for receiving java problem as they are discovered by some Java operation. IRegionA Java model region describes a hierarchical set of elements. ISourceManipulationCommon protocol for Java elements that support source code manipulations such as copy, move, rename, and delete. ISourceRangeA source range defines an element's source coordinates relative to its source buffer. ISourceReferenceCommon protocol for Java elements that have associated source code. ITypeRepresents either a source type in a compilation unit (either a top-level type, a member type, a local type, an anonymous type or a lambda expression) or a binary type in a class file. ITypeHierarchyA type hierarchy provides navigations between a type and its resolved supertypes and subtypes for a specific type or for all types within a region. ITypeHierarchyChangedListenerA listener which gets notified when a particular type hierarchy object changes. ITypeParameterRepresents a type parameter defined by a type or a method in a compilation unit or a class file. ITypeRootRepresents an entire Java type root (either an
Class Summary Class Description BindingKeyUtility class to decode or create a binding key. BufferChangedEventA buffer changed event describes how a buffer has changed. BuildJarIndexAn Ant task to generate the index file for the given jar path. CheckDebugAttributesAn Ant task to find out if a class file or a jar contains debug attributes. ClasspathContainerInitializerAbstract base implementation of all classpath container initializer. ClasspathVariableInitializerAbstract base implementation of all classpath variable initializers. CompletionContextCompletion context. CompletionFlagsUtility class for decoding additional flags in completion proposal. CompletionProposalCompletion proposal. CompletionRequestorAbstract base class for a completion requestor which is passed completion proposals as they are generated in response to a code assist request. CompletionRequestorAdapter Deprecated.Subclass
CorrectionEngineThis class is the entry point for source corrections. ElementChangedEventAn element changed event describes a change to the structure or contents of a tree of Java elements. FlagsUtility class for decoding modifier flags in Java elements. JavaConventionsProvides methods for checking Java-specific conventions such as name syntax. JavaCoreThe plug-in runtime class for the Java model plug-in containing the core (UI-free) support for Java projects. JDTCompilerAdapterAnt 1.5 compiler adapter for the Eclipse Java compiler. NamingConventionsProvides methods for computing Java-specific names. SignatureProvides methods for encoding and decoding type and method signature strings. SourceRangeA source range defines an element's source coordinates relative to its source buffer. ToolFactoryFactory for creating various compiler tools, such as scanners, parsers and compilers. WorkingCopyOwnerThe owner of an
ICompilationUnithandle in working copy mode.
Exception Summary Exception Description JavaModelExceptionA checked exception representing a failure in the Java model.