org.ujac.util.table
Class BeanColumn

java.lang.Object
  extended by org.ujac.util.table.DefaultColumn
      extended by org.ujac.util.table.BeanColumn
All Implemented Interfaces:
Serializable, Column, TableConstants, UjacTypes

public class BeanColumn
extends DefaultColumn

Name: BeanColumn
Description: A class for columns, holding getter and setter methods to support java bean access.

Author:
lauerc
See Also:
Serialized Form

Field Summary
 
Fields inherited from interface org.ujac.util.table.TableConstants
DEFAULT_DATE_FORMAT, DEFAULT_DOUBLE_FORMAT, DEFAULT_INTEGER_FORMAT, DEFAULT_TIME_FORMAT, DEFAULT_TIMESTAMP_FORMAT, ROW_TYPE_FOOTER, ROW_TYPE_GROUP, ROW_TYPE_GROUP_TITLE, ROW_TYPE_HEADER, ROW_TYPE_NORMAL
 
Fields inherited from interface org.ujac.util.UjacTypes
TYPE_BOOLEAN, TYPE_DATE, TYPE_DOUBLE, TYPE_FLOAT, TYPE_INT, TYPE_LONG, TYPE_NAME_BOOLEAN, TYPE_NAME_DATE, TYPE_NAME_DOUBLE, TYPE_NAME_FLOAT, TYPE_NAME_INT, TYPE_NAME_LONG, TYPE_NAME_OBJECT, TYPE_NAME_SHORT, TYPE_NAME_STRING, TYPE_NAME_TABLE, TYPE_NAME_TIME, TYPE_NAME_TIMESTAMP, TYPE_OBJECT, TYPE_SHORT, TYPE_STRING, TYPE_TABLE, TYPE_TIME, TYPE_TIMESTAMP
 
Constructor Summary
BeanColumn(BeanTable table, String name, boolean key, int type, Method getter)
          Constructs a BeanColumn instance with specific attributes.
BeanColumn(BeanTable table, String name, int type, Method getter)
          Constructs a BeanColumn instance with specific attributes.
 
Method Summary
 Method getGetter()
          Gets the getter method.
 Method getSetter()
          Gets the setter method.
 void setSetter(Method setter)
          Sets the setter method.
 
Methods inherited from class org.ujac.util.table.DefaultColumn
getAlias, getDataIndex, getFormat, getIndex, getLayoutHints, getName, getType, getTypeName, isKey, readData, setAlias, setDataIndex, setFormat, setFormat, setIndex, setKey, setLayoutHints, setName, setType, toString, writeData
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

BeanColumn

public BeanColumn(BeanTable table,
                  String name,
                  int type,
                  Method getter)
Constructs a BeanColumn instance with specific attributes.

Parameters:
table - The bean table instance this column is attached to.
name - The column name.
type - The column type.
getter - The getter method.

BeanColumn

public BeanColumn(BeanTable table,
                  String name,
                  boolean key,
                  int type,
                  Method getter)
Constructs a BeanColumn instance with specific attributes.

Parameters:
table - The bean table instance this column is attached to.
name - The column name.
key - Tells whether or not the column defines a key value.
type - The column type.
getter - The getter method.
Method Detail

getGetter

public Method getGetter()
Gets the getter method.

Returns:
The getter method.

getSetter

public Method getSetter()
Gets the setter method. If null is returned, this is a read only column.

Returns:
The setter method.

setSetter

public void setSetter(Method setter)
Sets the setter method.

Parameters:
setter - The setter method to set.


Copyright © 2003-2004 UJAC.org. All Rights Reserved.