#include <packet.h>
Inheritance diagram for Packet:


Definition at line 337 of file packet.h.
Public Member Functions | |
| unsigned char * | access (int off) const |
| unsigned char * | accessdata () const |
| void | allocdata (int) |
| unsigned char *const | bits () |
| Packet * | copy () const |
| int | datalen () const |
| void | initdata () |
| Packet () | |
| int & | ref_count () |
| Packet * | refcopy () |
| void | setdata (AppData *d) |
| AppData * | userdata () const |
Static Public Member Functions | |
| static Packet * | alloc (int) |
| static Packet * | alloc () |
| static void | dump_header (Packet *p, int offset, int length) |
| static void | free (Packet *) |
Data Fields | |
| Handler * | handler_ |
| u_int8_t | incoming |
| Packet * | next_ |
| Event * | prev_ |
| double | time_ |
| PacketStamp | txinfo_ |
| scheduler_uid_t | uid_ |
Static Public Attributes | |
| static int | hdrlen_ = 0 |
Protected Attributes | |
| int | ref_count_ |
Static Protected Attributes | |
| static Packet * | free_ |
Static Private Member Functions | |
| static void | init (Packet *) |
Private Attributes | |
| unsigned char * | bits_ |
| AppData * | data_ |
| bool | fflag_ |
|
|
Definition at line 352 of file packet.h. 00352 : bits_(0), data_(0), ref_count_(0), next_(0) { }
|
|
|
|
|
Definition at line 577 of file packet.h. References alloc(), and allocdata(). 00578 { 00579 Packet* p = alloc(); 00580 if (n > 0) 00581 p->allocdata(n); 00582 return (p); 00583 }
Here is the call graph for this function: ![]() |
|
|
|
Definition at line 568 of file packet.h. References abort(), and data_. Referenced by alloc(), Agent::allocpkt(), SensorQueryAgent::generate_query(), LandmarkAgent::makeUpdate(), and GAFAgent::makeUpDiscoveryMsg(). 00569 { 00570 assert(data_ == 0); 00571 data_ = new PacketData(n); 00572 if (data_ == 0) 00573 abort(); 00574 }
Here is the call graph for this function: ![]() |
|
|
Definition at line 353 of file packet.h. References bits_. Referenced by copy(), RLM_Receiver::recv(), and RLM_Sender::sendpkt(). 00353 { return (bits_); }
|
|
|
|
Definition at line 386 of file packet.h. References data_, and AppData::size(). Referenced by NatAgent::nat(), and RapAgent::recv().
Here is the call graph for this function: ![]() |
|
||||||||||||||||
|
Definition at line 623 of file packet.h. References bits_, HDR_CMN, hdrlen_, and hdr_cmn::uid(). Referenced by imepAgent::imep_dump_header(). 00624 { 00625 assert(offset + length <= p->hdrlen_); 00626 struct hdr_cmn *ch = HDR_CMN(p); 00627 00628 fprintf(stderr, "\nPacket ID: %d\n", ch->uid()); 00629 00630 for(int i = 0; i < length ; i+=16) { 00631 fprintf(stderr, "%02x %02x %02x %02x %02x %02x %02x %02x %02x %02x %02x %02x %02x %02x %02x %02x\n", 00632 p->bits_[offset + i], p->bits_[offset + i + 1], 00633 p->bits_[offset + i + 2], p->bits_[offset + i + 3], 00634 p->bits_[offset + i + 4], p->bits_[offset + i + 5], 00635 p->bits_[offset + i + 6], p->bits_[offset + i + 7], 00636 p->bits_[offset + i + 8], p->bits_[offset + i + 9], 00637 p->bits_[offset + i + 10], p->bits_[offset + i + 11], 00638 p->bits_[offset + i + 12], p->bits_[offset + i + 13], 00639 p->bits_[offset + i + 14], p->bits_[offset + i + 15]); 00640 } 00641 }
Here is the call graph for this function: ![]() |
|
|
|
Definition at line 532 of file packet.h. References bits_, and hdrlen_. Referenced by alloc(), and free().
|
|
|
Definition at line 361 of file packet.h. References data_. 00361 { data_ = 0;}
|
|
|
Definition at line 356 of file packet.h. References ref_count_. 00356 { return (ref_count_); }
|
|
|
Definition at line 355 of file packet.h. References ref_count_. Referenced by Mac802_15_4::IFSHandler(), Mac802_15_4::MCPS_DATA_indication(), SessionHelper::recv(), and NoDupChannel::sendUp(). 00355 { ++ref_count_; return this; }
|
|
|
Definition at line 381 of file packet.h. References data_. Referenced by HttpInvalAgent::send(), UdpAgent::sendmsg(), MessagePassingAgent::sendmsg(), SctpAgent::SendPacket(), and MessagePassingAgent::sendto().
|
|
|
Definition at line 378 of file packet.h. References data_. Referenced by UdpAgent::recv(), TPAgent::recv(), SctpAgent::recv(), RapAgent::recv(), MessagePassingAgent::recv(), and HttpInvalAgent::recv(). 00378 { 00379 return data_; 00380 }
|
|
|
Definition at line 339 of file packet.h. Referenced by access(), alloc(), bits(), copy(), dump_header(), and init(). |
|
|
Definition at line 342 of file packet.h. Referenced by accessdata(), alloc(), allocdata(), copy(), datalen(), free(), initdata(), setdata(), and userdata(). |
|
|
|
|
|
|
|
|
Definition at line 60 of file scheduler.h. Referenced by Scheduler::dispatch(), Scheduler::dumpq(), and Scheduler::schedule(). |
|
|
Definition at line 350 of file packet.h. Referenced by alloc(), copy(), dump_header(), init(), and PacketHeaderManager::PacketHeaderManager(). |
|
|
|
|
|
|
Definition at line 59 of file scheduler.h. Referenced by CalendarScheduler::cancel(), CalendarScheduler::deque(), CalendarScheduler::insert(), and CalendarScheduler::insert2(). |
|
|
Definition at line 347 of file packet.h. Referenced by free(), ref_count(), and refcopy(). |
|
|
|
Definition at line 395 of file packet.h. Referenced by copy(), Phy802_15_4::measureLinkQ(), Phy802_15_4::recv(), Phy802_15_4::recvOverHandler(), WirelessPhy::sendDown(), and WirelessPhy::sendUp(). |
|
1.4.6