|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectucar.nc2.Variable
ucar.nc2.Structure
ucar.nc2.dataset.StructureDS
public class StructureDS
An "enhanced" Structure.
NetcdfDataset
Nested Class Summary |
---|
Nested classes/interfaces inherited from class ucar.nc2.Variable |
---|
Variable.Cache |
Field Summary | |
---|---|
protected Structure |
orgVar
|
Fields inherited from class ucar.nc2.Structure |
---|
defaultBufferSize, isSubset, memberHash, members |
Fields inherited from class ucar.nc2.Variable |
---|
attributes, cache, dataType, debugCaching, defaultCoordsSizeToCache, defaultSizeToCache, dimensions, elementSize, group, hashCode, isMetadata, isVariableLength, ncfile, parent, proxyReader, shape, shapeAsSection, shortName, sizeToCache, spiObject |
Constructor Summary | |
---|---|
|
StructureDS(Group g,
Structure orgVar)
Create a StructureDS thats wraps a Structure |
|
StructureDS(NetcdfDataset ds,
Group group,
Structure parentStructure,
String shortName,
String dims,
String units,
String desc)
Constructor when theres no underlying variable. |
|
StructureDS(NetcdfDataset ds,
Group group,
Structure parent,
String shortName,
Structure orgVar)
Wrap the given Structure, making it into a StructureDS. |
protected |
StructureDS(NetcdfFile ncfile,
Group group,
String shortName)
|
Method Summary | |
---|---|
void |
addCoordinateSystem(CoordinateSystem p0)
Add a CoordinateSystem to the dataset. |
void |
clearCoordinateSystems()
clear previous coordinate systems. |
protected ArrayStructure |
convert(Array data,
Section section)
|
protected StructureData |
convert(StructureData sdata,
int recno)
|
protected Variable |
copy()
|
void |
enhance(Set<NetcdfDataset.Enhance> mode)
DO NOT USE DIRECTLY. |
List<CoordinateSystem> |
getCoordinateSystems()
Get the list of Coordinate Systems for this Variable. |
String |
getDescription()
Get the description of the Variable. |
DataType |
getOriginalDataType()
When this wraps another Variable, get the original Variable's DataType. |
String |
getOriginalName()
When this wraps another Variable, get the original Variable's DataType. |
Variable |
getOriginalVariable()
A StructureDS may wrap another Structure. |
String |
getUnitsString()
Get the Unit String for the Variable. |
Array |
reallyRead(Variable client,
CancelTask cancelTask)
public by accident, do not call directly. |
Array |
reallyRead(Variable client,
Section section,
CancelTask cancelTask)
public by accident, do not call directly. |
void |
removeCoordinateSystem(CoordinateSystem p0)
Remove a CoordinateSystem from the dataset. |
Structure |
select(List<String> memberNames)
Create a subset of the Structure consisting only of the given member variables |
String |
setName(String newName)
Set the short name, converting to valid CDM object name if needed. |
void |
setOriginalVariable(Variable orgVar)
Set the Structure to wrap. |
void |
setUnitsString(String units)
Set the Unit String for this Variable. |
Methods inherited from class java.lang.Object |
---|
finalize, getClass, notify, notifyAll, wait, wait, wait |
Methods inherited from interface ucar.nc2.VariableSimpleIF |
---|
getName |
Methods inherited from interface java.lang.Comparable |
---|
compareTo |
Field Detail |
---|
protected Structure orgVar
Constructor Detail |
---|
protected StructureDS(NetcdfFile ncfile, Group group, String shortName)
public StructureDS(NetcdfDataset ds, Group group, Structure parentStructure, String shortName, String dims, String units, String desc)
ds
- the containing NetcdfDataset.group
- the containing group; if null, use rootGroupparentStructure
- parent Structure, may be nullshortName
- variable shortName, must be unique within the Groupdims
- list of dimension names, space delimitedunits
- unit string (may be null)desc
- description (may be null)public StructureDS(Group g, Structure orgVar)
g
- parent grouporgVar
- original Structurepublic StructureDS(NetcdfDataset ds, Group group, Structure parent, String shortName, Structure orgVar)
ds
- the containing NetcdfDataset.group
- the containing group; may not be nullparent
- parent Structure, may be nullshortName
- variable shortName, must be unique within the GrouporgVar
- the original Structure to wrap.Method Detail |
---|
protected Variable copy()
copy
in class Structure
public Structure select(List<String> memberNames)
Structure
select
in class Structure
memberNames
- list of Variable names, already a member
public Variable getOriginalVariable()
getOriginalVariable
in interface VariableEnhanced
public void setOriginalVariable(Variable orgVar)
setOriginalVariable
in interface VariableEnhanced
orgVar
- original Variable, must be a Structurepublic DataType getOriginalDataType()
public String getOriginalName()
getOriginalName
in interface VariableEnhanced
public String setName(String newName)
Variable
setName
in class Variable
newName
- set to this value
public Array reallyRead(Variable client, CancelTask cancelTask) throws IOException
Variable
reallyRead
in interface ProxyReader
reallyRead
in class Variable
client
- the client VariablecancelTask
- user may cancel
IOException
- on errorpublic Array reallyRead(Variable client, Section section, CancelTask cancelTask) throws IOException, InvalidRangeException
Variable
reallyRead
in interface ProxyReader
reallyRead
in class Variable
client
- the client Variablesection
- the section of data to read.cancelTask
- user may cancel
IOException
- on error
InvalidRangeException
- if section has incorrect rank or illegal shape.protected ArrayStructure convert(Array data, Section section) throws IOException
IOException
protected StructureData convert(StructureData sdata, int recno) throws IOException
IOException
public void enhance(Set<NetcdfDataset.Enhance> mode)
enhance
in interface VariableEnhanced
public void clearCoordinateSystems()
VariableEnhanced
clearCoordinateSystems
in interface VariableEnhanced
public void addCoordinateSystem(CoordinateSystem p0)
Enhancements
addCoordinateSystem
in interface Enhancements
p0
- add this Coordinate Systempublic void removeCoordinateSystem(CoordinateSystem p0)
Enhancements
removeCoordinateSystem
in interface Enhancements
p0
- remove this coordinate systempublic List<CoordinateSystem> getCoordinateSystems()
Enhancements
getCoordinateSystems
in interface Enhancements
public String getDescription()
Variable
getDescription
in interface Enhancements
getDescription
in interface VariableIF
getDescription
in interface VariableSimpleIF
getDescription
in class Variable
public String getUnitsString()
Variable
getUnitsString
in interface Enhancements
getUnitsString
in interface VariableIF
getUnitsString
in interface VariableSimpleIF
getUnitsString
in class Variable
public void setUnitsString(String units)
VariableEnhanced
setUnitsString
in interface VariableEnhanced
units
- unit string
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |