Logo
中文版
详情联系: neusar-support@reachauto.com
ara::internal::libadaptiveplatform::NamedPipeClient类 参考

管道客户端类 更多...

#include <named_pipe_client.h>

ara::internal::libadaptiveplatform::NamedPipeClient 的协作图:
Collaboration graph

Public 成员函数

 NamedPipeClient ()=default
 NamedPipeClient的默认构造函数 更多...
 
 NamedPipeClient (const std::string &pathname, size_t const message_size, size_t const message_count, const bool block=true)
 NamedPipeClient的有参构造函数 更多...
 
 ~NamedPipeClient ()
 NamedPipeClient的析构函数 更多...
 
void Connect (const std::string &pathname)
 客户端连接到管道句柄 更多...
 
bool Clear () const
 清理读管道中残留的数据 更多...
 
template<typename DestinationType >
bool Receive (DestinationType &message, const int64_t timeout_ms=0) const
 客户端接收回复信息 更多...
 
template<typename SourceType >
bool Send (const SourceType &message) const
 客户端发送请求信息 更多...
 

Private 属性

std::unique_ptr< NamedOutputPipeserver_pipe_
 客户端管道句柄 @uptrace{N/A} 更多...
 
std::unique_ptr< NamedInputPipeclient_pipe_
 服务端管道句柄 @uptrace{N/A} 更多...
 

详细描述

管道客户端类

Swsid
N/A
符合标准
no
非标原因
N/A
种类
class
符号
NamedPipeClient
范围
namespace ara::internal::libadaptiveplatform
基类
N/A
分类
ara
头文件
ara/exec/named_pipe_client.h
注解
N/A
模板参数
N/A@uptrace{SWS_EM_02030,SWS_EM_02211,SWS_EM_02275}

在文件 第 行定义.

构造及析构函数说明

◆ NamedPipeClient() [1/2]

ara::internal::libadaptiveplatform::NamedPipeClient::NamedPipeClient ( )
default

NamedPipeClient的默认构造函数

模板参数
N/A
参数
[in]N/A
[out]N/A
[in,out]N/A
返回
N/A
注解
N/A
异常
N/A
Swsid
N/A
符合标准
no
非标原因
N/A
种类
function
可见
public
线程安全
N/A
Fireandforget
N/A
错误
N/A
头文件
ara/exec/named_pipe_client.h
异常安全
noexcept
分类
ara @uptrace{N/A}
范围
namespace ara::internal::libadaptiveplatform::NamedPipeClient

◆ NamedPipeClient() [2/2]

ara::internal::libadaptiveplatform::NamedPipeClient::NamedPipeClient ( const std::string &  pathname,
size_t const  message_size,
size_t const  message_count,
const bool  block = true 
)
inline

NamedPipeClient的有参构造函数

模板参数
N/A
参数
[in]pathname:管道名
[in]message_size:写入信息的长度
[in]message_count:写入信息的尺寸
[out]N/A
[in,out]N/A
返回
N/A
注解
N/A
异常
OpenPipeException
Swsid
N/A
符合标准
no
非标原因
N/A
种类
function
可见
public
线程安全
N/A
Fireandforget
N/A
错误
N/A
头文件
ara/exec/named_pipe_client.h
异常安全
no
分类
ara @uptrace{N/A}
范围
namespace ara::internal::libadaptiveplatform::NamedPipeClient

在文件 第 行定义.

◆ ~NamedPipeClient()

ara::internal::libadaptiveplatform::NamedPipeClient::~NamedPipeClient ( )

NamedPipeClient的析构函数

Function Implementation

模板参数
N/A
参数
[in]N/A
[out]N/A
[in,out]N/A
返回
N/A
注解
N/A
异常
N/A
Swsid
N/A
符合标准
no
非标原因
N/A
种类
function
可见
public
线程安全
N/A
Fireandforget
N/A
错误
N/A
头文件
ara/exec/named_pipe_client.h
异常安全
noexcept
分类
ara @uptrace{N/A}
范围
namespace ara::internal::libadaptiveplatform::NamedPipeClient

在文件 第 行定义.

成员函数说明

◆ Clear()

bool ara::internal::libadaptiveplatform::NamedPipeClient::Clear ( ) const

清理读管道中残留的数据

Function Implementation

