org.jxls.common.RowData Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of jxls Show documentation
Show all versions of jxls Show documentation
Small library for Excel generation based on XLS templates
package org.jxls.common;
import org.jxls.transform.Transformer;
import java.util.ArrayList;
import java.util.Iterator;
import java.util.List;
/**
* Represents an excel row data holder
* @author Leonid Vysochyn
*/
public class RowData implements Iterable {
protected int height;
private List cellDataList = new ArrayList();
private Transformer transformer;
public Transformer getTransformer() {
return transformer;
}
public void setTransformer(Transformer transformer) {
this.transformer = transformer;
}
public int getNumberOfCells(){
return cellDataList.size();
}
public CellData getCellData(int col){
if( col < cellDataList.size() ) return cellDataList.get(col);
else return null;
}
protected void addCellData(CellData cellData){
cellDataList.add(cellData);
}
public int getHeight() {
return height;
}
public Iterator iterator() {
return cellDataList.iterator();
}
}