com.efaxdeveloper.util.inbound
Class Barcode

java.lang.Object
  extended by com.efaxdeveloper.util.inbound.Barcode

public class Barcode
extends java.lang.Object

Barcode

Overview

The Barcode object is used by the client-side process to retrieve barcode information returned by the InboundRequest.getBarcodes() method. The getBarcodes() method returns an ArrayList of Barcode objects.

The following snippet provides an example of how to retrieve the ArrayList of Barcode objects from the InboundRequest application interface:

   // Instantiate a new InboundRequest instance
   InboundRequest req = new InboundRequest();

   ...

   // Establish a null Barcode reference
   Barcode b = null;

   // Establish a new ArrayList object to hold all Barcode objects. Use
   // the getBarcodesByPage(int) method to return all Barcode objects
   // from a specified page.
   ArrayList<Barcode> barcodes = new ArrayList<Barcode>(req.getBarcodes());

   // Establish an iterator Object
   Iterator<Barcode> iterator = barcodes.iterator();

   // Process each Barcode object
   while (iterator.hasNext()) {
     // Retrieve a Barcode object
     b = new Barcode(iterator.next());
     // Retrieve the Barcode object state
     out.println("<br>Key:           " + b.getKey());
     out.println("<br>ReadSequence:  " + b.getReadSequence());
     out.println("<br>ReadDirection: " + b.getReadDirection());
     out.println("<br>Symbology:     " + b.getSymbology());
     out.println("<br>PageNumber:    " + b.getPageNumber());
     out.println("<br>XStartPointA:  " + b.getXStartPointA());
     out.println("<br>XStartPointB:  " + b.getXStartPointB());
     out.println("<br>YStartPointA:  " + b.getYStartPointA());
     out.println("<br>YStartPointB:  " + b.getYStartPointB());
     out.println("<br>XEndPointA:    " + b.getXEndPointA());
     out.println("<br>XEndPointB:    " + b.getXEndPointB());
     out.println("<br>YEndPointA:    " + b.getYEndPointA());
     out.println("<br>YEndPointB:    " + b.getYEndPointB());
     out.println("<br>--------------------------------------------");
   }
   
 

Since:
1.0
Version:
2.0
See Also:
InboundRequest, InboundRequest.getBarcodes(), InboundRequest.getBarcodesByPage(int)

Constructor Summary
Barcode()
          Constructor method for Barcode
Barcode(Barcode barcode)
          Copy constructor method for Barcode
 
Method Summary
 java.lang.String getKey()
          Method to retrieve the Key from the XML POST BarcodeControl container.
 java.lang.String getPageNumber()
          Method to retrieve the PageNumber from the XML POST BarcodeControl container.
 java.lang.String getReadDirection()
          Method to retrieve the ReadDirection from the XML POST BarcodeControl container.
 java.lang.String getReadSequence()
          Method to retrieve the ReadSequence from the XML POST BarcodeControl container.
 java.lang.String getSymbology()
          Method to retrieve the Symbology from the XML POST BarcodeControl container.
 java.lang.String getXEndPointA()
          Method to retrieve the XEndPointA from the XML POST BarcodeControl container.
 java.lang.String getXEndPointB()
          Method to retrieve the XEndPointB from the XML POST BarcodeControl container.
 java.lang.String getXStartPointA()
          Method to retrieve the XStartPointA from the XML POST BarcodeControl container.
 java.lang.String getXStartPointB()
          Method to retrieve the XStartPointB from the XML POST BarcodeControl container.
 java.lang.String getYEndPointA()
          Method to retrieve the YEndPointA from the XML POST BarcodeControl container.
 java.lang.String getYEndPointB()
          Method to retrieve the YEndPointB from the XML POST BarcodeControl container.
 java.lang.String getYStartPointA()
          Method to retrieve the YStartPointA from the XML POST BarcodeControl container.
 java.lang.String getYStartPointB()
          Method to retrieve the YStartPointB from the XML POST BarcodeControl container.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Barcode

public Barcode()
Constructor method for Barcode


Barcode

public Barcode(Barcode barcode)
Copy constructor method for Barcode

Parameters:
barcode - an existing Barcode instance
Method Detail

getKey

public java.lang.String getKey()
Method to retrieve the Key from the XML POST BarcodeControl container.

The key contains the string representation of the barcode as interpreted by eFax Developer™.

Returns:
the interpreted barcode key

getPageNumber

