|
Oracle Fusion Middleware Java API Reference for Oracle Extension SDK Reference 11g Release 1 (11.1.1.9.0) E52944-01 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object
oracle.jdeveloper.java.provider.BaseFileProvider
oracle.jdeveloper.java.provider.CachedFileProvider
oracle.jdeveloper.java.provider.ProjectFileProvider
public class ProjectFileProvider
The ProjectFileProvider
is an implementation of the JavaFileProvider
interface which relies on the path information of a Project
for locating Java source and class files. This implementation will respond to changes in the project paths by updating its class locator, and flushing its cache.
Nested Class Summary |
---|
Nested classes/interfaces inherited from class oracle.jdeveloper.java.provider.CachedFileProvider |
---|
CachedFileProvider.SourceFileTracker |
Nested classes/interfaces inherited from class oracle.jdeveloper.java.provider.BaseFileProvider |
---|
BaseFileProvider.BaseClass, BaseFileProvider.BasePackage |
Field Summary | |
---|---|
protected oracle.jdeveloper.java.provider.ProjectFileProvider.ProjectObserver |
_projectObserver Our observer for tracking changes to the project. |
Fields inherited from class oracle.jdeveloper.java.provider.CachedFileProvider |
---|
_arrayCacheMap, _cacheLock, _cacheRefCount, _classCacheMap, _classFileCacheMap, _defaultClassLoader, _lastCacheFlushedTime, _nullClassLoader, _packageCacheMap, _sourceFileCacheMap, CLASS_NOT_FOUND |
Fields inherited from class oracle.jdeveloper.java.provider.BaseFileProvider |
---|
context |
Fields inherited from interface oracle.jdeveloper.java.provider.ProviderConstants |
---|
CLASS_TYPE, EMPTY_COLLECTION, SOURCE_TYPE, UNKNOWN_TYPE |
Constructor Summary | |
---|---|
ProjectFileProvider(ProviderContext e, Project project) Constructs a new ProjectFileProvider instance using the given project to locate Java source and class files. |
|
ProjectFileProvider(ProviderContext e, Project project, java.util.Map cache) |
Method Summary | |
---|---|
JavaClassLocator |
getClassLocator() Fetch the class locator to use for locating files. |
JavaClassLocator |
getClassLocatorInterruptibly() Get the class locator for this provider. |
static ProjectFileProvider |
getInstance(Project project) Static factory method for fetching an instance of the JavaFileProvider for the given project. |
static ProjectFileProvider |
getInstance(Project project, java.lang.Object key) Static factory method for fetching an instance of the JavaFileProvider for the given project. |
SourceClass |
getProjectSourceClass(java.lang.String fqClassName) Fetch the SourceClass instance for the given fully-qualified class name. |
protected void |
handleProjectClose() Utility routine to handle any necessary cleanup when the project closes. |
protected void |
handleProjectContentsChange() Utility routine to handle a change in the contents of the project (i.e., class added or removed.) |
protected void |
handleProjectLoad() Utility routine to handle any necessary setup or cleanup when the project is opened or reopened (revert). |
void |
handleProjectPathsChange() Utility routine to handle a change in the paths of the project |
protected boolean |
isProjectSourceURL(java.net.URL sourceURL) Fetch whether this source URL is part of the project's source path (including project dependencies). |
protected static boolean |
pathContainsURL(URLPath path, java.net.URL url) Utility to check whether the specified URL is present in one of the directories specified by URLPath. |
void |
reloadClassLocator() Force the class locator to be reloaded. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected final oracle.jdeveloper.java.provider.ProjectFileProvider.ProjectObserver _projectObserver
Constructor Detail |
---|
public ProjectFileProvider(ProviderContext e, Project project)
ProjectFileProvider
instance using the given project to locate Java source and class files.
project
- the project to usepublic ProjectFileProvider(ProviderContext e, Project project, java.util.Map cache)
Method Detail |
---|
public static ProjectFileProvider getInstance(Project project)
JavaFileProvider
for the given project.project
- the project to use for locating filespublic static ProjectFileProvider getInstance(Project project, java.lang.Object key)
JavaFileProvider
for the given project.project
- the project to use for locating filesprotected void handleProjectClose()
protected void handleProjectLoad()
public void handleProjectPathsChange()
protected void handleProjectContentsChange()
public JavaClassLocator getClassLocator()
getClassLocator
in class BaseFileProvider
public JavaClassLocator getClassLocatorInterruptibly() throws java.lang.InterruptedException
BaseFileProvider
getClassLocatorInterruptibly
in class BaseFileProvider
java.lang.InterruptedException
- if the calling thread is interrupted while the locator is being createdpublic void reloadClassLocator()
public SourceClass getProjectSourceClass(java.lang.String fqClassName)
fqClassName
- the fully-qualified class name in dotted notation, such as "java.lang.Object" or "java.util.Map.Entry"protected boolean isProjectSourceURL(java.net.URL sourceURL)
protected static boolean pathContainsURL(URLPath path, java.net.URL url)
|
Oracle Fusion Middleware Java API Reference for Oracle Extension SDK Reference 11g Release 1 (11.1.1.9.0) E52944-01 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |