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

E13403-02

oracle.ide.model
Interface Element

All Superinterfaces:
Displayable
All Known Subinterfaces:
CmtModelNode, ContentDirectory, DBObjectNode, DBObjectPlSqlNode, DBObjectProviderNode, DBObjectTypeNode, Folder, Palette, PaletteItem, PalettePage, RelativeDirectoryElement, SchemaObjectNode
All Known Implementing Classes:
AbstractDerivedLibrary, AbstractLibrary, AbstractTemplate, AddinJDK, AddinLibrary, AppClientProfile, ApplicationTemplate, ArchiveProfile, BaseDBObjectNode, BaseDBObjectTextNode, BasePlSqlTextNode, BrowsableWebDocumentNode, ChangeListItem, ClientProfile, CmtFolder, ConnectionListFilterNode, ConnectionNodeDecorator, ConnectionPlaceholderNode, Connections, ConnectorProfile, DataContainer, DataNode, DefaultContainer, DefaultContentDirectory, DefaultElement, DefaultFolder, DeployableTextNode, DeployElement, DeployFolder, DeployGalleryFolder, DeploymentProfiles, EarProfile, EjbProfile, ExternalLibrary, oracle.ide.gallery.GalleryFolder, HashStructureNode, HistoryElement, oracle.jdevimpl.webapp.html.HtmlSourceNode, IdeLayout, IdeProperties, IdeSystem, ImageNode, J2eeProfile, JavaClassNode, JavaNode, JavaSourceNode, JDKNode, JLibraryNode, JRunProcess, JspLibrary, JspSourceNode, Layout, Layouts, LegacyJDK, LegacyLibrary, LegacyLibraryDefinition, LegacyLibraryList, LibraryDataNode, LibraryElement, Node, ObservableFolder, PatchNode, PlsqlMethod, PlsqlPackage, PlsqlPackagedFunction, PlsqlPackagedProcedure, PlsqlTopLevelFunction, PlsqlTopLevelMethod, PlsqlTopLevelProcedure, Preferences, Profile, Project, ProjectLibrary, ProjectTemplate, ProviderNode, RegisteredDynamicNode, RelativeDirectoryContextFolder, RemoteProcess, RunningProcess, RunProcess, SchemaNode, SimpleLayout, SqlNode, StoredProcProfile, TaglibProfile, TextMergeNode, TextNode, UnrecognizedTextNode, VersionHistoryNode, WarProfile, WebDocumentNode, Workspace, Workspaces, XMLDataContainer, XMLDataNode, oracle.bali.xml.addin.XMLSourceNode

public interface Element
extends Displayable

The Element interface defines the protocol used by the IDE to communicate with data objects in order to display the objects in the UI. For example, objects that need to be shown in an ExplorerWindow will need to implement the Element interface.


Method Summary
 Attributes getAttributes()
          This method returns an Attributes object that encodes the attributes of the Element.
 java.util.Iterator<Element> getChildren()
          This method is part of the Element interface to provide a convenient way of getting an Iterator over any contained child Elements without having to test the object's type with the instanceof operator or having to downcast to a more specific type.
 java.lang.Object getData()
          Returns the data object associated with this Element.
 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
 

Method Detail

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.

Returns:
true if this Element may contain child Elements.

getChildren

java.util.Iterator<Element> getChildren()
This method is part of the Element interface to provide a convenient way of getting an Iterator over any contained child Elements 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 null from this method. An implementation of Element that could represent a non-leaf in a tree structure should return either an Iterator over the child Elements or null if there are no children.

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.


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.

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.1.0)

E13403-02

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