public java.lang.String getPageNumber()
Method to retrieve the PageNumber from the XML POST BarcodeControl container.

The page number represents the physical page location of the barcode.

Returns:
the physical page location of the barcode

getReadDirection

public java.lang.String getReadDirection()
Method to retrieve the ReadDirection from the XML POST BarcodeControl container.

The read direction represents the direction used to interpret the barcode.

The following represents possible returned values:

2-Dimensional
Left/Right
Top/Bottom
Right/Left
Bottom/Top

Returns:
the barcode read direction

getReadSequence

public java.lang.String getReadSequence()
Method to retrieve the ReadSequence from the XML POST BarcodeControl container.

The read sequence represents a per-page sequence number given to each barcode as it is read on a physical page.

Returns:
the read sequence number

getSymbology

public java.lang.String getSymbology()
Method to retrieve the Symbology from the XML POST BarcodeControl container.

The symbology contains the type of barcode symbology used.

Returns:
the barcode symbology

getXEndPointA

public java.lang.String getXEndPointA()
Method to retrieve the XEndPointA from the XML POST BarcodeControl container.

This method will return the X-coordinate (the horizontal) position of one trailing edge corner of a barcode in relation to its orientation on the page.

XEndPointA and YEndPointA together represent the x,y coordinates for one of the trailing edge corners of a barcode.

