ucar.grib.grib2
Class ParameterTable

java.lang.Object
  extended by ucar.grib.grib2.ParameterTable

public final class ParameterTable
extends Object

Performs operations related to loading parameter tables stored in files. Through a lookup table (see readParameterTableLookup) all of the supported Parameter Tables are known. A parameter consists of a discipline( ie Meteorological_products), a Category( ie Temperature ) and a number that refers to a name( ie Temperature)

see Parameters.txt

Author:
Robb Kambic /10/10/03

Constructor Summary
ParameterTable()
           
 
Method Summary
static void addLocalParameters(String LocalParameters)
          Read in local parameters
static void addParametersUser(InputStream is)
          Let the user add parameters
static void addParametersUser(String UserGribTable)
          Reads in the list of parameters and stores them.
static String getCategoryName(int d, int c)
          Get a description for the Category with ids id.
static String getDisciplineName(int aDis)
          Get a name for the Discipline with id.
static GridParameter getParameter(int d, int c, int p)
          Get a Parameter obj for the Parameter with ids id.
static GridParameter getParameter(int d, int c, int p, int center)
          Get a Local Parameter obj for the Parameter with ids id.
static String getParameterDescription(int d, int c, int p)
          Get a description for the Parameter with ids id.
static String getParameterName(int d, int c, int p)
          Get a Name for the Parameter with ids id.
static String getParameterUnit(int d, int c, int p)
          Get a unit for the Parameter with ids id.
static void main(String[] args)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ParameterTable

public ParameterTable()
Method Detail

getDisciplineName

public static String getDisciplineName(int aDis)
Get a name for the Discipline with id.

Parameters:
aDis - Discipline as a int
Returns:
Name of the Discipline

getCategoryName

public static String getCategoryName(int d,
                                     int c)
Get a description for the Category with ids id.

Parameters:
d - Discipline
c - Category
Returns:
Name for the Category

getParameterName

public static String getParameterName(int d,
                                      int c,
                                      int p)
Get a Name for the Parameter with ids id.

Parameters:
d - Discipline
c - Category
p - Parameter
Returns:
Name for the Parameter

getParameterUnit

public static String getParameterUnit(int d,
                                      int c,
                                      int p)
Get a unit for the Parameter with ids id.

Parameters:
d - Discipline
c - Category
p - Parameter
Returns:
unit for the Parameter

getParameterDescription

public static String getParameterDescription(int d,
                                             int c,
                                             int p)
Get a description for the Parameter with ids id.

Parameters:
d - Discipline
c - Category
p - Parameter
Returns:
Name for the Parameter

getParameter

public static GridParameter getParameter(int d,
                                         int c,
                                         int p)
Get a Parameter obj for the Parameter with ids id.

Parameters:
d - Discipline
c - Category
p - Parameter
Returns:
Parameter

getParameter

public static GridParameter getParameter(int d,
                                         int c,
                                         int p,
                                         int center)
Get a Local Parameter obj for the Parameter with ids id.

Parameters:
d - Discipline
c - Category
p - Parameter
center -
Returns:
Parameter

addParametersUser

public static void addParametersUser(String UserGribTable)
                              throws IOException
Reads in the list of parameters and stores them. Parameters are listed by row, fields are separated by tabs: Discipline, Catagory, Parmeter Number, Name, Units, & Description. For more information, look at IndexFormat.txt in the root of the distribution.

Parameters:
UserGribTable - Name
Throws:
IOException - on reading list user parameters

addParametersUser

public static void addParametersUser(InputStream is)
                              throws IOException
Let the user add parameters

Parameters:
is - InputStream
Throws:
IOException - on read

addLocalParameters

public static void addLocalParameters(String LocalParameters)
                               throws IOException
Read in local parameters

Parameters:
LocalParameters -
Throws:
IOException - on read

main

public static void main(String[] args)


Copyright © 1999-2011 UCAR/Unidata. All Rights Reserved.