RflySimSDK v3.05
RflySimSDK说明文档
载入中...
搜索中...
未找到
vrpn_SendTextMessageStreamProxy.h 文件参考

Header allowing use of a output stream-style method of sending text messages from devices. Contains the operator<< overload needed to stream into a vrpn_BaseClassUnique::SendTextMessageBoundCall, and the proxy object containing an ostringstream that executes the bound call when it's done having data streamed in to it. 更多...

#include "vrpn_BaseClass.h"
#include <sstream>
+ vrpn_SendTextMessageStreamProxy.h 的引用(Include)关系图:

浏览该文件的源代码.

class  vrpn_SendTextMessageStreamProxy
 

函数

template<typename T >
vrpn_SendTextMessageStreamProxy operator<< (vrpn_BaseClassUnique::SendTextMessageBoundCall const &call, T const &firstData)
 

详细描述

Header allowing use of a output stream-style method of sending text messages from devices. Contains the operator<< overload needed to stream into a vrpn_BaseClassUnique::SendTextMessageBoundCall, and the proxy object containing an ostringstream that executes the bound call when it's done having data streamed in to it.

This is a separate header to avoid including <sstream> in vrpn_BaseClass.h since the functionality is only used by device implementations themselves, and not even all of them. Further, since we create the stream proxy only once we've seen an operator<< (rather than as a part of the bound call), we know that if a stream proxy exists, it has a message to send.

日期
2011
作者
Ryan Pavlik rpavl.nosp@m.ik@i.nosp@m.astat.nosp@m.e.ed.nosp@m.u and abiry.nosp@m.an@r.nosp@m.yand..nosp@m.net http://academic.cleardefinition.com/ Iowa State University Virtual Reality Applications Center Human-Computer Interaction Graduate Program

函数说明

◆ operator<<()

template<typename T >
vrpn_SendTextMessageStreamProxy operator<< ( vrpn_BaseClassUnique::SendTextMessageBoundCall const & call,
T const & firstData )

Templated operator << that takes a vrpn_BaseClassUnique::SendTextMessageBoundCall on the left, and some data on the right, and uses that to initialize and return a temporary vrpn_SendTextMessageStreamProxy who will be able to accept additional streamed data before making the send_text_message call in its destructor at the end of the statement.