com.ibm.eNetwork.beans.HOD
Class MacroActionPrintExtract

java.lang.Object
  |
  +--com.ibm.eNetwork.beans.HOD.MacroAction
        |
        +--com.ibm.eNetwork.beans.HOD.MacroActionPrintExtract
All Implemented Interfaces:
com.ibm.eNetwork.HOD.common.HODConstants, com.ibm.eNetwork.beans.HOD.macro.parser.MacroParsable, java.io.Serializable

public class MacroActionPrintExtract
extends MacroAction

This class represents a printer extract action associated with a playing macro script. Using a reference to the target screen presentation space, the macro printer driver renders the screen to the current printer job. Optionally the rendering may be limited to a subset rectangle of the screen. It does this via a MacroPrinterDriver.writePrinter() call.

This action has this XML tag: <print action="extract" .... />

A MacroActionPrintExtract is associated with a MacroScreen to represent a point in the play sequence of the macro script when the rendering to the printer job should be done. Multiple PrintExtract actions may be done during the macro play in association with one of more MacroScreen objects.

More than one MacroActionPrintExtract may be issued during the playing of a macro script. It is the programmer responsibility to be sure the flow logic of the playing macro produces the desired printer job(s).

See Also:
Macro.getMacroPrinterDriver(), MacroPrinterDriver.writePrinter(ECLPS), MacroPrinterDriver.writePrinter(ECLPS, int, int, int, int), MacroActionPrintStart, MacroActionPrintEnd, Serialized Form

Fields inherited from interface com.ibm.eNetwork.HOD.common.HODConstants
DEFAULT_WIN_FONT, HOD_ICON_EVENT, HOD_MSG_FILE, HOD_RAS_COMPID_ADVMACRO, HOD_RAS_COMPID_ASSOC_PRT, HOD_RAS_COMPID_BLINKREMAP, HOD_RAS_COMPID_CODEPAGE, HOD_RAS_COMPID_COLORREMAP, HOD_RAS_COMPID_CONFIG, HOD_RAS_COMPID_FILETRANSFER, HOD_RAS_COMPID_FTP_SCREEN, HOD_RAS_COMPID_FTP_SESSION, HOD_RAS_COMPID_FTP_TERMINAL, HOD_RAS_COMPID_FUDOMA, HOD_RAS_COMPID_HOD_API, HOD_RAS_COMPID_IMPEXP, HOD_RAS_COMPID_JNILOAD, HOD_RAS_COMPID_KEYPAD, HOD_RAS_COMPID_KEYREMAP, HOD_RAS_COMPID_MACRO, HOD_RAS_COMPID_MACROMANGR, HOD_RAS_COMPID_PRT_TERMINAL, HOD_RAS_COMPID_SCREEN, HOD_RAS_COMPID_SESSION, HOD_RAS_COMPID_SESSION_MGR, HOD_RAS_COMPID_SLP, HOD_RAS_COMPID_TERMINAL, HOD_RAS_COMPID_ZIPPRINT, HOD_RAS_FUNC_NAME, HOD_START_UP, HOD_TRANSFER_FILE_INFO, MOUSE_DOUBLE_CLICK_THRESHOLD, XFER_ASCII_GET_OPTIONS, XFER_ASCII_GET_OPTIONS_DEFAULT, XFER_ASCII_PUT_OPTIONS, XFER_ASCII_PUT_OPTIONS_DEFAULT, XFER_BINARY_GET_OPTIONS, XFER_BINARY_GET_OPTIONS_DEFAULT, XFER_BINARY_PUT_OPTIONS, XFER_BINARY_PUT_OPTIONS_DEFAULT, XFER_DEFAULT_OPTIONS, XFER_FILETYPE_DTA, XFER_FILETYPE_SAVF, XFER_FILETYPE_SRC, XFER_HOST_TYPE, XFER_HOST_TYPE_CICS, XFER_HOST_TYPE_CMS, XFER_HOST_TYPE_DEFAULT, XFER_HOST_TYPE_OS400, XFER_HOST_TYPE_TSO, XFER_PACKET_SIZE, XFER_PACKET_SIZE_DEFAULT, XFER_TIME_OUT_VALUE, XFER_TIME_OUT_VALUE_DEFAULT, XFER_TRANSFER_MODE, XFER_TRANSFER_MODE_ASCII, XFER_TRANSFER_MODE_BINARY, XFER_TRANSFER_MODE_DEFAULT
 
