RflySimSDK v3.05
RflySimSDK说明文档
载入中...
搜索中...
未找到
vrpn_BaseClassUnique类 参考

#include <vrpn_BaseClass.h>

+ 类 vrpn_BaseClassUnique 继承关系图:
+ vrpn_BaseClassUnique 的协作图:

class  SendTextMessageBoundCall
 

Public 成员函数

vrpn_ConnectionconnectionPtr ()
 Returns a pointer to the connection this object is using
 

Public 属性

bool shutup
 

Protected 成员函数

int register_autodeleted_handler (vrpn_int32 type, vrpn_MESSAGEHANDLER handler, void *userdata, vrpn_int32 sender=vrpn_ANY_SENDER)
 
int send_text_message (const char *msg, struct timeval timestamp, vrpn_TEXT_SEVERITY type=vrpn_TEXT_NORMAL, vrpn_uint32 level=0)
 Sends a NULL-terminated text message from the device d_sender_id
 
SendTextMessageBoundCall send_text_message (vrpn_TEXT_SEVERITY type=vrpn_TEXT_NORMAL)
 
void server_mainloop (void)
 
void client_mainloop (void)
 

静态 Protected 成员函数

static int encode_text_message_to_buffer (char *buf, vrpn_TEXT_SEVERITY severity, vrpn_uint32 level, const char *msg)
 
static int decode_text_message_from_buffer (char *msg, vrpn_TEXT_SEVERITY *severity, vrpn_uint32 *level, const char *buf)
 Decodes the body of the text message from a buffer from the connection
 

Protected 属性

vrpn_Connectiond_connection
 Connection that this object talks to
 
char * d_servicename
 
vrpn_int32 d_sender_id
 part
 
vrpn_int32 d_text_message_id
 ID for text messages
 
vrpn_int32 d_ping_message_id
 Ask the server if they are there
 
vrpn_int32 d_pong_message_id
 Server telling that it is there
 

友元

class VRPN_API vrpn_TextPrinter
 
class SendTextMessageBoundCall
 

详细描述

INTERNAL class to hold members that there should only be one copy of even when a class inherits from multiple vrpn_BaseClasses because it inherits from multiple user-level classes. Note that not everything in vrpnBaseClass should be here, because (for example) the registration of types should be done for each parent class.

成员函数说明

◆ client_mainloop()

void client_mainloop ( void )
protected

Handles functions that all clients should provide in their mainloop() (warning of no server, for example) Should be called by all clients in their mainloop()

+ 这是这个函数的调用关系图:

◆ connectionPtr()

vrpn_Connection * connectionPtr ( )
inline

Returns a pointer to the connection this object is using

◆ decode_text_message_from_buffer()

static int decode_text_message_from_buffer ( char * msg,
vrpn_TEXT_SEVERITY * severity,
vrpn_uint32 * level,
const char * buf )
staticprotected

Decodes the body of the text message from a buffer from the connection

◆ encode_text_message_to_buffer()

static int encode_text_message_to_buffer ( char * buf,
vrpn_TEXT_SEVERITY severity,
vrpn_uint32 level,
const char * msg )
staticprotected

Encodes the body of the text message into a buffer, preparing for sending

◆ register_autodeleted_handler()

int register_autodeleted_handler ( vrpn_int32 type,
vrpn_MESSAGEHANDLER handler,
void * userdata,
vrpn_int32 sender = vrpn_ANY_SENDER )
protected

Registers a handler with the connection, and remembers to delete at destruction.

◆ send_text_message() [1/2]

int send_text_message ( const char * msg,
struct timeval timestamp,
vrpn_TEXT_SEVERITY type = vrpn_TEXT_NORMAL,
vrpn_uint32 level = 0 )
protected

Sends a NULL-terminated text message from the device d_sender_id

◆ send_text_message() [2/2]

SendTextMessageBoundCall send_text_message ( vrpn_TEXT_SEVERITY type = vrpn_TEXT_NORMAL)
inlineprotected

Returns an object you can stream into to send a text message from the device like send_text_message(vrpn_TEXT_WARNING) << "Value of i is: " << i; This use requires including vrpn_SendTextMessageStreamProxy.h

◆ server_mainloop()

void server_mainloop ( void )
protected

Handles functions that all servers should provide in their mainloop() (ping/pong, for example) Should be called by all servers in their mainloop()

+ 这是这个函数的调用关系图:

类成员变量说明

◆ d_connection

vrpn_Connection* d_connection
protected

Connection that this object talks to

◆ d_ping_message_id

vrpn_int32 d_ping_message_id
protected

Ask the server if they are there

◆ d_pong_message_id

vrpn_int32 d_pong_message_id
protected

Server telling that it is there

◆ d_sender_id

vrpn_int32 d_sender_id
protected

part

Sender ID registered with the connection

◆ d_servicename

char* d_servicename
protected

Name of this device, not including the connection

◆ d_text_message_id

vrpn_int32 d_text_message_id
protected

ID for text messages


该类的文档由以下文件生成: