|
Extension SDK | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectoracle.ide.layout.BaseLayout
oracle.ide.layout.SimpleLayout
Simple layout information. This is an extension of the BaseLayout
class. SimpleLayouts are generally user created layouts
that are owned by the IdeLayouts.
| Field Summary |
| Fields inherited from class oracle.ide.layout.BaseLayout |
_attributes, _lastModified, _url |
| Fields inherited from interface oracle.ide.layout.Layout |
LAYOUT_ACTIVE_PROPERTY, LAYOUT_NAME_PROPERTY |
| Fields inherited from interface oracle.ide.addin.Subject |
OBJECT_MODIFIED |
| Constructor Summary | |
SimpleLayout(java.net.URL url)
Constructor |
|
| Method Summary | |
void |
close()
Release the data associated with this item |
java.lang.Object |
copyTo(java.lang.Object target)
Copies the internal state of this object to the
specified copy. |
protected void |
copyToImpl(SimpleLayout copy)
|
boolean |
equals(java.lang.Object o)
|
protected boolean |
equalsImpl(SimpleLayout other)
|
javax.swing.Icon |
getIcon()
Returns an Icon that can be shown in association with this
Displayable. |
java.io.InputStream |
getInputStream()
Gets a InputStream that can be used to read the contents
of this object. |
java.io.OutputStream |
getOutputStream()
Gets a OutputStream that can be used to save the contents
of this object. |
IdeLayout |
getOwner()
Get the IdeLayout that owns this layout. |
protected OrderedProperties |
getProperties()
|
java.lang.String |
getProperty(java.lang.String key,
java.lang.String defaultValue)
Retrieves the value associated with a property. |
boolean |
isOpen()
True if the data item has been loaded already. |
boolean |
isPropertySet(java.lang.String key,
java.lang.String value,
java.lang.String defaultValue)
Returns true if the property identified by the given
key is equals the given value. |
void |
open()
Open (load) the data associated with this item. |
java.util.Enumeration |
propertyNames()
Returns an enumeration of all the keys in this property list, including the keys in the default property list. |
java.lang.Object |
removeProperty(java.lang.String key)
Removes the property. |
void |
reopen()
|
void |
save(boolean shallow)
Force the node to be re-loaded from file. |
void |
setInherited(Layout layout)
Set a layout from which this layout inherits settings. |
void |
setName(java.lang.String name)
|
void |
setOwner(IdeLayout owner)
Set the owner of this layout. |
protected void |
setProperties(OrderedProperties properties)
|
java.lang.Object |
setProperty(java.lang.String key,
java.lang.String value)
Sets the value for a property. |
| Methods inherited from class oracle.ide.layout.BaseLayout |
attach, copyToImpl, detach, equalsImpl, findLayout, getAttributes, getChildren, getData, getFilename, getLongLabel, getName, getShortLabel, getTimestamp, getToolTipText, getURL, isActive, isDirty, isNew, isReadOnly, markDirty, mayHaveChildren, notifyObservers, setActive, setURL, toString |
| Methods inherited from class java.lang.Object |
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
public SimpleLayout(java.net.URL url)
| Method Detail |
public java.lang.String getProperty(java.lang.String key,
java.lang.String defaultValue)
throws TransientMarker
PropertyAccess
getProperty in interface PropertyAccesskey - the property key for which a value is desired.defaultValue - the value to return if no value currently
exists.
TransientMarker
public java.lang.Object setProperty(java.lang.String key,
java.lang.String value)
throws TransientMarker
PropertyAccess
setProperty in interface PropertyAccesskey - the property key to setvalue - the string value to set
TransientMarkerpublic java.lang.Object removeProperty(java.lang.String key)
PropertyAccess
removeProperty in interface PropertyAccesskey - the property key to remove
public boolean isPropertySet(java.lang.String key,
java.lang.String value,
java.lang.String defaultValue)
true if the property identified by the given
key is equals the given value. If a
defaultValue is specified, that value is used in
the comparison. The strings are compared without regards to case.
public java.util.Enumeration propertyNames()
Enumeration,
Properties.defaultspublic void setInherited(Layout layout)
Layout
setInherited in interface LayoutsetInherited in class BaseLayout
public IdeLayout getOwner()
throws TransientMarker
LayoutIdeLayout that owns this layout.
getOwner in interface LayoutgetOwner in class BaseLayoutTransientMarker
public void setOwner(IdeLayout owner)
throws TransientMarker
Layout
setOwner in interface LayoutsetOwner in class BaseLayoutTransientMarkerpublic javax.swing.Icon getIcon()
DisplayableIcon 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.
getIcon in interface Displayable
public void setName(java.lang.String name)
throws java.beans.PropertyVetoException
java.beans.PropertyVetoException
public java.io.InputStream getInputStream()
throws java.io.IOException
InputStream that can be used to read the contents
of this object.
getInputStream in interface Documentjava.io.IOException - if a security manager exists and its
checkRead method denies read access.
public java.io.OutputStream getOutputStream()
throws java.io.IOException
OutputStream that can be used to save the contents
of this object.
java.io.IOException - if a security manager exists and its
checkRead method denies read access.public boolean isOpen()
isOpen in interface LazyLoadabletrue if the data item has already been opened.public void open()
open in interface Documentpublic void close()
close in interface Documentclose in class BaseLayoutpublic void reopen()
public void save(boolean shallow)
save in interface Documentshallow - do not save children if container.
TBDpublic java.lang.Object copyTo(java.lang.Object target)
Copyablethis object to the
specified copy. If copy is
null, then this method should create a new instance
of this class and proceed to copy the internal state
to the newly created object. Generally, only the persistent
state of the object should be copied, but whether or not it is
appropriate to copy transient properties is at the discretion
of the individual implementor.
Regardless of whether the copy occurs to an existing object or to
a newly created object, the return value is object to which
this object's state was copied.
There is a standard implementation pattern for the
copyTo method that helps avoid problems that arise
when a Copyable object is subclassed. The pattern
is:
public Object copyTo( Object target )
{
final <this_class> copy =
target != null ? (<this_class>) target : new <this_class>();
copyToImpl( copy );
return copy;
}
protected final void copyToImpl( <this_class> copy )
{
super.copyToImpl( copy ); // if necessary
// put code here for copying the properties of <this_class>
}
The parameter passed into the copyToImpl method is
the same type of this class. The responsibility of
copyToImpl is to copy the state of this
class through direct access of the fields. The
copyToImpl method should not use getters and setters
since these may be overridden, causing the state of
this class to be incompletely copied.
copyTo in interface Copyabletarget - The target object to which the state of
this object should be copied. If target
is null, then the copyTo method will
return a new instance of this class.
this
object was copied. If the target was
non-null, then the return value is the same as the
target object that was passed in; otherwise, the
return value is a new instance of this class.public boolean equals(java.lang.Object o)
protected final boolean equalsImpl(SimpleLayout other)
protected final void copyToImpl(SimpleLayout copy)
protected final OrderedProperties getProperties()
protected final void setProperties(OrderedProperties properties)
|
Extension SDK | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
Copyright ©1997, 2003, Oracle. All rights reserved.