|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectjet.report.xls.Worksheet
public class Worksheet
| Field Summary | |
|---|---|
static byte |
X
|
static byte |
Y
|
| Constructor Summary | |
|---|---|
Worksheet(java.lang.String encoding)
Constructs Worksheet Creates an empty Worksheet object and all the empty fields. |
|
| Method Summary | |
|---|---|
void |
addCell(Blank cell)
add a cell to the Worksheet |
void |
addChart(ChartInfo chartInfo,
GlobalWorksheet gws,
java.lang.String encoding)
add a chart to the Worksheet |
java.lang.StringBuffer |
addFormula(Formula formula,
GlobalWorksheet gws)
add a formula to the Worksheet |
void |
addHyperLink(HLink link)
add a Label hyperlink object to this object. |
void |
addHyperLink(HLink link,
GlobalWorksheet gws,
java.lang.String encoding,
BFont font,
boolean defFont)
add a HyperLink in the sheet |
void |
addLabel(BLabel cell,
GlobalWorksheet gws)
add a Label record to the Worksheet |
int |
addMergeRegion(Region region)
add a merged region |
void |
addPicture(GlobalWorksheet gws,
java.lang.String path,
ImgInfo imgInfo)
add a picture to the Worksheet |
void |
addPicture(GlobalWorksheet gws,
java.lang.String path,
ImgInfo imgInfo,
HLink link)
add a picture with hyperlink to the Worksheet |
void |
addRow(Row row)
add a new row in the Worksheet |
void |
addShapes(GlobalWorksheet gws,
ShapesInfo shapesInfo)
add a shape to the Worksheet |
void |
clearFreeze()
unfreeze panes |
void |
converLabel()
conver the Label record to LabelSST record in the Worksheet for share label in the whole worksheet |
short |
getCalcMode()
get the calculation mode |
short |
getColumnWidth(short column)
get the width of a given column in units of 1/20th of a point width (twips?) |
short |
getDefaultRowHeight()
get default row height |
short |
getDefaultRowHeightOptions()
get default row height option |
short |
getDefColWidth()
get default width of the column |
java.lang.String |
getFooter()
get print footer string |
short[] |
getFrozen()
get the freeze postion, if the worksheet is unfreeze the return value will null can get the coordinate x value throught ret[Worksheet.X] and y value through ret[Worksheet.Y] if the ret is not null. |
boolean |
getGridLine()
get whether the window should display gridlines |
boolean |
getGridset()
get whether the user has ever changed the setting of the Gridlines option |
boolean |
getHCenter()
get whether the sheet is to be centered between horizonal margins when printed |
java.lang.String |
getHeader()
get print header string |
double |
getMaxChange()
get the Maximum iteration change |
Region |
getMergeRegionAt(int index)
get a special merged region |
int |
getNumMergeRegions()
get the count of all merged regions |
boolean |
getPageBreak()
get whether window display page break option |
boolean |
getPrintGridlines()
get whether to print gridlines |
boolean |
getPrintHeaders()
get whether to print row and column heading |
boolean |
getRecalc()
get whether to recalculate before saving |
short |
getRefMode()
get the Reference mode |
java.lang.String |
getSheetName()
get the Worksheet name. |
boolean |
getVCenter()
get whether the sheet is to be centered between vertical margins when printed |
short |
getWSBool()
get WSBool option flag |
boolean |
isIteration()
get the Iteration option |
void |
modifyMsoDrawing(int increase)
modify MsoDrawing record |
void |
removeMergeRegion(int index)
remove a merged region |
void |
setCalcMode(short mode)
set the calculation mode |
void |
setColumnWidth(short column,
short width)
set the width for a given column in 1/20th of a character width units if the default column width is not 8, the method is unuseful. |
void |
setDefaultRowHeight(short rowheight)
set default row height |
void |
setDefaultRowHeightOptions(short flags)
set default row height option |
void |
setDefColWidth(short colwidth)
set default width of the column |
void |
setFooter(java.lang.String printPageFooter)
set print footer string and the length of the footer string |
void |
setFreezePane(short x,
short y)
set the freeze Panes |
void |
setGridLine(boolean bool)
set whether the window should display gridlines |
void |
setGridset(boolean bool)
set whether the user has ever changed the setting of the Gridlines option |
void |
setHCenter(boolean center)
set whether the sheet is to be centered between horizonal margins when printed |
void |
setHeader(java.lang.String printPageHeader)
set print header string and the length of the header string |
void |
setIteration(boolean bool)
set the Iteration option |
void |
setMaxChange(double change)
set the Maximum iteration change |
void |
setPageBreak(boolean bool)
set whether window display page break option |
void |
setPrintGridlines(boolean print)
set whether to print gridlines |
void |
setPrintHeaders(boolean print)
set whether to print row and column heading |
void |
setPrintLandscape(boolean isLandscape)
according the flag to set the Print Landscape |
void |
setRecalc(boolean recalc)
set whether to recalculate before saving |
void |
setRefMode(short mode)
set the Reference mode |
void |
setRowHeight(int rowNum,
short height)
set the heigth of special row |
void |
setSheetName(java.lang.String sheetname)
set the Worksheet name |
void |
setVCenter(boolean center)
set whether the sheet is to be centered between vertical margins when printed |
void |
setWSBool(short flag)
set WSBool option flag |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final byte X
public static final byte Y
| Constructor Detail |
|---|
public Worksheet(java.lang.String encoding)
| Method Detail |
|---|
public void setSheetName(java.lang.String sheetname)
sheetname - The name of Worksheet.public void setPrintLandscape(boolean isLandscape)
isLandscape -
public void setFreezePane(short x,
short y)
x - y - format - public void clearFreeze()
public short[] getFrozen()
public java.lang.String getSheetName()
public void addRow(Row row)
row - The Row to be added.
public void addLabel(BLabel cell,
GlobalWorksheet gws)
cell - The Label to be adddedgws - The GloabalWorksheet to be added Sst in it.public void addHyperLink(HLink link)
link -
public void addHyperLink(HLink link,
GlobalWorksheet gws,
java.lang.String encoding,
BFont font,
boolean defFont)
link - The HyperLink to be adddedgws - The GloabalWorksheet of the workbook.defFont - Whether use the default font of the HyperLink to the cell which be added HyperLinkpublic void converLabel()
public void addCell(Blank cell)
cell - The cell to be addded, the cell can be BNumber or BoolErr
public java.lang.StringBuffer addFormula(Formula formula,
GlobalWorksheet gws)
throws java.io.IOException
formula - The formula to be addded.
java.io.IOExceptionpublic void modifyMsoDrawing(int increase)
public void addPicture(GlobalWorksheet gws,
java.lang.String path,
ImgInfo imgInfo)
path - The path of picture to be addded.
public void addPicture(GlobalWorksheet gws,
java.lang.String path,
ImgInfo imgInfo,
HLink link)
path - The path of picture to be addded.
public void addShapes(GlobalWorksheet gws,
ShapesInfo shapesInfo)
type - The type of shapes to be addded.
public void addChart(ChartInfo chartInfo,
GlobalWorksheet gws,
java.lang.String encoding)
throws java.io.IOException
chartInfo - The information of the chart to be addded.
java.io.IOExceptionpublic void setCalcMode(short mode)
mode - The calculation mode. 0 for manual; 1 for automatic;
-1 for automatic, except tablespublic short getCalcMode()
public void setRefMode(short mode)
mode - The Reference mode. 0 for R1C1 mode; 1 for A1 mode.public short getRefMode()
public void setIteration(boolean bool)
bool - Whether Iteration option is on or not. 0 : off; 1 : on.public boolean isIteration()
public void setMaxChange(double change)
change - The maximum iteration changepublic double getMaxChange()
public void setRecalc(boolean recalc)
recalc - whether to recalculate before saving or notpublic boolean getRecalc()
public void setPrintHeaders(boolean print)
print - whether to print row and column heading or notpublic boolean getPrintHeaders()
public void setPrintGridlines(boolean print)
print - whether to print gridlines or notpublic boolean getPrintGridlines()
public void setGridset(boolean bool)
bool - whether has changed or notpublic boolean getGridset()
public void setPageBreak(boolean bool)
bool - whether window display page break or notpublic boolean getPageBreak()
public void setGridLine(boolean bool)
bool - whether the window should display gridlinespublic boolean getGridLine()
public void setDefaultRowHeight(short rowheight)
rowheight - The default row heightpublic short getDefaultRowHeight()
public void setDefaultRowHeightOptions(short flags)
flags - The default row height option
the value of the flags is INCOMPATIBLE, ZERO, EXASC or EXDSC in class DefRowHeight or combine this valuepublic short getDefaultRowHeightOptions()
public void setWSBool(short flag)
flag - The WSBool option flag
the value of the flags is SHOWAUTOBREAKS, DIALOG, APPLYSTYLES, RWSUMSBELOW, COLSUMSRIGHT,
FITTOPAGE, DSPGUTS, AEE, AFE in class WSBool or combine of thempublic short getWSBool()
public void setHeader(java.lang.String printPageHeader)
str - The header stringpublic java.lang.String getHeader()
public void setFooter(java.lang.String printPageFooter)
printPageFooter - The footer stringpublic java.lang.String getFooter()
public void setHCenter(boolean center)
center - whether the sheet is to be centered between horizonal margins when printedpublic boolean getHCenter()
public void setVCenter(boolean center)
center - whether the sheet is to be centered between vertical margins when printedpublic boolean getVCenter()
public void setDefColWidth(short colwidth)
colwidth - The default width of the columnpublic short getDefColWidth()
public short getColumnWidth(short column)
public void setColumnWidth(short column,
short width)
column - - the column numberwidth - (in units of 1/20th of a character width)public int addMergeRegion(Region region)
region - The merged regionpublic void removeMergeRegion(int index)
index - The index of merged region to be removedpublic Region getMergeRegionAt(int index)
index - The index of merged region to be gottenpublic int getNumMergeRegions()
public void setRowHeight(int rowNum,
short height)
rowNum - the row number to setthe - row height to set
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||