Overview | Package | Class | Tree | Deprecated | Index | Help
| Copyright © 2000, 2008, Oracle and/or its affiliates. All rights reserved.
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## com.bea.p13n.property
Class AbstractPropertySet

    java.lang.Object
      com.bea.p13n.property.AbstractPropertySet

All Implemented Interfaces
  PropertySet, Serializable

Direct Known Subclasses:
  PropertySetImpl

    public abstract class AbstractPropertySet

extends Object
implements PropertySet, Serializable

Default implementation of a Property Sets, which is a logical grouping of property definitions. A Property Set can be defined to contain the definitions of a group of related properties, such as user preferences.

These property definitions are used by Configurable Entity EJB's to validate property values and retrieve default values for properties. They can also be used by tools to display a list of available properties for an entity.

See Also
  Serialized Form

Constructor Summary
`AbstractPropertySet()` Default constructor
`AbstractPropertySet(String typeArg, String nameArg, String descriptionArg)` Constructor to initialize attributes

Method Summary
`void` | `addPropertyDefinition(String name, PropertyDefinition value)` Add a property definition to the property set.
`String` | `getDescription()` Get the description of this property set
`String` | `getName()` Get the name of this property set
`PropertyDefinition` | `getPropertyDefinition(String key)` Retrieve a particular PropertyDefinition by name.
`Map<String,PropertyDefinition>` | `getPropertyDefinitions()` Retrieve all the property definitions in this property set.
`String` | `getType()` Get the type of this property set.
`void` | `setDescription(String s)` Set the description of this property set
`void` | `setName(String s)` Set the name of this property set
`void` | `setType(String s)` Set the type of this property set.

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### AbstractPropertySet

    public AbstractPropertySet()

  Default constructor

### AbstractPropertySet

    public AbstractPropertySet(String typeArg,
                               String nameArg,
                               String descriptionArg)

  Constructor to initialize attributes

Method Detail

### getName

    public String getName()

  Get the name of this property set

  Specified by:
    `getName` in interface `PropertySet`

### setName

    public void setName(String s)

  Set the name of this property set

### getDescription

    public String getDescription()

  Get the description of this property set

  Specified by:
    `getDescription` in interface `PropertySet`

### setDescription

    public void setDescription(String s)

  Set the description of this property set

### getType

    public String getType()

  Get the type of this property set. The Type is a String that specifies what types of Entities are intended to use the properties defined in a property set. When a ConfigurableEntity EJB is deployed, it must define a variable PropertySetType in its deployment descriptor; at run-time, only property sets of that type will be used to validate properties for that entity.

  Type is also used as a way to namespace property sets - two property sets can have the same name, as long as they are different types.

  Specified by:
    `getType` in interface `PropertySet`

### setType

    public void setType(String s)

  Set the type of this property set. The Type is a String that specifies what types of Entities are intended to use the properties defined in a property set. When a ConfigurableEntity EJB is deployed, it must define a variable PropertySetType in its deployment descriptor; at run-time, only property sets of that type will be used to validate properties for that entity.

  Type is also used as a way to namespace property sets - two property sets can have the same name, as long as they are different types.

### getPropertyDefinitions

    public Map<String,PropertyDefinition> getPropertyDefinitions()

  Retrieve all the property definitions in this property set.

  Specified by:
    `getPropertyDefinitions` in interface `PropertySet`
  Returns
    a Map of property name -> PropertyDefinition objects that make up this property set; or null if the property set is empty

### getPropertyDefinition

    public PropertyDefinition getPropertyDefinition(String key)

  Retrieve a particular PropertyDefinition by name.

  Specified by:
    `getPropertyDefinition` in interface `PropertySet`
  Parameters
    `key` - the name of the PropertyDefinition to retrieve
  Returns
    the named PropertyDefinition, or null if it does not exist

### addPropertyDefinition

    public void addPropertyDefinition(String name,
                                      PropertyDefinition value)

  Add a property definition to the property set. This is NOT exposed in the public interface because property sets are read-only to the outside world.

  Parameters
    `name` - the new property's name
    `value` - the new property definition

Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2000, 2008, Oracle and/or its affiliates. All rights reserved.
Oracle is a registered trademark of Oracle Corporation and/or its affiliates.
Other names may be trademarks of their respective owners.