2008-07-29 1.1.0

org.eclipse.soda.dk.barcode.reader.simulator
Class BarcodeReaderSimulator

java.lang.Object
  extended by ConnectionTransport
      extended by org.eclipse.soda.dk.barcode.reader.simulator.BarcodeReaderSimulator
All Implemented Interfaces:
BundleActivator

public class BarcodeReaderSimulator
extends ConnectionTransport
implements BundleActivator

GPS NMEA Transport.

The devicekit properties keys and default values.

gpsnmeatransport.hardwareflowcontrol 0
gpsnmeatransport.parity none
gpsnmeatransport.stopbits 1
gpsnmeatransport.comport 1
gpsnmeatransport.readintervaltimeout 50
gpsnmeatransport.softwareflowcontrol 0
gpsnmeatransport.writetotaltimeout 100
gpsnmeatransport.databits 8
gpsnmeatransport.readtotaltimeout 1000
gpsnmeatransport.baudrate 4800
gpsnmeatransport.linger -1
gpsnmeatransport.readtimeout 1000
gpsnmeatransport.readsize -1
gpsnmeatransport.localport -1
gpsnmeatransport.host localhost
gpsnmeatransport.writesize -1
gpsnmeatransport.remoteport 8901
gpsnmeatransport.connection serial
gpsnmeatransport.hardwareflowcontrol=0 gpsnmeatransport.parity=none gpsnmeatransport.stopbits=1 gpsnmeatransport.comport=1 gpsnmeatransport.readintervaltimeout=50 gpsnmeatransport.softwareflowcontrol=0 gpsnmeatransport.writetotaltimeout=100 gpsnmeatransport.databits=8 gpsnmeatransport.readtotaltimeout=1000 gpsnmeatransport.baudrate=4800 gpsnmeatransport.linger=-1 gpsnmeatransport.readtimeout=1000 gpsnmeatransport.readsize=-1 gpsnmeatransport.localport=-1 gpsnmeatransport.host=localhost gpsnmeatransport.writesize=-1 gpsnmeatransport.remoteport=8901 gpsnmeatransport.connection=serial

The list of exported services:

Version:
1.1.0
See Also:
org.eclipse.soda.dk.transport.service.TransportService

Field Summary
protected  BarcodeReaderSimulator barcodeReaderSimulator
          Define the barcode reader simulator (BarcodeReaderSimulator) field.
static java.lang.String CLASS_NAME
          Defines the class name.
static byte[] HEX_TABLE
          Define the hex table (byte[]) constant.
 
Constructor Summary
BarcodeReaderSimulator()
          Constructs a new instance of the GpsNmeaTransport class.
 
Method Summary
 ConnectionService getDefaultConnection()
          Gets the default connection.
 TcpipServerConnectionService getDefaultTcpipServerConnection()
          Gets the default tcpip server connection (TcpipServerConnectionService) value.
 LatitudeData getLatitude(java.lang.String nmeaString)
          Get latitude with the specified nmea string parameter and return the LatitudeData result.
 LongitudeData getLongitude(java.lang.String nmeaString)
          Get longitude with the specified nmea string parameter and return the LongitudeData result.
static void main(java.lang.String[] args)
          Main with the specified args parameter.
 void processInput()
          Process input.
 int processInput(byte[] bytes, int length)
          Process the input bytes and notify listeners of any messages found.
 void setup()
          Sets user-defined varables to use in the test.
 void start(BundleContext context)
          Start with the specified context parameter.
 void stop(BundleContext context)
          Stop with the specified context parameter.
protected  void write(MessageService message)
          Write with the specified message parameter.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

CLASS_NAME

public static final java.lang.String CLASS_NAME
Defines the class name.

See Also:
Constant Field Values

HEX_TABLE

public static final byte[] HEX_TABLE
Define the hex table (byte[]) constant.


barcodeReaderSimulator

protected BarcodeReaderSimulator barcodeReaderSimulator
Define the barcode reader simulator (BarcodeReaderSimulator) field.

Constructor Detail

BarcodeReaderSimulator

public BarcodeReaderSimulator()
Constructs a new instance of the GpsNmeaTransport class.

Method Detail

main

public static void main(java.lang.String[] args)
Main with the specified args parameter.

Parameters:
args - The args (String[]) parameter.

getDefaultConnection

public ConnectionService getDefaultConnection()
Gets the default connection.

Returns:
ConnectionService The default connection used by this transport.

getDefaultTcpipServerConnection

public TcpipServerConnectionService getDefaultTcpipServerConnection()
Gets the default tcpip server connection (TcpipServerConnectionService) value.

Returns:
The default tcpip server connection (TcpipServerConnectionService) value.

getLatitude

public LatitudeData getLatitude(java.lang.String nmeaString)
Get latitude with the specified nmea string parameter and return the LatitudeData result.

Parameters:
nmeaString - The nmea string (String) parameter.
Returns:
Results of the get latitude (LatitudeData) value.

getLongitude

public LongitudeData getLongitude(java.lang.String nmeaString)
Get longitude with the specified nmea string parameter and return the LongitudeData result.

Parameters:
nmeaString - The nmea string (String) parameter.
Returns:
Results of the get longitude (LongitudeData) value.

processInput

public void processInput()
Process input.

See Also:
processInput(byte[],int)

processInput

public int processInput(byte[] bytes,
                        int length)
                 throws java.lang.Exception
Process the input bytes and notify listeners of any messages found.

Parameters:
bytes - The bytes (byte[]) parameter.
length - The length (int) parameter.
Returns:
Results of the process input (int) value.
Throws:
java.lang.Exception - Exception.
See Also:
processInput()

setup

public void setup()
Sets user-defined varables to use in the test.

User defined properties and default values.

retrytime DEFAULT_RETRY_TIME
noactivitytimeout DEFAULT_NO_ACTIVITY_TIMEOUT

See Also:
org.eclipse.soda.dk.transport.Transport#setup()

start

public void start(BundleContext context)
           throws java.lang.Exception
Start with the specified context parameter.

Specified by:
start in interface BundleActivator
Parameters:
context - The context (BundleContext) parameter.
Throws:
java.lang.Exception - Exception.

stop

public void stop(BundleContext context)
          throws java.lang.Exception
Stop with the specified context parameter.

Specified by:
stop in interface BundleActivator
Parameters:
context - The context (BundleContext) parameter.
Throws:
java.lang.Exception - Exception.

write

protected void write(MessageService message)
              throws java.lang.Exception
Write with the specified message parameter.

Parameters:
message - The message (MessageService) parameter.
Throws:
java.lang.Exception - Exception.

2008-07-29 1.1.0

Copyright (c) 2008 IBM. See license in Legal section.