Package ucar.unidata.metdata
Class WMOHeader
java.lang.Object
ucar.unidata.metdata.WMOHeader
- All Implemented Interfaces:
Serializable
,Comparable
This class enscapsulates an WMO "Abbreviated heading", the
string used as an identifer on WMO format messages.
Ref: _Manual on the Global Telecommunications System_, Volume 1,
Global Aspects. WMO-No. 386, 1986
Paragraph 2.3.2 page A.II-3
- Version:
- $Revision: 1.8 $
- Author:
- Glenn Davis
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionWMOHeader
(ByteString.Concrete src, ByteString.TrSubString TTAA, byte ii, ByteString.SubString CCCC, Timestamp ts) Create a new WMOHeader -
Method Summary
Modifier and TypeMethodDescriptionint
Compare to another objectint
Imposes a "natural order" on WMOHeaders.Returns the "international four letter location indicator of the station originating or compiling the bulletin" (CCCC).getText()
Get the headerGet the timestamptoString()
Return a String representation of this WMOHeader
-
Constructor Details
-
WMOHeader
public WMOHeader(ByteString.Concrete src, ByteString.TrSubString TTAA, byte ii, ByteString.SubString CCCC, Timestamp ts) Create a new WMOHeader- Parameters:
src
- source of the HeaderTTAA
- TTAA portionii
- II portionCCCC
- CCCC portionts
- timestamp
-
-
Method Details
-
getTimestamp
Get the timestamp- Returns:
- timestamp
-
getText
Get the header- Returns:
- the header text
-
getCallSign
Returns the "international four letter location indicator of the station originating or compiling the bulletin" (CCCC).- Returns:
- the CCCC portion
-
compareTo
Imposes a "natural order" on WMOHeaders.Compares this object with the specified object for order. Returns a negative integer, zero, or a positive integer as this object is less than, equal to, or greater than the specified object.
- Parameters:
hdr
- the Object to be compared.- Returns:
- a negative integer, zero, or a positive integer as this object is less than, equal to, or greater than the specified object.
- Throws:
ClassCastException
- if the specified object's type prevents it from being compared to this Object.- See Also:
-
compareTo
Compare to another object- Specified by:
compareTo
in interfaceComparable
- Parameters:
oo
- Object to compare- Returns:
- a negative integer, zero, or a positive integer as this object is less than, equal to, or greater than the specified object.
-
toString
Return a String representation of this WMOHeader
-