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

## org.jboss.util.property
Class PropertyContainer

    java.lang.Object
      java.util.Dictionary
          java.util.Hashtable
              java.util.Properties
                  org.jboss.util.property.PropertyMap
                      org.jboss.util.property.PropertyContainer

All Implemented Interfaces:
  Cloneable, Map, Serializable

public class PropertyContainer
extends PropertyMap

Provides helper methods for working with instance or class properties.

Version:
  `$Revision: 1.2 $`
Author:
  Jason Dillon
See Also:
  Serialized Form

Field Summary
`protected String` | `groupname` The group name for this container.

Fields inherited from class org.jboss.util.property.PropertyMap
`boundListeners, EMPTY_ARRAY_PROPERTY, PROPERTY_NAME_SEPARATOR, unboundListeners`

Fields inherited from class java.util.Properties
`defaults`

Constructor Summary
`PropertyContainer(Class type)` Initialize the container with a property group of the given class name.
`PropertyContainer(Properties props)` Initialize the container with a property group.
`PropertyContainer(String groupname)` Initialize the container with a property group of the given name.

Method Summary
`protected void` | `bindField(String name)` Creates a `FieldBoundPropertyListener` for the field and property name and adds it the underlying property group.
`protected void` | `bindField(String name, String propertyName)` Creates a `FieldBoundPropertyListener` for the field and property name and adds it the underlying property group.
`protected void` | `bindMethod(String name)` Creates a `MethodBoundPropertyListener` for the method and property name and adds it the underlying property group.
`protected void` | `bindMethod(String name, String propertyName)` Creates a `MethodBoundPropertyListener` for the method and property name and adds it the underlying property group.
`protected void` | `throwException(String name)`
`protected void` | `throwException(String name, String msg)`
`protected void` | `throwException(String name, String msg, Throwable nested)`
`protected void` | `throwException(String name, Throwable nested)`

Methods inherited from class org.jboss.util.property.PropertyMap
`addPropertyListener, addPropertyListener, addPropertyListeners, containsProperty, entrySet, firePropertyAdded, firePropertyChanged, firePropertyRemoved, getArrayProperty, getArrayProperty, getProperty, getPropertyGroup, getPropertyGroup, keySet, load, load, load, load, makeIndexPropertyName, makePrefixedPropertyName, names, put, remove, removeProperty, removePropertyListener, removePropertyListener, setProperty`

Methods inherited from class java.util.Properties
`getProperty, list, list, load, propertyNames, save, store`

Methods inherited from class java.util.Hashtable
`clear, clone, contains, containsKey, containsValue, elements, entrySet, equals, get, hashCode, isEmpty, keys, keySet, putAll, rehash, size, toString, values`

Methods inherited from class java.lang.Object
`finalize, getClass, notify, notifyAll, wait, wait, wait`

Field Detail

### groupname

    protected String groupname

  The group name for this container.

Constructor Detail

### PropertyContainer

    public PropertyContainer(Properties props)

  Initialize the container with a property group.

### PropertyContainer

    public PropertyContainer(String groupname)

  Initialize the container with a property group of the given name.

Parameters:
  `groupname` - Property group name.

### PropertyContainer

    public PropertyContainer(Class type)

  Initialize the container with a property group of the given class name.

Parameters:
  `type` - The class whos name will be the property group name.

Method Detail

### bindField

    protected void bindField(String name,
                             String propertyName)

  Creates a `FieldBoundPropertyListener` for the field and property name and adds it the underlying property group.

  Parameters:
    `name` - The field name to bind values to.
    `propertyName` - The property name to bind to.
  Throws:
    `IllegalArgumentException` - Field of property name is null or empty.

### bindField

    protected void bindField(String name)

  Creates a `FieldBoundPropertyListener` for the field and property name and adds it the underlying property group.

  Parameters:
    `name` - The field name and property to bind values to.
  Throws:
    `IllegalArgumentException` - Field of property name is null or empty.

### bindMethod

    protected void bindMethod(String name,
                              String propertyName)

  Creates a `MethodBoundPropertyListener` for the method and property name and adds it the underlying property group.

  Parameters:
    `name` - The method name to bind values to.
    `propertyName` - The property name to bind to.
  Throws:
    `IllegalArgumentException` - Method of property name is null or empty.

### bindMethod

    protected void bindMethod(String name)

  Creates a `MethodBoundPropertyListener` for the method and property name and adds it the underlying property group.

  Parameters:
    `name` - The method name and property to bind values to.
  Throws:
    `IllegalArgumentException` - Method of property name is null or empty.

### throwException

    protected void throwException(String name)
                           throws PropertyException

  Throws:
    `PropertyException`

### throwException

    protected void throwException(String name,
                                  String msg)
                           throws PropertyException

  Throws:
    `PropertyException`

### throwException

    protected void throwException(String name,
                                  String msg,
                                  Throwable nested)
                           throws PropertyException

  Throws:
    `PropertyException`

### throwException

    protected void throwException(String name,
                                  Throwable nested)
                           throws PropertyException

  Throws:
    `PropertyException`

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

Copyright © 2002 JBoss Group, LLC. All Rights Reserved.