Oxygen XML Editor 11.2 Author API

ro.sync.ecss.extensions.commons.table.support
Class CALSColSpec

java.lang.Object
  extended by ro.sync.ecss.extensions.commons.table.support.CALSColSpec

public class CALSColSpec
extends Object

The column specification for a CALS table model (e.g. DocBook or DITA tables).


Constructor Summary
CALSColSpec(int colNumber, String colName, String colWidth)
          Constructor.
CALSColSpec(int colNumber, String colName, WidthRepresentation colWidth)
          Constructor.
 
Method Summary
 String createXMLFragment(String ns)
          Creates the XML fragment corresponding to the column specification obtained from the colNumber, colName and colWidth fields.
 String getColumnName()
           
 int getColumnNumber()
           
 WidthRepresentation getColWidth()
           
 void setColWidth(WidthRepresentation colWidth)
          Set the new WidthRepresentation corresponding to the column specification.
 String toString()
          Creates a String representation of the column specification.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

CALSColSpec

public CALSColSpec(int colNumber,
                   String colName,
                   String colWidth)
Constructor.

Parameters:
colNumber - The number of the column. It is 1 based.
colName - The name of the column.
colWidth - The string representation of the column width as described in the WidthRepresentation.

CALSColSpec

public CALSColSpec(int colNumber,
                   String colName,
                   WidthRepresentation colWidth)
Constructor.

Parameters:
colNumber - The number of this column. It is 1 based.
colName - The name of this column.
colWidth - The column width representation.
Method Detail

getColumnNumber

public int getColumnNumber()
Returns:
The column number. It is 1 based.

getColumnName

public String getColumnName()
Returns:
The name of the column.

getColWidth

public WidthRepresentation getColWidth()
Returns:
Returns the column width representation.

toString

public String toString()
Creates a String representation of the column specification.

Overrides:
toString in class Object
See Also:
Object.toString()

createXMLFragment

public String createXMLFragment(String ns)
Creates the XML fragment corresponding to the column specification obtained from the colNumber, colName and colWidth fields.
The general format of the generated fragment is:

<colspec colnum="integer_value" colname="string_value" colwidth="string_value" xmlns="URI"/>

Parameters:
ns - The namespace URI of the table element. It can be null.
Returns:
The XML fragment corresponding to the column specification.

setColWidth

public void setColWidth(WidthRepresentation colWidth)
Set the new WidthRepresentation corresponding to the column specification.

Parameters:
colWidth - The column width to be set.

Oxygen XML Editor 11.2 Author API

© Copyright SyncRO Soft SRL 2002 - 2010.