Rational Developer for Power Systems Software
V7.6

com.ibm.etools.iseries.edit.verifiers.comm.bridge
Class ADEControlBlock

java.lang.Object
  extended by com.ibm.etools.iseries.edit.verifiers.comm.bridge.ADEControlBlock
All Implemented Interfaces:
ICODECommIntegrationConstants

public class ADEControlBlock
extends Object
implements ICODECommIntegrationConstants

This class corresponds to the CODE comm ADE_CB structure. Currently this is just used as a unique id


Field Summary
static String copyright
           
static int OPENDBF_STATE
           
static int OPENFIELD_STATE
           
static int OPENGET_STATE
           
static int OPENGETIFS_STATE
           
static int OPENLIST_FIELDS_STATE
           
static int OPENLIST_RECORDS_STATE
           
 
Fields inherited from interface com.ibm.etools.iseries.edit.verifiers.comm.bridge.ICODECommIntegrationConstants
ADEOPT_ALL, ADEOPT_ASIS, ADEOPT_CODE, ADEOPT_DATE, ADEOPT_EDIT, ADEOPT_FIRST, ADEOPT_INACTIVE, ADEOPT_LENGTH, ADEOPT_NOTAG, ADEOPT_SECOND, ADEOPT_SIZE, ADERC_BUFFER_SMALL, ADERC_CCSID_NF, ADERC_EDIT_NF, ADERC_EOF, ADERC_FIELD_NF, ADERC_FILE_AUTH, ADERC_FILE_NF, ADERC_FILE_TYPE, ADERC_INACT, ADERC_INVALID_ALIAS, ADERC_INVALID_MSG, ADERC_LIB_AUTH, ADERC_LIB_NF, ADERC_MBR_NF, ADERC_NO_SERVER, ADERC_OBJ_AUTH, ADERC_OBJ_NF, ADERC_OK, ADERC_PROG_ERR, ADERC_RECORD_NF, ADERC_RSST_ERR, ADERC_SYS_ERR, ALIAS_LENGTH, BOOL_FALSE, BOOL_TRUE, CHKFILE_ADM, CHKFILE_DBCS, CHKFILE_DDM, CHKFILE_DISPLAY, CHKFILE_ICF, CHKFILE_JOIN, CHKFILE_KEYED, CHKFILE_LOGICAL, CHKFILE_MIXED, CHKFILE_PHYSICAL, CHKFILE_PRINTER, CHKFILE_SOURCE, CHKOP_ADD, CHKOP_ALL, CHKOP_CHANGE, CHKOP_COPY, CHKOP_CPYMBR, CHKOP_DELETE, CHKOP_EDIT, CHKOP_MANAGE, CHKOP_OBJOPERATE, CHKOP_OBJOPRMGT, CHKOP_READ, CHKOP_READADD, CHKOP_UPDATE, CHKOP_USE, CHKOP_USEADD, CHKSTATUS_FTYPERETURNED, CHKSTATUS_IGCSYS, CHKSTATUS_LIBREAD, CHKSTATUS_MBRLOCK, CHKSTATUS_OBJREAD, CHKTYPE_ADM, CHKTYPE_BASEDON, CHKTYPE_LIB, CHKTYPE_MBR, CHKTYPE_OBJ, EXTKWD_CHECKAB, EXTKWD_CHECKFE, EXTKWD_CHECKM10, EXTKWD_CHECKM11, EXTKWD_CHECKME, EXTKWD_CHECKMF, EXTKWD_CHECKMF10, EXTKWD_CHECKMF11, EXTKWD_CHECKVN, EXTKWD_CHECKVNE, EXTKWD_CHKMSGID, EXTKWD_COMPEQ, EXTKWD_COMPGE, EXTKWD_COMPGT, EXTKWD_COMPLE, EXTKWD_COMPLT, EXTKWD_COMPNE, EXTKWD_COMPNG, EXTKWD_COMPNL, EXTKWD_DFT, EXTKWD_RANGE, EXTKWD_VALUES, NULL_CHAR, OP_CONCAT, OP_RENAME, OP_SUBSTRING, OP_TRANS_CONCAT, OP_TRANS_RENAME, OP_TRANSLATE, RSE_CHECK_CCSID, RSE_CHECK_OBJECT, RSE_CHECK_OBJECT_2, RSE_CHECK_OBJECT_IFS, RSE_CLOSE, RSE_CLOSE_SOCKET, RSE_DEFAULT_ALIAS, RSE_DEVFILE_INFO, RSE_EDIT_WORD, RSE_GET_CWD_IFS, RSE_GET_ENCODING_SCHEME, RSE_GET_ENV_IFS, RSE_IS_ALIAS_VALID, RSE_IS_ANY_ALIAS_VALID, RSE_MSG_TEXT, RSE_OPEN_DBF, RSE_OPEN_FIELD, RSE_OPEN_GET, RSE_OPEN_GET_IFS, RSE_OPEN_LIST, RSE_READ, RSE_READ_DBF, RSE_READ_FIELD, RSE_READ_IFS, RSE_RESOLVE_DBF, RSE_SORT_SEQ_TABLE, RSE_SQL_LANG_LENGTH, RSE_SYNTAX_CHECK_SQL, RSE_SYS_INFO, RSE_XLATE, XLATE_GET, XLATE_PUT
 
Constructor Summary
protected ADEControlBlock(int state)
          Constructor for ADEControlBlock.
 
Method Summary
protected  void free()
          Release all resources associated with this control block
protected static void free(int id)
          Release all resources associated with the ADEControlBlock with id.
protected  int getID()
          Return the id for this "control block"
protected  IQSYSDatabaseField getISeriesField()
          Retursn the ISeriesField currently associated with this control block.
