CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
List of all members | Public Member Functions | Private Attributes
OtherMessageView Class Reference

#include <OtherMessage.h>

Public Member Functions

uint32 bodySize () const
 
uint32 code () const
 
uint8msgBody () const
 
 OtherMessageView (void *buf)
 
uint32 size () const
 
uint8startAddress ()
 

Private Attributes

uint8buf_
 
Headerhead_
 
uint8msg_body_start_
 

Detailed Description

Definition at line 41 of file OtherMessage.h.

Constructor & Destructor Documentation

OtherMessageView::OtherMessageView ( void *  buf)
inline

Definition at line 47 of file OtherMessage.h.

References buf_, and msg_body_start_.

47  :
48  buf_((uint8*)buf),
49  head_((Header*)buf)
50  {
51  msg_body_start_ = buf_ + sizeof(Header);
52  }
unsigned char uint8
Definition: MsgTools.h:11
uint8 * msg_body_start_
Definition: OtherMessage.h:64

Member Function Documentation

uint32 OtherMessageView::bodySize ( ) const
inline

Definition at line 58 of file OtherMessage.h.

References buf_, convert32(), head_, msg_body_start_, and Header::size_.

58  {
59  return convert32(head_->size_) - (msg_body_start_ - buf_);
60  }
char_uint32 size_
Definition: MsgHeader.h:12
uint32 convert32(char_uint32 v)
Definition: MsgTools.h:30
uint8 * msg_body_start_
Definition: OtherMessage.h:64
uint32 OtherMessageView::code ( ) const
inline

Definition at line 54 of file OtherMessage.h.

References Header::code_, and head_.

54 { return head_->code_; }
uint8 code_
Definition: MsgHeader.h:11
uint8* OtherMessageView::msgBody ( ) const
inline

Definition at line 56 of file OtherMessage.h.

References msg_body_start_.

56 {return msg_body_start_; }
uint8 * msg_body_start_
Definition: OtherMessage.h:64
uint32 OtherMessageView::size ( void  ) const
inline

Definition at line 55 of file OtherMessage.h.

References convert32(), head_, and Header::size_.

55 { return convert32(head_->size_); }
char_uint32 size_
Definition: MsgHeader.h:12
uint32 convert32(char_uint32 v)
Definition: MsgTools.h:30
uint8* OtherMessageView::startAddress ( )
inline

Definition at line 57 of file OtherMessage.h.

References buf_.

57 { return buf_; }

Member Data Documentation

uint8* OtherMessageView::buf_
private

Definition at line 63 of file OtherMessage.h.

Referenced by bodySize(), OtherMessageView(), and startAddress().

Header* OtherMessageView::head_
private

Definition at line 65 of file OtherMessage.h.

Referenced by bodySize(), code(), and size().

uint8* OtherMessageView::msg_body_start_
private

Definition at line 64 of file OtherMessage.h.

Referenced by bodySize(), msgBody(), and OtherMessageView().