2009-06-02 1.2.0

org.eclipse.soda.dk.gps.nmea.simulator
Class GpsNmeaSimulator

java.lang.Object
  extended by ConnectionTransport
      extended by org.eclipse.soda.dk.gps.nmea.simulator.GpsNmeaSimulator

public class GpsNmeaSimulator
extends ConnectionTransport

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:

Since:
1.0
Version:
1.2.0
See Also:
org.eclipse.soda.dk.transport.service.TransportService

Field Summary
static java.lang.String CLASS_NAME
          Defines the class name.
static byte[] HEX_TABLE
          Define the hex table (byte[]) constant.
 
Constructor Summary
GpsNmeaSimulator()
          Constructs a new instance of the GpsNmeaTransport class.
 
Method Summary
 ConnectionService getDefaultConnection()
          Gets the default connection (ConnectionService) value.
 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[] arguments)
          Main with the specified arguments 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 variables to use in the test.
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.

Constructor Detail

GpsNmeaSimulator

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

Method Detail

main

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

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

getDefaultConnection

public ConnectionService getDefaultConnection()
Gets the default connection (ConnectionService) value.

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()
                  throws java.lang.Exception
Process input.

Throws:
java.lang.Exception - Exception.
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 variables 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()

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.

2009-06-02 1.2.0

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