Constructor Summary
MacroActionPrintExtract()
          The default constructor for this class.
MacroActionPrintExtract(int sRow, int sCol, int eRow, int eCol)
          A non-default constructor for the situation where all of the row and column values must be specified for the target rectangle.
 
Method Summary
 void execute()
          Executes the PrintExtract action.
 java.lang.String format(int argType, boolean displayAll)
          Formats the action object's contents into a readable string.
 java.lang.String getAssignToVar()
          Returns the name of the variable to which the return code for this action will be assigned.
 int getECol()
          Returns the lower right column of the extract area.
 java.lang.String getEColRaw()
          Returns the expression form for the lower right column of the extract area.
 int getERow()
          Returns the lower right row of the extract area.
 java.lang.String getERowRaw()
          Returns the expression form for the lower right row of the extract area.
 int getSCol()
          Returns the upper left column of the extract area.
 java.lang.String getSColRaw()
          Returns the expression form for the upper left column of the extract area.
 int getSRow()
          Returns the upper left row of the extract area.
 java.lang.String getSRowRaw()
          Returns the expression form for the upper left row of the extract area.
 boolean isAssignToVar()
          Is there a global macro variable to receive the return code result of this call' action performed in the execute() method?
 void setAssignToVar(java.lang.String argAssign)
          Sets the variable to receive the return code of this action.
 void setECol(int argC)
          Sets the lower right column of the extract area.
 void setECol(java.lang.String argC)
          Sets the expression form for the lower right column of the extract area.
 void setERow(int argR)
          Sets the lower right row for the extract area.
 void setERow(java.lang.String argR)
          Sets the expression form for the lower right row of the extract area.
 void setSCol(int argC)
          Sets the upper left column for the extract area.
 void setSCol(java.lang.String argC)
          Sets the expression form for the upper left column of the extract area.
 void setSRow(int argR)
          Sets the upper left row for the extract area.
 void setSRow(java.lang.String argR)
          Sets the expression form for the upper left row of the extract area.
 
Methods inherited from class com.ibm.eNetwork.beans.HOD.MacroAction
clone, equals, halt, setECLSession, setOwner, setRuntimeListeners
 
Methods inherited from class java.lang.Object
getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface com.ibm.eNetwork.beans.HOD.macro.parser.MacroParsable
setAttributes, setError
 

Constructor Detail

MacroActionPrintExtract

public MacroActionPrintExtract()
The default constructor for this class.

If you use this constructor you must call all the set methods of this class to properly set up the action.

See Also:
MacroActionPrintStart.MacroActionPrintStart(), MacroActionPrintEnd.MacroActionPrintEnd()

MacroActionPrintExtract

public MacroActionPrintExtract(int sRow,
                               int sCol,
                               int eRow,
                               int eCol)
A non-default constructor for the situation where all of the row and column values must be specified for the target rectangle.

Parameters:
sRow - Upper left row.
sCol - Upper left column.
eRow - Lower right row.
eCol - Lower right column.

See Also:
MacroActionPrintStart.MacroActionPrintStart(), MacroActionPrintEnd.MacroActionPrintEnd()
Method Detail

execute

public void execute()
Executes the PrintExtract action.

At miminum the owning Macro and an ECLSession must have been set. The coordinates for the extract action default to sRow=1, sCol=1, eRow=-1 and eCol=-1 where -1 means the last row and the last column available in the current ECLPS of the target ECLSession.

The coordinates may be adjusted with their corresponding setters.

If an external assignment variable has been specified, then the return code from the associated MacroPrinterDriver will be assigned to it.

Overrides:
execute in class MacroAction
See Also:
MacroAction.setECLSession(com.ibm.eNetwork.ECL.ECLSession), MacroAction.setOwner(com.ibm.eNetwork.beans.HOD.Macro), setAssignToVar(java.lang.String)

format

public java.lang.String format(int argType,
                               boolean displayAll)
Formats the action object's contents into a readable string. Intended for visual feedback, such as with the MacroDebugActionEvent class.

