com.pdfjet
Class BarCode2D

java.lang.Object
  extended by com.pdfjet.BarCode2D
All Implemented Interfaces:
Drawable

public class BarCode2D
extends java.lang.Object
implements Drawable

Used to create PDF417 2D barcodes. Please see Example_12.


Constructor Summary
BarCode2D(java.lang.String str)
          Constructor for 2D barcodes.
 
Method Summary
 float[] drawOn(Page page)
          Draws this barcode on the specified page.
 void setLocation(float x, float y)
          Sets the location of this barcode on the page.
 void setPosition(double x, double y)
          Sets the position of this barcode on the page.
 void setPosition(float x, float y)
          Sets the position of this barcode on the page.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

BarCode2D

public BarCode2D(java.lang.String str)
Constructor for 2D barcodes.

Parameters:
str - the specified string.
Method Detail

setPosition

public void setPosition(double x,
                        double y)
Sets the position of this barcode on the page.

Parameters:
x - the x coordinate of the top left corner of the barcode.
y - the y coordinate of the top left corner of the barcode.

setPosition

public void setPosition(float x,
                        float y)
Sets the position of this barcode on the page.

Parameters:
x - the x coordinate of the top left corner of the barcode.
y - the y coordinate of the top left corner of the barcode.

setLocation

public void setLocation(float x,
                        float y)
Sets the location of this barcode on the page.

Parameters:
x - the x coordinate of the top left corner of the barcode.
y - the y coordinate of the top left corner of the barcode.

drawOn

public float[] drawOn(Page page)
               throws java.lang.Exception
Draws this barcode on the specified page.

Specified by:
drawOn in interface Drawable
Parameters:
page - the page to draw this barcode on.
Returns:
x and y coordinates of the bottom right corner of this component.
Throws:
java.lang.Exception