![]() | |
Prev Class | Next Class | Frames | No Frames |
Summary: Nested | Field | Method | Constr | Detail: Nested | Field | Method | Constr |
java.lang.Object
com.lowagie.text.Row
Row
is part of a Table
and contains some Cells
.
All Row
s are constructed by a Table
-object.
You don't have to construct any Row
yourself.
In fact you can't construct a Row
outside the package.
Since a Cell
can span several rows and/or columns
a row can contain reserved space without any content.
Field Summary | |
static int |
|
static int |
|
static int |
|
protected Object[] |
|
protected int |
|
protected int |
|
protected int |
|
protected Properties |
|
protected boolean[] |
|
protected int |
|
Fields inherited from interface com.lowagie.text.Element | |
ALIGN_BASELINE , ALIGN_BOTTOM , ALIGN_CENTER , ALIGN_JUSTIFIED , ALIGN_JUSTIFIED_ALL , ALIGN_LEFT , ALIGN_MIDDLE , ALIGN_RIGHT , ALIGN_TOP , ALIGN_UNDEFINED , ANCHOR , ANNOTATION , AUTHOR , CCITTG3_1D , CCITTG3_2D , CCITTG4 , CCITT_BLACKIS1 , CCITT_ENCODEDBYTEALIGN , CCITT_ENDOFBLOCK , CCITT_ENDOFLINE , CELL , CHAPTER , CHUNK , CREATIONDATE , CREATOR , HEADER , IMGRAW , IMGTEMPLATE , JPEG , KEYWORDS , LIST , LISTITEM , MARKED , MULTI_COLUMN_TEXT , PARAGRAPH , PHRASE , PRODUCER , PTABLE , RECTANGLE , ROW , SECTION , SUBJECT , TABLE , TITLE |
Constructor Summary | |
|
Method Summary | |
(package private) int |
|
(package private) int |
|
int |
|
(package private) void |
|
Object |
|
ArrayList |
|
(package private) int |
|
(package private) int |
|
int |
|
boolean |
|
(package private) boolean |
|
static boolean |
|
boolean |
|
(package private) boolean |
|
(package private) boolean |
|
(package private) void |
|
void |
|
void |
|
int |
|
(package private) int |
|
int |
|
public static final int CELL
id of the Cell element in a Row
- Field Value:
- 1
public static final int NULL
id of a null element in a Row
- Field Value:
- 0
public static final int TABLE
id of the Table element in a Row
- Field Value:
- 2
protected Object[] cells
This is the array of Objects (Cell
orTable
).
protected int columns
This is the number of columns in theRow
.
protected int currentColumn
This is a valid position theRow
.
protected int horizontalAlignment
This is the vertical alignment.
protected Properties markupAttributes
Contains extra markupAttributes
protected boolean[] reserved
This is the array that keeps track of reserved cells.
protected int verticalAlignment
This is the vertical alignment.
protected Row(int columns)
Constructs aRow
with a certain number of columns.
- Parameters:
columns
- a number of columns
(package private) int addElement(Object element)
Adds aCell
to theRow
.
- Parameters:
element
- the element to add (currently only Cells and Tables supported)
- Returns:
- the column position the
Cell
was added, or-1
if theelement
couldn't be added.
(package private) int addElement(Object element, int column)
Adds an element to theRow
at the position given.
- Parameters:
element
- the element to add. (currently only Cells and Tables supportedcolumn
- the position where to add the cell.
- Returns:
- the column position the
Cell
was added, or-1
if theCell
couldn't be added.
public int columns()
Gets the number of columns.
- Returns:
- a value
(package private) void deleteColumn(int column)
Returns aRow
that is a copy of thisRow
in which a certain column has been deleted.
- Parameters:
column
- the number of the column to delete
public Object getCell(int column)
Gets aCell
orTable
from a certain column.
- Parameters:
column
- the column theCell/Table
is in.
- Returns:
- the
Cell
,Table
or Object if the column was reserved or null if empty.
public ArrayList getChunks()
Gets all the chunks in this element.
- Returns:
- an
ArrayList
(package private) int getElementID(int column)
Returns the type-id of the element in a Row.
- Parameters:
column
- the column of which you'd like to know the type
- Returns:
- the type-id of the element in the row
(package private) int getObjectID(Object element)
Returns the type-id of an Object.
- Parameters:
element
- the object of which you'd like to know the type-id, -1 if invalid
- Returns:
- the type-id of an object
public int horizontalAlignment()
Gets the horizontal alignment.
- Returns:
- a value
public boolean isEmpty()
Checks if the row is empty.
- Returns:
true
if none of the columns is reserved.
(package private) boolean isReserved(int column)
Returns true/false when this position in theRow
has been reserved, either filled or through a colspan of an Element.
- Parameters:
column
- the column.
- Returns:
true
if the column was reserved,false
if not.
public static boolean isTag(String tag)
Checks if a given tag corresponds with this object.
- Parameters:
tag
- the given tag
- Returns:
- true if the tag corresponds
public boolean process(ElementListener listener)
Processes the element by adding it (or the different parts) to aElementListener
.
- Parameters:
listener
- anElementListener
- Returns:
true
if the element was processed successfully
(package private) boolean reserve(int column)
Reserves aCell
in theRow
.
- Parameters:
column
- the column that has to be reserved.
- Returns:
true
if the column was reserved,false
if not.
(package private) boolean reserve(int column, int size)
Reserves aCell
in theRow
.
- Parameters:
column
- the column that has to be reserved.size
- the number of columns
- Returns:
true
if the column was reserved,false
if not.
(package private) void setElement(Object aElement, int column)
PutsCell
to theRow
at the position given, doesn't reserve colspan.
- Parameters:
aElement
- the cell to add.column
- the position where to add the cell.
public void setHorizontalAlignment(int value)
Sets the horizontal alignment.
- Parameters:
value
- the new value
public void setVerticalAlignment(int value)
Sets the vertical alignment.
- Parameters:
value
- the new value
public int type()
Gets the type of the text element.
- Returns:
- a type
(package private) int validPosition()
Gets the index of the current, valid position
- Returns:
- a value
public int verticalAlignment()
Gets the vertical alignment.
- Returns:
- a value