Extension SDK

oracle.jdeveloper.model
Class ImageNode

java.lang.Object
  extended byoracle.ide.model.DefaultDisplayable
      extended byoracle.ide.model.DefaultElement
          extended byoracle.ide.model.DefaultDocument
              extended byoracle.ide.model.DefaultNode
                  extended byoracle.jdeveloper.model.ImageNode
All Implemented Interfaces:
Category, Data, Dirtyable, Displayable, Document, Element, LazyLoadable, Locatable, Node, Subject
Direct Known Subclasses:
GifImageNode, JpegImageNode, PngImageNode

public class ImageNode
extends DefaultNode

Node subclass for image files. This class should be instantiated only through a subclass and not directly.


Field Summary
 
Fields inherited from interface oracle.ide.addin.Subject
OBJECT_MODIFIED
 
Fields inherited from interface oracle.ide.model.Category
UNDEFINED
 
Constructor Summary
protected ImageNode()
           
protected ImageNode(java.net.URL url)
           
 
Method Summary
 void close()
          Closes the Document and unloads any associated data.
 javax.swing.Icon getIcon()
          Returns an Icon that can be shown in association with this Displayable.
 java.awt.Image getImage()
           
 boolean isDirty()
          True if the data in the object has been modified.
 boolean isNew()
          Returns true if the document's data has never been saved.
 void markDirty(boolean dirty)
          Marks the data with the specified dirty state.
 void open()
          Opens the Document and loads any associated data into the appropriate data structures.
 void setURL(java.net.URL url)
          Sets the URL associated with this DefaultNode and recaches the DefaultNode in the NodeFactory with the new URL so that subsequent queries for the DefaultNode will return successfully.
 
Methods inherited from class oracle.ide.model.DefaultNode
equalsImpl, getCategory
 
Methods inherited from class oracle.ide.model.DefaultDocument
attach, copyToImpl, createSubject, detach, ensureOpen, equalsImpl, getInputStream, getLongLabel, getShortLabel, getSubject, getTimestamp, getTimestampDirectly, getToolTipText, getURL, isOpen, isReadOnly, notifyObservers, refreshTimestamp, save, setOpen, setTimestampDirectly
 
Methods inherited from class oracle.ide.model.DefaultElement
getAttributes, getChildren, getData, mayHaveChildren
 
Methods inherited from class oracle.ide.model.DefaultDisplayable
toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface oracle.ide.model.Document
getInputStream, getTimestamp, isReadOnly, save
 
Methods inherited from interface oracle.ide.model.Locatable
getURL
 
Methods inherited from interface oracle.ide.model.Element
getAttributes, getChildren, mayHaveChildren
 
Methods inherited from interface oracle.ide.model.Data
getData
 
Methods inherited from interface oracle.ide.model.Displayable
getLongLabel, getShortLabel, getToolTipText, toString
 
Methods inherited from interface oracle.ide.addin.Subject
attach, detach, notifyObservers
 
Methods inherited from interface oracle.ide.model.LazyLoadable
isOpen
 

Constructor Detail

ImageNode

protected ImageNode()

ImageNode

protected ImageNode(java.net.URL url)
Method Detail

getImage

public java.awt.Image getImage()

open

public void open()
          throws java.io.IOException
Description copied from interface: Document
Opens the Document and loads any associated data into the appropriate data structures. If the implementation of this method completes successfully, the LazyLoadable.isOpen() method should then return true.

Specified by:
open in interface Document
Overrides:
open in class DefaultDocument
Throws:
java.io.IOException
See Also:
Document.open()

close

public void close()
           throws java.io.IOException
Description copied from interface: Document
Closes the Document and unloads any associated data. When this method returns, the state of the Document object should be equivalent to when the Document object has just been instantiated but not yet opened.

Specified by:
close in interface Document
Overrides:
close in class DefaultDocument
Throws:
java.io.IOException
See Also:
Document.close()

isNew

public boolean isNew()
Description copied from interface: Document
Returns true if the document's data has never been saved.

Specified by:
isNew in interface Document
Overrides:
isNew in class DefaultDocument

getIcon

public javax.swing.Icon getIcon()
Description copied from interface: Displayable
Returns an Icon that can be shown in association with this Displayable. Typically the icon will be used in a tree control or list control. Therefore the icon must fit naturally within the space normally given to items within those controls. Such icons are usually 16x16 in size or, if there is a one-pixel transparent padding around the edge, 18x18 in size. It is strongly recommended that icons returned by this method be either 16x16 or 18x18 in size. If null is returned, the control may show a default icon, or it may show no icon, whichever is appropriate.

Specified by:
getIcon in interface Displayable
Overrides:
getIcon in class DefaultDisplayable
See Also:
Displayable.getIcon()

isDirty

public boolean isDirty()
Description copied from interface: Dirtyable
True if the data in the object has been modified.

Specified by:
isDirty in interface Dirtyable
Overrides:
isDirty in class DefaultDocument

markDirty

public void markDirty(boolean dirty)
Description copied from interface: Dirtyable
Marks the data with the specified dirty state. This method is called markDirty(...) instead of setDirty(...) so that the JavaBeans Introspector will not mistakenly identify "dirty" as a JavaBean property.

Specified by:
markDirty in interface Dirtyable
Overrides:
markDirty in class DefaultDocument

setURL

public void setURL(java.net.URL url)
Description copied from class: DefaultNode
Sets the URL associated with this DefaultNode and recaches the DefaultNode in the NodeFactory with the new URL so that subsequent queries for the DefaultNode will return successfully.

Specified by:
setURL in interface Locatable
Overrides:
setURL in class DefaultNode
See Also:
Locatable.setURL(URL), DefaultDocument.setURL(URL)

Extension SDK

 

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