MFEM  v3.4
Finite element discretization library
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Pages
Public Member Functions | Protected Member Functions | Protected Attributes | Static Protected Attributes | List of all members
mfem::socketbuf Class Reference

#include <socketstream.hpp>

Inheritance diagram for mfem::socketbuf:
[legend]
Collaboration diagram for mfem::socketbuf:
[legend]

Public Member Functions

 socketbuf ()
 
 socketbuf (int sd)
 
 socketbuf (const char hostname[], int port)
 
virtual int attach (int sd)
 
int detach ()
 
virtual int open (const char hostname[], int port)
 
virtual int close ()
 
int getsocketdescriptor ()
 
bool is_open ()
 
virtual ~socketbuf ()
 

Protected Member Functions

virtual int sync ()
 
virtual int_type underflow ()
 
virtual int_type overflow (int_type c=traits_type::eof())
 
virtual std::streamsize xsgetn (char_type *__s, std::streamsize __n)
 
virtual std::streamsize xsputn (const char_type *__s, std::streamsize __n)
 

Protected Attributes

int socket_descriptor
 
char ibuf [buflen]
 
char obuf [buflen]
 

Static Protected Attributes

static const int buflen = 1024
 

Detailed Description

Definition at line 31 of file socketstream.hpp.

Constructor & Destructor Documentation

mfem::socketbuf::socketbuf ( )
inline

Definition at line 39 of file socketstream.hpp.

mfem::socketbuf::socketbuf ( int  sd)
inlineexplicit

Definition at line 44 of file socketstream.hpp.

mfem::socketbuf::socketbuf ( const char  hostname[],
int  port 
)
inline

Definition at line 50 of file socketstream.hpp.

virtual mfem::socketbuf::~socketbuf ( )
inlinevirtual

Definition at line 70 of file socketstream.hpp.

Member Function Documentation

int mfem::socketbuf::attach ( int  sd)
virtual

Attach a new socket descriptor to the socketbuf. Returns the old socket descriptor which is NOT closed.

Reimplemented in mfem::GnuTLS_socketbuf.

Definition at line 48 of file socketstream.cpp.

int mfem::socketbuf::close ( )
virtual

Reimplemented in mfem::GnuTLS_socketbuf.

Definition at line 106 of file socketstream.cpp.

int mfem::socketbuf::detach ( )
inline

Definition at line 60 of file socketstream.hpp.

int mfem::socketbuf::getsocketdescriptor ( )
inline

Definition at line 66 of file socketstream.hpp.

bool mfem::socketbuf::is_open ( )
inline

Definition at line 68 of file socketstream.hpp.

int mfem::socketbuf::open ( const char  hostname[],
int  port 
)
virtual

Reimplemented in mfem::GnuTLS_socketbuf.

Definition at line 58 of file socketstream.cpp.

socketbuf::int_type mfem::socketbuf::overflow ( int_type  c = traits_type::eof())
protectedvirtual

Definition at line 165 of file socketstream.cpp.

int mfem::socketbuf::sync ( )
protectedvirtual

Reimplemented in mfem::GnuTLS_socketbuf.

Definition at line 118 of file socketstream.cpp.

socketbuf::int_type mfem::socketbuf::underflow ( )
protectedvirtual

Reimplemented in mfem::GnuTLS_socketbuf.

Definition at line 144 of file socketstream.cpp.

std::streamsize mfem::socketbuf::xsgetn ( char_type *  __s,
std::streamsize  __n 
)
protectedvirtual

Reimplemented in mfem::GnuTLS_socketbuf.

Definition at line 180 of file socketstream.cpp.

std::streamsize mfem::socketbuf::xsputn ( const char_type *  __s,
std::streamsize  __n 
)
protectedvirtual

Reimplemented in mfem::GnuTLS_socketbuf.

Definition at line 214 of file socketstream.cpp.

Member Data Documentation

const int mfem::socketbuf::buflen = 1024
staticprotected

Definition at line 35 of file socketstream.hpp.

char mfem::socketbuf::ibuf[buflen]
protected

Definition at line 36 of file socketstream.hpp.

char mfem::socketbuf::obuf[buflen]
protected

Definition at line 36 of file socketstream.hpp.

int mfem::socketbuf::socket_descriptor
protected

Definition at line 34 of file socketstream.hpp.


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