Elexis: Das führende OpenSource-Arztpraxisprogamm
im deutschsprachigen Raum
Java doc for Elexis version 2.1.7.dev vom 17.03.2013

ag.ion.bion.officelayer.internal.text.table.extended
Class ETextTable

java.lang.Object
  extended by ag.ion.bion.officelayer.internal.text.table.extended.ETextTable
All Implemented Interfaces:
ICloneServiceProvider, IETextTable

public class ETextTable
extends java.lang.Object
implements IETextTable

Implementation for extended tables.


Constructor Summary
ETextTable(ITextDocument textDocument, ITextTable textTable)
          Constructs new extended text table.
 
Method Summary
 void addRows(int count)
          Adds row(s) to the table.
 void addRows(int index, int count)
          Adds row(s) at submitted index to the table.
 void addRows(int index, int count, boolean after)
          Adds row(s) before or after submitted index to the table.
 void addTable(ITextTable textTable)
          Addes a new text table.
 IETextTableCell getCell(int rowIndex, int columnIndex)
          Returns cell with the submitted column and row index.
 IETextTableCell getCell(java.lang.String cellName)
          Returns cell with the submitted name.
 IETextTableCellRange getCellRange(int firstColumnIndex, int firstRowIndex, int lastColumnIndex, int lastRowIndex)
          Returns cell range on the basis submitted index informations.
 IETextTableCellRange getCellRange(java.lang.String rangeName)
          Returns cell range on the basis of the submitted cell range name.
 ICloneService getCloneService()
          Gets the clone service of the element.
 IETextTableColumn getColumn(int columnIndex)
          Returns a column at submitted index the table.
 int getColumnCount()
          Returns number of available columns.
 IETextTableColumn[] getColumns()
          Returns all columns of a table.
 ITextTableProperties[] getProperties()
          Returns properties of the text table.
 IETextTableRow getRow(int index)
          Returns text table row.
 int getRowCount()
          Returns number of available rows.
 IETextTableRow[] getRows()
          Returns text table rows.
 ITextTable getTextTable(int index)
          Returns a specified text table.
 int getTextTableIndex(ITextTable textTable)
          Returns a specified text table.
 ETextTableManagement getTextTableManagement()
          Returns the text table management.
 void remove()
          Removes the table.
 void removeRow(int index)
          Removes a specified row.
 void removeRows(int index)
          Removes rows.
 void removeRows(int index, int count)
          Removes rows.
 void removeTables(int index, int count)
          Removes tables.
 void spreadColumnsEvenly()
          Spread all columns evenly.
 void spreadColumnsEvenly(int startIndex, int endIndex)
          Spread columns in range evenly.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ETextTable

public ETextTable(ITextDocument textDocument,
                  ITextTable textTable)
           throws java.lang.IllegalArgumentException
Constructs new extended text table.

Parameters:
textDocument - the text document
textTable - the first text table
Throws:
java.lang.IllegalArgumentException - if one of the parameter is not valid
Method Detail

addRows

public void addRows(int count)
             throws TextException
Adds row(s) to the table.

Specified by:
addRows in interface IETextTable
Parameters:
count - number of rows to be added
Throws:
TextException - if the row(s) can not be added

addRows

public void addRows(int index,
                    int count)
             throws TextException
Adds row(s) at submitted index to the table.

Specified by:
addRows in interface IETextTable
Parameters:
index - index to be used
count - number of rows to be added
Throws:
TextException - if the row(s) can not be added

addRows

public void addRows(int index,
                    int count,
                    boolean after)
             throws TextException
Adds row(s) before or after submitted index to the table.

Specified by:
addRows in interface IETextTable
Parameters:
index - index to be used
count - number of rows to be added
after - true, if the rows shoud be addes after submitted index
Throws:
TextException - if the row(s) can not be added

getRowCount

public int getRowCount()
Returns number of available rows.

Specified by:
getRowCount in interface IETextTable
Returns:
number of available rows.

getCell

public IETextTableCell getCell(int rowIndex,
                               int columnIndex)
                        throws TextException
Returns cell with the submitted column and row index.

Specified by:
getCell in interface IETextTable
Parameters:
rowIndex - row index of the cell
columnIndex - column index of the cell
Returns:
cell with the submitted column and row index
Throws:
TextException - if the cell is not available

getCell

public IETextTableCell getCell(java.lang.String cellName)
                        throws TextException
Returns cell with the submitted name.

Specified by:
getCell in interface IETextTable
Parameters:
name - name of the cell
Returns:
cell with the submitted name
Throws:
TextException - if the cell is not available

getCellRange

