Class PolyLineAnnotation
- java.lang.Object
-
- com.pdf_tools.fourheights.pdftoolbox.internal.NativeBase
-
- com.pdf_tools.fourheights.pdftoolbox.internal.NativeObject
-
- com.pdf_tools.fourheights.pdftoolbox.pdf.annotations.Annotation
-
- com.pdf_tools.fourheights.pdftoolbox.pdf.annotations.MarkupAnnotation
-
- com.pdf_tools.fourheights.pdftoolbox.pdf.annotations.DrawingAnnotation
-
- com.pdf_tools.fourheights.pdftoolbox.pdf.annotations.PolyLineAnnotation
-
public class PolyLineAnnotation extends DrawingAnnotation
A drawing annotation that consists of several line segments
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static PolyLineAnnotation
create(Document targetDocument, Path path, Stroke stroke)
Create a poly-line annotation.LineEnding
getEndStyle()
The ending point's style (Getter)Paint
getLineEndingFill()
The line ending filling paint for both start and end (Getter)LineEnding
getStartStyle()
The starting point's style (Getter)-
Methods inherited from class com.pdf_tools.fourheights.pdftoolbox.pdf.annotations.DrawingAnnotation
getPaint, getPopup
-
Methods inherited from class com.pdf_tools.fourheights.pdftoolbox.pdf.annotations.MarkupAnnotation
getInfo, getLocked, getReplies
-
Methods inherited from class com.pdf_tools.fourheights.pdftoolbox.pdf.annotations.Annotation
copy, getBoundingBox, getHidden, getId, getNoPrint, getNoRotate, getNoZoom
-
Methods inherited from class com.pdf_tools.fourheights.pdftoolbox.internal.NativeObject
equals, hashCode
-
-
-
-
Method Detail
-
create
public static PolyLineAnnotation create(Document targetDocument, Path path, Stroke stroke) throws ConformanceException, UnsupportedFeatureException
Create a poly-line annotation.
The returned poly-line annotation is not yet part of any page. It can be added to a page's list of annotations.- Parameters:
targetDocument
- The output document with which the returned object is associated.path
- The path of the poly line.stroke
- The stroking parameters used for stroking the poly-line. The stroking paint is used as the annotation's main paint.- Returns:
- The newly created poly-line annotation.
- Throws:
java.lang.IllegalArgumentException
- if thetargetDocument
has already been closedjava.lang.IllegalArgumentException
- if thetargetDocument
is read-onlyjava.lang.IllegalArgumentException
- if thetargetDocument
's conformance is not PDF 2.0 and thepath
argument contains curve-to operationsjava.lang.IllegalArgumentException
- if thepath
argument contains close-subpath or rectangle operationsUnsupportedFeatureException
- if thetargetDocument
's conformance is PDF 2.0 and thepath
argument contains curve-to operationsjava.lang.IllegalArgumentException
- if thepath
argument has not been constructed with apdftoolbox.pdf.content.PathGenerator
java.lang.IllegalArgumentException
- if thestroke
argument is not associated with thetargetDocument
java.lang.IllegalArgumentException
- if thestroke
'spdftoolbox.pdf.content.Stroke.getPaint
has apdftoolbox.pdf.content.Paint.getColorSpace
other than a device color spacejava.lang.IllegalArgumentException
- if thestroke
'spdftoolbox.pdf.content.Stroke.getPaint
has a non-null
pdftoolbox.pdf.content.Paint.getTransparency
withpdftoolbox.pdf.content.Transparency.getBlendMode
other thanpdftoolbox.pdf.content.BlendMode.NORMAL
java.lang.IllegalArgumentException
- if thestroke
argument'spdftoolbox.pdf.content.Stroke.getLineCapStyle
is other thanpdftoolbox.pdf.content.LineCapStyle.BUTT
java.lang.IllegalArgumentException
- if thestroke
argument'spdftoolbox.pdf.content.Stroke.getLineJoinStyle
is other thanpdftoolbox.pdf.content.LineJoinStyle.MITER
java.lang.IllegalArgumentException
- if thestroke
argument'spdftoolbox.pdf.content.Stroke.getMiterLimit
is other than 10java.lang.IllegalArgumentException
- if thestroke
argument'spdftoolbox.pdf.content.Stroke.getDashPhase
is other than 0ConformanceException
- if the explicitly requested PDF conformance is smaller than PDF 1.5java.lang.IllegalArgumentException
- iftargetDocument
isnull
java.lang.IllegalArgumentException
- ifpath
isnull
java.lang.IllegalArgumentException
- ifstroke
isnull
-
getStartStyle
public LineEnding getStartStyle()
The starting point's style (Getter)
- Throws:
java.lang.IllegalStateException
- if the object has already been closed
-
getEndStyle
public LineEnding getEndStyle()
The ending point's style (Getter)
- Throws:
java.lang.IllegalStateException
- if the object has already been closed
-
getLineEndingFill
public Paint getLineEndingFill()
The line ending filling paint for both start and end (Getter)
- Throws:
java.lang.IllegalStateException
- if the object has already been closed
-
-