|
fop 1.0 | ||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.fop.pdf.PDFObject
org.apache.fop.pdf.PDFNumber
This class represents a simple number object. It also contains contains some utility methods for outputting numbers to PDF.
Field Summary |
Fields inherited from class org.apache.fop.pdf.PDFObject |
DATE_FORMAT, log |
Constructor Summary | |
PDFNumber()
|
Method Summary | |
static java.lang.String |
doubleOut(double doubleDown)
Output a double value to a string suitable for PDF (6 decimal digits). |
static java.lang.String |
doubleOut(java.lang.Double doubleDown)
Output a Double value to a string suitable for PDF. |
static java.lang.String |
doubleOut(double doubleDown,
int dec)
Output a double value to a string suitable for PDF. |
java.lang.Number |
getNumber()
Returns the number. |
void |
setNumber(java.lang.Number number)
Sets the number. |
protected java.lang.String |
toPDFString()
This method returns a String representation of the PDF object. The result is normally converted/encoded to a byte array by toPDF(). Only use this method to implement the serialization if the object can be fully represented as text. If the PDF representation of the object contains binary content use toPDF() or output(OutputStream) instead. This applies to any object potentially containing a string object because string object are encrypted and therefore need to be binary. |
Methods inherited from class org.apache.fop.pdf.PDFObject |
contentEquals, encode, encodeBinaryToHexString, encodeString, encodeText, formatDateTime, formatDateTime, formatObject, getDocument, getDocumentSafely, getGeneration, getObjectID, getObjectNumber, getParent, hasObjectNumber, makeReference, output, outputInline, referencePDF, setDocument, setObjectNumber, setParent, toPDF |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public PDFNumber()
Method Detail |
public java.lang.Number getNumber()
public void setNumber(java.lang.Number number)
number
- the numberpublic static java.lang.String doubleOut(java.lang.Double doubleDown)
doubleDown
- the Double value
public static java.lang.String doubleOut(double doubleDown)
doubleDown
- the double value
public static java.lang.String doubleOut(double doubleDown, int dec)
doubleDown
- the Double valuedec
- the number of decimal places to output
protected java.lang.String toPDFString()
toPDFString
in class PDFObject
|
fop 1.0 | ||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |