net.sourceforge.jgrib
Class GribRecordBMS

java.lang.Object
  extended by net.sourceforge.jgrib.GribRecordBMS

public class GribRecordBMS
extends java.lang.Object

A class that represents the bitmap section (BMS) of a GRIB record. It indicates grid points where no parameter value is defined.

Version:
1.0
Author:
Benjamin Stark

Field Summary
protected  boolean[] bitmap
          The bit map.
protected  int length
          Length in bytes of this section.
 
Constructor Summary
GribRecordBMS(BitInputStream in)
          Constructs a GribRecordBMS object from a bit input stream.
 
Method Summary
 boolean[] getBitmap()
          Get bit map.
 int getLength()
          Get length in bytes of this section.
 java.lang.String toString()
          Get a string representation of this BMS.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

length

protected int length
Length in bytes of this section.


bitmap

protected boolean[] bitmap
The bit map.

Constructor Detail

GribRecordBMS

public GribRecordBMS(BitInputStream in)
              throws java.io.IOException,
                     NoValidGribException
Constructs a GribRecordBMS object from a bit input stream.

Parameters:
in - bit input stream with BMS content
Throws:
java.io.IOException - if stream can not be opened etc.
NoValidGribException - if stream contains no valid GRIB file
Method Detail

getLength

public int getLength()
Get length in bytes of this section.

Returns:
length in bytes

getBitmap

public boolean[] getBitmap()
Get bit map.

Returns:
bit map as array of boolean values

toString

public java.lang.String toString()
Get a string representation of this BMS.

Overrides:
toString in class java.lang.Object
Returns:
string representation of this BMS