Top Description Constructors Methods
org.apache.pdfbox.examples.util

public Class PrintImageLocations

extends PDFStreamEngine
Class Inheritance
Imports
org.apache.pdfbox.cos.COSBase, .COSName, org.apache.pdfbox.pdmodel.PDDocument, .PDPage, org.apache.pdfbox.pdmodel.graphics.PDXObject, org.apache.pdfbox.pdmodel.graphics.form.PDFormXObject, org.apache.pdfbox.pdmodel.graphics.image.PDImageXObject, org.apache.pdfbox.util.Matrix, org.apache.pdfbox.contentstream.operator.DrawObject, .Operator, .OperatorName, org.apache.pdfbox.Loader, org.apache.pdfbox.contentstream.PDFStreamEngine, java.io.File, .IOException, java.util.List, org.apache.pdfbox.contentstream.operator.state.Concatenate, .Restore, .Save, .SetGraphicsStateParameters, .SetMatrix

This is an example on how to get the x/y coordinates of image locations.
Author
Ben Litchfield

Constructor Summary

AccessConstructor and Description
public
PrintImageLocations()

Default constructor.

Method Summary

Modifier and TypeMethod and Description
public static void
main(String[]
The command line arguments.
args
)

This will print the documents data.

protected void
processOperator(Operator
The operation to perform.
operator
,
List<COSBase>
The list of arguments.
operands
)

Overrides org.apache.pdfbox.contentstream.PDFStreamEngine.processOperator.

This is used to handle an operation.

private static void
usage()

This will print the usage for this document.

Inherited from org.apache.pdfbox.contentstream.PDFStreamEngine:
addOperatorapplyTextAdjustmentbeginMarkedContentSequencebeginTextdecreaseLevelendMarkedContentSequenceendTextgetAppearancegetCurrentPagegetGraphicsStackSizegetGraphicsStategetInitialMatrixgetLevelgetResourcesgetTextLineMatrixgetTextMatrixincreaseLevelisShouldProcessColorOperatorsoperatorExceptionprocessAnnotationprocessChildStreamprocessOperatorprocessPageprocessSoftMaskprocessTilingPatternprocessTilingPatternprocessTransparencyGroupprocessType3StreamrestoreGraphicsStackrestoreGraphicsStatesaveGraphicsStacksaveGraphicsStatesetLineDashPatternsetTextLineMatrixsetTextMatrixshowAnnotationshowFontGlyphshowFormshowGlyphshowTextshowTextStringshowTextStringsshowTransparencyGroupshowType3GlyphtransformedPointtransformWidthunsupportedOperator

Constructor Detail

PrintImageLocationsback to summary
public PrintImageLocations() throws IOException

Default constructor.

Exceptions
IOException:
If there is an error loading text stripper properties.

Method Detail

mainback to summary
public static void main(String[] args) throws IOException

This will print the documents data.

Parameters
args:String[]

The command line arguments.

Exceptions
IOException:
If there is an error parsing the document.
processOperatorback to summary
protected void processOperator(Operator operator, List<COSBase> operands) throws IOException

Overrides org.apache.pdfbox.contentstream.PDFStreamEngine.processOperator.

This is used to handle an operation.

Parameters
operator:Operator

The operation to perform.

operands:List<COSBase>

The list of arguments.

Annotations
@Override
Exceptions
IOException:
If there is an error processing the operation.
usageback to summary
private static void usage()

This will print the usage for this document.