Package com.ironsoftware.ironpdf.stamp
Class ImageStamper
java.lang.Object
com.ironsoftware.ironpdf.stamp.Stamper
com.ironsoftware.ironpdf.stamp.ImageStamper
This allows the user to edit an existing PDF by adding an image. A subclass of
Stamper
. Defines an Image PDF Stamper.
PdfDocument.applyStamp(Stamper, PageSelection)
-
Constructor Summary
ConstructorDescriptionImageStamper
(byte[] imageBytes) Initializes a new instance of theImageStamper
class.ImageStamper
(BufferedImage bufferedImage) Initializes a new instance of theImageStamper
class.ImageStamper
(String imagePath) Initializes a new instance of theImageStamper
class.ImageStamper
(Path imagePath) Initializes a new instance of theImageStamper
class. -
Method Summary
Methods inherited from class com.ironsoftware.ironpdf.stamp.Stamper
getHorizontalAlignment, getHorizontalOffset, getHtml, getHyperlink, getMaxHeight, getMaxWidth, getMinHeight, getMinWidth, getOpacity, getRotation, getScale, getVerticalAlignment, getVerticalOffset, isStampBehindContent, setHorizontalAlignment, setHorizontalOffset, setHtml, setHyperlink, setMaxHeight, setMaxWidth, setMinHeight, setMinWidth, setOpacity, setRotation, setScale, setStampBehindContent, setVerticalAlignment, setVerticalOffset
-
Constructor Details
-
ImageStamper
Initializes a new instance of theImageStamper
class.- Parameters:
imagePath
- The path of the image to be stamped by this stamper- Throws:
IOException
- the io exception
-
ImageStamper
Initializes a new instance of theImageStamper
class.- Parameters:
imagePath
- The uri of the image to be stamped by this stamper- Throws:
IOException
- the io exception
-
ImageStamper
public ImageStamper(byte[] imageBytes) Initializes a new instance of theImageStamper
class.- Parameters:
imageBytes
- The uri of the image to be stamped by this stamper
-
ImageStamper
Initializes a new instance of theImageStamper
class.- Parameters:
bufferedImage
- TheBufferedImage
object- Throws:
IOException
- the io exception
-
-
Method Details
-
getImageData
public final byte[] getImageData()Gets image data (byte[]).- Returns:
- the image byte[]
-