| 1 |
package org.freehep.graphicsio.pdf; |
| 2 |
|
| 3 |
import java.io.IOException; |
| 4 |
import java.util.Calendar; |
| 5 |
|
| 6 |
/** |
| 7 |
* Implements the Page Object (see Table 3.17). Inheritable Page Attributes are |
| 8 |
* in PDFPageBase. |
| 9 |
* <p> |
| 10 |
* |
| 11 |
* @author Mark Donszelmann |
| 12 |
* @version $Id: freehep-graphicsio-pdf/src/main/java/org/freehep/graphicsio/pdf/PDFPage.java f493ff6e61b2 2005/12/01 18:46:43 duns $ |
| 13 |
*/ |
| 14 |
public class PDFPage extends PDFPageBase { |
| 15 |
|
| 16 |
PDFPage(PDF pdf, PDFByteWriter writer, PDFObject object, PDFRef parent) |
| 17 |
throws IOException { |
| 18 |
super(pdf, writer, object, parent); |
| 19 |
entry("Type", pdf.name("Page")); |
| 20 |
} |
| 21 |
|
| 22 |
public void setBleedBox(double x, double y, double w, double h) |
| 23 |
throws IOException { |
| 24 |
double[] rectangle = { x, y, w, h }; |
| 25 |
entry("BleedBox", rectangle); |
| 26 |
} |
| 27 |
|
| 28 |
public void setTrimBox(double x, double y, double w, double h) |
| 29 |
throws IOException { |
| 30 |
double[] rectangle = { x, y, w, h }; |
| 31 |
entry("TrimBox", rectangle); |
| 32 |
} |
| 33 |
|
| 34 |
public void setArtBox(double x, double y, double w, double h) |
| 35 |
throws IOException { |
| 36 |
double[] rectangle = { x, y, w, h }; |
| 37 |
entry("ArtBox", rectangle); |
| 38 |
} |
| 39 |
|
| 40 |
public void setContents(String content) throws IOException { |
| 41 |
entry("Contents", pdf.ref(content)); |
| 42 |
} |
| 43 |
|
| 44 |
public void setThumb(String thumb) throws IOException { |
| 45 |
entry("Thumb", pdf.ref(thumb)); |
| 46 |
} |
| 47 |
|
| 48 |
public void setB(String[] b) throws IOException { |
| 49 |
entry("B", pdf.ref(b)); |
| 50 |
} |
| 51 |
|
| 52 |
public void setDur(double dur) throws IOException { |
| 53 |
entry("Dur", dur); |
| 54 |
} |
| 55 |
|
| 56 |
public void setTrans(String trans) throws IOException { |
| 57 |
entry("Trans", pdf.ref(trans)); |
| 58 |
} |
| 59 |
|
| 60 |
public void setAnnots(String[] annots) throws IOException { |
| 61 |
entry("Annots", pdf.ref(annots)); |
| 62 |
} |
| 63 |
|
| 64 |
public void setAA(String aa) throws IOException { |
| 65 |
entry("AA", pdf.ref(aa)); |
| 66 |
} |
| 67 |
|
| 68 |
public void setPieceInfo(String pieceInfo) throws IOException { |
| 69 |
entry("PieceInfo", pdf.ref(pieceInfo)); |
| 70 |
} |
| 71 |
|
| 72 |
public void setLastModified(Calendar date) throws IOException { |
| 73 |
entry("LastModified", date); |
| 74 |
} |
| 75 |
|
| 76 |
public void setStructParents(int structParents) throws IOException { |
| 77 |
entry("StructParents", structParents); |
| 78 |
} |
| 79 |
|
| 80 |
public void setID(String id) throws IOException { |
| 81 |
entry("ID", id); |
| 82 |
} |
| 83 |
|
| 84 |
public void setPZ(double pz) throws IOException { |
| 85 |
entry("PZ", pz); |
| 86 |
} |
| 87 |
|
| 88 |
public void setSeparationInfo(String separationInfo) throws IOException { |
| 89 |
entry("SeparationInfo", pdf.ref(separationInfo)); |
| 90 |
} |
| 91 |
} |