Oxygen XML Editor 11.2 Author API

ro.sync.ecss.extensions.commons.table.spansupport
Class TEITableCellSpanProvider

java.lang.Object
  extended by ro.sync.ecss.extensions.commons.table.spansupport.TEITableCellSpanProvider
All Implemented Interfaces:
AuthorTableCellSpanProvider, Extension

public class TEITableCellSpanProvider
extends Object
implements AuthorTableCellSpanProvider

Provides cell spanning information about TEI tables.


Constructor Summary
TEITableCellSpanProvider()
           
 
Method Summary
 Integer getColSpan(AuthorElement cellElement)
          Compute the number of columns the cell spans across by looking at the 'cols' attribute.
 String getDescription()
           
 Integer getRowSpan(AuthorElement cellElement)
          Compute the number of rows the cell spans across by looking at the 'rows' attribute.
 boolean hasColumnSpecifications(AuthorElement tableElement)
          This method tells if the table contains column specifications.
 void init(AuthorElement tableElement)
          Nothing to do.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TEITableCellSpanProvider

public TEITableCellSpanProvider()
Method Detail

getColSpan

public Integer getColSpan(AuthorElement cellElement)
Compute the number of columns the cell spans across by looking at the 'cols' attribute.

Specified by:
getColSpan in interface AuthorTableCellSpanProvider
Parameters:
cellElement - The node that represents a table cell in CSS.
Returns:
The number of columns this cell spans across (the minimum returned value must be 1) or null if not specified.
See Also:
AuthorTableCellSpanProvider.getColSpan(AuthorElement)

getRowSpan

public Integer getRowSpan(AuthorElement cellElement)
Compute the number of rows the cell spans across by looking at the 'rows' attribute.

Specified by:
getRowSpan in interface AuthorTableCellSpanProvider
Parameters:
cellElement - The AuthorElement that represents a table cell in CSS.
Returns:
The number of rows this cell spans across (the minimum returned value must be 1) or null if not specified.
See Also:
AuthorTableCellSpanProvider.getRowSpan(AuthorElement)

init

public void init(AuthorElement tableElement)
Nothing to do. Cell spanning information in a TEI table is given through the attributes of the cell element.

Specified by:
init in interface AuthorTableCellSpanProvider
Parameters:
tableElement - The AuthorElement representing a table (it has the CSS display property set on 'table').
See Also:
AuthorTableCellSpanProvider.init(AuthorElement)

getDescription

public String getDescription()
Specified by:
getDescription in interface Extension
Returns:
The description of the extension.
See Also:
Extension.getDescription()

hasColumnSpecifications

public boolean hasColumnSpecifications(AuthorElement tableElement)
Description copied from interface: AuthorTableCellSpanProvider
This method tells if the table contains column specifications. For example the CALS table model requires colspec elements to be present.

Specified by:
hasColumnSpecifications in interface AuthorTableCellSpanProvider
Parameters:
tableElement - The AuthorElement that is rendered as a table.
Returns:
true if some column specification info is present or if the table doesn't require any column specification info.
See Also:
AuthorTableCellSpanProvider.hasColumnSpecifications(ro.sync.ecss.extensions.api.node.AuthorElement)

Oxygen XML Editor 11.2 Author API

© Copyright SyncRO Soft SRL 2002 - 2010.