|
|||||||||
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.RawApplicationPackets
gov.nasa.gsfc.drl.rtstps.core.output.hdf5.VIIRSRawApplicationPackets
public class VIIRSRawApplicationPackets
Implements an algorithm for collecting VIIRS segmented or group packets into a cohesive unit so that blocks of them maybe written atomically into the RawApplicationPackets area for a VIIRS RDR file. The goal then of this class is to keep the segments together in each RawApplicationPackets and to put several together as designated before contents are then ready to be written to the RDR file.
Field Summary | |
---|---|
private long |
currentScanNumber
|
private int |
scanCounter
|
private int |
scansPerGranule
|
private java.util.EnumSet<PacketName> |
sciPacketRange
|
private Stats |
stats
|
Fields inherited from class gov.nasa.gsfc.drl.rtstps.core.output.hdf5.RawApplicationPackets |
---|
packetPool |
Constructor Summary | |
---|---|
VIIRSRawApplicationPackets(int allRDRId,
int setNum)
Constructor which attempts to read the RawApplicationPacket entry that pre-exists. |
|
VIIRSRawApplicationPackets(int readId,
int setNum,
boolean usedByGranuleOnly)
|
|
VIIRSRawApplicationPackets(SpacecraftId satellite,
int setNum,
int scansPerGranule,
PacketPool packetPool)
Constructor for creating an nth instance of a VIIRS raw application data packet area |
|
VIIRSRawApplicationPackets(Stats stats,
SpacecraftId satellite,
int setNum,
int scansPerGranule,
PacketPool packetPool)
|
Method Summary | |
---|---|
void |
close()
Close out the RawApplicationPacket which writes the results to the HDF file and cleans up. |
private boolean |
isVIIRSSciencePacket(Packet p)
|
boolean |
notFull_OLD(Packet p)
Determine if the object will take more packets. |
boolean |
notFull(Packet p)
Determine if the object will take more packets. |
void |
put(Packet p)
The packet is stored until a packet transition which is checked in the notFull() method. |
boolean |
write(int hdfFile)
Write the collected group of packets to the designated HDF file using the handle |
Methods inherited from class gov.nasa.gsfc.drl.rtstps.core.output.hdf5.RawApplicationPackets |
---|
getAppIdCounts, getData, getDataSet, getDataSpace, getFirstTime, getLastTime, getPacketList, getPacketTypeCounts, getPacketTypes, getStaticHeader, getTimeSpan, getTotalPacketCounts, setFirstTime, setLastTime, updateAppIdCounters |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
private long currentScanNumber
private int scanCounter
private int scansPerGranule
private java.util.EnumSet<PacketName> sciPacketRange
private Stats stats
Constructor Detail |
---|
public VIIRSRawApplicationPackets(SpacecraftId satellite, int setNum, int scansPerGranule, PacketPool packetPool)
satellite
- the name of the spacecraftsetNum
- the set numberpublic VIIRSRawApplicationPackets(Stats stats, SpacecraftId satellite, int setNum, int scansPerGranule, PacketPool packetPool)
public VIIRSRawApplicationPackets(int allRDRId, int setNum) throws RtStpsException
allRDRId
- the rdrAll Groups idsetNum
- the set number of raw entry
RtStpsException
public VIIRSRawApplicationPackets(int readId, int setNum, boolean usedByGranuleOnly) throws RtStpsException
RtStpsException
Method Detail |
---|
public boolean notFull(Packet p) throws RtStpsException
notFull
in class RawApplicationPackets
p
- packet to be written
RtStpsException
public boolean notFull_OLD(Packet p) throws RtStpsException
p
- packet to be written
RtStpsException
private boolean isVIIRSSciencePacket(Packet p)
public void put(Packet p) throws RtStpsException
put
in class RawApplicationPackets
p
- VIIRS science packet to be written
RtStpsException
- the packet is not a VIIRS science packet or the scan number does not match previous packets (notFull was not called first)public boolean write(int hdfFile) throws RtStpsException
write
in class RawApplicationPackets
hdfFile
- handle to the HDF file
any
- HDF exceptions are wrapped in an RtStpsException
RtStpsException
public void close() throws RtStpsException
close
in class RawApplicationPackets
any
- HDF exceptions are wrapped in an RtStpsException
RtStpsException
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |