Package loci.poi.hssf.usermodel
Class HSSFFooter
- java.lang.Object
-
- loci.poi.hssf.usermodel.HSSFFooter
-
public class HSSFFooter extends java.lang.ObjectClass to read and manipulate the footer.The footer works by having a left, center, and right side. The total cannot be more that 255 bytes long. One uses this class by getting the HSSFFooter from HSSFSheet and then getting or setting the left, center, and right side. For special things (such as page numbers and date), one can use a the methods that return the characters used to represent these. One can also change the fonts by using similar methods.
- Author:
- Shawn Laubach (slaubach at apache dot org)
-
-
Constructor Summary
Constructors Modifier Constructor Description protectedHSSFFooter(FooterRecord footerRecord)Constructor.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static java.lang.Stringdate()Returns the string representing the current datestatic java.lang.StringendDoubleUnderline()Returns the string representing the end double underlinestatic java.lang.StringendUnderline()Returns the string representing the end underlinestatic java.lang.Stringfile()Returns the string representing the current file namestatic java.lang.Stringfont(java.lang.String font, java.lang.String style)Returns the string that represents the change in font.static java.lang.StringfontSize(short size)Returns the string that represents the change in font size.java.lang.StringgetCenter()Get the center of the footer.java.lang.StringgetLeft()Get the left side of the footer.java.lang.StringgetRight()Get the right side of the footer.static java.lang.StringnumPages()Returns the string representing the number of pages.static java.lang.Stringpage()Returns the string representing the current page numbervoidsetCenter(java.lang.String newCenter)Sets the center string.voidsetLeft(java.lang.String newLeft)Sets the left string.voidsetRight(java.lang.String newRight)Sets the right string.static java.lang.StringstartDoubleUnderline()Returns the string representing the start double underlinestatic java.lang.StringstartUnderline()Returns the string representing the start underlinestatic java.lang.Stringtab()Returns the string representing the current tab (sheet) namestatic java.lang.Stringtime()Returns the string representing the current time
-
-
-
Constructor Detail
-
HSSFFooter
protected HSSFFooter(FooterRecord footerRecord)
Constructor. Creates a new footer interface from a footer record- Parameters:
footerRecord- Footer record to create the footer with
-
-
Method Detail
-
getLeft
public java.lang.String getLeft()
Get the left side of the footer.- Returns:
- The string representing the left side.
-
setLeft
public void setLeft(java.lang.String newLeft)
Sets the left string.- Parameters:
newLeft- The string to set as the left side.
-
getCenter
public java.lang.String getCenter()
Get the center of the footer.- Returns:
- The string representing the center.
-
setCenter
public void setCenter(java.lang.String newCenter)
Sets the center string.- Parameters:
newCenter- The string to set as the center.
-
getRight
public java.lang.String getRight()
Get the right side of the footer.- Returns:
- The string representing the right side.
-
setRight
public void setRight(java.lang.String newRight)
Sets the right string.- Parameters:
newRight- The string to set as the right side.
-
fontSize
public static java.lang.String fontSize(short size)
Returns the string that represents the change in font size.- Parameters:
size- the new font size- Returns:
- The special string to represent a new font size
-
font
public static java.lang.String font(java.lang.String font, java.lang.String style)Returns the string that represents the change in font.- Parameters:
font- the new fontstyle- the fonts style- Returns:
- The special string to represent a new font size
-
page
public static java.lang.String page()
Returns the string representing the current page number- Returns:
- The special string for page number
-
numPages
public static java.lang.String numPages()
Returns the string representing the number of pages.- Returns:
- The special string for the number of pages
-
date
public static java.lang.String date()
Returns the string representing the current date- Returns:
- The special string for the date
-
time
public static java.lang.String time()
Returns the string representing the current time- Returns:
- The special string for the time
-
file
public static java.lang.String file()
Returns the string representing the current file name- Returns:
- The special string for the file name
-
tab
public static java.lang.String tab()
Returns the string representing the current tab (sheet) name- Returns:
- The special string for tab name
-
startUnderline
public static java.lang.String startUnderline()
Returns the string representing the start underline- Returns:
- The special string for start underline
-
endUnderline
public static java.lang.String endUnderline()
Returns the string representing the end underline- Returns:
- The special string for end underline
-
startDoubleUnderline
public static java.lang.String startDoubleUnderline()
Returns the string representing the start double underline- Returns:
- The special string for start double underline
-
endDoubleUnderline
public static java.lang.String endDoubleUnderline()
Returns the string representing the end double underline- Returns:
- The special string for end double underline
-
-