|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectgov.nasa.gsfc.drl.rtstps.core.output.hdf5.RDRProduct
public class RDRProduct
Create an RDR Product in the /Data_Products and provide methods to write the Aggregate
and Granule
or it can be used
read a pre-existing RDR Product and its Aggregate, and any Granules in it. Implements the Iterator interface for this purpose.
Field Summary | |
---|---|
private Aggregate |
aggregate
|
private Collection |
collection
|
private long |
counter
|
private DataSetType |
dataSetType
|
private Granule |
firstGranule
|
private long |
granuleCount
|
private int |
hdfFile
|
private Granule |
lastGranule
|
private long |
numObjects
|
private FixedDomainDescription |
processingDomain
|
private int |
rdrGroup
|
private RDRName |
rdrName
|
private int |
rootGroup
|
private Sensor |
sensor
|
Constructor Summary | |
---|---|
RDRProduct(int hdfFile,
int rootGroup,
RDRName rdrName,
Sensor sensor,
Collection collection,
DataSetType dataSetType,
FixedDomainDescription processingDomain)
Constructor for creating the specific RDR DataProduct, note this is package private so it must be used by a another class in this package to create instances of it. |
|
RDRProduct(int dataProductHandle,
RDRName rdrName)
Constructor for reading the contents of a pre-existing RDR product. |
Method Summary | |
---|---|
void |
close()
Close the HDF group for this RDR Product |
Aggregate |
getAggregate()
Return the Aggregate associated with this RDR Product |
PDSDate |
getBeginningDateTime()
Return the beginning date of the first observation time (interpreted as the first packet with a time stamp) |
GranuleId |
getBeginningGranuleId()
Return the first GranuleId for the first Granule in this RDR Product |
long |
getBeginningOrbit()
Return the beginning orbit |
Collection |
getCollection()
Return the Collection |
DataSetType |
getDataSetType()
Return the DataSetType |
PDSDate |
getEndingDateTime()
Return the ending date of the first observation time (interpreted as the last packet with a time stamp) |
GranuleId |
getEndingGranuleId()
Return the last GranuleId for the last Granule in this RDR Product |
long |
getEndingOrbit()
Return the ending orbit |
Granule |
getGranule(int granuleNumber)
Get the granule designated by the granuleNumber. |
long |
getGranuleCount()
Return the number of granules in the RDR Product |
Sensor |
getInstrument_Short_Name()
Return the Instrument_Short_Name |
Collection |
getN_Collection_Short_Name()
Return the N_Collection_Short_Name |
DataSetType |
getN_Dataset_Type_Tag()
Return the N_Dataset_Type_Tag |
FixedDomainDescription |
getN_Processing_Domain()
Return the N_Processing_Domain |
FixedDomainDescription |
getProcessingDomain()
Return the FixedDomainDescription |
RDRName |
getRDRName()
Return the RDRName |
Sensor |
getSensor()
Return the Sensor |
boolean |
hasNext()
Return true or false if there are more items in the RDR Product to read |
CommonDataSetObject |
next()
Return either the next Granule or the Aggregate in a common object |
Aggregate |
readAggregate()
Read the aggregate off the HDF file and return the Aggregate object populate with the info held there. |
private void |
readAttributes()
Read the attributes associated with the RDR Product |
void |
remove()
|
java.lang.String |
toString()
|
void |
write(Aggregate aggregate)
Write the Aggregate associated with this RDR Product |
void |
write(Granule granule)
Write a Granule associated with this RDR Product |
private void |
writeAttributes()
Write attributes to the RDR Product |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
private int hdfFile
private int rootGroup
private int rdrGroup
private RDRName rdrName
private Sensor sensor
private Collection collection
private DataSetType dataSetType
private FixedDomainDescription processingDomain
private Aggregate aggregate
private Granule firstGranule
private Granule lastGranule
private long granuleCount
private long numObjects
private long counter
Constructor Detail |
---|
RDRProduct(int hdfFile, int rootGroup, RDRName rdrName, Sensor sensor, Collection collection, DataSetType dataSetType, FixedDomainDescription processingDomain) throws RtStpsException
DataProducts
hdfFile
- the HDF file handlerootGroup
- the "Data_Product" handlerdrName
- the RDR name of the product like "VIIRS_SCIENCE_RDR"sensor
- the sensorcollection
- the collectiondataSetType
- the dataSetTypeprocessingDomain
- the processing domain
RtStpsException
- wraps any HDF exceptionspublic RDRProduct(int dataProductHandle, RDRName rdrName) throws RtStpsException
dataProductHandle
- the "/Data_Products" handlerdrName
- the name of the RDR that should be in the /Data_Products, if not an exceptions it thrown
RtStpsException
- wraps any HDF exceptionsMethod Detail |
---|
public Aggregate readAggregate() throws RtStpsException
RtStpsException
- HDF exceptions are wrapped herepublic void write(Aggregate aggregate) throws RtStpsException
aggregate
- the Aggregate
of interest
RtStpsException
- wraps any HDF exceptionpublic void write(Granule granule) throws RtStpsException
granule
- the Granule
RtStpsException
- wraps any HDF exceptionpublic Sensor getInstrument_Short_Name()
Sensor
public Collection getN_Collection_Short_Name()
Collection
public DataSetType getN_Dataset_Type_Tag()
DataSetType
public FixedDomainDescription getN_Processing_Domain()
FixedDomainDescription
public RDRName getRDRName()
RDRName
public Sensor getSensor()
Sensor
public Collection getCollection()
Collection
public DataSetType getDataSetType()
DataSetType
public FixedDomainDescription getProcessingDomain()
FixedDomainDescription
public Aggregate getAggregate()
Aggregate
public GranuleId getBeginningGranuleId()
GranuleId
for the first Granulepublic GranuleId getEndingGranuleId()
GranuleId
for the last Granulepublic long getBeginningOrbit()
long
containing the orbitpublic long getEndingOrbit()
long
containing the orbitpublic PDSDate getBeginningDateTime()
PDSDate
containing the packet timepublic PDSDate getEndingDateTime()
PDSDate
containing the packet timepublic long getGranuleCount()
int
containing the countpublic void close() throws RtStpsException
RtStpsException
- wraps any HDF exceptionprivate void writeAttributes() throws RtStpsException
RtStpsException
- wraps any HDF exceptionprivate void readAttributes() throws RtStpsException
RtStpsException
- wraps any HDF exceptionpublic boolean hasNext()
hasNext
in interface java.util.Iterator<CommonDataSetObject>
public CommonDataSetObject next()
next
in interface java.util.Iterator<CommonDataSetObject>
CommonDataSetObject
public void remove()
remove
in interface java.util.Iterator<CommonDataSetObject>
public Granule getGranule(int granuleNumber) throws RtStpsException
granuleNumber
- the granule with that number for example XXX-SCIENCE-RDR_Gran_0 would be retrieved if zero is given here
RtStpsException
public java.lang.String toString()
toString
in class java.lang.Object
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |