public class DataModelImpl
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
SELECTED_INDEX
The name of the index-of-the-selected-thing property.
|
Constructor and Description |
---|
DataModelImpl(javax.swing.JList jList)
Constructs from a JList.
|
Modifier and Type | Method and Description |
---|---|
void |
addListDataListener(javax.swing.event.ListDataListener listener)
Adds a listener for changes to the underlying list of things.
|
void |
addListSelectionListener(javax.swing.event.ListSelectionListener listener)
Adds a listener for changes to the selected things.
|
void |
addPropertyChangeListener(java.lang.String name,
java.beans.PropertyChangeListener listener)
Adds a PropertyChangeListener for a named property.
|
protected static visad.FlatField |
ensureCartesianWindProfile(visad.FlatField input)
Ensures that a wind profile is in cartesian coordinates.
|
visad.Field |
getDewPointProfile(int index)
Returns the dew-point profile at the given index.
|
visad.Tuple |
getMeanWind(int index)
Returns the mean-wind at the given index.
|
protected MeanWindCell |
getMeanWindCell(int index)
Returns the mean-wind cell at the given index.
|
visad.DataReference |
getMeanWindRef(int index)
Returns the data reference for the mean-wind at the given index.
|
protected RAOB |
getRAOB(int index)
Returns the RAOB at the given index.
|
int |
getSelectedIndex()
Returns the index of the selected sounding.
|
int |
getSize()
Returns the number of soundings.
|
visad.Field[] |
getSounding(int index)
Returns the aerological sounding data at the given index.
|
visad.Field |
getTemperatureProfile(int index)
Returns the temperature profile at the given index.
|
java.lang.Object[] |
getWindData(int index)
Returns the wind profile and mean-wind at the given index.
|
visad.Field |
getWindProfile(int index)
Returns the wind profile at the given index.
|
boolean |
isSelectedIndex(int index)
Indicates if the given sounding is a member of the selected soundings.
|
void |
removeListDataListener(javax.swing.event.ListDataListener listener)
Removes a listener for changes to the underlying list of things.
|
void |
removeListSelectionListener(javax.swing.event.ListSelectionListener listener)
Removes a listener for changes to the selected things.
|
void |
removePropertyChangeListener(java.lang.String name,
java.beans.PropertyChangeListener listener)
Removes a PropertyChangeListener for a named property.
|
void |
restoreSelectedSoundings()
Restores the selected soundings to their original values.
|
public static final java.lang.String SELECTED_INDEX
public DataModelImpl(javax.swing.JList jList)
jList
- The underlying JList whose mutable data model
contains the sounding data and whose list
selection model determines the selected
soundings and selected sounding.public int getSize()
public boolean isSelectedIndex(int index)
index
- The index of the sounding.true
if and only if the given
sounding is a member of the selected soundings.public int getSelectedIndex()
public void restoreSelectedSoundings() throws visad.VisADException, java.rmi.RemoteException
visad.VisADException
- VisAD failure.java.rmi.RemoteException
- Java RMI failure.public visad.Field[] getSounding(int index) throws java.lang.IndexOutOfBoundsException
index
- The index of the sounding.java.lang.IndexOutOfBoundsException
- The index is out of range.public visad.Field getTemperatureProfile(int index) throws java.lang.IndexOutOfBoundsException
index
- The index of the temperature profile.java.lang.IndexOutOfBoundsException
- The index is out of range.public visad.Field getDewPointProfile(int index) throws java.lang.IndexOutOfBoundsException
index
- The index of the dew-point profile.java.lang.IndexOutOfBoundsException
- The index is out of range.public java.lang.Object[] getWindData(int index) throws java.lang.IndexOutOfBoundsException, visad.VisADException, java.rmi.RemoteException
index
- The index of the sounding.java.lang.IndexOutOfBoundsException
- The index is out of range.visad.VisADException
- VisAD failure.java.rmi.RemoteException
- Java RMI failure.public visad.Field getWindProfile(int index) throws java.lang.IndexOutOfBoundsException, visad.VisADException, java.rmi.RemoteException
index
- The index of the wind profile.java.lang.IndexOutOfBoundsException
- The index is out of range.visad.VisADException
- VisAD failure.java.rmi.RemoteException
- Java RMI failure.public visad.Tuple getMeanWind(int index) throws visad.VisADException, java.rmi.RemoteException
index
- The index of the mean-wind.visad.VisADException
- VisAD failure.java.rmi.RemoteException
- Java RMI failure.public visad.DataReference getMeanWindRef(int index) throws visad.VisADException, java.rmi.RemoteException
index
- The index of the mean-wind.visad.VisADException
- VisAD failure.java.rmi.RemoteException
- Java RMI failure.public void addPropertyChangeListener(java.lang.String name, java.beans.PropertyChangeListener listener)
name
- The name of the property.listener
- The PropertyChangeListener to be added.public void removePropertyChangeListener(java.lang.String name, java.beans.PropertyChangeListener listener)
name
- The name of the property.listener
- The PropertyChangeListener to be removed.public void addListSelectionListener(javax.swing.event.ListSelectionListener listener)
listener
- The listener for changes to the selected
things.public void removeListSelectionListener(javax.swing.event.ListSelectionListener listener)
listener
- The listener for changes to the selected
things.public void addListDataListener(javax.swing.event.ListDataListener listener)
listener
- The listener for changes to the underlying list
of things.public void removeListDataListener(javax.swing.event.ListDataListener listener)
listener
- The listener for changes to the underlying list
of things.protected RAOB getRAOB(int index) throws java.lang.IndexOutOfBoundsException
index
- The index of the RAOB.java.lang.IndexOutOfBoundsException
- The index is out of range.protected static visad.FlatField ensureCartesianWindProfile(visad.FlatField input) throws visad.VisADException, java.rmi.RemoteException
input
- Wind profile in cartesian or polar coordinates.visad.VisADException
- if a core VisAD failure occurs.java.rmi.RemoteException
- if a Java RMI failure occurs.protected MeanWindCell getMeanWindCell(int index) throws visad.VisADException, java.rmi.RemoteException
index
- The index of the mean-wind cell.visad.VisADException
- VisAD failure.java.rmi.RemoteException
- Java RMI failure.