F´ Flight Software - C/C++ Documentation  devel
A framework for building embedded system applications to NASA flight quality standards.
Fw::FilePacket Class Reference

A file packet. More...

#include <Fw/FilePacket/FilePacket.hpp>

Classes

class  CancelPacket
 The type of a cancel packet. More...
 
class  DataPacket
 The type of a data packet. More...
 
class  EndPacket
 The type of an end packet. More...
 
class  Header
 The type of a packet header. More...
 
class  PathName
 The type of a path name. More...
 
struct  StartPacket
 The type of a start packet. More...
 

Public Types

enum  Type {
  T_START = 0 , T_DATA = 1 , T_END = 2 , T_CANCEL = 3 ,
  T_NONE = 255
}
 Packet type. More...
 

Public Member Functions

 FilePacket ()
 
SerializeStatus fromBuffer (const Buffer &buffer)
 
const HeaderasHeader () const
 
const StartPacketasStartPacket () const
 
const DataPacketasDataPacket () const
 
const EndPacketasEndPacket () const
 
const CancelPacketasCancelPacket () const
 
void fromStartPacket (const StartPacket &startPacket)
 
void fromDataPacket (const DataPacket &dataPacket)
 
void fromEndPacket (const EndPacket &endPacket)
 
void fromCancelPacket (const CancelPacket &cancelPacket)
 
U32 bufferSize () const
 
SerializeStatus toBuffer (Buffer &buffer) const
 

Detailed Description

A file packet.

Definition at line 27 of file FilePacket.hpp.

Member Enumeration Documentation

◆ Type

Packet type.

Enumerator
T_START 
T_DATA 
T_END 
T_CANCEL 
T_NONE 

Definition at line 36 of file FilePacket.hpp.

Constructor & Destructor Documentation

◆ FilePacket()

Fw::FilePacket::FilePacket ( )
inline

Definition at line 357 of file FilePacket.hpp.

Member Function Documentation

◆ asCancelPacket()

const FilePacket::CancelPacket & Fw::FilePacket::asCancelPacket ( ) const

Get this as a CancelPacket

Definition at line 61 of file FilePacket.cpp.

◆ asDataPacket()

const FilePacket::DataPacket & Fw::FilePacket::asDataPacket ( ) const

Get this as a DataPacket

Definition at line 47 of file FilePacket.cpp.

◆ asEndPacket()

const FilePacket::EndPacket & Fw::FilePacket::asEndPacket ( ) const

Get this as an EndPacket

Definition at line 54 of file FilePacket.cpp.

◆ asHeader()

const FilePacket::Header & Fw::FilePacket::asHeader ( ) const

Get this as a Header

Definition at line 34 of file FilePacket.cpp.

◆ asStartPacket()

const FilePacket::StartPacket & Fw::FilePacket::asStartPacket ( ) const

Get this as a StartPacket

Definition at line 40 of file FilePacket.cpp.

◆ bufferSize()

U32 Fw::FilePacket::bufferSize ( ) const

Get the buffer size needed to hold this FilePacket

Definition at line 96 of file FilePacket.cpp.

◆ fromBuffer()

SerializeStatus Fw::FilePacket::fromBuffer ( const Buffer buffer)

Initialize this from a Buffer

Definition at line 22 of file FilePacket.cpp.

◆ fromCancelPacket()

void Fw::FilePacket::fromCancelPacket ( const CancelPacket cancelPacket)

Initialize this with a CancelPacket

Definition at line 89 of file FilePacket.cpp.

◆ fromDataPacket()

void Fw::FilePacket::fromDataPacket ( const DataPacket dataPacket)

Initialize this with a DataPacket

Definition at line 75 of file FilePacket.cpp.

◆ fromEndPacket()

void Fw::FilePacket::fromEndPacket ( const EndPacket endPacket)

Initialize this with an EndPacket

Definition at line 82 of file FilePacket.cpp.

◆ fromStartPacket()

void Fw::FilePacket::fromStartPacket ( const StartPacket startPacket)

Initialize this with a StartPacket

Definition at line 68 of file FilePacket.cpp.

◆ toBuffer()

SerializeStatus Fw::FilePacket::toBuffer ( Buffer buffer) const

Convert this FilePacket to a Buffer

Definition at line 116 of file FilePacket.cpp.


The documentation for this class was generated from the following files: