Class RotatePrint

All Implemented Interfaces:
Runnable

public class RotatePrint extends OutputRequest
Output request executor for POSPrinter method RotatePrint.
  • Field Details

    • SidewaysCommands

      public final List<OutputRequest> SidewaysCommands
      List holds all outstanding output requests.
  • Constructor Details

    • RotatePrint

      public RotatePrint(JposCommonProperties props, int station, int rotation)
      Constructor. Stores given parameters for later use.
      Parameters:
      props - Property set of device service.
      station - The printer station to be used. May be either S_RECEIPT or S_SLIP.
      rotation - Direction of rotation. One of RP_RIGHT90, RP_LEFT90 or RP_ROTATE180, optionally ORed with one of RP_BARCODE or RP_BITMAP, or RP_NORMAL.
  • Method Details

    • getStation

      public int getStation()
      POSPrinter method RotatePrint parameter station, see UPOS specification.
      Returns:
      RotatePrint parameter station.
    • getRotation

      public int getRotation()
      POSPrinter method RotatePrint parameter rotation, see UPOS specification.
      Returns:
      RotatePrint parameter rotation.
    • addMethod

      public void addMethod(OutputRequest request) throws jpos.JposException
      Adds an output request to the request queue.
      Parameters:
      request - Request to be enqueued.
      Throws:
      jpos.JposException - if request is null (specifying synchronous method implementation).
    • invoke

      public void invoke() throws jpos.JposException
      Description copied from class: JposOutputRequest
      Invokes the command. Must be implemented in derived class. Calls finished() to wake up potentially waiting threads.
      Overrides:
      invoke in class JposOutputRequest
      Throws:
      jpos.JposException - JposException thrown by the command to be executed.