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

E17493-02

oracle.ide.model
Class HashStructureNode

java.lang.Object
  extended by oracle.ide.model.Node
      extended by oracle.ide.model.DataContainer
          extended by oracle.ide.model.HashStructureNode
All Implemented Interfaces:
Displayable, Element, Folder, LazyLoadable, Locatable, Observer, Subject, Dirtyable, PropertyStorage
Direct Known Subclasses:
Project, Workspace

public abstract class HashStructureNode
extends DataContainer
implements PropertyStorage

Node implementation for an object that stores properties in a HashStructure and persists those properties to XML via HashStructureIO.


Field Summary
 
Fields inherited from class oracle.ide.model.Node
LOG_READONLY
 
Fields inherited from interface oracle.javatools.data.PropertyStorage
DATA_KEY
 
Method Summary
 void applyBatchChanges(java.lang.Runnable runnable)
           
protected  void closeImpl()
          Subclasses should override this method to customize the close() behavior.
abstract  java.lang.Object copyTo(java.lang.Object target)
           
protected  void copyToImpl(HashStructureNode copy)
           
 boolean equals(java.lang.Object o)
           
protected  boolean equalsImpl(HashStructureNode other)
           
protected  java.lang.String getNamespaceURI()
           
protected  java.lang.Object getObjectStoreTarget()
           
 HashStructure getProperties()
          Returns a cascading HashStructure that represents this project's persistent properties.
 HashStructure getPropertiesForOverriding()
           
protected  java.lang.String getRootQName()
           
 HashStructure getUserPropertiesOnly()
          Returns a HashStructure that contains only the user-private properties (no shared properties).
 boolean isDefault()
          For HashStructureNode subtypes that keep default state in a separate Node instance, this method should return true if this Node is the default instance.
protected  boolean isUserPropertiesEnabled()
           
protected  HashStructureIO newHashStructureIO()
           
protected  ObjectStore newObjectStore()
           
protected  void openImpl()
          Subclasses should override this method to customize the open() behavior.
protected  void saveImpl()
          Subclasses should override this method to customize the save() behavior.
 void saveUserProperties()
           
 void setURL(java.net.URL url)
          Sets the URL associated with this Node and recaches the Node in the NodeFactory with the new URL so that subsequent queries for the Node will return successfully.
 
Methods inherited from class oracle.ide.model.DataContainer
add, add, add, canAdd, canRemove, containsChild, equalsImpl, getBaseDirectory, getChildren, getListOfChildren, getProperty, getProperty, getSharedPropertiesOnly, getURL, mayHaveChildren, remove, remove, removeAll, removeAll, resetSubDirtyableOwners, revertImpl, setListOfChildren, setProperty, setSubDirtyableOwner, size, update
 
Methods inherited from class oracle.ide.model.Node
addNodeListener, addNodeListenerForType, addNodeListenerForTypeHierarchy, attach, beginThreadNodeUsageCycle, callUnderReadLock, callUnderWriteLock, close, createSubject, delete, deleteImpl, detach, endThreadNodeUsage, endThreadNodeUsageCycle, ensureOpen, equalsImpl, getAttributes, getData, getIcon, getInputStream, getLongLabel, getShortLabel, getSubject, getTimestamp, getTimestampLoadedUnsafe, getToolTipText, getTransientProperties, getUnmodifiedTimestamp, isDirty, isLoaded, isMigrating, isNew, isOpen, isReadLocked, isReadOnly, isReadOrWriteLocked, isTrackedInNodeCache, isWriteLocked, lockCount, markDirty, markDirtyImpl, nodeLock, notifyObservers, open, readLock, readLockCount, readLockInterruptibly, readUnlock, refreshTimestamp, removeNodeListener, removeNodeListenerForType, removeNodeListenerForTypeHierarchy, rename, renameImpl, reportOpenException, revert, runUnderReadLock, runUnderWriteLock, save, setEventLog, setMigrating, setOpen, setReadOnly, setTimestampDirectly, toString, tryRunUnderReadLock, unsetMigrating, upgradeLock, upgradeUnlock, urlReadOnlyChanged, writeLock, writeLockCount, writeLockInterruptibly, writeUnlock
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface oracle.ide.model.Element
getAttributes, getData
 
