|
|
|
|
Uses of Interface org.eclipse.jdt.core.IJavaElement
Subinterfaces of
IJavaElement in
org.eclipse.jdt.core
|
interface
|
IAnnotation
Represents an annotation on a package declaration, a type, a method, a field
or a local variable in a compilation unit or a class file. |
interface
|
IClassFile
Represents an entire binary type (single .class file). |
interface
|
ICompilationUnit
Represents an entire Java compilation unit (source file with one of the
Java-like extensions ). |
interface
|
IField
Represents a field declared in a type. |
interface
|
IImportContainer
Represents an import container is a child of a Java compilation unit that contains
all (and only) the import declarations. |
interface
|
IImportDeclaration
Represents an import declaration in Java compilation unit. |
interface
|
IInitializer
Represents a stand-alone instance or class (static) initializer in a type. |
interface
|
IJavaModel
Represent the root Java element corresponding to the workspace. |
interface
|
IJavaProject
A Java project represents a view of a project resource in terms of Java
elements such as package fragments, types, methods and fields. |
interface
|
ILocalVariable
Represents a local variable declared in a method or an initializer. |
interface
|
IMember
Common protocol for Java elements that can be members of types. |
interface
|
IMethod
Represents a method (or constructor) declared in a type. |
interface
|
IPackageDeclaration
Represents a package declaration in Java compilation unit. |
interface
|
IPackageFragment
A package fragment is a portion of the workspace corresponding to an entire package,
or to a portion thereof. |
interface
|
IPackageFragmentRoot
A package fragment root contains a set of package fragments. |
interface
|
IType
Represents either a source type in a compilation unit (either a top-level
type, a member type, a local type or an anonymous type)
or a binary type in a class file. |
interface
|
ITypeParameter
Represents a type parameter defined by a type or a method
in a compilation unit or a class file. |
interface
|
ITypeRoot
Represents an entire Java type root (either an ICompilationUnit
or an IClassFile ). |
Methods in
org.eclipse.jdt.core that return
IJavaElement
|
IJavaElement[]
|
ICodeAssist.
codeSelect
(int offset,
int length)
Returns the Java elements corresponding to the given selected text in this compilation unit. |
IJavaElement[]
|
ICodeAssist.
codeSelect
(int offset,
int length,
WorkingCopyOwner owner)
Returns the Java elements corresponding to the given selected text in this compilation unit. |
static
IJavaElement
|
JavaCore.
create
(
IFile file)
Returns the Java element corresponding to the given file, or
null if unable to associate the given file
with a Java element. |
static
IJavaElement
|
JavaCore.
create
(
IFolder folder)
Returns the package fragment or package fragment root corresponding to the given folder, or
null if unable to associate the given folder with a Java element. |
static
IJavaElement
|
JavaCore.
create
(
IResource resource)
Returns the Java element corresponding to the given resource, or
null if unable to associate the given resource
with a Java element. |
static
IJavaElement
|
JavaCore.
create
(
IResource resource,
IJavaProject project)
Returns the Java element corresponding to the given file, its project being the given
project. |
static
IJavaElement
|
JavaCore.
create
(
String handleIdentifier)
Returns the Java model element corresponding to the given handle identifier
generated by IJavaElement.getHandleIdentifier() , or
null if unable to create the associated element. |
static
IJavaElement
|
JavaCore.
create
(
String handleIdentifier,
WorkingCopyOwner owner)
Returns the Java model element corresponding to the given handle identifier
generated by IJavaElement.getHandleIdentifier() , or
null if unable to create the associated element. |
IJavaElement
|
IJavaProject.
findElement
(
IPath path)
Returns the IJavaElement corresponding to the given
classpath-relative path, or null if no such
IJavaElement is found. |
IJavaElement
|
IJavaProject.
findElement
(
IPath path,
WorkingCopyOwner owner)
Returns the IJavaElement corresponding to the given
classpath-relative path, or null if no such
IJavaElement is found. |
IJavaElement
|
IJavaProject.
findElement
(
String bindingKey,
WorkingCopyOwner owner)
Finds the Java element corresponding to the given binding key if any,
else returns null . |
IJavaElement[]
|
IWorkingCopy.
findElements
(
IJavaElement element)
Deprecated. Use
ICompilationUnit.findElements(IJavaElement) instead.
|
IJavaElement[]
|
ICompilationUnit.
findElements
(
IJavaElement element)
Finds the elements in this compilation unit that correspond to
the given element. |
IJavaElement
|
IWorkingCopy.
findSharedWorkingCopy
(
IBufferFactory bufferFactory)
Deprecated. Use
ICompilationUnit.findWorkingCopy(WorkingCopyOwner) instead.
|
IJavaElement
|
IJavaElement.
getAncestor
(int ancestorType)
Returns the first ancestor of this Java element that has the given type. |
IJavaElement[]
|
IParent.
getChildren
()
Returns the immediate children of this element. |
IJavaElement[]
|
IType.
getChildrenForCategory
(
String category)
Returns the children of this type that have the given category as a @category tag. |
IJavaElement
|
IJavaElementDelta.
getElement
()
Returns the element that this delta describes a change to. |
IJavaElement
|
ITypeRoot.
getElementAt
(int position)
Returns the smallest element within this Java type root that
includes the given source position (that is, a method, field, etc.), or
null if there is no element other than the Java type root
itself at the given position, or if the given position is not
within the source range of the source of this Java type root. |
IJavaElement[]
|
IRegion.
getElements
()
Returns the top level elements in this region. |
IJavaElement[]
|
IJavaModelStatus.
getElements
()
Returns any Java elements associated with the failure (see specification
of the status code), or an empty array if no elements are related to this
particular status code. |
IJavaElement
|
CompletionContext.
getEnclosingElement
()
Returns the innermost enclosing Java element which contains the completion location or null if this element cannot be computed. |
IJavaElement
|
IJavaElementDelta.
getMovedFromElement
()
Returns an element describing this element before it was moved
to its current location, or null if the
IJavaElementDelta.F_MOVED_FROM change flag is not set. |
IJavaElement
|
IJavaElementDelta.
getMovedToElement
()
Returns an element describing this element in its new location,
or null if the
IJavaElementDelta.F_MOVED_TO change
flag is not set. |
IJavaElement
|
IWorkingCopy.
getOriginal
(
IJavaElement workingCopyElement)
Deprecated. Use
getPrimaryElement() instead.
|
IJavaElement
|
IWorkingCopy.
getOriginalElement
()
Deprecated. Use
getPrimaryElement() instead.
|
IJavaElement
|
IJavaElement.
getParent
()
Returns the element directly containing this element,
or null if this element has no parent. |
IJavaElement
|
IJavaElement.
getPrimaryElement
()
Returns the primary element (whose compilation unit is the primary compilation unit)
this working copy element was created from, or this element if it is a descendant of a
primary compilation unit or if it is not a descendant of a working copy (e.g. it is a
binary member). |
IJavaElement
|
IWorkingCopy.
getSharedWorkingCopy
(
IProgressMonitor monitor,
IBufferFactory factory,
IProblemRequestor problemRequestor)
Deprecated. Use
ICompilationUnit.getWorkingCopy(WorkingCopyOwner, IProblemRequestor, IProgressMonitor) instead.
|
IJavaElement[]
|
CompletionContext.
getVisibleElements
(
String typeSignature)
Return the elements which are visible from the completion location and which can be assigned to the given type. |
IJavaElement
|
IWorkingCopy.
getWorkingCopy
()
Deprecated. Use
ICompilationUnit.getWorkingCopy(IProgressMonitor) instead.
|
IJavaElement
|
IClassFile.
getWorkingCopy
(
IProgressMonitor monitor,
IBufferFactory factory)
Deprecated. Use
ITypeRoot.getWorkingCopy(WorkingCopyOwner, IProgressMonitor) instead
|
IJavaElement
|
IWorkingCopy.
getWorkingCopy
(
IProgressMonitor monitor,
IBufferFactory factory,
IProblemRequestor problemRequestor)
Deprecated. Use
ICompilationUnit.getWorkingCopy(WorkingCopyOwner, IProblemRequestor, IProgressMonitor) instead.
|
Methods in
org.eclipse.jdt.core with parameters of type
IJavaElement
|
void
|
IRegion.
add
(
IJavaElement element)
Adds the given element and all of its descendents to this region. |
static void
|
JavaCore.
addJavaElementMarkerAttributes
(
Map attributes,
IJavaElement element)
Configures the given marker attribute map for the given Java element. |
void
|
JavaCore.
configureJavaElementMarker
(
IMarker marker,
IJavaElement element)
Configures the given marker for the given Java element. |
boolean
|
IRegion.
contains
(
IJavaElement element)
Returns whether the given element is contained in this region. |
void
|
IJavaModel.
copy
(
IJavaElement[] elements,
IJavaElement[] containers,
IJavaElement[] siblings,
String[] renamings,
boolean replace,
IProgressMonitor monitor)
Copies the given elements to the specified container(s). |
void
|
IJavaModel.
copy
(
IJavaElement[] elements,
IJavaElement[] containers,
IJavaElement[] siblings,
String[] renamings,
boolean replace,
IProgressMonitor monitor)
Copies the given elements to the specified container(s). |
void
|
IJavaModel.
copy
(
IJavaElement[] elements,
IJavaElement[] containers,
IJavaElement[] siblings,
String[] renamings,
boolean replace,
IProgressMonitor monitor)
Copies the given elements to the specified container(s). |
void
|
ISourceManipulation.
copy
(
IJavaElement container,
IJavaElement sibling,
String rename,
boolean replace,
IProgressMonitor monitor)
Copies this element to the given container. |
IField
|
IType.
createField
(
String contents,
IJavaElement sibling,
boolean force,
IProgressMonitor monitor)
Creates and returns a field in this type with the
given contents. |
IImportDeclaration
|
ICompilationUnit.
createImport
(
String name,
IJavaElement sibling,
int flags,
IProgressMonitor monitor)
Creates and returns an import declaration in this compilation unit
with the given name. |
IImportDeclaration
|
ICompilationUnit.
createImport
(
String name,
IJavaElement sibling,
IProgressMonitor monitor)
Creates and returns an non-static import declaration in this compilation unit
with the given name. |
IInitializer
|
IType.
createInitializer
(
String contents,
IJavaElement sibling,
IProgressMonitor monitor)
Creates and returns a static initializer in this type with the
given contents. |
IMethod
|
IType.
createMethod
(
String contents,
IJavaElement sibling,
boolean force,
IProgressMonitor monitor)
Creates and returns a method or constructor in this type with the
given contents. |
IType
|
IType.
createType
(
String contents,
IJavaElement sibling,
boolean force,
IProgressMonitor monitor)
Creates and returns a type in this type with the
given contents. |
IType
|
ICompilationUnit.
createType
(
String contents,
IJavaElement sibling,
boolean force,
IProgressMonitor monitor)
Creates and returns a type in this compilation unit with the
given contents. |
void
|
IJavaModel.
delete
(
IJavaElement[] elements,
boolean force,
IProgressMonitor monitor)
Deletes the given elements, forcing the operation if necessary and specified. |
IJavaElement[]
|
IWorkingCopy.
findElements
(
IJavaElement element)
Deprecated. Use
ICompilationUnit.findElements(IJavaElement) instead.
|
IJavaElement[]
|
ICompilationUnit.
findElements
(
IJavaElement element)
Finds the elements in this compilation unit that correspond to
the given element. |
IJavaElement
|
IWorkingCopy.
getOriginal
(
IJavaElement workingCopyElement)
Deprecated. Use
getPrimaryElement() instead.
|
boolean
|
IJavaProject.
isOnClasspath
(
IJavaElement element)
Returns whether the given element is on the classpath of this project,
that is, referenced from a classpath entry and not explicitly excluded
using an exclusion pattern. |
static boolean
|
JavaCore.
isReferencedBy
(
IJavaElement element,
IMarker marker)
Returns whether the given marker references the given Java element. |
static boolean
|
JavaCore.
isReferencedBy
(
IJavaElement element,
IMarkerDelta markerDelta)
Returns whether the given marker delta references the given Java element. |
void
|
IJavaModel.
move
(
IJavaElement[] elements,
IJavaElement[] containers,
IJavaElement[] siblings,
String[] renamings,
boolean replace,
IProgressMonitor monitor)
Moves the given elements to the specified container(s). |
void
|
IJavaModel.
move
(
IJavaElement[] elements,
IJavaElement[] containers,
IJavaElement[] siblings,
String[] renamings,
boolean replace,
IProgressMonitor monitor)
Moves the given elements to the specified container(s). |
void
|
IJavaModel.
move
(
IJavaElement[] elements,
IJavaElement[] containers,
IJavaElement[] siblings,
String[] renamings,
boolean replace,
IProgressMonitor monitor)
Moves the given elements to the specified container(s). |
void
|
ISourceManipulation.
move
(
IJavaElement container,
IJavaElement sibling,
String rename,
boolean replace,
IProgressMonitor monitor)
Moves this element to the given container. |
void
|
IJavaModel.
refreshExternalArchives
(
IJavaElement[] elementsScope,
IProgressMonitor monitor)
Triggers an update of the JavaModel with respect to the referenced external archives. |
boolean
|
IRegion.
remove
(
IJavaElement element)
Removes the specified element from the region and returns
true if successful, false if the remove
fails. |
void
|
IJavaModel.
rename
(
IJavaElement[] elements,
IJavaElement[] destinations,
String[] names,
boolean replace,
IProgressMonitor monitor)
Renames the given elements as specified. |
void
|
IJavaModel.
rename
(
IJavaElement[] elements,
IJavaElement[] destinations,
String[] names,
boolean replace,
IProgressMonitor monitor)
Renames the given elements as specified. |
Methods in
org.eclipse.jdt.core.search with parameters of type
IJavaElement
|
void
|
IJavaSearchResultCollector.
accept
(
IResource resource,
int start,
int end,
IJavaElement enclosingElement,
int accuracy)
Deprecated. Replaced by
SearchRequestor.acceptSearchMatch(SearchMatch) .
|
static
IJavaSearchScope
|
SearchEngine.
createJavaSearchScope
(
IJavaElement[] elements)
Returns a Java search scope limited to the given Java elements. |
static
IJavaSearchScope
|
SearchEngine.
createJavaSearchScope
(
IJavaElement[] elements,
boolean includeReferencedProjects)
Returns a Java search scope limited to the given Java elements. |
static
IJavaSearchScope
|
SearchEngine.
createJavaSearchScope
(
IJavaElement[] elements,
int includeMask)
Returns a Java search scope limited to the given Java elements. |
static
SearchPattern
|
SearchPattern.
createPattern
(
IJavaElement element,
int limitTo)
Returns a search pattern based on a given Java element. |
static
SearchPattern
|
SearchPattern.
createPattern
(
IJavaElement element,
int limitTo,
int matchRule)
Returns a search pattern based on a given Java element. |
static
ISearchPattern
|
SearchEngine.
createSearchPattern
(
IJavaElement element,
int limitTo)
Deprecated. Use
SearchPattern.createPattern(IJavaElement, int) instead.
|
boolean
|
IJavaSearchScope.
encloses
(
IJavaElement element)
Checks whether this scope encloses the given element. |
void
|
SearchEngine.
search
(
IWorkspace workspace,
IJavaElement element,
int limitTo,
IJavaSearchScope scope,
IJavaSearchResultCollector resultCollector)
Deprecated. Use
SearchEngine.search(SearchPattern, SearchParticipant[], IJavaSearchScope, SearchRequestor, IProgressMonitor) instead.
|
void
|
SearchEngine.
searchDeclarationsOfAccessedFields
(
IJavaElement enclosingElement,
SearchRequestor requestor,
IProgressMonitor monitor)
Searches for all declarations of the fields accessed in the given element. |
void
|
SearchEngine.
searchDeclarationsOfAccessedFields
(
IWorkspace workspace,
IJavaElement enclosingElement,
IJavaSearchResultCollector resultCollector)
Deprecated. Use
SearchEngine.searchDeclarationsOfAccessedFields(IJavaElement, SearchRequestor, IProgressMonitor) instead.
|
void
|
SearchEngine.
searchDeclarationsOfReferencedTypes
(
IJavaElement enclosingElement,
SearchRequestor requestor,
IProgressMonitor monitor)
Searches for all declarations of the types referenced in the given element. |
void
|
SearchEngine.
searchDeclarationsOfReferencedTypes
(
IWorkspace workspace,
IJavaElement enclosingElement,
IJavaSearchResultCollector resultCollector)
Deprecated. Use
SearchEngine.searchDeclarationsOfReferencedTypes(IJavaElement, SearchRequestor, IProgressMonitor) instead.
|
void
|
SearchEngine.
searchDeclarationsOfSentMessages
(
IJavaElement enclosingElement,
SearchRequestor requestor,
IProgressMonitor monitor)
Searches for all declarations of the methods invoked in the given element. |
void
|
SearchEngine.
searchDeclarationsOfSentMessages
(
IWorkspace workspace,
IJavaElement enclosingElement,
IJavaSearchResultCollector resultCollector)
Deprecated. Use
SearchEngine.searchDeclarationsOfSentMessages(IJavaElement, SearchRequestor, IProgressMonitor) instead.
|
void
|
ReferenceMatch.
setLocalElement
(
IJavaElement element)
Store the local element in the match. |
void
|
TypeReferenceMatch.
setOtherElements
(
IJavaElement[] otherElements)
Sets the other elements of this search match. |
Constructors in
org.eclipse.jdt.core.search with parameters of type
IJavaElement
|
FieldDeclarationMatch
(
IJavaElement element,
int accuracy,
int offset,
int length,
SearchParticipant participant,
IResource resource)
Creates a new field declaration match. |
FieldReferenceMatch
(
IJavaElement enclosingElement,
int accuracy,
int offset,
int length,
boolean isReadAccess,
boolean isWriteAccess,
boolean insideDocComment,
SearchParticipant participant,
IResource resource)
Creates a new field reference match. |
LocalVariableDeclarationMatch
(
IJavaElement element,
int accuracy,
int offset,
int length,
SearchParticipant participant,
IResource resource)
Creates a new local variable declaration match. |
LocalVariableReferenceMatch
(
IJavaElement enclosingElement,
int accuracy,
int offset,
int length,
boolean isReadAccess,
boolean isWriteAccess,
boolean insideDocComment,
SearchParticipant participant,
IResource resource)
Creates a new local variable reference match. |
MethodDeclarationMatch
(
IJavaElement element,
int accuracy,
int offset,
int length,
SearchParticipant participant,
IResource resource)
Creates a new method declaration match. |
MethodReferenceMatch
(
IJavaElement enclosingElement,
int accuracy,
int offset,
int length,
boolean constructor,
boolean synthetic,
boolean superInvocation,
boolean insideDocComment,
SearchParticipant participant,
IResource resource)
Creates a new method reference match. |
MethodReferenceMatch
(
IJavaElement enclosingElement,
int accuracy,
int offset,
int length,
boolean constructor,
boolean synthetic,
boolean insideDocComment,
SearchParticipant participant,
IResource resource)
Creates a new method reference match. |
MethodReferenceMatch
(
IJavaElement enclosingElement,
int accuracy,
int offset,
int length,
boolean insideDocComment,
SearchParticipant participant,
IResource resource)
Creates a new method reference match. |
PackageDeclarationMatch
(
IJavaElement element,
int accuracy,
int offset,
int length,
SearchParticipant participant,
IResource resource)
Creates a new package declaration match. |
PackageReferenceMatch
(
IJavaElement enclosingElement,
int accuracy,
int offset,
int length,
boolean insideDocComment,
SearchParticipant participant,
IResource resource)
Creates a new package reference match. |
ReferenceMatch
(
IJavaElement enclosingElement,
int accuracy,
int offset,
int length,
boolean insideDocComment,
SearchParticipant participant,
IResource resource)
Creates a new reference match. |
SearchMatch
(
IJavaElement element,
int accuracy,
int offset,
int length,
SearchParticipant participant,
IResource resource)
Creates a new search match. |
TypeDeclarationMatch
(
IJavaElement element,
int accuracy,
int offset,
int length,
SearchParticipant participant,
IResource resource)
Creates a new type declaration match. |
TypeParameterDeclarationMatch
(
IJavaElement element,
int accuracy,
int offset,
int length,
SearchParticipant participant,
IResource resource)
Creates a new type parameter match. |
TypeParameterReferenceMatch
(
IJavaElement enclosingElement,
int accuracy,
int offset,
int length,
boolean insideDocComment,
SearchParticipant participant,
IResource resource)
Creates a new field reference match. |
TypeReferenceMatch
(
IJavaElement enclosingElement,
int accuracy,
int offset,
int length,
boolean insideDocComment,
SearchParticipant participant,
IResource resource)
Creates a new type reference match. |
Methods in
org.eclipse.jdt.ui with parameters of type
IJavaElement
|
static void
|
JavaElementLabels.
getDeclarationLabel
(
IJavaElement declaration,
long flags,
StringBuffer buf)
Appends the label for a import container, import or package declaration to a
StringBuffer
. |
static void
|
JavaElementLabels.
getDeclarationLabel
(
IJavaElement declaration,
long flags,
StyledString result)
Appends the label for a import container, import or package declaration to a
StyledString . |
static
String
|
JavaElementLabels.
getElementLabel
(
IJavaElement element,
long flags)
Returns the label for a Java element with the flags as defined by this class. |
static void
|
JavaElementLabels.
getElementLabel
(
IJavaElement element,
long flags,
StringBuffer buf)
Returns the label for a Java element with the flags as defined by this class. |
static void
|
JavaElementLabels.
getElementLabel
(
IJavaElement element,
long flags,
StyledString result)
Returns the styled label for a Java element with the flags as defined by this class. |
static
URL
|
JavaUI.
getJavadocBaseLocation
(
IJavaElement element)
Returns the Javadoc base URL for an element. |
static
URL
|
JavaUI.
getJavadocLocation
(
IJavaElement element,
boolean includeAnchor)
Returns the Javadoc URL for an element. |
static
StyledString
|
JavaElementLabels.
getStyledElementLabel
(
IJavaElement element,
long flags)
Returns the styled label for a Java element with the flags as defined by this class. |
protected boolean
|
StandardJavaElementContentProvider.
isPackageFragmentEmpty
(
IJavaElement element)
Tests if the given element is a empty package fragment. |
static
IEditorPart
|
JavaUI.
openInEditor
(
IJavaElement element)
Opens an editor on the given Java element in the active page. |
static
IEditorPart
|
JavaUI.
openInEditor
(
IJavaElement element,
boolean activate,
boolean reveal)
Opens an editor on the given Java element in the active page. |
static void
|
JavaUI.
revealInEditor
(
IEditorPart part,
IJavaElement element)
Reveals the given java element in the given editor. |
void
|
ITypeHierarchyViewPart.
setInputElement
(
IJavaElement element)
Sets the input element of this type hierarchy view. |
Copyright (c) IBM Corp. and others 2000, 2008. All Rights Reserved.
|
|
|