public final class ImageStamp extends Stamp
Reresents graphic stamp.
Constructor and Description |
---|
ImageStamp(InputStream image)
Initializes a new instance of the
ImageStamp class. |
ImageStamp(String fileName)
Creates image stamp by image in the specified file.
|
Modifier and Type | Method and Description |
---|---|
void |
close()
Closes this instance
|
double |
getHeight()
Gets image height.
|
InputStream |
getImage()
Gets image stream used for stamping.
|
int |
getQuality()
Gets quality of image stamp in percent.
|
double |
getWidth()
Gets image width.
|
void |
put(Page page)
Adds graphic stamp on the page.
|
void |
setHeight(double value)
Sets image height.
|
void |
setQuality(int value)
Sets quality of image stamp in percent.
|
void |
setWidth(double value)
Sets image width.
|
getBackground, getBottomMargin, getHorizontalAlignment, getLeftMargin, getOpacity, getOutlineOpacity, getOutlineWidth, getRightMargin, getRotate, getRotateAngle, getStampId, getTopMargin, getVerticalAlignment, getXIndent, getYIndent, getZoom, getZoomX, getZoomY, setBackground, setBottomMargin, setHorizontalAlignment, setLeftMargin, setOpacity, setOutlineOpacity, setOutlineWidth, setRightMargin, setRotate, setRotateAngle, setStampId, setTopMargin, setVerticalAlignment, setXIndent, setYIndent, setZoom, setZoomX, setZoomY
public ImageStamp(InputStream image)
Initializes a new instance of the ImageStamp
class.
image
- Stream which contains image data.public ImageStamp(String fileName)
Creates image stamp by image in the specified file.
fileName
- Name of the file which contains image.public InputStream getImage()
Gets image stream used for stamping.
public double getWidth()
Gets image width. Setting this property allos to scal image horizontally.
public void setWidth(double value)
Sets image width. Setting this property allos to scal image horizontally.
public double getHeight()
Gets image height. Setting this image allows to scale image vertically.
public void setHeight(double value)
Sets image height. Setting this image allows to scale image vertically.
public int getQuality()
Gets quality of image stamp in percent. Valid values are 0..100%.
public void setQuality(int value)
Sets quality of image stamp in percent. Valid values are 0..100%.
value
- int valuepublic void put(Page page)
Adds graphic stamp on the page.
public void close()