Joda System API

org.joda.property.impl
Class BeanMetaData

java.lang.Object
  |
  +--org.joda.property.impl.BeanMetaData

public class BeanMetaData
extends java.lang.Object

MetaData about a Bean derived by reflection. This is cached for performance by bean type.

Author:
Stephen Colebourne

Field Summary
protected  BeanMethods iBeanMethods
          The bean methods instance
protected  PropertyMetaData[] iPropertyMetaData
          The list of methods in the interface which refer to properties
protected  java.lang.Class iType
          The type that this is the meta data for
 
Constructor Summary
protected BeanMetaData(java.lang.Class beanType)
          Constructor.
 
Method Summary
 BeanMethods getBeanMethods()
          Get the BeanMethods implementation, where additional non-property methods are specified.
 java.lang.Class getBeanType()
          Get the type of the bean.
static BeanMetaData getMetaData(java.lang.Class beanType)
          Get an instance of a BeanMetaData.
 PropertyMetaData[] getPropertyMetaData()
          Get the property meta data array describing the bean
 PropertyMetaData getPropertyMetaData(java.lang.String propertyName)
          Get a property meta data object by property name.
protected  BeanMethods initBeanMethods(java.lang.Class beanInterface)
          Get the BeanMethods class associated with the bean
 java.lang.String toString()
          Get a debugging string representing this object.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

iType

protected final java.lang.Class iType
The type that this is the meta data for


iPropertyMetaData

protected final PropertyMetaData[] iPropertyMetaData
The list of methods in the interface which refer to properties


iBeanMethods

protected BeanMethods iBeanMethods
The bean methods instance

Constructor Detail

BeanMetaData

protected BeanMetaData(java.lang.Class beanType)
Constructor.

Parameters:
beanType - the type of the bean, either interface or class
Method Detail

getMetaData

public static BeanMetaData getMetaData(java.lang.Class beanType)
Get an instance of a BeanMetaData. This will check the cache, creating a new instance if necessary.

Parameters:
beanType - the type of the bean, either interface or class
Returns:
a shared instance of the BeanMetaData

initBeanMethods

protected BeanMethods initBeanMethods(java.lang.Class beanInterface)
Get the BeanMethods class associated with the bean

Returns:
BeanMethods instance

getPropertyMetaData

public PropertyMetaData[] getPropertyMetaData()
Get the property meta data array describing the bean

Returns:
property meta data array

getPropertyMetaData

public PropertyMetaData getPropertyMetaData(java.lang.String propertyName)
Get a property meta data object by property name.

Returns:
property meta data object

getBeanType

public java.lang.Class getBeanType()
Get the type of the bean. This may be an interface or a class depending on the approach in use.

Returns:
bean type

getBeanMethods

public BeanMethods getBeanMethods()
Get the BeanMethods implementation, where additional non-property methods are specified. The BeanMethods concept is only used by the interface approach to designing a Joda model.

Returns:
BeanMethods object or null

toString

public java.lang.String toString()
Get a debugging string representing this object.

Overrides:
toString in class java.lang.Object
Returns:
debugging string

Joda System API

Copyright © 2001-2003 Stephen Colebourne. All Rights Reserved.