Methods inherited from interface oracle.ide.model.Displayable
getIcon, getLongLabel, getShortLabel, getToolTipText, toString
 

Method Detail

setURL

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

Specified by:
setURL in interface Locatable
Overrides:
setURL in class Node
Parameters:
url - The URL to set.
See Also:
Locatable.setURL(URL)

copyTo

public abstract java.lang.Object copyTo(java.lang.Object target)

copyToImpl

protected final void copyToImpl(HashStructureNode copy)

getProperties

public final HashStructure getProperties()
Returns a cascading HashStructure that represents this project's persistent properties. "Cascading" means that the returned HashStructure actually encapsulates two HashStructures -- a user-private one and a team-level ("shared") one.

Property lookups on the cascading HashStructure will start in the user-private structure and, if the property value is not assigned there, fallback on the shared structure.

Property changes on the cascading HashStructure are only applied to the user-private structure. To make changes to the shared structure, use DataContainer.getSharedPropertiesOnly().

Specified by:
getProperties in interface PropertyStorage
Overrides:
getProperties in class DataContainer
Returns:
The HashStructure wrapped by this PropertyStorage.

getPropertiesForOverriding

public final HashStructure getPropertiesForOverriding()

getUserPropertiesOnly

public final HashStructure getUserPropertiesOnly()
Returns a HashStructure that contains only the user-private properties (no shared properties).

Overrides:
getUserPropertiesOnly in class DataContainer

openImpl

protected void openImpl()
                 throws java.io.IOException
Description copied from class: Node
Subclasses should override this method to customize the open() behavior. Node.open() invokes this only if the node is not open, under write lock. The Node implementation does nothing.

Overrides:
openImpl in class Node
Throws:
java.io.IOException - if an I/O error occurred while opening

closeImpl

protected void closeImpl()
                  throws java.io.IOException
Description copied from class: Node
Subclasses should override this method to customize the close() behavior. Node.close() invokes this only if the node is open, under write lock. The Node implementation does nothing.

Overrides:
closeImpl in class DataContainer
Throws:
java.io.IOException - if an I/O error occurred while closing

saveImpl

protected void saveImpl()
                 throws java.io.IOException
Description copied from class: Node
Subclasses should override this method to customize the save() behavior. Node.save() invokes this only if the node is dirty, under write lock. The Node implementation does nothing.

Overrides:
saveImpl in class DataContainer
Throws:
java.io.IOException - if an I/O error occurred while saving

saveUserProperties

public final void saveUserProperties()
                              throws java.io.IOException
Throws:
java.io.IOException

newObjectStore

protected final ObjectStore newObjectStore()
Overrides:
newObjectStore in class DataContainer

newHashStructureIO

protected HashStructureIO newHashStructureIO()

getNamespaceURI

protected java.lang.String getNamespaceURI()

getRootQName

protected java.lang.String getRootQName()

getObjectStoreTarget

protected final java.lang.Object getObjectStoreTarget()
Overrides:
getObjectStoreTarget in class DataContainer

isDefault

public boolean isDefault()
For HashStructureNode subtypes that keep default state in a separate Node instance, this method should return true if this Node is the default instance.


isUserPropertiesEnabled

protected boolean isUserPropertiesEnabled()
Returns:
true if this HashStructureNode instance should enable support for keeping a distinct set of user properties from shared properties. If this method returns false, the user properties and shared properties will be the same HashStructure. The default implementation of this method always returns false. A subclass has to opt into enabling user properties.

applyBatchChanges

public final void applyBatchChanges(java.lang.Runnable runnable)

equals

public boolean equals(java.lang.Object o)
Overrides:
equals in class DataContainer

equalsImpl

protected final boolean equalsImpl(HashStructureNode other)

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.