站内搜索: 请输入搜索关键词
当前页面: 在线文档首页 > NetBeans API Javadoc 5.5.0

Sheet (NetBeans Nodes API) - NetBeans API Javadoc 5.5.0

org.openide.nodes 6.7.22

org.openide.nodes
Class Sheet

java.lang.Object
  extended by org.openide.nodes.Sheet

public final class Sheet
extends Object

Support for creation of property sets. Allows easy addition, modification, and deletion of properties. Also permits listening on changes of contained properties.


Nested Class Summary
static class Sheet.Set
          A set of Bean properties.
 
Field Summary
static String EXPERT
          Name for expert Bean property set.
static String PROPERTIES
          Name for regular Bean property set.
 
Constructor Summary
Sheet()
          Default constructor.
 
Method Summary
 void addPropertyChangeListener(PropertyChangeListener l)
          Add a change listener.
 Sheet cloneSheet()
          Create a deep copy of the sheet.
static Sheet createDefault()
          Convenience method to create new sheet with only one empty set, named PROPERTIES.
static Sheet.Set createExpertSet()
          Convenience method to create new sheet set named EXPERT.
static Sheet.Set createPropertiesSet()
          Convenience method to create new sheet set named PROPERTIES.
 Sheet.Set get(String name)
          Find the property set with a given name.
 Sheet.Set put(Sheet.Set set)
          Add a property set.
 Sheet.Set remove(String set)
          Remove a property set from the sheet.
 void removePropertyChangeListener(PropertyChangeListener l)
          Remove a change listener.
 Node.PropertySet[] toArray()
          Obtain the array of property sets.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

PROPERTIES

public static final String PROPERTIES
Name for regular Bean property set.

See Also:
Constant Field Values

EXPERT

public static final String EXPERT
Name for expert Bean property set.

See Also:
Constant Field Values
Constructor Detail

Sheet

public Sheet()
Default constructor.

Method Detail

toArray

public final Node.PropertySet[] toArray()
Obtain the array of property sets.

Returns:
the array

cloneSheet

public Sheet cloneSheet()
Create a deep copy of the sheet. Listeners are not copied.

Returns:
the cloned object

get

public Sheet.Set get(String name)
Find the property set with a given name.

Parameters:
name - name of the set
Returns:
the property set, or null if no such set exists

put

public Sheet.Set put(Sheet.Set set)
Add a property set. If the set does not yet exist in the sheet, inserts a new set with the implied name. Otherwise the old set is replaced by the new one.

Parameters:
set - to add
Returns:
the previous set with the same name, or null if this is a fresh insertion

remove

public Sheet.Set remove(String set)
Remove a property set from the sheet.

Parameters:
set - name of set to remove
Returns:
removed set, or null if the set could not be found

createDefault

public static Sheet createDefault()
Convenience method to create new sheet with only one empty set, named PROPERTIES. Display name and hint are settable via the appropriate bundle.

Returns:
a new sheet with default property set

createPropertiesSet

public static Sheet.Set createPropertiesSet()
Convenience method to create new sheet set named PROPERTIES.

Returns:
a new properties sheet set

createExpertSet

public static Sheet.Set createExpertSet()
Convenience method to create new sheet set named EXPERT.

Returns:
a new expert properties sheet set

addPropertyChangeListener

public void addPropertyChangeListener(PropertyChangeListener l)
Add a change listener.

Parameters:
l - the listener

removePropertyChangeListener

public void removePropertyChangeListener(PropertyChangeListener l)
Remove a change listener.

Parameters:
l - the listener

org.openide.nodes 6.7.22

Built on May 28 2007.  |  Portions Copyright 1997-2005 Sun Microsystems, Inc. All rights reserved.