RInside Version 0.2.12
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros
BinaryStream Class Reference

#include <binarystream.h>

Classes

class  stream_exception
 

Public Member Functions

 BinaryStream (int read_fd, int write_fd)
 
 ~BinaryStream ()
 
void close ()
 
 BinaryStream (const BinaryStream &)=delete
 
BinaryStreamoperator= (const BinaryStream &)=delete
 
 BinaryStream (BinaryStream &&)
 
BinaryStreamoperator= (BinaryStream &&)
 
void write (const char *buffer, size_t len)
 
template<typename T >
void write (const T &t)
 
template<typename T >
void write (T &t)
 
size_t read (char *buffer, size_t len)
 
template<typename T >
std::enable_if
< std::is_arithmetic< T >
::value, size_t >::type 
read (T *t)
 
template<typename T >
read ()
 

Static Public Member Functions

static BinaryStream connectToUnixSocket (const char *)
 

Private Attributes

bool is_eof
 
int read_fd
 
int write_fd
 

Detailed Description

Definition at line 45 of file binarystream.h.

Constructor & Destructor Documentation

BinaryStream::BinaryStream ( int  read_fd,
int  write_fd 
)

Definition at line 18 of file binarystream.cpp.

Referenced by connectToUnixSocket().

BinaryStream::~BinaryStream ( )

Definition at line 21 of file binarystream.cpp.

References close().

Here is the call graph for this function:

BinaryStream::BinaryStream ( const BinaryStream )
delete
BinaryStream::BinaryStream ( BinaryStream &&  other)

Definition at line 39 of file binarystream.cpp.

Member Function Documentation

void BinaryStream::close ( )

Definition at line 25 of file binarystream.cpp.

References is_eof, read_fd, and write_fd.

Referenced by connectToUnixSocket(), and ~BinaryStream().

BinaryStream BinaryStream::connectToUnixSocket ( const char *  server_path)
static

Definition at line 53 of file binarystream.cpp.

References BinaryStream(), and close().

Referenced by test_callbacks(), test_console_output(), test_multiple(), test_plot(), and test_setting_getting().

Here is the call graph for this function:

BinaryStream& BinaryStream::operator= ( const BinaryStream )
delete
BinaryStream & BinaryStream::operator= ( BinaryStream &&  other)

Definition at line 45 of file binarystream.cpp.

References is_eof, read_fd, and write_fd.

template<typename T >
std::enable_if< std::is_arithmetic<T>::value, size_t>::type BinaryStream::read ( T *  t)
inline

Definition at line 64 of file binarystream.h.

References read().

Referenced by read().

Here is the call graph for this function:

template<typename T >
T BinaryStream::read ( )

Definition at line 182 of file binarystream.h.

Referenced by read().

template<typename T >
void BinaryStream::write ( const T &  t)

Definition at line 175 of file binarystream.h.

template<typename T >
void BinaryStream::write ( T &  t)

Definition at line 178 of file binarystream.h.

Member Data Documentation

bool BinaryStream::is_eof
private

Definition at line 72 of file binarystream.h.

Referenced by close(), operator=(), and read().

int BinaryStream::read_fd
private

Definition at line 73 of file binarystream.h.

Referenced by close(), operator=(), and read().

int BinaryStream::write_fd
private

Definition at line 73 of file binarystream.h.

Referenced by close(), operator=(), and write().


The documentation for this class was generated from the following files: