org.mbari.siam.devices.dummy
Class SineDummyParser

java.lang.Object
  extended by org.mbari.siam.distributed.PacketParser
      extended by org.mbari.siam.utils.DelimitedStringParser
          extended by org.mbari.siam.devices.dummy.SineDummyParser
All Implemented Interfaces:
java.io.Serializable

public class SineDummyParser
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 _namingPrefix
           
static int BASE_INDEX
           
protected  java.util.Vector fieldNames
           
protected  java.util.Vector fieldUnits
           
static int SIN0_INDEX
           
static int SIN1_INDEX
           
static int SIN2_INDEX
           
static int SIN3_INDEX
           
static int SIN4_INDEX
           
static int SIN5_INDEX
           
static int SIN6_INDEX
           
static int SIN7_INDEX
           
static int SIN8_INDEX
           
static int SIN9_INDEX
           
 
Fields inherited from class org.mbari.siam.utils.DelimitedStringParser
_delimiters, _fieldVector
 
Fields inherited from class org.mbari.siam.distributed.PacketParser
_registryName
 
Constructor Summary
SineDummyParser()
          No-arg constructor needed to instantiate via class loader (e.g.
SineDummyParser(java.lang.String registryName, java.lang.String delimiters)
           
 
Method Summary
protected  void initialize()
           
protected  PacketParser.Field processToken(int nToken, java.lang.String token)
          Process the token, whose position in string is nToken.
 void setNamingPrefix(java.lang.String prefix)
          setNamimgPrefix allows callers to set a naming prefix to prevent naming collisions in DataTurbine.
 
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

BASE_INDEX

public static final int BASE_INDEX
See Also:
Constant Field Values

SIN0_INDEX

public static final int SIN0_INDEX
See Also:
Constant Field Values

SIN1_INDEX

public static final int SIN1_INDEX
See Also:
Constant Field Values

SIN2_INDEX

public static final int SIN2_INDEX
See Also:
Constant Field Values

SIN3_INDEX

public static final int SIN3_INDEX
See Also:
Constant Field Values

SIN4_INDEX

public static final int SIN4_INDEX
See Also:
Constant Field Values

SIN5_INDEX

public static final int SIN5_INDEX
See Also:
Constant Field Values

SIN6_INDEX

public static final int SIN6_INDEX
See Also:
Constant Field Values

SIN7_INDEX

public static final int SIN7_INDEX
See Also:
Constant Field Values

SIN8_INDEX

public static final int SIN8_INDEX
See Also:
Constant Field Values

SIN9_INDEX

public static final int SIN9_INDEX
See Also:
Constant Field Values

fieldNames

protected java.util.Vector fieldNames

fieldUnits

protected java.util.Vector fieldUnits

_namingPrefix

protected java.lang.String _namingPrefix
Constructor Detail

SineDummyParser

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


SineDummyParser

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

setNamingPrefix

public void setNamingPrefix(java.lang.String prefix)
                     throws java.lang.Exception
setNamimgPrefix allows callers to set a naming prefix to prevent naming collisions in DataTurbine. Sinece all InputState packets parse the same way, different inputs can set the prefix equal to the input name+"_", giving each data field a unique (and easily identifiable) OSDT channel name. This method is invoked by the main control loop packet parser

Throws:
java.lang.Exception

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.