Oracle Fusion Middleware Java API Reference for Oracle Extension SDK Reference
11g Release 1 (11.1.1.4.0)

E13403-05

oracle.jdeveloper.audit.model
Interface ContentDirectory

All Superinterfaces:
Displayable, Element, Locatable
All Known Implementing Classes:
DefaultContentDirectory

public interface ContentDirectory
extends Element, Locatable

A single directory contained by one or more ContentRoots. The content roots, if more than one, will necesarily have the same URLs.


Method Summary
 boolean canContainJavaSources()
          Gets whether this directory can contain Java sources.
 Attributes getAttributes()
          This method returns an Attributes object that encodes the attributes of the Element.
 java.util.Iterator<Element> getChildren()
          Gets the children of this content set directory.
 java.util.Collection<java.lang.String> getContentSetKeys()
          Gets the keys of the content sets containing this directory.
 java.lang.Object getData()
          Returns the data object associated with this Element.
 int getDepth()
          Gets the depth of this directory.
 java.lang.String getName()
          Gets the simple name of this directory.
 java.lang.String getRelativePath()
          Gets the slash-separated path of this directory relative to its content set root directory.
 java.util.Collection<ContentRoot> getRoots()
          Gets the ContentRoots containing this directory.
 java.net.URL getURL()
          Gets the URL of this directory.
 boolean mayHaveChildren()
          This method is part of the Element interface to provide a convenient way of determining whether an object may have children without having to test the object's type with the instanceof operator or having to downcast to a more specific type.
 
Methods inherited from interface oracle.ide.model.Displayable
getIcon, getLongLabel, getShortLabel, getToolTipText, toString
 
Methods inherited from interface oracle.ide.model.Locatable
setURL
 

Method Detail

getURL

java.net.URL getURL()
Gets the URL of this directory.

Specified by:
getURL in interface Locatable
Returns:
The URL identifying this Locatable.

getRelativePath

java.lang.String getRelativePath()
Gets the slash-separated path of this directory relative to its content set root directory.


getDepth

int getDepth()
Gets the depth of this directory.


getName

java.lang.String getName()
Gets the simple name of this directory.


getRoots

java.util.Collection<ContentRoot> getRoots()
Gets the ContentRoots containing this directory.


getContentSetKeys

java.util.Collection<java.lang.String> getContentSetKeys()
Gets the keys of the content sets containing this directory.


canContainJavaSources

boolean canContainJavaSources()
Gets whether this directory can contain Java sources.


mayHaveChildren

boolean mayHaveChildren()
This method is part of the Element interface to provide a convenient way of determining whether an object may have children without having to test the object's type with the instanceof operator or having to downcast to a more specific type.

An implementation of Element that represents a leaf in a tree structure should return false from this method. An implementation of Element that could represent a non-leaf in a tree structure should return true from this method, even if it does not currently contain any children.

A ContentDirectory should always return true.

Specified by:
mayHaveChildren in interface Element
Returns:
true if this Element may contain child Elements.

getChildren

java.util.Iterator<Element> getChildren()
Gets the children of this content set directory.

The children are Node and ContentDirectory elements for the file and directories directly contained by the directory.

Specified by:
getChildren in interface Element
Returns:
an Iterator over any child Elements contained by this Element. If there are no children, null is returned.

getAttributes

Attributes getAttributes()
This method returns an Attributes object that encodes the attributes of the Element. Changing the attribute settings on the return object changes the element attributes. Subclasses should use their super class attributes object to define their own attributes. This allows subclasses to inherit their super class attributes. If a subclass does not wish to inherit attributes, they should first call getAttributes().clear() and define new attributes.

The default attributes of a ContentDirectory are empty.

Specified by:
getAttributes in interface Element

getData

java.lang.Object getData()
Returns the data object associated with this Element. Implementations will often simply return this, since the Element is often its own data object. If the implementation returns an object other than this, be sure to set ElementAttributes.DECORATES_DATA_ELEMENT.

The data of a ContentDirectory is itself.

Specified by:
getData in interface Element
Returns:
the data object associated with this Element instance.

Oracle Fusion Middleware Java API Reference for Oracle Extension SDK Reference
11g Release 1 (11.1.1.4.0)

E13403-05

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