org.mbari.siam.foce.devices.controlLoop
Class BaseResponseParser

java.lang.Object
  extended by org.mbari.siam.distributed.PacketParser
      extended by org.mbari.siam.utils.DelimitedStringParser
          extended by org.mbari.siam.foce.devices.controlLoop.BaseResponseParser
All Implemented Interfaces:
java.io.Serializable
Direct Known Subclasses:
PH_ResponseParser, VEL_ResponseParser

public class BaseResponseParser
extends DelimitedStringParser

See Also:
Serialized Form

Nested Class Summary
 
Nested classes/interfaces inherited from class org.mbari.siam.distributed.PacketParser
PacketParser.Field, PacketParser.Record
 
Field Summary
protected  java.lang.String _prefix
          field prefix
static int CORRECTION_INDEX
           
static int ERROR_INDEX
           
 java.util.Vector fieldNames
           
 java.util.Vector fieldUnits
           
static int INDEX_BASE
           
static int MAX_BASE_INDEX
           
static int OFFSET_INDEX
           
static int PROCESS_VALUE_INDEX
           
static int RAW_CORR_INDEX
           
static int RECORD_TYPE_INDEX
           
static int SETPOINT_INDEX
           
 
Fields inherited from class org.mbari.siam.utils.DelimitedStringParser
_delimiters, _fieldVector
 
Fields inherited from class org.mbari.siam.distributed.PacketParser
_registryName
 
Constructor Summary
BaseResponseParser()
          No-arg constructor needed to instantiate via class loader (e.g.
BaseResponseParser(java.lang.String registryName, java.lang.String delimiters)
           
BaseResponseParser(java.lang.String registryName, java.lang.String delimiters, java.lang.String prefix)
           
 
Method Summary
protected  void initialize()
           
protected  PacketParser.Field processToken(int nToken, java.lang.String token)
          Process the token, whose position in string is nToken.
 
Methods inherited from class org.mbari.siam.utils.DelimitedStringParser
decimalValue, parseFields
 
Methods inherited from class org.mbari.siam.distributed.PacketParser
getField
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

INDEX_BASE

public static final int INDEX_BASE
See Also:
Constant Field Values

RECORD_TYPE_INDEX

public static final int RECORD_TYPE_INDEX
See Also:
Constant Field Values

PROCESS_VALUE_INDEX

public static final int PROCESS_VALUE_INDEX
See Also:
Constant Field Values

OFFSET_INDEX

public static final int OFFSET_INDEX
See Also:
Constant Field Values

SETPOINT_INDEX

public static final int SETPOINT_INDEX
See Also:
Constant Field Values

ERROR_INDEX

public static final int ERROR_INDEX
See Also:
Constant Field Values

CORRECTION_INDEX

public static final int CORRECTION_INDEX
See Also:
Constant Field Values

RAW_CORR_INDEX

public static final int RAW_CORR_INDEX
See Also:
Constant Field Values

MAX_BASE_INDEX

public static final int MAX_BASE_INDEX
See Also:
Constant Field Values

fieldNames

public java.util.Vector fieldNames

fieldUnits

public java.util.Vector fieldUnits

_prefix

protected java.lang.String _prefix
field prefix

Constructor Detail

BaseResponseParser

public BaseResponseParser()
No-arg constructor needed to instantiate via class loader (e.g. by logView)


BaseResponseParser

public BaseResponseParser(java.lang.String registryName,
                          java.lang.String delimiters)

BaseResponseParser

public BaseResponseParser(java.lang.String registryName,
                          java.lang.String delimiters,
                          java.lang.String prefix)
Method Detail

initialize

protected void initialize()

processToken

protected PacketParser.Field processToken(int nToken,
                                          java.lang.String token)
                                   throws java.text.ParseException
Process the token, whose position in string is nToken. If token corresponds to a Field, create and return the field. Otherwise return null.

Specified by:
processToken in class DelimitedStringParser
Throws:
java.text.ParseException


Copyright © 2003 MBARI.

The Monterey Bay Aquarium Research Institute (MBARI) provides this documentation and code "as is", with no warranty, express or implied, of its quality or consistency. It is provided without support and without obligation on the part of MBARI to assist in its use, correction, modification, or enhancement.