public IETextTableCellRange getCellRange(int firstColumnIndex,
                                         int firstRowIndex,
                                         int lastColumnIndex,
                                         int lastRowIndex)
                                  throws TextException
Returns cell range on the basis submitted index informations.

Specified by:
getCellRange in interface IETextTable
Parameters:
fistColumnIndex - index of first column inside the range
firstRowIndex - index of first row inside the range
lastColumnIndex - index of last column inside the range
lastRowIndex - index of last row inside the range
Returns:
cell range on the basis submitted index informations
Throws:
TextException - if the cell range is not available

getCellRange

public IETextTableCellRange getCellRange(java.lang.String rangeName)
                                  throws TextException
Returns cell range on the basis of the submitted cell range name.

Specified by:
getCellRange in interface IETextTable
Parameters:
cellRangeName - name of the cell range
Returns:
cell range on the basis of the submitted cell range name
Throws:
TextException - if the cell range is not available

getColumn

public IETextTableColumn getColumn(int columnIndex)
                            throws TextException
Returns a column at submitted index the table.

Specified by:
getColumn in interface IETextTable
Parameters:
columnIndex - index of the column
Returns:
column of a table
Throws:
TextException - if any error occurs

getColumnCount

public int getColumnCount()
Returns number of available columns.

Specified by:
getColumnCount in interface IETextTable
Returns:
number of available columns

getColumns

public IETextTableColumn[] getColumns()
                               throws TextException
Returns all columns of a table.

Specified by:
getColumns in interface IETextTable
Returns:
columns of a table
Throws:
TextException - if any error occurs

getProperties

public ITextTableProperties[] getProperties()
Returns properties of the text table.

Specified by:
getProperties in interface IETextTable
Returns:
properties of the text table

spreadColumnsEvenly

public void spreadColumnsEvenly()
                         throws TextException
Spread all columns evenly.

Specified by:
spreadColumnsEvenly in interface IETextTable
Throws:
TextException - if necessary properties are not available

spreadColumnsEvenly

public void spreadColumnsEvenly(int startIndex,
                                int endIndex)
                         throws TextException
Spread columns in range evenly.

Specified by:
spreadColumnsEvenly in interface IETextTable
Parameters:
startIndex - index of the first column in range
endIndex - index of the last column in range
Throws:
TextException - if necessary properties are not available

getRows

public IETextTableRow[] getRows()
                         throws TextException
Returns text table rows.

Specified by:
getRows in interface IETextTable
Returns:
text table rows
Throws:
TextException - if any error occurs

getRow

public IETextTableRow getRow(int index)
                      throws TextException
Returns text table row.

Specified by:
getRow in interface IETextTable
Parameters:
index - the row index
Returns:
text table row
Throws:
TextException - if any error occurs

getTextTableIndex

public int getTextTableIndex(ITextTable textTable)
Returns a specified text table.

Parameters:
textTable - text table
Returns:
the index of a text table

getTextTable

public ITextTable getTextTable(int index)
Returns a specified text table.

Parameters:
index - the index of the text table
Returns:
the text table

getTextTableManagement

public ETextTableManagement getTextTableManagement()
Returns the text table management.

Returns:
the text table management.

removeRow

public void removeRow(int index)
               throws TextException
Removes a specified row.

Specified by:
removeRow in interface IETextTable
Parameters:
index - index of the row
Throws:
TextException - if the row could not removed

removeRows

public void removeRows(int index,
                       int count)
                throws TextException
Removes rows.

Specified by:
removeRows in interface IETextTable
Parameters:
index - index of the first row
count - number of rows to remove
Throws:
TextException - if the rows could not removed

removeRows

public void removeRows(int index)
                throws TextException
Removes rows.

Specified by:
removeRows in interface IETextTable
Parameters:
index - index of the first row
Throws:
TextException - if the rows could not removed

removeTables

public void removeTables(int index,
                         int count)
                  throws TextException
Removes tables.

Parameters:
index - index of the first row
count - number of the tables to remove
Throws:
TextException - if the rows could not removed

remove

public void remove()
            throws TextException
Removes the table.

Specified by:
remove in interface IETextTable
Throws:
TextException - if the table could not be removed.

getCloneService

public ICloneService getCloneService()
                              throws CloneException
Gets the clone service of the element.

Specified by:
getCloneService in interface ICloneServiceProvider
Returns:
the clone service
Throws:
CloneException - if the clone service could not be returned

addTable

public void addTable(ITextTable textTable)
              throws TextException
Addes a new text table.

Parameters:
textTable - new text table
Throws:
TextException

Elexis: Das führende OpenSource-Arztpraxisprogamm
im deutschsprachigen Raum
Java doc for Elexis version 2.1.7.dev vom 17.03.2013