com.java4less.rdatamatrix
Class RDataMatrixFacade

java.lang.Object
  extended by com.java4less.rdatamatrix.RDataMatrixFacade
All Implemented Interfaces:
IBarcodeGenerator

public class RDataMatrixFacade
extends java.lang.Object
implements IBarcodeGenerator

helper class for creating barcodes with just one method. Used by webservices and plugins.


Constructor Summary
RDataMatrixFacade()
           
RDataMatrixFacade(java.lang.String code, byte[] codeBinary, boolean processTilde, int moduleSize, int margin, java.lang.String encoding, java.lang.String format, java.util.Properties properties)
          generate the barcode object and return image
 
Method Summary
 void createBarcode(java.util.Properties properties)
          create barcode image from properties file
 void createBarcode(java.lang.String code, byte[] codeBinary, boolean processTilde, int moduleSize, int margin, java.lang.String encoding, java.lang.String format, java.util.Properties properties)
          generate the barcode object
 java.awt.Image createBarcodeImage(java.lang.String code, byte[] codeBinary, boolean processTilde, int moduleSize, int margin, java.lang.String encoding, java.lang.String format, java.util.Properties properties)
          generate the barcode object and return image
 java.awt.Image createImage()
          create image for the generated barcode
 RDataMatrix getBarcode()
          return barcode object
 void paintBarcode(java.awt.Graphics g)
          paint barcode on external graphics
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

RDataMatrixFacade

public RDataMatrixFacade()

RDataMatrixFacade

public RDataMatrixFacade(java.lang.String code,
                         byte[] codeBinary,
                         boolean processTilde,
                         int moduleSize,
                         int margin,
                         java.lang.String encoding,
                         java.lang.String format,
                         java.util.Properties properties)
generate the barcode object and return image

Parameters:
code - value to be encoded
codeBinary - binary value to be encoded
processTilde - See documentation http://www.java4less.com/barcodes/barcodes.php?info=guide
moduleSize - size (pixels) of the modules (dots) of the matrix.
margin - number of pixels
encoding - The default is ASCII. Posible values are ASCII, C40, TEXT, BASE256 and AUTO.
format - If empty the format will be selected automatically, if not you can specify the format (e.g. C24X24).
properties - currently ignored, use null
Method Detail

getBarcode

public RDataMatrix getBarcode()
return barcode object

Returns:

createBarcodeImage

public java.awt.Image createBarcodeImage(java.lang.String code,
                                         byte[] codeBinary,
                                         boolean processTilde,
                                         int moduleSize,
                                         int margin,
                                         java.lang.String encoding,
                                         java.lang.String format,
                                         java.util.Properties properties)
generate the barcode object and return image

Parameters:
code - value to be encoded
codeBinary - binary value to be encoded
processTilde - See documentation http://www.java4less.com/barcodes/barcodes.php?info=guide
moduleSize - size (pixels) of the modules (dots) of the matrix.
margin - number of pixels
encoding - The default is ASCII. Posible values are ASCII, C40, TEXT, BASE256 and AUTO.
format - If empty the format will be selected automatically, if not you can specify the format (e.g. C24X24).
properties - currently ignored, use null

createBarcode

public void createBarcode(java.lang.String code,
                          byte[] codeBinary,
                          boolean processTilde,
                          int moduleSize,
                          int margin,
                          java.lang.String encoding,
                          java.lang.String format,
                          java.util.Properties properties)
generate the barcode object

Parameters:
code -
processTilde -
moduleSize -
margin -
encoding -
format -

createImage

public java.awt.Image createImage()
create image for the generated barcode

Specified by:
createImage in interface IBarcodeGenerator
Returns:

createBarcode

public void createBarcode(java.util.Properties properties)
create barcode image from properties file

Specified by:
createBarcode in interface IBarcodeGenerator

paintBarcode

public void paintBarcode(java.awt.Graphics g)
Description copied from interface: IBarcodeGenerator
paint barcode on external graphics

Specified by:
paintBarcode in interface IBarcodeGenerator