net.sf.marineapi.nmea.util
Enum DataStatus

java.lang.Object
  extended by java.lang.Enum<DataStatus>
      extended by net.sf.marineapi.nmea.util.DataStatus
All Implemented Interfaces:
Serializable, Comparable<DataStatus>

public enum DataStatus
extends Enum<DataStatus>

DataStatus defines the validity of data being broadcasted by an NMEA device.

Version:
$Revision: 59 $
Author:
Kimmo Tuukkanen

Enum Constant Summary
ACTIVE
          Valid data available.
VOID
          No valid data available.
 
Method Summary
 char toChar()
          Returns the character used in NMEA sentences to indicate the status.
static DataStatus valueOf(char ch)
          Returns the DataStatus enum for status char used in sentences.
static DataStatus valueOf(String name)
          Returns the enum constant of this type with the specified name.
static DataStatus[] values()
          Returns an array containing the constants of this enum type, in the order they're declared.
 
Methods inherited from class java.lang.Enum
clone, compareTo, equals, getDeclaringClass, hashCode, name, ordinal, toString, valueOf
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
 

Enum Constant Detail

ACTIVE

public static final DataStatus ACTIVE
Valid data available. May also indicate boolean value true.


VOID

public static final DataStatus VOID
No valid data available. May also indicate boolean value false.

Method Detail

values

public static final DataStatus[] values()
Returns an array containing the constants of this enum type, in the order they're declared. This method may be used to iterate over the constants as follows:
for(DataStatus c : DataStatus.values())
        System.out.println(c);

Returns:
an array containing the constants of this enum type, in the order they're declared

valueOf

public static DataStatus valueOf(String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)

Parameters:
name - the name of the enum constant to be returned.
Returns:
the enum constant with the specified name
Throws:
IllegalArgumentException - if this enum type has no constant with the specified name

toChar

public char toChar()
Returns the character used in NMEA sentences to indicate the status.

Returns:
Char indicator for DataStatus

valueOf

public static DataStatus valueOf(char ch)
Returns the DataStatus enum for status char used in sentences.

Parameters:
ch - Status char
Returns:
DataStatus


Copyright (C) 2010-2011 Java Marine API author(s). All Rights Reserved.