Class DefaultPdfTextLocation
- java.lang.Object
-
- com.itextpdf.kernel.pdf.canvas.parser.listener.DefaultPdfTextLocation
-
- All Implemented Interfaces:
IPdfTextLocation
public class DefaultPdfTextLocation extends java.lang.Object implements IPdfTextLocation
This class acts as a default implementation of IPdfTextLocation
-
-
Constructor Summary
Constructors Constructor Description DefaultPdfTextLocation(Rectangle rect, java.lang.String text)Creates new pdf text location.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description RectanglegetRectangle()java.lang.StringgetText()DefaultPdfTextLocationsetRectangle(Rectangle rectangle)Sets text rectangle (occupied area) for this pdf text location.DefaultPdfTextLocationsetText(java.lang.String text)Sets text for this pdf text location.
-
-
-
Field Detail
-
rectangle
private Rectangle rectangle
-
text
private java.lang.String text
-
-
Constructor Detail
-
DefaultPdfTextLocation
public DefaultPdfTextLocation(Rectangle rect, java.lang.String text)
Creates new pdf text location.- Parameters:
rect- text rectangle on pdf canvastext- actual text on designated area of canvas
-
-
Method Detail
-
getRectangle
public Rectangle getRectangle()
- Specified by:
getRectanglein interfaceIPdfTextLocation- Returns:
- the visual
Rectanglein which the text is located
-
setRectangle
public DefaultPdfTextLocation setRectangle(Rectangle rectangle)
Sets text rectangle (occupied area) for this pdf text location.- Parameters:
rectangle- new text rectangle- Returns:
- this
DefaultPdfTextLocationinstance
-
getText
public java.lang.String getText()
- Specified by:
getTextin interfaceIPdfTextLocation- Returns:
- the text
-
setText
public DefaultPdfTextLocation setText(java.lang.String text)
Sets text for this pdf text location.- Parameters:
text- new text- Returns:
- this
DefaultPdfTextLocationinstance
-
-