protected  IQSYSDatabaseFile getISeriesFile()
          Return the ISeriesFile currently associated with this control block.
protected  FDKWDStruct getNextFieldKeyword()
          Retrieve the next keyword
protected static ADEControlBlock lookup(CToJavaInputStream in)
          Lookup the control block.
protected static ADEControlBlock lookup(int id)
          Given an ADEControlBlock id, find the corresponding instance
protected  void setFileContents(String[] fileContents)
          Sets the fileContents.
protected  void setIncludeSequenceArea(boolean include)
          Include sequence area when writing records from the rseRead after an rseOpenGet
protected  void setISeriesField(IQSYSDatabaseField field)
          Sets the ISeriesField associated with this control block.
protected  void setISeriesFile(IQSYSDatabaseFile file)
          Sets the ISeriesFile associated with this control block.
protected  void setLSFIELDStruct(LSFIELDStruct lsfield)
          Sets the LSFIELDStruct for subsuquent writing
protected  void setLSRECStruct(LSRECStruct[] records)
          Sets the LSRECStruct for subsequent writing
protected  void write(JavaToCOutputStream out)
          Write the id to the output stream
protected  void writeInfo(JavaToCOutputStream out)
          Method writeInfo.
protected  void writeInfo(JavaToCOutputStream out, boolean resolveConcatFields)
          Method writeInfo.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

copyright

public static final String copyright
See Also:
Constant Field Values

OPENGET_STATE

public static final int OPENGET_STATE
See Also:
Constant Field Values

OPENFIELD_STATE

public static final int OPENFIELD_STATE
See Also:
Constant Field Values

OPENLIST_FIELDS_STATE

public static final int OPENLIST_FIELDS_STATE
See Also:
Constant Field Values

OPENDBF_STATE

public static final int OPENDBF_STATE
See Also:
Constant Field Values

OPENLIST_RECORDS_STATE

public static final int OPENLIST_RECORDS_STATE
See Also:
Constant Field Values

OPENGETIFS_STATE

public static final int OPENGETIFS_STATE
See Also:
Constant Field Values
Constructor Detail

ADEControlBlock

protected ADEControlBlock(int state)
Constructor for ADEControlBlock.

Parameters:
state - The state of the control block, use one of the predefined state constants.
Method Detail

getID

protected int getID()
Return the id for this "control block"


write

protected void write(JavaToCOutputStream out)
              throws IOException
Write the id to the output stream

Throws:
IOException

lookup

protected static ADEControlBlock lookup(int id)
Given an ADEControlBlock id, find the corresponding instance

Returns:
The ADEControlBlock corresponding to the id, or null if no ADEControlBlock exists for this key

lookup

protected static ADEControlBlock lookup(CToJavaInputStream in)
                                 throws IOException
Lookup the control block. This is done be reading the first int from the input stream and using this as the control block number.

Throws:
IOException

free

protected void free()
Release all resources associated with this control block


free

protected static void free(int id)
Release all resources associated with the ADEControlBlock with id. This is the same as calling ADEControlBlock.lookup(id).free()


setISeriesField

protected void setISeriesField(IQSYSDatabaseField field)
Sets the ISeriesField associated with this control block. This allows us to remember which ISeriesField is being used between RSEOpenField and RSEReadField requests.


getISeriesFile

protected IQSYSDatabaseFile getISeriesFile()
Return the ISeriesFile currently associated with this control block.

See Also:
ADEControlBlock.setISeriesFile

setISeriesFile

protected void setISeriesFile(IQSYSDatabaseFile file)
Sets the ISeriesFile associated with this control block. This allows us to remember which ISeriesFile is being used between RSEOpenDBF and RSERead requests.


getISeriesField

protected IQSYSDatabaseField getISeriesField()
Retursn the ISeriesField currently associated with this control block.

See Also:
ADEControlBlock.setISeriesField

getNextFieldKeyword

protected FDKWDStruct getNextFieldKeyword()
Retrieve the next keyword

Returns:
The next keyword for the current database field stored in this control block or null if there are no more keywords

setFileContents

protected void setFileContents(String[] fileContents)
Sets the fileContents.

Parameters:
fileContents - The fileContents to set

setIncludeSequenceArea

protected void setIncludeSequenceArea(boolean include)
Include sequence area when writing records from the rseRead after an rseOpenGet


setLSFIELDStruct

protected void setLSFIELDStruct(LSFIELDStruct lsfield)
Sets the LSFIELDStruct for subsuquent writing


setLSRECStruct

protected void setLSRECStruct(LSRECStruct[] records)
Sets the LSRECStruct for subsequent writing


writeInfo

protected void writeInfo(JavaToCOutputStream out)
                  throws IOException
Method writeInfo. Writes the next record from a previous query. What gets written to the output stream depends on the previous operation requested by the CODE communications layer. This is represented by the state of the control block.

Parameters:
out -
Throws:
IOException

writeInfo

protected void writeInfo(JavaToCOutputStream out,
                         boolean resolveConcatFields)
                  throws IOException
Method writeInfo. Writes the next record from a previous query. What gets written to the output stream depends on the previous operation requested by the CODE communications layer. This is represented by the state of the control block.

Parameters:
out - OutputStream to write results
resolveConcatFields - Whether concatenated fields should be resolved (this is only used by list fields.
Throws:
IOException

Rational Developer for Power Systems Software
V7.6

Copyright © 2011 IBM Corp. All Rights Reserved.

Note: This documentation is for part of an interim API that is still under development and expected to change significantly before reaching stability. It is being made available at this early stage to solicit feedback from pioneering adopters on the understanding that any code that uses this API will almost certainly be broken (repeatedly) as the API evolves.