模板参数
N/A
参数
[in]pathname:客户端管道路径
[out]N/A
[in,out]N/A
返回
N/A
注解
N/A
异常
N/A
Swsid
N/A
符合标准
no
非标原因
N/A
种类
function
可见
public
线程安全
N/A
Fireandforget
N/A
错误
N/A
头文件
ara/exec/named_pipe_client.h
异常安全
no
分类
ara @uptrace{N/A}
范围
namespace ara::internal::libadaptiveplatform::NamedPipeClient

在文件 第 行定义.

引用了 .

被这些函数引用 , 以及 .

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

◆ Connect()

void ara::internal::libadaptiveplatform::NamedPipeClient::Connect ( const std::string &  pathname)

客户端连接到管道句柄

Function Implementation

模板参数
N/A
参数
[in]pathname:客户端管道路径
[out]N/A
[in,out]N/A
返回
N/A
注解
N/A
异常
N/A
Swsid
N/A
符合标准
no
非标原因
N/A
种类
function
可见
public
线程安全
N/A
Fireandforget
N/A
错误
N/A
头文件
ara/exec/named_pipe_client.h
异常安全
no
分类
ara @uptrace{N/A}
范围
namespace ara::internal::libadaptiveplatform::NamedPipeClient

在文件 第 行定义.

引用了 .

被这些函数引用 , , , 以及 .

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

◆ Receive()

template<typename DestinationType >
bool ara::internal::libadaptiveplatform::NamedPipeClient::Receive ( DestinationType &  message,
const int64_t  timeout_ms = 0 
) const
inline

客户端接收回复信息

模板参数
N/A
参数
[in]N/A
[out]message:服务端回复的信息
[in,out]N/A
返回
bool:如果正确接收回复返回true, 否则返回false
注解
N/A
异常
SelectException,TimeoutException,ErrnoException
Swsid
N/A
符合标准
no
非标原因
N/A
种类
function
可见
public
线程安全
N/A
Fireandforget
N/A
错误
N/A
头文件
ara/exec/named_pipe_client.h
异常安全
no
分类
ara @uptrace{N/A}
范围
namespace ara::internal::libadaptiveplatform::NamedPipeClient

在文件 第 行定义.

引用了 .

被这些函数引用 , 以及 .

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

◆ Send()

template<typename SourceType >
bool ara::internal::libadaptiveplatform::NamedPipeClient::Send ( const SourceType &  message) const
inline

客户端发送请求信息

模板参数
N/A
参数
[in]message:客户端发送的请求信息
[out]N/A
[in,out]N/A
返回
bool:如果正确发送信息返回true, 否则返回false
注解
N/A
异常
OpenPipeException,ErrnoException
Swsid
N/A
符合标准
no
非标原因
N/A
种类
function
可见
public
线程安全
N/A
Fireandforget
N/A
错误
N/A
头文件
ara/exec/named_pipe_client.h
异常安全
no
分类
ara @uptrace{N/A}
范围
namespace ara::internal::libadaptiveplatform::NamedPipeClient

在文件 第 行定义.

引用了 .

被这些函数引用 .

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

类成员变量说明

◆ client_pipe_

std::unique_ptr<NamedInputPipe> ara::internal::libadaptiveplatform::NamedPipeClient::client_pipe_
private

服务端管道句柄 @uptrace{N/A}

Swsid
N/A
符合标准
yes
非标原因
N/A
种类
variable
可见
private
线程安全
N/A
Fireandforget
N/A
错误
N/A
头文件
ara/exec/named_pipe_client.h
异常安全
noexcept
分类
ara
范围
namespace ara::internal::libadaptiveplatform::NamedPipeClient

在文件 第 行定义.

被这些函数引用 .

◆ server_pipe_

std::unique_ptr<NamedOutputPipe> ara::internal::libadaptiveplatform::NamedPipeClient::server_pipe_
private

客户端管道句柄 @uptrace{N/A}

Swsid
N/A
符合标准
yes
非标原因
N/A
种类
variable
可见
private
线程安全
N/A
Fireandforget
N/A
错误
N/A
头文件
ara/exec/named_pipe_client.h
异常安全
noexcept
分类
ara
范围
namespace ara::internal::libadaptiveplatform::NamedPipeClient

在文件 第 行定义.

被这些函数引用 , 以及 .