Goby3  3.1.5a
2024.05.23
httplib::Stream Class Referenceabstract

#include <goby/util/thirdparty/cpp-httplib/httplib.h>

Inheritance diagram for httplib::Stream:
httplib::detail::BufferStream httplib::detail::SocketStream

Public Member Functions

virtual ~Stream ()=default
 
virtual bool is_readable () const =0
 
virtual bool is_writable () const =0
 
virtual ssize_t read (char *ptr, size_t size)=0
 
virtual ssize_t write (const char *ptr, size_t size)=0
 
virtual void get_remote_ip_and_port (std::string &ip, int &port) const =0
 
virtual void get_local_ip_and_port (std::string &ip, int &port) const =0
 
virtual socket_t socket () const =0
 
template<typename... Args>
ssize_t write_format (const char *fmt, const Args &... args)
 
ssize_t write (const char *ptr)
 
ssize_t write (const std::string &s)
 

Detailed Description

Definition at line 577 of file httplib.h.

Constructor & Destructor Documentation

◆ ~Stream()

virtual httplib::Stream::~Stream ( )
virtualdefault

Member Function Documentation

◆ get_local_ip_and_port()

virtual void httplib::Stream::get_local_ip_and_port ( std::string &  ip,
int port 
) const
pure virtual

◆ get_remote_ip_and_port()

virtual void httplib::Stream::get_remote_ip_and_port ( std::string &  ip,
int port 
) const
pure virtual

◆ is_readable()

virtual bool httplib::Stream::is_readable ( ) const
pure virtual

◆ is_writable()

virtual bool httplib::Stream::is_writable ( ) const
pure virtual

◆ read()

virtual ssize_t httplib::Stream::read ( char ptr,
size_t  size 
)
pure virtual

◆ socket()

virtual socket_t httplib::Stream::socket ( ) const
pure virtual

◆ write() [1/3]

ssize_t httplib::Stream::write ( const char ptr)
inline

Definition at line 5934 of file httplib.h.

◆ write() [2/3]

virtual ssize_t httplib::Stream::write ( const char ptr,
size_t  size 
)
pure virtual

◆ write() [3/3]

ssize_t httplib::Stream::write ( const std::string &  s)
inline

Definition at line 5936 of file httplib.h.

◆ write_format()

template<typename... Args>
ssize_t httplib::Stream::write_format ( const char fmt,
const Args &...  args 
)
inline

Definition at line 1689 of file httplib.h.


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