Based solely on the barcode's orientation and its position on the fax image, the X-coordinate returned by this method will represent a different trailing edge corner as follows:

  • A barcode received horizontally on the page where the barcode's trailing edge is positioned toward the right side of the page will produce a left-to-right read direction and an XEndPointA representing the horizontal position for the upper right corner of the barcode image's trailing edge at the X-axis.
  • A barcode received vertically on the page where the barcode's trailing edge is positioned toward the bottom of the page will produce a top-to-bottom read direction and an XEndPointA representing the horizontal position of the lower left corner of the barcode image's trailing edge at the X-axis.
  • A barcode received vertically on the page where the barcode's trailing edge is positioned toward the top of the page will produce a bottom-to-top read direction and an XEndPointA representing the horizontal position for the upper left corner of the barcode image's trailing edge at the X-axis.
  • A barcode received upside-down on the page, where the barcode's trailing edge is positioned toward the left side of the page, will produce a right-to-left read direction and an XEndPointA representing the horizontal position of the upper left corner of the barcode image's trailing edge at the X-axis.
  • Returns:
    the trailing edge x-axis coordinate for point-A
    See Also:
    getYEndPointA()

    getXEndPointB

    public java.lang.String getXEndPointB()
    Method to retrieve the XEndPointB from the XML POST BarcodeControl container.

    This method will return the X-coordinate (the horizontal) position of the opposing trailing edge corner of a barcode in relation to its orientation on the page.

    XEndPointB and YEndPointB together represent the x,y coordinates for the opposing trailing edge corner of a barcode.

    Based solely on the barcode's orientation and its position on the fax image, the X-coordinate returned by this method will represent a different trailing edge corner as follows:

  • A barcode received horizontally on the page where the barcode's trailing edge is positioned toward the right side of the page will produce a left-to-right read direction and an XEndPointB representing the horizontal position for the lower right corner of the barcode image's trailing edge at the X-axis.
  • A barcode received vertically on the page where the barcode's trailing edge is positioned toward the bottom of the page will produce a top-to-bottom read direction and an XEndPointB representing the horizontal position of the lower right corner of the barcode image's trailing edge at the X-axis.
  • A barcode received vertically on the page where the barcode's trailing edge is positioned toward the top of the page will produce a bottom-to-top read direction and an XEndPointB representing the horizontal position for the upper right corner of the barcode image's trailing edge at the X-axis.
  • A barcode received upside-down on the page, where the barcode's trailing edge is positioned toward the left side of the page, will produce a right-to-left read direction and an XEndPointB representing the horizontal position of the lower left corner of the barcode image's trailing edge at the X-axis.
  • Returns:
    the trailing edge x-axis coordinate for point-B
    See Also:
    getYEndPointB()

    getXStartPointA

    public java.lang.String getXStartPointA()
    Method to retrieve the XStartPointA from the XML POST BarcodeControl container.

    This method will return the X-coordinate (the horizontal) position of one leading edge corner of a barcode in relation to its orientation on the page.

    XStartPointA and YStartPointA together represent the x,y coordinates for one of the leading edge corners of a barcode.

    Based solely on the barcode's orientation and its position on the fax image, the X-coordinate returned by this method will represent a different leading edge corner as follows:

  • A barcode received horizontally on the page where the barcode's leading edge is positioned toward the left side of the page will produce a left-to-right read direction and an XStartPointA representing the horizontal position for the upper left corner of the barcode image's leading edge at the X-axis.
  • A barcode received vertically on the page where the barcode's leading edge is positioned toward the top of the page will produce a top-to-bottom read direction and an XStartPointA representing the horizontal position of the upper left corner of the barcode image's leading edge at the X-axis.
  • A barcode received vertically on the page where the barcode's leading edge is positioned toward the bottom of the page will produce a bottom-to-top read direction and an XStartPointA representing the horizontal position for the lower left corner of the barcode image's leading edge at the X-axis.
  • A barcode received upside-down on the page, where the barcode's leading edge is positioned toward the right side of the page, will produce a right-to-left read direction and an XStartPointA representing the horizontal position of the upper right corner of the barcode image's leading edge at the X-axis.
  • Returns:
    the leading edge x-axis coordinate for point-A
    See Also:
    getYStartPointA()

    getXStartPointB

    public java.lang.String getXStartPointB()
    Method to retrieve the XStartPointB from the XML POST BarcodeControl container.

    This method will return the X-coordinate (the horizontal) position of the opposing leading edge corner of a barcode in relation to its orientation on the page.

    XStartPointB and YStartPointB together represent the x,y coordinates for the opposing leading edge corner of a barcode.

    Based solely on the barcode's orientation and its position on the fax image, the X-coordinate returned by this method will represent a different leading edge corner as follows:

  • A barcode received horizontally on the page where the barcode's leading edge is positioned toward the left side of the page will produce a left-to-right read direction and an XStartPointB representing the horizontal position for the lower left corner of the barcode image's leading edge at the X-axis.
  • A barcode received vertically on the page where the barcode's leading edge is positioned toward the top of the page will produce a top-to-bottom read direction and an XStartPointB representing the horizontal position of the upper right corner of the barcode image's leading edge at the X-axis.
  • A barcode received vertically on the page where the barcode's leading edge is positioned toward the bottom of the page will produce a bottom-to-top read direction and an XStartPointB representing the horizontal position for the lower right corner of the barcode image's leading edge at the X-axis.
  • A barcode received upside-down on the page, where the barcode's leading edge is positioned toward the right side of the page, will produce a right-to-left read direction and an XStartPointB representing the horizontal position of the lower right corner of the barcode image's leading edge at the X-axis.
  • Returns:
    the leading edge x-axis coordinate for point-B
    See Also:
    getYStartPointB()

    getYEndPointA

    public java.lang.String getYEndPointA()
    Method to retrieve the YEndPointA from the XML POST BarcodeControl container.

    This method will return the Y-coordinate (the vertical) position of one trailing edge corner of a barcode in relation to its orientation on the page.

    XEndPointA and YEndPointA together represent the x,y coordinates for one of the trailing edge corners of a barcode.

    Based solely on the barcode's orientation and its position on the fax image, the Y-coordinate returned by this method will represent a different trailing edge corner as follows:

  • A barcode received horizontally on the page where the barcode's trailing edge is positioned toward the right side of the page will produce a left-to-right read direction and a YEndPointA representing the vertical position for the upper right corner of the barcode image's trailing edge at the Y-axis.
  • A barcode received vertically on the page where the barcode's trailing edge is positioned toward the bottom of the page will produce a top-to-bottom read direction and a YEndPointA representing the vertical position of the lower left corner of the barcode image's trailing edge at the Y-axis.
  • A barcode received vertically on the page where the barcode's trailing edge is positioned toward the top of the page will produce a bottom-to-top read direction and a YEndPointA representing the vertical position for the upper left corner of the barcode image's trailing edge at the Y-axis.
  • A barcode received upside-down on the page, where the barcode's trailing edge is positioned toward the left side of the page, will produce a right-to-left read direction and a YEndPointA representing the vertical position of the upper left corner of the barcode image's trailing edge at the Y-axis.
  • Returns:
    the trailing edge y-axis coordinate for point-A
    See Also:
    getXEndPointA()

    getYEndPointB

    public java.lang.String getYEndPointB()
    Method to retrieve the YEndPointB from the XML POST BarcodeControl container.

    This method will return the Y-coordinate (the vertical) position of the opposing trailing edge corner of a barcode in relation to its orientation on the page.

    XEndPointB and YEndPointB together represent the x,y coordinates for the opposing trailing edge corner of a barcode.

    Based solely on the barcode's orientation and its position on the fax image, the Y-coordinate returned by this method will represent a different trailing edge corner as follows:

  • A barcode received horizontally on the page where the barcode's trailing edge is positioned toward the right side of the page will produce a left-to-right read direction and a YEndPointB representing the vertical position for the lower right corner of the barcode image's trailing edge at the Y-axis.
  • A barcode received vertically on the page where the barcode's trailing edge is positioned toward the bottom of the page will produce a top-to-bottom read direction and a YEndPointB representing the vertical position of the lower right corner of the barcode image's trailing edge at the Y-axis.
  • A barcode received vertically on the page where the barcode's trailing edge is positioned toward the top of the page will produce a bottom-to-top read direction and a YEndPointB representing the vertical position for the upper right corner of the barcode image's trailing edge at the Y-axis.
  • A barcode received upside-down on the page, where the barcode's trailing edge is positioned toward the left side of the page, will produce a right-to-left read direction and a YEndPointB representing the vertical position of the lower left corner of the barcode image's trailing edge at the Y-axis.
  • Returns:
    the trailing edge y-axis coordinate for point-B
    See Also:
    getXEndPointB()

    getYStartPointA

    public java.lang.String getYStartPointA()
    Method to retrieve the YStartPointA from the XML POST BarcodeControl container.

    This method will return the Y-coordinate (the vertical) position of one leading edge corner of a barcode in relation to its orientation on the page.

    XStartPointA and YStartPointA together represent the x,y coordinates for one of the leading edge corners of a barcode.

    Based solely on the barcode's orientation and its position on the fax image, the Y-coordinate returned by this method will represent a different leading edge corner as follows:

  • A barcode received horizontally on the page where the barcode's leading edge is positioned toward the left side of the page will produce a left-to-right read direction and a YStartPointA representing the vertical position for the upper left corner of the barcode image's leading edge at the Y-axis.
  • A barcode received vertically on the page where the barcode's leading edge is positioned toward the top of the page will produce a top-to-bottom read direction and a YStartPointA representing the vertical position of the upper left corner of the barcode image's leading edge at the Y-axis.
  • A barcode received vertically on the page where the barcode's leading edge is positioned toward the bottom of the page will produce a bottom-to-top read direction and a YStartPointA representing the vertical position for the lower left corner of the barcode image's leading edge at the Y-axis.
  • A barcode received upside-down on the page where the barcode's leading edge is positioned toward the right side of the page will produce a right-to-left read direction and a YStartPointA representing the vertical position of the upper right corner of the barcode image's leading edge at the Y-axis.
  • Returns:
    the leading edge y-axis coordinate for point-A
    See Also:
    getXStartPointA()

    getYStartPointB

    public java.lang.String getYStartPointB()
    Method to retrieve the YStartPointB from the XML POST BarcodeControl container.

    This method will return the Y-coordinate (the vertical) position of the opposing leading edge corner of a barcode in relation to its orientation on the page.

    XStartPointB and YStartPointB together represent the x,y coordinates for the opposing leading edge corner of a barcode.

    Based solely on the barcode's orientation and its position on the fax image, the Y-coordinate returned by this method will represent a different leading edge corner as follows:

  • A barcode received horizontally on the page where the barcode's leading edge is positioned toward the left side of the page will produce a left-to-right read direction and a YStartPointB representing the vertical position for the lower left corner of the barcode image's leading edge at the Y-axis.
  • A barcode received vertically on the page where the barcode's leading edge is positioned toward the top of the page will produce a top-to-bottom read direction and a YStartPointB representing the vertical position of the upper right corner of the barcode image's leading edge at the Y-axis.
  • A barcode received vertically on the page where the barcode's leading edge is positioned toward the bottom of the page will produce a bottom-to-top read direction and a YStartPointB representing the vertical position for the lower right corner of the barcode image's leading edge at the Y-axis.
  • A barcode received upside-down on the page where the barcode's leading edge is positioned toward the right side of the page will produce a right-to-left read direction and a YStartPointB representing the vertical position of the lower right corner of the barcode image's leading edge at the Y-axis.
  • Returns:
    the leading edge y-axis coordinate for point-B
    See Also:
    getXStartPointB()