|
Oracle Fusion Middleware Java API Reference for Oracle Extension SDK 11g Release 2 (11.1.2.3.0) E17493-04 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object
oracle.ide.file.ProjectCache
public class ProjectCache
Caches project properties. Once the cache is populated, it is no longer necessary to load project files to get the project properties. Loading a project file requires file I/O and XML parsing, which is very expensive. The cache is especially useful for operations that need to access the properties of a large number of projects at once.
Constructor Summary | |
---|---|
protected |
ProjectCache(Workspace workspace) |
Method Summary | |
---|---|
void |
close() Close this cache. |
Path |
getContentPath(Project project) Get the project content path. |
Path |
getContentPath(Project project, java.lang.String contentSetKey) Get the project content path for a specific content set. |
java.util.Collection<Project> |
getDirectDependencies(Project project) Get the projects that a project directly depends on. |
java.util.Collection<Project> |
getDownstreamDependencies(Project project) Get the downstream dependencies of a project. |
static ProjectCache |
getInstance(Workspace workspace) Get the project cache for an application workspace. |
protected LibraryPaths |
getLibraryPaths(Project project, java.lang.String key) Get library paths from the cache. |
protected java.util.List<LibraryPaths> |
getLibraryPathsList(Project project, java.lang.String key) Get a list of library paths from the cache. |
protected java.util.logging.Logger |
getLogger() Get the logger used to log messages related to the cache. |
protected Path |
getPath(Project project, java.lang.String key) Get a path from the cache. |
java.lang.String[] |
getTechnologyScopeKeys(Project project) Get the technology scope keys used by a project. |
java.util.Collection<Project> |
getTransitiveDependencies(Project project) Get the transitive closure of the projects a project depends on. |
static void |
invalidate(java.util.Collection<Project> projects) Invalidate the project cache for a set of projects. |
static void |
invalidate(Project project) Invalidate the project cache for a specific project. |
static void |
invalidate(Workspace workspace) Invalidate the project cache for an application workspace. |
static void |
invalidateLibraries() Invalidate the project cache due to library changes. |
protected Project |
loadProject(Project project) Gets the project in order to load it. |
protected void |
putLibraryPaths(Project project, java.lang.String key, LibraryPaths libraryPaths) Put library paths into the cache. |
protected void |
putLibraryPathsList(Project project, java.lang.String key, java.util.List<LibraryPaths> libraryPathsList) Put a list of library paths into the cache. |
protected void |
putPath(Project project, java.lang.String key, Path path) Put a path in the cache. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
protected ProjectCache(Workspace workspace)
Method Detail |
---|
public static ProjectCache getInstance(Workspace workspace)
close()
on the cache instance when the cache is no longer in use.workspace
- the workspacepublic static void invalidate(Workspace workspace)
workspace
- the workspacepublic static void invalidate(java.util.Collection<Project> projects)
projects
- the projectspublic static void invalidate(Project project)
project
- the projectpublic static void invalidateLibraries()
public void close()
public Path getContentPath(Project project)
project
- the projectProjectContent.getAllContents()
public Path getContentPath(Project project, java.lang.String contentSetKey)
project
- the projectcontentSetKey
- the content set keyProjectContent.getContentSet(java.lang.String)
public java.util.Collection<Project> getDirectDependencies(Project project)
project
- the projectpublic java.util.Collection<Project> getTransitiveDependencies(Project project) throws java.lang.InterruptedException
project
- the projectjava.lang.InterruptedException
- if the calling thread is interruptedpublic java.util.Collection<Project> getDownstreamDependencies(Project project) throws java.lang.InterruptedException
project
- the projectjava.lang.InterruptedException
- if the calling thread is interruptedpublic java.lang.String[] getTechnologyScopeKeys(Project project)
project
- the projectprotected Path getPath(Project project, java.lang.String key)
project
- the project the path was cached forkey
- the path keynull
if the path is not cachedprotected void putPath(Project project, java.lang.String key, Path path)
project
- the project the path is being cached forkey
- the path keypath
- the path to be cachedprotected LibraryPaths getLibraryPaths(Project project, java.lang.String key)
project
- the project the library paths were cached forkey
- the library paths keynull
if the library paths are not in the cacheprotected void putLibraryPaths(Project project, java.lang.String key, LibraryPaths libraryPaths)
project
- the project the library paths are being cached forkey
- the library paths keylibraryPaths
- the library pathsprotected java.util.List<LibraryPaths> getLibraryPathsList(Project project, java.lang.String key)
project
- the project the library paths list was cached forkey
- the library paths list keynull
if the library paths list is not cachedprotected void putLibraryPathsList(Project project, java.lang.String key, java.util.List<LibraryPaths> libraryPathsList)
project
- the project the library paths list is being cached forkey
- the library paths list keylibraryPathsList
- the library paths listprotected Project loadProject(Project project)
protected java.util.logging.Logger getLogger()
|
Oracle Fusion Middleware Java API Reference for Oracle Extension SDK 11g Release 2 (11.1.2.3.0) E17493-04 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |