Package ucar.visad.display
Class LatLonLabels
java.lang.Object
ucar.visad.display.Displayable
ucar.visad.display.DisplayableData
ucar.visad.display.LineDrawing
ucar.visad.display.TextDisplayable
ucar.visad.display.LatLonLabels
Class for creating lat/lon labels
-
Nested Class Summary
Nested classes/interfaces inherited from class ucar.visad.display.DisplayableData
DisplayableData.DragAdapter -
Field Summary
Fields inherited from class ucar.visad.display.LineDrawing
COLOR, LINE_STYLE, LINE_WIDTH, POINT_SIZEFields inherited from class ucar.visad.display.DisplayableData
MANIPULABLE, renderer, VISIBLEFields inherited from class ucar.visad.display.Displayable
DISPLAY, parent, SCALAR_MAP_SET -
Constructor Summary
ConstructorsConstructorDescriptionDefault ctorLatLonLabels(String name) Create a LatLonLabels with the nameLatLonLabels(String name, ScalarType textType) Create a default objectLatLonLabels(String name, ScalarType textType, boolean isLatitude, float increment, float min, float max, float base, float[] labelLines) Create LatLonLabelsLatLonLabels(LatLonLabels that) Copy constructorLatLonLabels(ScalarType textType) Create a LatLonLabels with the type for the values -
Method Summary
Modifier and TypeMethodDescriptionprotected voidGenerate the label fieldfloatgetBase()floatGet the interval between labels (degrees)Get the label formatfloat[]floatgetMax()floatgetMin()Return the currently used ScalarType for display.booleanGet whether to use 0-360 labels for longitudebooleanvoidsetBase(float base) voidsetInterval(float interval) Set the interval between labels (degrees)voidsetLabelFormat(String labelFormat) Set the interval between labels (degrees)voidsetLabelLines(float[] labelLines) voidsetLatitude(boolean isLatitude) voidsetMax(float max) voidsetMin(float min) voidsetTextType(ScalarType textType) Set the text type to use.voidsetUse360(boolean yesorno) Set whether to use 0-360 labels for longitudevoidsetValues(float increment, float min, float max, float base, float[] labelLines) Set the values for this LatLonLabelsMethods inherited from class ucar.visad.display.TextDisplayable
cloneForDisplay, getDataRenderer, getFont, getHersheyFont, getJustification, getNumberFormat, getScreenLocked, getSphere, getTextSize, getverticalJustification, setCharacterRotation, setDisplayUnit, setFont, setJustification, setNumberFormat, setRotation, setScreenLocked, setSphere, setTextSize, setVerticalJustification, setVisibleMethods inherited from class ucar.visad.display.LineDrawing
getColor, getLineStyle, getLineWidth, getPointSize, setColor, setHSV, setHSV, setLineStyle, setLineWidth, setPointSize, setRGB, setRGB, setRGBA, setRGBAMethods inherited from class ucar.visad.display.DisplayableData
addAction, dataChange, destroy, getActive, getAnimationSet, getData, getName, hasData, hasDataObject, isManipulable, isPickable, myAddConstantMaps, myAddDataReferences, myRemoveDataReferences, removeAction, setActive, setData, setDataReference, setDragAdapter, setManipulable, setPickable, setPointMode, setUseFastRendering, showme, toStringMethods inherited from class ucar.visad.display.Displayable
addConstantMap, addConstantMaps, addDataReferences, addPropertyChangeListener, addPropertyChangeListener, addRefsInvoked, addScalarMap, addScalarMaps, applyColorUnit, applyDisplayUnit, checkUnit, combineConstantMaps, destroyDisplayable, firePropertyChange, firePropertyChange, fireScalarMapSetChange, getColorUnit, getConstantMaps, getDestroyed, getDisplay, getDisplayMaster, getDisplayUnit, getPointMode, getScalarMap, getScalarMap, getScalarMap, getScalarMapSet, getUseFastRendering, getUseTimesInAnimation, getVisible, isActive, isUnitCompatible, isVisible, logException, removeConstantMap, removeDataReferences, removePropertyChangeListener, removePropertyChangeListener, removeScalarMap, replaceScalarMap, setAdjustFlow, setColorPalette, setColorPalette, setColorUnit, setConstantPosition, setContourInfo, setDisplay, setDisplayActive, setDisplayInactive, setDisplayMaster, setOverrideAnimationSet, setOverrideAnimationSet, setParent, setRangeForColor, setRangeForColor, setScalarMapSet, setSelectedRange, setSelectedRange, setUseTimesInAnimation, toFront
-
Constructor Details
-
LatLonLabels
Default ctor- Throws:
RemoteException- Java RMI problemVisADException- Unable to create VisAD object
-
LatLonLabels
Create a LatLonLabels with the name- Parameters:
name- the name for the DataReference- Throws:
RemoteException- Java RMI problemVisADException- Unable to create VisAD object
-
LatLonLabels
Create a LatLonLabels with the type for the values- Parameters:
textType- the type for the text- Throws:
RemoteException- Java RMI problemVisADException- Unable to create VisAD object
-
LatLonLabels
Create a default object- Parameters:
name- the name for the DataReferencetextType- the type for the values- Throws:
RemoteException- Java RMI problemVisADException- Unable to create VisAD object
-
LatLonLabels
public LatLonLabels(String name, ScalarType textType, boolean isLatitude, float increment, float min, float max, float base, float[] labelLines) throws VisADException, RemoteException Create LatLonLabels- Parameters:
name- the name for the DataReferencetextType- the type for the valuesisLatitude- true if is latitudeincrement- the incrementmin- the minimum valuemax- the maximum valuebase- the base valuelabelLines- the lines to label- Throws:
RemoteException- Java RMI problemVisADException- Unable to create VisAD object
-
LatLonLabels
Copy constructor- Parameters:
that- the other LatLonLabels- Throws:
RemoteException- Java RMI problemVisADException- Problem creating VisAD object
-
-
Method Details
-
setValues
public void setValues(float increment, float min, float max, float base, float[] labelLines) throws VisADException, RemoteException Set the values for this LatLonLabels- Parameters:
increment- the incrementmin- the minimum valuemax- the maximum valuebase- the baselabelLines- the label locations- Throws:
RemoteException- Java RMI problemVisADException- Unable to create VisAD object
-
getTextType
Return the currently used ScalarType for display.- Overrides:
getTextTypein classTextDisplayable- Returns:
- the ScalarType
-
setTextType
Set the text type to use.- Overrides:
setTextTypein classTextDisplayable- Parameters:
textType- RealType or TextType to map to Display.Text- Throws:
VisADException- VisAD failure.RemoteException- Java RMI failure.
-
createLabels
Generate the label field- Throws:
RemoteException- Java RMI problemVisADException- Unable to create VisAD object
-
isLatitude
public boolean isLatitude()- Returns:
- the isLatitude
-
setLatitude
- Parameters:
isLatitude- the isLatitude to set- Throws:
RemoteException- Java RMI ExceptionVisADException- problem creating labels
-
getBase
public float getBase()- Returns:
- the base
-
setBase
- Parameters:
base- the base to set- Throws:
RemoteException- Java RMI ExceptionVisADException- problem creating labels
-
getMax
public float getMax()- Returns:
- the max
-
setMax
- Parameters:
max- the max to set- Throws:
RemoteException- Java RMI ExceptionVisADException- problem creating labels
-
getMin
public float getMin()- Returns:
- the min
-
setMin
- Parameters:
min- the min to set- Throws:
RemoteException- Java RMI ExceptionVisADException- problem creating labels
-
getInterval
public float getInterval()Get the interval between labels (degrees)- Returns:
- the increment
-
setInterval
Set the interval between labels (degrees)- Parameters:
interval- the interval to set- Throws:
RemoteException- Java RMI ExceptionVisADException- problem creating labels
-
getUse360
public boolean getUse360()Get whether to use 0-360 labels for longitude- Returns:
- true if using 0-360
-
setUse360
Set whether to use 0-360 labels for longitude- Parameters:
yesorno- true to use 0-360 labels for longitude- Throws:
RemoteException- Java RMI ExceptionVisADException- problem creating labels
-
getLabelFormat
Get the label format- Returns:
- the increment
-
setLabelFormat
Set the interval between labels (degrees)- Parameters:
labelFormat- the label format- Throws:
RemoteException- Java RMI ExceptionVisADException- problem creating labels
-
getLabelLines
public float[] getLabelLines()- Returns:
- the labelLines
-
setLabelLines
- Parameters:
labelLines- the labelLines to set- Throws:
RemoteException- Java RMI ExceptionVisADException- problem creating labels
-