|
w11 - cpp 0.794
Backend server for Rlink and w11
|
FIXME_docs. More...
#include <RethBuf.hpp>
Public Types | |
| typedef std::shared_ptr< RethBuf > | pbuf_t |
Public Member Functions | |
| RethBuf () | |
| Default constructor. | |
| ~RethBuf () | |
| Destructor. | |
| void | Clear () |
| FIXME_docs. | |
| void | SetSize (uint16_t size) |
| FIXME_docs. | |
| void | SetTime () |
| FIXME_docs. | |
| void | SetTime (const Rtime &time) |
| FIXME_docs. | |
| uint16_t | Size () const |
| FIXME_docs. | |
| const Rtime & | Time () const |
| FIXME_docs. | |
| const uint8_t * | Buf8 () const |
| FIXME_docs. | |
| const uint16_t * | Buf16 () const |
| FIXME_docs. | |
| const uint32_t * | Buf32 () const |
| FIXME_docs. | |
| uint8_t * | Buf8 () |
| FIXME_docs. | |
| uint16_t * | Buf16 () |
| FIXME_docs. | |
| uint32_t * | Buf32 () |
| FIXME_docs. | |
| void | SetMacDestination (uint64_t mac) |
| FIXME_docs. | |
| void | SetMacSource (uint64_t mac) |
| FIXME_docs. | |
| uint64_t | MacDestination () const |
| FIXME_docs. | |
| uint64_t | MacSource () const |
| FIXME_docs. | |
| uint16_t | Type () const |
| FIXME_docs. | |
| bool | IsMcast () const |
| FIXME_docs. | |
| bool | IsBcast () const |
| FIXME_docs. | |
| ssize_t | Read (int fd) |
| FIXME_docs. | |
| ssize_t | Write (int fd) const |
| FIXME_docs. | |
| std::string | FrameInfo () const |
| FIXME_docs. | |
| void | Dump (std::ostream &os, int ind=0, const char *text=0, int detail=0) const |
| FIXME_docs. | |
Static Public Attributes | |
| static const size_t | kMaxSize = 1514 |
| max ethernet frame size | |
| static const size_t | kMinSize = 60 |
| min ethernet frame size | |
| static const size_t | kCrcSize = 4 |
| size of ethernet CRC | |
| static const size_t | kWOffDstMac = 0 |
| offset dst mac in 16 bit wrds | |
| static const size_t | kWOffSrcMac = 3 |
| offset src mac in 16 bit wrds | |
| static const size_t | kWOffTyp = 6 |
| offset type in 16 bit wrds | |
Protected Attributes | |
| Rtime | fTime |
| uint16_t | fSize |
| uint8_t | fBuf [kMaxSize+kCrcSize] |
FIXME_docs.
Definition at line 27 of file RethBuf.hpp.
| typedef std::shared_ptr<RethBuf> Retro::RethBuf::pbuf_t |
Definition at line 29 of file RethBuf.hpp.
| Retro::RethBuf::RethBuf | ( | ) |
Default constructor.
Definition at line 50 of file RethBuf.cpp.
| Retro::RethBuf::~RethBuf | ( | ) |
Destructor.
Definition at line 57 of file RethBuf.cpp.
|
inline |
FIXME_docs.
Definition at line 24 of file RethBuf.ipp.
References fSize.
Referenced by Retro::Rw11CntlDEUNA::TxRingHandler().
|
inline |
FIXME_docs.
Definition at line 33 of file RethBuf.ipp.
References fSize.
Referenced by Retro::Rw11CntlDEUNA::RxRingHandler(), and Retro::Rw11CntlDEUNA::TxRingHandler().
|
inline |
FIXME_docs.
Definition at line 42 of file RethBuf.ipp.
References fTime, and Retro::Rtime::GetClock().
Referenced by Retro::Rw11CntlDEUNA::TxRingHandler().
|
inline |
|
inline |
FIXME_docs.
Definition at line 60 of file RethBuf.ipp.
References fSize.
Referenced by Dump(), FrameInfo(), Retro::Rw11CntlDEUNA::RxRingHandler(), Retro::Rw11VirtEthTap::Snd(), and Retro::Rw11CntlDEUNA::TxRingHandler().
|
inline |
|
inline |
FIXME_docs.
Definition at line 76 of file RethBuf.ipp.
References fBuf.
Referenced by Dump(), Retro::Rw11CntlDEUNA::RxRingHandler(), and Retro::Rw11CntlDEUNA::TxRingHandler().
|
inline |
FIXME_docs.
Definition at line 84 of file RethBuf.ipp.
References fBuf.
Referenced by IsBcast(), MacDestination(), MacSource(), Retro::Rw11CntlDEUNA::RxRingHandler(), SetMacDestination(), SetMacSource(), Retro::Rw11CntlDEUNA::TxRingHandler(), and Type().
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
FIXME_docs.
Definition at line 124 of file RethBuf.ipp.
References Buf16(), kWOffDstMac, and Retro::RethTools::Mac2WList().
|
inline |
FIXME_docs.
Definition at line 133 of file RethBuf.ipp.
References Buf16(), kWOffSrcMac, and Retro::RethTools::Mac2WList().
Referenced by Retro::Rw11CntlDEUNA::TxRingHandler().
|
inline |
FIXME_docs.
Definition at line 142 of file RethBuf.ipp.
References Buf16(), kWOffDstMac, and Retro::RethTools::WList2Mac().
Referenced by FrameInfo(), and Retro::Rw11CntlDEUNA::TxRingHandler().
|
inline |
FIXME_docs.
Definition at line 150 of file RethBuf.ipp.
References Buf16(), kWOffSrcMac, and Retro::RethTools::WList2Mac().
Referenced by FrameInfo().
| uint16_t Retro::RethBuf::Type | ( | ) | const |
FIXME_docs.
Definition at line 63 of file RethBuf.cpp.
References Buf16(), and kWOffTyp.
Referenced by FrameInfo().
|
inline |
FIXME_docs.
Definition at line 158 of file RethBuf.ipp.
References fBuf.
Referenced by Retro::Rw11CntlDEUNA::RxRingHandler(), and Retro::Rw11CntlDEUNA::TxRingHandler().
|
inline |
FIXME_docs.
Definition at line 166 of file RethBuf.ipp.
References Buf16().
Referenced by Retro::Rw11CntlDEUNA::RxRingHandler(), and Retro::Rw11CntlDEUNA::TxRingHandler().
| ssize_t Retro::RethBuf::Read | ( | int | fd | ) |
| ssize_t Retro::RethBuf::Write | ( | int | fd | ) | const |
| std::string Retro::RethBuf::FrameInfo | ( | ) | const |
FIXME_docs.
Definition at line 89 of file RethBuf.cpp.
References Retro::RethTools::Mac2String(), MacDestination(), MacSource(), Retro::RosPrintf(), Size(), and Type().
Referenced by Dump(), and Retro::Rw11CntlDEUNA::LogFrameInfo().
| void Retro::RethBuf::Dump | ( | std::ostream & | os, |
| int | ind = 0, |
||
| const char * | text = 0, |
||
| int | detail = 0 |
||
| ) | const |
FIXME_docs.
Definition at line 102 of file RethBuf.cpp.
References Buf8(), FrameInfo(), fTime, Retro::RosPrintf(), and Size().
Referenced by Retro::Rw11CntlDEUNA::Dump(), and Retro::Rw11CntlDEUNA::TxRingHandler().
|
static |
max ethernet frame size
Definition at line 68 of file RethBuf.hpp.
Referenced by Read(), and Retro::Rw11CntlDEUNA::TxRingHandler().
|
static |
min ethernet frame size
Definition at line 69 of file RethBuf.hpp.
Referenced by Retro::Rw11CntlDEUNA::RxRingHandler(), and Retro::Rw11CntlDEUNA::TxRingHandler().
|
static |
size of ethernet CRC
Definition at line 70 of file RethBuf.hpp.
Referenced by Retro::Rw11CntlDEUNA::RxRingHandler().
|
static |
offset dst mac in 16 bit wrds
Definition at line 71 of file RethBuf.hpp.
Referenced by MacDestination(), and SetMacDestination().
|
static |
offset src mac in 16 bit wrds
Definition at line 72 of file RethBuf.hpp.
Referenced by MacSource(), and SetMacSource().
|
static |
|
protected |
Definition at line 76 of file RethBuf.hpp.
|
protected |