Oracle Fusion Middleware Java API Reference for Oracle Extension SDK
11g Release 2 (11.1.2.1.0)

E17493-02

oracle.jdevimpl.audit.model
Class DefaultContentCache

java.lang.Object
  extended by oracle.jdevimpl.audit.model.DefaultContentCache
All Implemented Interfaces:
ContentCache

public class DefaultContentCache
extends java.lang.Object
implements ContentCache


Constructor Summary
DefaultContentCache(java.util.List<ContentRoot> roots)
           
 
Method Summary
 boolean acceptsUrl(ContentRoot root, java.net.URL url)
          Gets whether a content set root accepts a URL.
 ContentDirectory getContainingDirectory(ContentDirectory directory)
          Gets the containing content set directory of a content set directory, or null if the directory is a root directory.
 java.util.Collection<ContentDirectory> getDirectories(java.net.URL url)
          Gets the content set directories for a URL.
 java.util.Collection<ContentDirectory> getRootDirectories(java.util.Set<ContentRoot.Type> types)
          Gets the content set directories for the content set roots of the cached projects.
 java.util.Collection<ContentRoot> getRoots()
          Gets the content set roots of the project.
 java.util.Collection<ContentRoot> getRoots(java.net.URL url)
          Gets the roots which contains a URL, ordered from longest to shortest, or empty if none.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DefaultContentCache

public DefaultContentCache(java.util.List<ContentRoot> roots)
Method Detail

getRoots

public java.util.Collection<ContentRoot> getRoots()
Description copied from interface: ContentCache
Gets the content set roots of the project.

Specified by:
getRoots in interface ContentCache

getRoots

public java.util.Collection<ContentRoot> getRoots(java.net.URL url)
Description copied from interface: ContentCache
Gets the roots which contains a URL, ordered from longest to shortest, or empty if none. If the URL does not pass project and root filters with respect to a root, the root is not included.

Specified by:
getRoots in interface ContentCache

acceptsUrl

public boolean acceptsUrl(ContentRoot root,
                          java.net.URL url)
Description copied from interface: ContentCache
Gets whether a content set root accepts a URL. To be accepted, the URL must pass both the root pattern filters and the project filters. For file URLs, acceptance is determined with IntersectedFilters.inferFromFilters(java.lang.String); for directory URLs, with IntersectedFilters.isIncluded(java.lang.String).

Specified by:
acceptsUrl in interface ContentCache
Parameters:
root - The content set root.
url - The URL to test.

getRootDirectories

public java.util.Collection<ContentDirectory> getRootDirectories(java.util.Set<ContentRoot.Type> types)
Description copied from interface: ContentCache
Gets the content set directories for the content set roots of the cached projects.

Since roots from different content sets that have the same URL are merged into a single content set directory, there may be fewer content set directories than roots. Note that neither project nor root filters apply to the roots themselves.

Specified by:
getRootDirectories in interface ContentCache
Parameters:
types - The content root types for which to get directories.

getDirectories

public java.util.Collection<ContentDirectory> getDirectories(java.net.URL url)
Description copied from interface: ContentCache
Gets the content set directories for a URL. If the URL does not pass project and root filters with respect to a root, the root is not included. There will only be one directory unless the URL is contained by two or more content sets with different roots (and thus the URL has a different relative path with respect to each root).

If the specified URL is a directory URL, the URL of the directories will be that URL; if the specified URL is a file URL, the URL of the directories will be the parent of that URL.

Specified by:
getDirectories in interface ContentCache

getContainingDirectory

public ContentDirectory getContainingDirectory(ContentDirectory directory)
Description copied from interface: ContentCache
Gets the containing content set directory of a content set directory, or null if the directory is a root directory.

Specified by:
getContainingDirectory in interface ContentCache

Oracle Fusion Middleware Java API Reference for Oracle Extension SDK
11g Release 2 (11.1.2.1.0)

E17493-02

Copyright © 1997, 2011, Oracle. All rights reserved.