|
|||||||||
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.CopyPacket
public class CopyPacket
Utility class to make a deep copy of a Packet
. This class is needed to specifically support this package
being included in the RT-STPS processing chain because RT-STPS caches its outgoing packets on a local list
and cannot guarantee they won't be used once the main processing loop has been iterated over. Since several
part of this package hold onto packets in internal lists, a copy is needed in order for this to work within
RT-STPS. If this module is stand-alone, then a copy of input packet is not necessary as long as any packet
reader does not assume it can reuse a packet object it creates.
In order to have some efficiency the Packet is taken from a Packet pool. The pool creates new Packets if
there are not any. When the packet is not longer being used, the deep copied packet this class returns
should be put back on the PacketPool
.
Constructor Summary | |
---|---|
CopyPacket()
|
Method Summary | |
---|---|
static Packet |
deep(Packet source,
PacketPool packetPool)
Deep copy an input Packet |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public CopyPacket()
Method Detail |
---|
public static Packet deep(Packet source, PacketPool packetPool) throws RtStpsException
source
- an input Packet
RtStpsException
- an exception from the PacketPool
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |