package net.sf.jasperreports.crosstabs.fill;

import net.sf.jasperreports.crosstabs.JRCellContents;
import net.sf.jasperreports.crosstabs.JRCrosstabCell;
import net.sf.jasperreports.engine.fill.JRFillCellContents;
import net.sf.jasperreports.engine.fill.JRFillObjectFactory;

public class JRFillCrosstabCell implements JRCrosstabCell {
  private JRCrosstabCell parentCell;
  
  protected JRFillCellContents contents;
  
  public JRFillCrosstabCell(JRCrosstabCell cell, JRFillObjectFactory factory) {
    factory.put(cell, this);
    this.parentCell = cell;
    this.contents = factory.getCell(cell.getContents());
  }
  
  public String getRowTotalGroup() {
    return this.parentCell.getRowTotalGroup();
  }
  
  public String getColumnTotalGroup() {
    return this.parentCell.getColumnTotalGroup();
  }
  
  public JRCellContents getContents() {
    return (JRCellContents)this.contents;
  }
  
  public JRFillCellContents getFillContents() {
    return this.contents;
  }
  
  public Integer getWidth() {
    return this.parentCell.getWidth();
  }
  
  public Integer getHeight() {
    return this.parentCell.getHeight();
  }
  
  public Object clone() {
    return null;
  }
}
