public class SimplePageDefinition extends Object implements PageDefinition
Constructor and Description |
---|
SimplePageDefinition(PageFormat format)
Creates a 1x1 page defintion.
|
SimplePageDefinition(PageFormat format,
int x,
int y)
Creates a new SimplePageDefinition object.
|
SimplePageDefinition(PageSize papersize)
Creates a 1x1 page defintion.
|
SimplePageDefinition(PageSize papersize,
int orientation,
Insets margins)
Creates a 1x1 page defintion.
|
Modifier and Type | Method and Description |
---|---|
Object |
clone()
Creates a copy of this page definition.
|
boolean |
equals(Object obj)
Checks whether this page definition object is equal to the given object.
|
float |
getHeight()
Returns the total height of the logical page.
|
int |
getPageCount()
Returns the number of physical pages in this page definition.
|
int |
getPageCountHorizontal()
Returns the number of horizontal pages in this page definition.
|
int |
getPageCountVertical()
Returns the number of vertical pages in this page definition.
|
PageFormat |
getPageFormat() |
PageFormat |
getPageFormat(int pos)
Returns the physical page format for the given position.
|
Rectangle2D |
getPagePosition(int index)
Returns the printable area within the logical page area covered by the physical page at the given position.
|
Rectangle2D[] |
getPagePositions()
Returns all page position known to this page definition.
|
float |
getWidth()
Returns the total width of the logical page.
|
int |
hashCode()
Computes a hashcode for this page definition.
|
String |
toString() |
public SimplePageDefinition(PageFormat format, int x, int y)
format
- the pageformat used as base.x
- the number of physical pages in a row.y
- the number of physical pages in a column.public SimplePageDefinition(PageFormat format)
format
- the pageformat.public SimplePageDefinition(PageSize papersize, int orientation, Insets margins)
public SimplePageDefinition(PageSize papersize)
public int getPageCount()
getPageCount
in interface PageDefinition
public PageFormat getPageFormat(int pos)
getPageFormat
in interface PageDefinition
pos
- the position in the page grid.public Rectangle2D getPagePosition(int index)
getPagePosition
in interface PageDefinition
index
- the positon.public Rectangle2D[] getPagePositions()
getPagePositions
in interface PageDefinition
PageDefinition.getPagePosition(int)
public float getHeight()
getHeight
in interface PageDefinition
public float getWidth()
getWidth
in interface PageDefinition
public Object clone() throws CloneNotSupportedException
clone
in interface PageDefinition
clone
in class Object
CloneNotSupportedException
public boolean equals(Object obj)
public int getPageCountHorizontal()
public int getPageCountVertical()
public int hashCode()
public PageFormat getPageFormat()
Copyright © 2002–2017 Pentaho Corporation. All rights reserved.