Class Cobolnteraction

An implementation class that enables a component to execute Cobol Server functions.
java.lang.Object

extended by com.microfocus.cobol.connector.cci.CobolInteraction

All Implemented Interfaces

Interaction

Class Specifications

public class CobolInteraction

extends Object

implements Interaction

Field Summary

protected Connection connection
static int ERR_NO_MANAGED_CONNECTION
protected com.microfocus.cobol.connector.logging.RALogger log

Constructor Summary

CobolInteraction(Connection con)
Construct a Cobol Interaction instance.

Methods

Method Summary
void clearWarnings()

Clear all warnings with the Cobol Server.

void close()

close the interaction.

Record execute(InteractionSpec iSpec, Record input)

Execute a Cobol Server function specified in the interaction spec.

boolean execute(InteractionSpec iSpec, Record input, Record output)

Execute a Cobol Server function specified in the interaction spec.

Connection getConnection()

Get the CobolConnection handle associated with this Cobol Interaction instance.

ResourceWarning getWarnings()

Get warnings from the Cobol Server.

protected void prepareFromCobCall(com.microfocus.cobol.lang.ParameterList outputList, Record out)
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

Field Detail

connection
protected Connection connection
log
protected transient com.microfocus.cobol.connector.logging.RALogger log
ERR_NO_MANAGED_CONNECTION
public static final int ERR_NO_MANAGED_CONNECTION

See Also:

Constant Field Values

Constructor Detail

CobolInteraction
public CobolInteraction(Connection con)

Construct a Cobol Interaction instance.

Parameters:
con The CobolConnection handle.
See Also:
CobolConnection

Method Detail

getConnection
public Connection getConnection()

Get the CobolConnection handle associated with this Cobol Interaction instance.

Specified by:
getConnection in interface Interaction
Returns:
CobolConnection handle.
close
public void close()
           throws ResourceException

Close the interaction.

Specified by:
close in interface Interaction
Throws:
ResourceException
execute
public Record execute(InteractionSpec iSpec,
                      Record input)
               throws ResourceException

Execute a Cobol Server function specified in the interaction spec.

Specified by:
execute in interface Interaction
Parameters:
iSpec The CobolInteractionSpec.
input The input record to the interaction.
Returns:
The output Record.
Throws:
ResourceException
execute
public boolean execute(InteractionSpec iSpec,
                 Record input
                 Record output)
          throws ResourceException

Execute a Cobol Server function specified in the interaction spec.

Specified by:
execute in interface Interaction
Parameters:
iSpec The CobolInteractionSpec.
input The input record to the interaction.
output The output record for the interaction.
Returns:
The output record.
Throws:
ResourceException
getWarnings
public ResourceWarning getWarnings()
                            throws ResourceException

Get warnings from the Cobol Server.

Specified by:
getWarnings in interface Interaction
Returns:
Resource warning.
Throws:
ResourceException
clearWarnings
public ResourceWarning clearWarnings()
                              throws ResourceException

Clear warnings from the Cobol Server.

Specified by:
clearWarnings in interface Interaction
Returns:
Resource warning.
Throws:
ResourceException
prepareFromCobCall
protected void prepareFromCobCall(com.microfocus.cobol.lang.ParameterList outputList,
                                  Record out)
                           throws ResourceException
Throws:
ResourceException