visad
Class DataReferenceImpl

java.lang.Object
  extended by visad.ThingReferenceImpl
      extended by visad.DataReferenceImpl
All Implemented Interfaces:
DataReference, ThingReference

public class DataReferenceImpl
extends ThingReferenceImpl
implements DataReference

DataReferenceImpl is a local implementation of DataReference.

DataReferenceImpl is not Serializable and should not be copied between JVMs.


Constructor Summary
DataReferenceImpl(java.lang.String name)
          Constructs from a name for the instance.
 
Method Summary
 boolean equals(java.lang.Object obj)
           
 Data getData()
          get referenced Data object, or null if none
 MathType getType()
          get MathType of referenced Data object, or null if none; this is more efficient than getData().getType() for RemoteDataReferences
 void setData(Data d)
          Sets the data object to which this instance refers.
 java.lang.String toString()
           
 
Methods inherited from class visad.ThingReferenceImpl
acknowledgeThingChanged, adaptedAcknowledgeThingChanged, adaptedPeekThingChanged, addThingChangedListener, findThingChangedLink, getName, getThing, getTick, incTick, peekThingChanged, removeThingChangedListener, setThing
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface visad.ThingReference
acknowledgeThingChanged, addThingChangedListener, getName, getThing, getTick, incTick, peekThingChanged, removeThingChangedListener, setThing
 

Constructor Detail

DataReferenceImpl

public DataReferenceImpl(java.lang.String name)
                  throws VisADException
Constructs from a name for the instance.

Parameters:
name - The name for this instance.
Throws:
VisADException - if the name is null.
Method Detail

getData

public Data getData()
Description copied from interface: DataReference
get referenced Data object, or null if none

Specified by:
getData in interface DataReference

getType

public MathType getType()
                 throws VisADException,
                        java.rmi.RemoteException
Description copied from interface: DataReference
get MathType of referenced Data object, or null if none; this is more efficient than getData().getType() for RemoteDataReferences

Specified by:
getType in interface DataReference
Throws:
VisADException
java.rmi.RemoteException

setData

public void setData(Data d)
             throws VisADException,
                    java.rmi.RemoteException
Sets the data object to which this instance refers.

Specified by:
setData in interface DataReference
Parameters:
d - The data object.
Throws:
ReferenceException - if the data object is null.
RemoteVisADException - if the data object is a RemoteData.
VisADException
java.rmi.RemoteException

equals

public boolean equals(java.lang.Object obj)
Overrides:
equals in class ThingReferenceImpl

toString

public java.lang.String toString()
Overrides:
toString in class ThingReferenceImpl