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

## nextapp.echo2.app.componentxml
Class ComponentIntrospector

    java.lang.Object
      nextapp.echo2.app.componentxml.ComponentIntrospector

    public class ComponentIntrospector

extends java.lang.Object

Provides introspection into Echo components. A wrapper for JavaBean APIs to preform introspection on Echo Components. Provides convenience methods to retrieve available property names, types, and other bean-related information.

Method Summary
`static ComponentIntrospector` | `forName(java.lang.String typeName, java.lang.ClassLoader classLoader)` Creates a new `ComponentIntrospector` for a type of Echo component.
`java.util.Iterator` | `getConstantNames()` Retrieves the names of all constants.
`java.lang.Object` | `getConstantValue(java.lang.String constantName)` Retrieves the value of the constant with the specified name.
`java.lang.Class` | `getObjectClass()` Returns the class being introspected.
`java.lang.Class` | `getPropertyClass(java.lang.String propertyName)` Returns the `Class` of a specific property.
`java.beans.PropertyDescriptor` | `getPropertyDescriptor(java.lang.String propertyName)` Returns the `PropertyDescriptor` for the specified property.
`java.lang.reflect.Method` | `getWriteMethod(java.lang.String propertyName)` Returns a write (setter) method for a specific property.
`boolean` | `isIndexedProperty(java.lang.String propertyName)` Determines whether a property is an indexed property.

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

Method Detail

### forName

    public static ComponentIntrospector forName(java.lang.String typeName,
                                                java.lang.ClassLoader classLoader)
                                         throws java.lang.ClassNotFoundException

  Creates a new `ComponentIntrospector` for a type of Echo component.

  Parameters:
    `typeName` - the type name of Echo component
    `classLoader` - the class loader from which the type class may be retrieved
  Throws:
    `java.lang.ClassNotFoundException`

### getConstantNames

    public java.util.Iterator getConstantNames()

  Retrieves the names of all constants. A constant is defined to be any public static final variable declared in the introspected class.

  Returns:
    an iterator over the constant names

### getConstantValue

    public java.lang.Object getConstantValue(java.lang.String constantName)

  Retrieves the value of the constant with the specified name.

  Parameters:
    `constantName` - the name of the constant (unqualified)
  Returns:
    the constant value, or null if no such constant exists
  See Also:
    `getConstantNames()`

### getObjectClass

    public java.lang.Class getObjectClass()

  Returns the class being introspected.

  Returns:
    the introspected class

### getPropertyClass

    public java.lang.Class getPropertyClass(java.lang.String propertyName)

  Returns the `Class` of a specific property.

  Parameters:
    `propertyName` - the name of the property
  Returns:
    the `Class` of the property

### getPropertyDescriptor

    public java.beans.PropertyDescriptor getPropertyDescriptor(java.lang.String propertyName)

  Returns the `PropertyDescriptor` for the specified property.

  Parameters:
    `propertyName` - the name of the property
  Returns:
    the `PropertyDescriptor` associated with the property

### getWriteMethod

    public java.lang.reflect.Method getWriteMethod(java.lang.String propertyName)

  Returns a write (setter) method for a specific property.

  Parameters:
    `propertyName` - the name of the property
  Returns:
    the write method (if available)

### isIndexedProperty

    public boolean isIndexedProperty(java.lang.String propertyName)

  Determines whether a property is an indexed property.

  Parameters:
    `propertyName` - the name of the property to query
  Returns:
    true if the specified property is indexed

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