org.displaytag.model
Class Column

java.lang.Object
  extended byorg.displaytag.model.Column

public class Column
extends java.lang.Object

Represents a column in a table.

Version:
$Revision: 1.20 $ ($Author: fgiust $)
Author:
Fabrizio Giustina

Constructor Summary
Column(HeaderCell headerCell, Cell currentCell, Row parentRow)
          Constructor for Column.
 
Method Summary
 java.lang.String createChoppedAndLinkedValue()
          Calculates the cell content, cropping or linking the value as needed.
 java.lang.String getChoppedAndLinkedValue()
          get the final value to be displayed in the table.
 java.lang.String getCloseTag()
          Generates the cell close tag (</td>).
 int getGroup()
          returns the grouping order of this column or -1 if the column is not grouped.
 java.lang.String getOpenTag()
          Generates the cell open tag.
 java.lang.Object getValue(boolean decorated)
          Gets the value, after calling the table / column decorator is requested.
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

Column

public Column(HeaderCell headerCell,
              Cell currentCell,
              Row parentRow)
Constructor for Column.

Parameters:
headerCell - HeaderCell
currentCell - Cell
parentRow - Row
Method Detail

getValue

public java.lang.Object getValue(boolean decorated)
                          throws ObjectLookupException,
                                 DecoratorException
Gets the value, after calling the table / column decorator is requested.

Parameters:
decorated - boolean
Returns:
Object
Throws:
ObjectLookupException - for errors in bean property lookup
DecoratorException - if a column decorator is used and an exception is thrown during value decoration

getOpenTag

public java.lang.String getOpenTag()
                            throws ObjectLookupException,
                                   DecoratorException
Generates the cell open tag.

Returns:
String td open tag
Throws:
ObjectLookupException - for errors in bean property lookup
DecoratorException - if a column decorator is used and an exception is thrown during value decoration

getCloseTag

public java.lang.String getCloseTag()
Generates the cell close tag (</td>).

Returns:
String td closing tag

createChoppedAndLinkedValue

public java.lang.String createChoppedAndLinkedValue()
                                             throws ObjectLookupException,
                                                    DecoratorException
Calculates the cell content, cropping or linking the value as needed.

Returns:
String
Throws:
ObjectLookupException - for errors in bean property lookup
DecoratorException - if a column decorator is used and an exception is thrown during value decoration

getChoppedAndLinkedValue

public java.lang.String getChoppedAndLinkedValue()
get the final value to be displayed in the table. This method can only be called after getOpenTag(), where the content is evaluated

Returns:
String final value to be displayed in the table

getGroup

public int getGroup()
returns the grouping order of this column or -1 if the column is not grouped.

Returns:
int grouping order of this column or -1 if the column is not grouped

toString

public java.lang.String toString()
See Also:
Object.toString()


Copyright © 2002-2005 the Displaytag team. All Rights Reserved.