Interface BBjBridgeResponse


public interface BBjBridgeResponse
After calling BBjBridge.runBBj() the BBjBridgeResponse will contain any data that has been written to the ALIASed BBj channel by the called BBj program.

An instance of BBjBridgeResponse may be obtained by calling JavaBBjBridgeFactory.createBridgeResponse().

  • Method Summary

    Modifier and Type
    Method
    Description
    boolean
    indication of whether the response was the result of a timed-out request
    byte[]
    get(byte[] key)
    Retrieves data that was written by the BBjProgram using a record oriented write with a key.
    get(String key)
    Retrieves data that was written by the BBjProgram using a record oriented write with a key.
    byte[]
    Retrieves data that was written by the BBjProgram using byte-oriented writes.
    int
    Retrieves the exit code of the process that was run.
    byte[]
    getKey(int p_index)
    Returns key at a specified index.
    int
    Accessor for number of records in data.
    int
    getRecordNumberFromKey(byte[] p_key)
    Retrieves the index position of a key.
    byte[]
    getValue(int p_index)
    Returns value at a specified index.
    boolean
    Indicates whether this response contains record-oriented data.
  • Method Details

    • getBytes

      byte[] getBytes()
      Retrieves data that was written by the BBjProgram using byte-oriented writes.
      Returns:
      The bytes that have been written by the BBj program.
    • get

      byte[] get(byte[] key)
      Retrieves data that was written by the BBjProgram using a record oriented write with a key.
      Returns:
      The bytes that have been written by the BBj program or null if no such key was written.
    • get

      String get(String key)
      Retrieves data that was written by the BBjProgram using a record oriented write with a key.
      Returns:
      The bytes that have been written by the BBj program or null if no such key was written.
    • getExitCode

      int getExitCode()
      Retrieves the exit code of the process that was run.
    • isRecordOriented

      boolean isRecordOriented()
      Indicates whether this response contains record-oriented data.
    • getRecordCount

      int getRecordCount()
      Accessor for number of records in data.
      Returns:
      The number of records currently in this object.
    • getRecordNumberFromKey

      int getRecordNumberFromKey(byte[] p_key)
      Retrieves the index position of a key.
      Parameters:
      p_key - The key of interest.
      Returns:
      The index at which the key was found, or -1 if no such key.
    • getKey

      byte[] getKey(int p_index) throws ArrayIndexOutOfBoundsException
      Returns key at a specified index.
      Parameters:
      p_index - Index of desired key.
      Returns:
      The key at desired index.
      Throws:
      ArrayIndexOutOfBoundsException
    • getValue

      byte[] getValue(int p_index) throws ArrayIndexOutOfBoundsException
      Returns value at a specified index.
      Parameters:
      p_index - Index of desired value.
      Returns:
      The value at desired index.
      Throws:
      ArrayIndexOutOfBoundsException
    • didTimeOut

      boolean didTimeOut()
      indication of whether the response was the result of a timed-out request