gov.nasa.gsfc.drl.rtstps.core.output.hdf5
Class RDR

java.lang.Object
  extended by gov.nasa.gsfc.drl.rtstps.core.output.hdf5.RDR
Direct Known Subclasses:
ATMS_RDR, BasicRDR, CRIS_RDR, SpacecraftDiaryRDR, SpacecraftDiaryRDR2, VIIRS_RDR

public abstract class RDR
extends java.lang.Object

The basic guts of building the RDR HDF infrastructure. This class should be overridden for each specific RDR sensor including the Spacecraft Diary in use.


Field Summary
private  int depth
           
static java.lang.String DocumentName
           
private  java.util.List<Granule> granuleList
           
private  PacketPool packetPool
           
private  java.util.LinkedList<RawApplicationPackets> raps
           
private  RDRAll rdrAll
           
private  RDRName rdrName
           
private  RDRProduct rdrProduct
           
private  int setNum
           
 
Constructor Summary
RDR()
          Deprecated. 
RDR(Stats stats, RDRName rdrName, AllData allData, DataProducts dataProds, FixedDomainDescription drl)
          Build an RDR around the name, and other items
 
Method Summary
 void close()
          Finish up any local cleanup and close the rdrAll and rdrProduct...
protected  void createGranule(RawApplicationPackets rap)
          Used to create the granule associated with the RawApplicationPacket structure, this method should be sufficient for most science sensors except for the Spacecraft Diary which is unique and has its own implementation.
protected abstract  RawApplicationPackets createRawApplicationPackets(RDRName rdrName)
          Override this in the specific specific sensor RawApplicationPacket class
private  void finish()
          Build the Aggregate and other wise clean up ...
 java.util.List<RawApplicationPackets> getAllRawApplicationPackets()
          Return a list of RawApplicationsPacket objects that have been created in processing
 RawApplicationPackets getCurrentRawApplicationPackets()
          Get the first (active) RawApplicationsPacket that have been created in processing
(package private)  int getDepth()
          The current depth...
(package private)  java.util.List<Granule> getGranules()
          Deprecated. 
(package private)  PacketPool getPacketPool()
           
 ProductIdentifiers getProductId()
          Get the product identifier
(package private)  java.util.LinkedList<RawApplicationPackets> getRaps()
          The list of RawApplicationPackets as LinkedList
 RDRAll getRDRAll()
          Get the RDRAll object
 RDRName getRDRName()
          Get the RDR name
 RDRProduct getRDRProduct()
          Get the RDRProduct
(package private)  int getSetNum()
          Get the current set number
(package private)  void nextSetNum()
          Increment the set number
 void put(Packet p)
          Put a packet into the RDR.
(package private)  void setDepth(int depth)
          The counting depth of RawApplicationPacket, this is associated with an old implementation and probably should be deprecated
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

rdrName

private RDRName rdrName

rdrAll

private RDRAll rdrAll

rdrProduct

private RDRProduct rdrProduct

raps

private java.util.LinkedList<RawApplicationPackets> raps

depth

private int depth

setNum

private int setNum

granuleList

private java.util.List<Granule> granuleList

DocumentName

public static java.lang.String DocumentName

packetPool

private PacketPool packetPool
Constructor Detail

RDR

@Deprecated
RDR()
Deprecated. 

Only used by SpacecraftDiary RDR


RDR

public RDR(Stats stats,
           RDRName rdrName,
           AllData allData,
           DataProducts dataProds,
           FixedDomainDescription drl)
    throws RtStpsException
Build an RDR around the name, and other items

Parameters:
rdrName - the RDR name
allData - the AllData object
dataProds - the DataProducts object
drl - the DRL domain
Throws:
RtStpsException - wraps various HDF exceptions
Method Detail

put

public void put(Packet p)
         throws RtStpsException
Put a packet into the RDR.

Parameters:
p - the Packet of interest
Throws:
RtStpsException - wraps any HDF or other exceptions

createRawApplicationPackets

protected abstract RawApplicationPackets createRawApplicationPackets(RDRName rdrName)
Override this in the specific specific sensor RawApplicationPacket class

Parameters:
rdrName - the RDE name
Returns:
the specific RawApplicationPackets for the sensor in the super class

getRDRName

public RDRName getRDRName()
Get the RDR name

Returns:
the RDRName

getRDRAll

public RDRAll getRDRAll()
Get the RDRAll object

Returns:
the RDRAll object

getRDRProduct

public RDRProduct getRDRProduct()
Get the RDRProduct

Returns:
the RDRProduct

getAllRawApplicationPackets

public java.util.List<RawApplicationPackets> getAllRawApplicationPackets()
Return a list of RawApplicationsPacket objects that have been created in processing

Returns:
the List of RawApplicationPackets

getCurrentRawApplicationPackets

public RawApplicationPackets getCurrentRawApplicationPackets()
Get the first (active) RawApplicationsPacket that have been created in processing

Returns:
the first RawApplicationPackets

close

public void close()
           throws RtStpsException
Finish up any local cleanup and close the rdrAll and rdrProduct...

Throws:
RtStpsException - wraps any HDF or other exceptions

createGranule

protected void createGranule(RawApplicationPackets rap)
                      throws RtStpsException
Used to create the granule associated with the RawApplicationPacket structure, this method should be sufficient for most science sensors except for the Spacecraft Diary which is unique and has its own implementation.

Parameters:
rap - the RawApplicationPackets associated with a particular sensor
Throws:
RtStpsException - wraps any HDF or other exceptions

finish

private void finish()
             throws RtStpsException
Build the Aggregate and other wise clean up ...

Throws:
RtStpsException

getProductId

public ProductIdentifiers getProductId()
Get the product identifier

Returns:
the ProductIdentifiers

getRaps

final java.util.LinkedList<RawApplicationPackets> getRaps()
The list of RawApplicationPackets as LinkedList

Returns:
LinkedList of RawApplicationPackets

getGranules

@Deprecated
final java.util.List<Granule> getGranules()
Deprecated. 

A list of the created granule objects

Returns:
List of Granule

nextSetNum

final void nextSetNum()
Increment the set number


getSetNum

final int getSetNum()
Get the current set number

Returns:
the set number in an int

setDepth

final void setDepth(int depth)
The counting depth of RawApplicationPacket, this is associated with an old implementation and probably should be deprecated

Parameters:
depth - the new depth

getDepth

final int getDepth()
The current depth...

Returns:
the depth in an int

getPacketPool

final PacketPool getPacketPool()