public class CallServiceProgramProcedure extends java.lang.Object implements Program
This is designed so that classes to call a service program procedure can be created by extending this class. For examples, see the Direct Known Subclasses information in the javadoc.
A class that extends this class must implement the following methods corresponding to CallServiceProgramParameterFormat.
CallServiceProgramParameterFormat
Modifier and Type | Field and Description |
---|---|
static int |
RETURN_VALUE_FORMAT_INTEGER |
static int |
RETURN_VALUE_FORMAT_INTEGER_AND_ERROR_NUMBER |
static int |
RETURN_VALUE_FORMAT_NONE |
static int |
RETURN_VALUE_FORMAT_POINTER |
Constructor and Description |
---|
CallServiceProgramProcedure() |
CallServiceProgramProcedure(java.lang.String serviceProgramName,
java.lang.String serviceProgramLibrary,
java.lang.String exportName,
int returnValueFormat) |
Modifier and Type | Method and Description |
---|---|
java.lang.String |
getExportName() |
int |
getNumberOfParameters()
Returns the number of parameters for this program.
|
CallServiceProgramParameterFormat |
getParameterFormat() |
byte[] |
getParameterInputData(int parmIndex)
Returns the input data of the parameter at the specified index.
|
int |
getParameterInputLength(int parmIndex)
Returns the input length of the parameter at the specified index.
|
int |
getParameterOutputLength(int parmIndex)
Returns the output length of the parameter at the specified index.
|
int |
getParameterType(int parmIndex)
Returns the type of parameter at the specified index.
|
java.lang.String |
getProgramLibrary()
Returns the library of the program object.
|
java.lang.String |
getProgramName()
Returns the name of the program object.
|
int |
getReturnValueErrorNumber() |
int |
getReturnValueFormat() |
int |
getReturnValueInteger() |
byte[] |
getReturnValuePointer() |
java.lang.String |
getServiceProgramLibrary() |
java.lang.String |
getServiceProgramName() |
byte[] |
getTempDataBuffer()
The implementor can create their own temp byte array for the output parameter size and reuse it each time a call is performed,
or for more than one parameter on the same call.
|
void |
newCall()
Invoked before any other methods on this interface by CommandConnection whenever this Program is called.
|
void |
setExportName(java.lang.String name) |
void |
setParameterFormat(CallServiceProgramParameterFormat format) |
void |
setParameterOutputData(int parmIndex,
byte[] tempData,
int maxLength)
Sets the output data for the parameter at the specified index.
|
void |
setReturnValueFormat(int retval) |
void |
setServiceProgramLibrary(java.lang.String lib) |
void |
setServiceProgramName(java.lang.String name) |
public static final int RETURN_VALUE_FORMAT_NONE
public static final int RETURN_VALUE_FORMAT_INTEGER
public static final int RETURN_VALUE_FORMAT_POINTER
public static final int RETURN_VALUE_FORMAT_INTEGER_AND_ERROR_NUMBER
public CallServiceProgramProcedure()
public CallServiceProgramProcedure(java.lang.String serviceProgramName, java.lang.String serviceProgramLibrary, java.lang.String exportName, int returnValueFormat)
public java.lang.String getServiceProgramName()
public void setServiceProgramName(java.lang.String name)
public java.lang.String getServiceProgramLibrary()
public void setServiceProgramLibrary(java.lang.String lib)
public java.lang.String getExportName()
public void setExportName(java.lang.String name)
public int getReturnValueFormat()
public void setReturnValueFormat(int retval)
public CallServiceProgramParameterFormat getParameterFormat()
public void setParameterFormat(CallServiceProgramParameterFormat format)
public java.lang.String getProgramName()
Program
getProgramName
in interface Program
public java.lang.String getProgramLibrary()
Program
getProgramLibrary
in interface Program
public int getNumberOfParameters()
Program
getNumberOfParameters
in interface Program
public final byte[] getTempDataBuffer()
Program
getTempDataBuffer
in interface Program
public void newCall()
Program
public int getReturnValueInteger()
public int getReturnValueErrorNumber()
public byte[] getReturnValuePointer()
public int getParameterInputLength(int parmIndex)
Program
getParameterInputLength
in interface Program
public int getParameterOutputLength(int parmIndex)
Program
getParameterOutputLength
in interface Program
public int getParameterType(int parmIndex)
Program
getParameterType
in interface Program
Parameter
public byte[] getParameterInputData(int parmIndex)
Program
getParameterInputData
in interface Program
public void setParameterOutputData(int parmIndex, byte[] tempData, int maxLength)
Program
setParameterOutputData
in interface Program