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


Definition at line 516 of file packet.h.
Public Member Functions | |
| virtual void | bind () |
| TclObject * | create (int argc, const char *const *argv) |
| virtual void | export_offsets () |
Protected Member Functions | |
| void | bind_offset (int *off) |
| void | field_offset (const char *fieldname, int offset) |
| virtual int | method (int argc, const char *const *argv) |
| void | offset (int *off) |
| PacketHeaderClass (const char *classname, int hdrsize) | |
Protected Attributes | |
| int | hdrlen_ |
| int * | offset_ |
|
||||||||||||
|
Definition at line 52 of file packet.cc.
|
|
|
Definition at line 63 of file packet.cc. References export_offsets(), and hdrlen_. 00064 { 00065 TclClass::bind(); 00066 Tcl& tcl = Tcl::instance(); 00067 tcl.evalf("%s set hdrlen_ %d", classname_, hdrlen_); 00068 export_offsets(); 00069 add_method("offset"); 00070 }
Here is the call graph for this function: ![]() |
|
|
||||||||||||
|
Definition at line 58 of file packet.cc.
|
|
|
Reimplemented in ResvHeaderClass, IPHeaderClass, CommonHeaderClass, and MacHeaderClass. Definition at line 72 of file packet.cc. Referenced by bind().
|
|
||||||||||||
|
Definition at line 76 of file packet.cc. Referenced by ResvHeaderClass::export_offsets(), CommonHeaderClass::export_offsets(), MacHeaderClass::export_offsets(), and IPHeaderClass::export_offsets(). 00077 { 00078 Tcl& tcl = Tcl::instance(); 00079 tcl.evalf("%s set offset_(%s) %d", classname_, fieldname, offset); 00080 }
|
|
||||||||||||
|
Definition at line 82 of file packet.cc. References offset_. 00083 { 00084 Tcl& tcl = Tcl::instance(); 00085 int argc = ac - 2; 00086 const char*const* argv = av + 2; 00087 if (argc == 3) { 00088 if (strcmp(argv[1], "offset") == 0) { 00089 if (offset_) { 00090 *offset_ = atoi(argv[2]); 00091 return TCL_OK; 00092 } 00093 tcl.resultf("Warning: cannot set offset_ for %s", 00094 classname_); 00095 return TCL_OK; 00096 } 00097 } 00098 else if (argc == 2) { 00099 if (strcmp(argv[1], "offset") == 0) { 00100 if (offset_) { 00101 tcl.resultf("%d", *offset_); 00102 return TCL_OK; 00103 } 00104 } 00105 } 00106 return TclClass::method(ac, av); 00107 }
|
|
|
Definition at line 522 of file packet.h. References offset_. Referenced by SRHeaderClass::SRHeaderClass(). 00522 {offset_= off;}
|
|
|
Definition at line 523 of file packet.h. Referenced by bind(). |
|
|
Definition at line 524 of file packet.h. Referenced by bind_offset(), method(), and offset(). |
1.4.6