Overrides:
format in class MacroAction
Parameters:
argType - Reserved, currently only XML strings are supported.
displayAll - If true, optional parameters will be formatted also.
Returns:
String - That reflects the contents of the action.

getSRow

public int getSRow()
Returns the upper left row of the extract area.

Returns:
int - The upper left row.
See Also:
setSRow(int), getSRowRaw()

getSRowRaw

public java.lang.String getSRowRaw()
Returns the expression form for the upper left row of the extract area.

Returns:
String - The expression form of the upper left row.
See Also:
setSRow(String), getSRow()

setSRow

public void setSRow(int argR)
Sets the upper left row for the extract area.

Parameters:
argR - The upper left row of the extract area.
See Also:
getSRow(), setSRow(String), #setSRow(MacroEvaluableIntf)

setSRow

public void setSRow(java.lang.String argR)
Sets the expression form for the upper left row of the extract area.

Parameters:
argR - The expression form for the upper left row of the extract area.
See Also:
getSRow(), setSRow(int), #setSRow(MacroEvaluableIntf)

getSCol

public int getSCol()
Returns the upper left column of the extract area.

Returns:
int - The upper left column.
See Also:
setSCol(int), getSColRaw()

getSColRaw

public java.lang.String getSColRaw()
Returns the expression form for the upper left column of the extract area.

Returns:
String - The expression form of the upper left column.
See Also:
setSCol(String), getSCol()

setSCol

public void setSCol(int argC)
Sets the upper left column for the extract area.

Parameters:
argC - The upper left column of the extract area.
See Also:
getSCol(), setSCol(String), #setSCol(MacroEvaluableIntf)

setSCol

public void setSCol(java.lang.String argC)
Sets the expression form for the upper left column of the extract area.

Parameters:
argC - The expression form for the upper left column of the extract area.
See Also:
getSCol(), setSCol(int), #setSCol(MacroEvaluableIntf)

getERow

public int getERow()
Returns the lower right row of the extract area.

Returns:
int - The lower right row.
See Also:
setERow(int), getERowRaw()

getERowRaw

public java.lang.String getERowRaw()
Returns the expression form for the lower right row of the extract area.

Returns:
String - The expression form of the lower right row.
See Also:
setERow(String), getERow()

setERow

public void setERow(int argR)
Sets the lower right row for the extract area.

Parameters:
argR - The lower right row of the extract area.
See Also:
getERow(), setERow(String), #setERow(MacroEvaluableIntf)

setERow

public void setERow(java.lang.String argR)
Sets the expression form for the lower right row of the extract area.

Parameters:
argR - The expression form for the lower right row of the extract area.
See Also:
getERow(), setERow(int), #setERow(MacroEvaluableIntf)

getECol

public int getECol()
Returns the lower right column of the extract area.

Returns:
int - The lower right column.
See Also:
setECol(int), getEColRaw()

getEColRaw

public java.lang.String getEColRaw()
Returns the expression form for the lower right column of the extract area.

Returns:
String - The expression form of the lower right column.
See Also:
setECol(String), getECol()

setECol

public void setECol(int argC)
Sets the lower right column of the extract area.

Parameters:
argC - The lower right column of the extract area.
See Also:
getECol(), setECol(String), #setECol(MacroEvaluableIntf)

setECol

public void setECol(java.lang.String argC)
Sets the expression form for the lower right column of the extract area.

Parameters:
argC - The expression form for the lower right column of the extract area.
See Also:
getECol(), setECol(int), #setECol(MacroEvaluableIntf)

getAssignToVar

public java.lang.String getAssignToVar()
Returns the name of the variable to which the return code for this action will be assigned. An empty String indicates that no variable has been designated to receive the assignment.

Returns:
String - The name of variable being updated with the return code of this action.
See Also:
execute(), isAssignToVar(), setAssignToVar(java.lang.String)

isAssignToVar

public boolean isAssignToVar()
Is there a global macro variable to receive the return code result of this call' action performed in the execute() method?
Returns:
boolean - whether there is a variable name specified.
See Also:
execute(), getAssignToVar(), setAssignToVar(java.lang.String)

setAssignToVar

public void setAssignToVar(java.lang.String argAssign)
Sets the variable to receive the return code of this action.

Parameters:
argAssign - The name of the return code assignment variable.
See Also:
execute(), isAssignToVar(), getAssignToVar()