Документ взят из кэша поисковой машины. Адрес
оригинального документа
: http://angel.cs.msu.su/projects/system/toolsdoc/netcdf_java/ucar/netcdf/Schema.html
Дата изменения: Tue Dec 28 20:59:06 2004 Дата индексирования: Sun Apr 10 00:13:21 2016 Кодировка: |
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--ucar.netcdf.Schema
Schema collects the metadata which describes or defines a Netcdf. This is a set of ProtoVariable, the DimensionSet which is the union of the Dimensions used, and any global Attributes.
Instances are used as templates in creation of new Netcdf datasets.
Variable descriptions in form of ProtoVariable instances can be added to, overwritten, or deleted from a Schema. The associated set of global attributes may also be modified.
ProtoVariable
,
DimensionSet
,
AttributeSet
,
Netcdf
,
Collection
, Serialized FormConstructor Summary | |
Schema()
Create an empty Schema |
|
Schema(Netcdf nc)
Create a Schema initialized by an existing Netcdf. |
|
Schema(ProtoVariable[] varArray,
Attribute[] attrArray)
Create a Schema initialized by an array of ProtoVariable and an array of Attributes. |
|
Schema(Schema sc)
Copy constructor. |
Method Summary | |
boolean |
contains(java.lang.Object oo)
Tests if the argument is in this set. |
boolean |
contains(java.lang.String name)
Tests if the ProtoVariable identified by name
is in this set. |
ProtoVariable |
get(java.lang.String name)
Retrieve the variable associated with the specified name. |
Attribute |
getAttribute(java.lang.String name)
Convenience function; look up (global) Attribute by name. |
AttributeSet |
getAttributes()
Returns the set of attributes associated with this, also know as the "global" attributes. |
DimensionSet |
getDimensions()
Returns the set of dimensions associated with this, the union of those used by each of the variables. |
ProtoVariableIterator |
iterator()
Returns ProtoVariableIterator for the elements. |
ProtoVariable |
put(ProtoVariable var)
Ensures that this set contains the specified ProtoVariable. |
Attribute |
putAttribute(Attribute attr)
Convenience function; add global attribute. |
boolean |
remove(java.lang.Object oo)
Delete the ProtoVariable specified from this set. |
boolean |
remove(java.lang.String name)
Delete the ProtoVariable specified by name from this set. |
int |
size()
Returns the number of ProtoVariable objects in this set |
ProtoVariable[] |
toArray()
Returns a new Array containing the elements of this set. |
void |
toCdl(java.lang.StringBuffer buf)
Format as CDL. |
java.lang.String |
toString()
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
public Schema()
public Schema(Schema sc)
sc
- Schema to copy from. May be empty, shouldn't be null.public Schema(Netcdf nc)
This would be the first step in making a copy of a Netcdf, making a partial copy, or using and existing Netcdf basis for another.
nc
- Netcdf from which to generate the Schema.public Schema(ProtoVariable[] varArray, Attribute[] attrArray)
varArray
- ProtoVariable [] to initialize the Schema.
May be null or length 0.attrArray
- ProtoVariable [] to initialize the (global) Attributes.
May be null or length 0.Method Detail |
public int size()
public ProtoVariableIterator iterator()
ProtoVariableIterator
public ProtoVariable[] toArray()
public ProtoVariable get(java.lang.String name)
name
- String which identifies the desired variablepublic boolean contains(java.lang.String name)
name
is in this set.name
- String which identifies the desired variabletrue
if and only if this set contains
the named ProtoVariable.public boolean contains(java.lang.Object oo)
oo
- some Objecttrue
if and only if this set contains
oo
public ProtoVariable put(ProtoVariable var)
var
- the ProtoVariable to be added to this set.public boolean remove(java.lang.String name)
name
- String identifying the ProtoVariable to be removed.public boolean remove(java.lang.Object oo)
oo
- ProtoVariable to be removed.public DimensionSet getDimensions()
public AttributeSet getAttributes()
public Attribute getAttribute(java.lang.String name)
name
- the name of the attributepublic Attribute putAttribute(Attribute attr)
attr
- the Attribute to be added to this set.AttributeSet.put(ucar.netcdf.Attribute)
public void toCdl(java.lang.StringBuffer buf)
buf
- StringBuffer into which to writepublic java.lang.String toString()
toString
in class java.lang.Object
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |