#include <network.h>
Classes | |
| struct | thread_params_t |
Public Types | |
| enum | protocols_supported_e { NONE, HTTP, HTTPS, RTMP, RTMPT, RTMPTS, RTMPE, RTMPS, DTN, NONE, HTTP, HTTPS, RTMP, RTMPT, RTMPTS, RTMPE, RTMPS, DTN } |
This enum contains the list of all supported protocols. More... | |
| enum | protocols_supported_e { NONE, HTTP, HTTPS, RTMP, RTMPT, RTMPTS, RTMPE, RTMPS, DTN, NONE, HTTP, HTTPS, RTMP, RTMPT, RTMPTS, RTMPE, RTMPS, DTN } |
This enum contains the list of all supported protocols. More... | |
| typedef boost::uint8_t | byte_t |
| typedef bool | entry_t (thread_params_t *) |
| typedef boost::uint8_t | byte_t |
| typedef bool | entry_t (thread_params_t *) |
Public Member Functions | |
| Network () | |
| ~Network () | |
| int | createServer (void) |
| Create a new server. After creating it, then you have to wait for an incoming connection. | |
| int | createServer (short port) |
| int | newConnection (void) |
| Accept a client connection for the current server. | |
| int | newConnection (int fd) |
| int | newConnection (bool block, int fd) |
| int | newConnection (bool block) |
| bool | connectSocket (const std::string &sock) |
| Connect to a named pipe. | |
| bool | createClient (void) |
| Create a client connection to a tcp/ip server. | |
| bool | createClient (short port) |
| bool | createClient (const std::string &hostname) |
| bool | createClient (const std::string &hostname, short port) |
| boost::shared_ptr< cygnal::Buffer > | readNet () |
| Read from the opened connection. | |
| int | readNet (cygnal::Buffer &buffer) |
| int | readNet (int fd, cygnal::Buffer &buffer) |
| int | readNet (int fd, cygnal::Buffer *buffer) |
| int | readNet (cygnal::Buffer &buffer, int timeout) |
| int | readNet (int fd, cygnal::Buffer &buffer, int timeout) |
| int | readNet (byte_t *data, int nbytes) |
| int | readNet (byte_t *data, int nbytes, int timeout) |
| int | readNet (int fd, byte_t *data, int nbytes) |
| int | readNet (int fd, byte_t *data, int nbytes, int timeout) |
| int | writeNet (cygnal::Buffer *buffer) |
| Write to the opened connection. | |
| int | writeNet (cygnal::Buffer &buffer) |
| int | writeNet (int fd, cygnal::Buffer *buffer) |
| int | writeNet (int fd, cygnal::Buffer &buffer) |
| int | writeNet (const std::string &data) |
| int | writeNet (const byte_t *data, int nbytes) |
| int | writeNet (int fd, const byte_t *buffer, int nbytes) |
| int | writeNet (int fd, const byte_t *buffer, int nbytes, int timeout) |
| boost::shared_ptr< std::vector < struct pollfd > > | waitForNetData (int limit, struct pollfd *fds) |
| Wait for sries of file descriptors for data. | |
| fd_set | waitForNetData (int limit, fd_set data) |
| fd_set | waitForNetData (std::vector< int > &data) |
| bool | closeNet () |
| Close the connection. | |
| bool | closeNet (int fd) |
| bool | closeConnection () |
| bool | closeConnection (int fd) |
| void | toggleDebug (bool val) |
| bool | netDebug () |
| bool | send (const char *str) |
| bool | connected () const |
| void | setPort (short x) |
| short | getPort () const |
| void | setFileFd (int x) |
| int | getFileFd () const |
| int | getListenFd () const |
| void | setListenFd (int x) |
| const std::string & | getURL () const |
| void | setURL (const std::string &url) |
| const std::string & | getProtocol () const |
| void | setProtocol (const std::string &proto) |
| const std::string & | getHost () const |
| void | setHost (const std::string &host) |
| const std::string & | getPortStr () const |
| void | setPortStr (const std::string &port) |
| const std::string & | getPath () const |
| void | setPath (const std::string &path) |
| void | setTimeout (int x) |
| int | getTimeout () const |
| Network & | operator= (Network &net) |
| void | addPollFD (struct pollfd &fd, entry_t *ptr) |
| void | addPollFD (struct pollfd &fd) |
| void | erasePollFD (int fd) |
| void | erasePollFD (std::vector< struct pollfd >::iterator &itt) |
| struct pollfd & | getPollFD (int fd) |
| struct pollfd * | getPollFDPtr () |
| void | addEntry (int fd, entry_t *func) |
| entry_t * | getEntry (int fd) |
| size_t | sniffBytesReady (int fd) |
| Network () | |
| ~Network () | |
| int | createServer (void) |
| Create a new server. After creating it, then you have to wait for an incoming connection. | |
| int | createServer (short port) |
| int | newConnection (void) |
| Accept a client connection for the current server. | |
| int | newConnection (int fd) |
| int | newConnection (bool block, int fd) |
| int | newConnection (bool block) |
| bool | connectSocket (const std::string &sock) |
| Connect to a named pipe. | |
| bool | createClient (void) |
| Create a client connection to a tcp/ip server. | |
| bool | createClient (short port) |
| bool | createClient (const std::string &hostname) |
| bool | createClient (const std::string &hostname, short port) |
| boost::shared_ptr< cygnal::Buffer > | readNet () |
| Read from the opened connection. | |
| int | readNet (cygnal::Buffer &buffer) |
| int | readNet (int fd, cygnal::Buffer &buffer) |
| int | readNet (int fd, cygnal::Buffer *buffer) |
| int | readNet (cygnal::Buffer &buffer, int timeout) |
| int | readNet (int fd, cygnal::Buffer &buffer, int timeout) |
| int | readNet (byte_t *data, int nbytes) |
| int | readNet (byte_t *data, int nbytes, int timeout) |
| int | readNet (int fd, byte_t *data, int nbytes) |
| int | readNet (int fd, byte_t *data, int nbytes, int timeout) |
| int | writeNet (cygnal::Buffer *buffer) |
| Write to the opened connection. | |
| int | writeNet (cygnal::Buffer &buffer) |
| int | writeNet (int fd, cygnal::Buffer *buffer) |
| int | writeNet (int fd, cygnal::Buffer &buffer) |
| int | writeNet (const std::string &data) |
| int | writeNet (const byte_t *data, int nbytes) |
| int | writeNet (int fd, const byte_t *buffer, int nbytes) |
| int | writeNet (int fd, const byte_t *buffer, int nbytes, int timeout) |
| boost::shared_ptr< std::vector < struct pollfd > > | waitForNetData (int limit, struct pollfd *fds) |
| Wait for sries of file descriptors for data. | |
| fd_set | waitForNetData (int limit, fd_set data) |
| fd_set | waitForNetData (std::vector< int > &data) |
| bool | closeNet () |
| Close the connection. | |
| bool | closeNet (int fd) |
| bool | closeConnection () |
| bool | closeConnection (int fd) |
| void | toggleDebug (bool val) |
| bool | netDebug () |
| bool | send (const char *str) |
| bool | connected () const |
| void | setPort (short x) |
| short | getPort () const |
| void | setFileFd (int x) |
| int | getFileFd () const |
| int | getListenFd () const |
| void | setListenFd (int x) |
| const std::string & | getURL () const |
| void | setURL (const std::string &url) |
| const std::string & | getProtocol () const |
| void | setProtocol (const std::string &proto) |
| const std::string & | getHost () const |
| void | setHost (const std::string &host) |
| const std::string & | getPortStr () const |
| void | setPortStr (const std::string &port) |
| const std::string & | getPath () const |
| void | setPath (const std::string &path) |
| void | setTimeout (int x) |
| int | getTimeout () const |
| Network & | operator= (Network &net) |
| void | addPollFD (struct pollfd &fd, entry_t *ptr) |
| void | addPollFD (struct pollfd &fd) |
| void | erasePollFD (int fd) |
| void | erasePollFD (std::vector< struct pollfd >::iterator &itt) |
| struct pollfd & | getPollFD (int fd) |
| struct pollfd * | getPollFDPtr () |
| void | addEntry (int fd, entry_t *func) |
| entry_t * | getEntry (int fd) |
| size_t | sniffBytesReady (int fd) |
Protected Attributes | |
| in_addr_t | _ipaddr |
| int | _sockfd |
| int | _listenfd |
| short | _port |
| std::string | _portstr |
| std::string | _url |
| std::string | _protocol |
| std::string | _host |
| std::string | _path |
| bool | _connected |
| bool | _debug |
| int | _timeout |
| size_t | _bytes_loaded |
| std::map< int, entry_t * > | _handlers |
| std::vector< struct pollfd > | _pollfds |
| boost::mutex | _poll_mutex |
| boost::mutex | _net_mutex |
This is a low level network class for Gnash and Cygnal. This handles the grunt work on both the client side and the server side of a network connection.
| typedef boost::uint8_t gnash::Network::byte_t |
| typedef boost::uint8_t gnash::Network::byte_t |
| typedef bool gnash::Network::entry_t(thread_params_t *) |
| typedef bool gnash::Network::entry_t(thread_params_t *) |
| gnash::Network::Network | ( | ) |
References _.
| gnash::Network::~Network | ( | ) |
References closeNet().
| gnash::Network::Network | ( | ) |
| gnash::Network::~Network | ( | ) |
| void gnash::Network::addEntry | ( | int | fd, | |
| Network::entry_t * | func | |||
| ) |
References _handlers, and _poll_mutex.
| void gnash::Network::addEntry | ( | int | fd, | |
| entry_t * | func | |||
| ) |
| void gnash::Network::addPollFD | ( | struct pollfd & | fd, | |
| Network::entry_t * | func | |||
| ) |
References __PRETTY_FUNCTION__, _handlers, _poll_mutex, _pollfds, and gnash::pollfd::fd.
| void gnash::Network::addPollFD | ( | struct pollfd & | fd | ) |
| void gnash::Network::addPollFD | ( | struct pollfd & | fd | ) |
References __PRETTY_FUNCTION__, _poll_mutex, _pollfds, and gnash::pollfd::fd.
| bool gnash::Network::closeConnection | ( | int | fd | ) |
References __FUNCTION__, and ogl::close().
| bool gnash::Network::closeConnection | ( | ) |
| bool gnash::Network::closeConnection | ( | int | fd | ) |
| bool gnash::Network::closeConnection | ( | void | ) |
References _connected, and _listenfd.
Referenced by admin_handler().
| bool gnash::Network::closeNet | ( | ) |
Close the connection.
| fd | The file descritor of the open connection to close. |
References _connected.
Referenced by admin_handler(), connection_handler(), event_handler(), main(), cygnal::rtmp_handler(), gnash::Lirc::~Lirc(), and ~Network().
| bool gnash::Network::closeNet | ( | int | fd | ) |
References _, ogl::close(), and errno.
| bool gnash::Network::closeNet | ( | ) |
Close the connection.
| fd | The file descritor of the open connection to close. |
| bool gnash::Network::closeNet | ( | int | fd | ) |
| bool gnash::Network::connected | ( | ) | const [inline] |
Referenced by gnash::RTMPClient::connectToServer(), and operator=().
| bool gnash::Network::connected | ( | ) | const [inline] |
| bool gnash::Network::connectSocket | ( | const std::string & | sock | ) |
Connect to a named pipe.
| sock | The name of the named pipe to connect to. |
Referenced by gnash::Lirc::init().
| bool gnash::Network::connectSocket | ( | const std::string & | sock | ) |
Connect to a named pipe.
| sock | The name of the named pipe to connect to. |
| bool gnash::Network::createClient | ( | void | ) |
Create a client connection to a tcp/ip server.
| port | The tcp/ip port to use for contacting the server. | |
| hostname | The name of the host to connect to. The default is localhost. |
References _port, and gnash::RTMP_PORT.
Referenced by gnash::RTMPClient::connectToServer(), and cygnal::HTTPServer::processPostRequest().
| bool gnash::Network::createClient | ( | short | port | ) |
| bool gnash::Network::createClient | ( | void | ) |
Create a client connection to a tcp/ip server.
| port | The tcp/ip port to use for contacting the server. | |
| hostname | The name of the host to connect to. The default is localhost. |
| bool gnash::Network::createClient | ( | short | port | ) |
| bool gnash::Network::createClient | ( | const std::string & | hostname | ) |
| bool gnash::Network::createClient | ( | const std::string & | hostname, | |
| short | port | |||
| ) |
| bool gnash::Network::createClient | ( | const std::string & | hostname | ) |
| bool gnash::Network::createClient | ( | const std::string & | hostname, | |
| short | port | |||
| ) |
| int gnash::Network::createServer | ( | void | ) |
Create a new server. After creating it, then you have to wait for an incoming connection.
| port | The optional port number to wait on for connections. |
| int gnash::Network::createServer | ( | short | port | ) |
| int gnash::Network::createServer | ( | short | port | ) |
| int gnash::Network::createServer | ( | void | ) |
Create a new server. After creating it, then you have to wait for an incoming connection.
| port | The optional port number to wait on for connections. |
References _port.
Referenced by admin_handler(), connection_handler(), and main().
| void gnash::Network::erasePollFD | ( | int | fd | ) |
| void gnash::Network::erasePollFD | ( | std::vector< struct pollfd >::iterator & | itt | ) |
| void gnash::Network::erasePollFD | ( | int | fd | ) |
References __PRETTY_FUNCTION__, _poll_mutex, and _pollfds.
| void gnash::Network::erasePollFD | ( | std::vector< struct pollfd >::iterator & | itt | ) |
| Network::entry_t * gnash::Network::getEntry | ( | int | fd | ) |
References _handlers, and _poll_mutex.
| entry_t* gnash::Network::getEntry | ( | int | fd | ) |
| int gnash::Network::getFileFd | ( | ) | const [inline] |
| int gnash::Network::getFileFd | ( | ) | const [inline] |
| const std::string& gnash::Network::getHost | ( | ) | const [inline] |
Referenced by operator=().
| const std::string& gnash::Network::getHost | ( | ) | const [inline] |
| int gnash::Network::getListenFd | ( | ) | const [inline] |
Referenced by operator=().
| int gnash::Network::getListenFd | ( | ) | const [inline] |
| const std::string& gnash::Network::getPath | ( | ) | const [inline] |
References _path.
Referenced by operator=().
| const std::string& gnash::Network::getPath | ( | ) | const [inline] |
References _path.
| struct pollfd & gnash::Network::getPollFD | ( | int | fd | ) | [read] |
References _poll_mutex, and _pollfds.
| struct pollfd& gnash::Network::getPollFD | ( | int | fd | ) | [read] |
| struct pollfd * gnash::Network::getPollFDPtr | ( | ) | [read] |
References _poll_mutex, and _pollfds.
| struct pollfd* gnash::Network::getPollFDPtr | ( | ) | [read] |
| short gnash::Network::getPort | ( | ) | const [inline] |
Referenced by operator=().
| short gnash::Network::getPort | ( | ) | const [inline] |
| const std::string& gnash::Network::getPortStr | ( | ) | const [inline] |
Referenced by operator=().
| const std::string& gnash::Network::getPortStr | ( | ) | const [inline] |
| const std::string& gnash::Network::getProtocol | ( | ) | const [inline] |
Referenced by operator=().
| const std::string& gnash::Network::getProtocol | ( | ) | const [inline] |
| int gnash::Network::getTimeout | ( | ) | const [inline] |
Referenced by operator=().
| int gnash::Network::getTimeout | ( | ) | const [inline] |
| const std::string& gnash::Network::getURL | ( | ) | const [inline] |
Referenced by operator=().
| const std::string& gnash::Network::getURL | ( | ) | const [inline] |
| bool gnash::Network::netDebug | ( | ) | [inline] |
Referenced by operator=().
| bool gnash::Network::netDebug | ( | ) | [inline] |
| int gnash::Network::newConnection | ( | void | ) |
Accept a client connection for the current server.
| fd | The optional file descriptor to wait on for connections. | |
| block | True if this should be a blocking wait. |
| int gnash::Network::newConnection | ( | int | fd | ) |
| int gnash::Network::newConnection | ( | bool | block, | |
| int | fd | |||
| ) |
| int gnash::Network::newConnection | ( | bool | block | ) |
| int gnash::Network::newConnection | ( | bool | block, | |
| int | fd | |||
| ) |
| int gnash::Network::newConnection | ( | bool | block | ) |
References _listenfd, and newConnection().
| int gnash::Network::newConnection | ( | int | fd | ) |
References newConnection().
| int gnash::Network::newConnection | ( | void | ) |
Accept a client connection for the current server.
| fd | The optional file descriptor to wait on for connections. | |
| block | True if this should be a blocking wait. |
References _listenfd.
Referenced by admin_handler(), connection_handler(), main(), and newConnection().
References _connected, _debug, _host, _listenfd, _path, _port, _portstr, _protocol, _timeout, _url, connected(), getFileFd(), getHost(), getListenFd(), getPath(), getPort(), getPortStr(), getProtocol(), getTimeout(), getURL(), and netDebug().
| int gnash::Network::readNet | ( | int | fd, | |
| cygnal::Buffer & | buffer, | |||
| int | timeout | |||
| ) |
| int gnash::Network::readNet | ( | int | fd, | |
| cygnal::Buffer * | buffer | |||
| ) |
| int gnash::Network::readNet | ( | int | fd, | |
| cygnal::Buffer & | buffer | |||
| ) |
References _timeout, readNet(), cygnal::Buffer::reference(), cygnal::Buffer::resize(), and cygnal::Buffer::size().
| int gnash::Network::readNet | ( | int | fd, | |
| byte_t * | data, | |||
| int | nbytes | |||
| ) |
| boost::shared_ptr<cygnal::Buffer> gnash::Network::readNet | ( | ) |
Read from the opened connection.
| buffer | A Buffer class to hold the data. | |
| timeout | An optional timeout for reading data, in seconds. | |
| fd | The optional file descriptor to read data from. | |
| nbytes | The number of bytes to try to read. |
| int gnash::Network::readNet | ( | cygnal::Buffer & | buffer | ) |
| int gnash::Network::readNet | ( | int | fd, | |
| cygnal::Buffer & | buffer | |||
| ) |
| int gnash::Network::readNet | ( | int | fd, | |
| byte_t * | data, | |||
| int | nbytes, | |||
| int | timeout | |||
| ) |
References _, __FUNCTION__, _debug, _port, gnash::key::e, errno, and gnash::hexify().
| int gnash::Network::readNet | ( | cygnal::Buffer & | buffer, | |
| int | timeout | |||
| ) |
| int gnash::Network::readNet | ( | byte_t * | data, | |
| int | nbytes | |||
| ) |
| int gnash::Network::readNet | ( | int | fd, | |
| byte_t * | data, | |||
| int | nbytes | |||
| ) |
| int gnash::Network::readNet | ( | int | fd, | |
| byte_t * | data, | |||
| int | nbytes, | |||
| int | timeout | |||
| ) |
| boost::shared_ptr< cygnal::Buffer > gnash::Network::readNet | ( | ) |
Read from the opened connection.
| buffer | A Buffer class to hold the data. | |
| timeout | An optional timeout for reading data, in seconds. | |
| fd | The optional file descriptor to read data from. | |
| nbytes | The number of bytes to try to read. |
Referenced by admin_handler(), gnash::RTMPClient::clientFinish(), gnash::Lirc::getButton(), gnash::Lirc::getKey(), main(), cygnal::Handler::parseFirstRequest(), cygnal::HTTPServer::processPostRequest(), readNet(), gnash::HTTP::recvChunked(), gnash::RTMP::recvMsg(), and gnash::HTTP::recvMsg().
| int gnash::Network::readNet | ( | cygnal::Buffer & | buffer | ) |
| int gnash::Network::readNet | ( | cygnal::Buffer & | buffer, | |
| int | timeout | |||
| ) |
References readNet(), cygnal::Buffer::reference(), cygnal::Buffer::resize(), and cygnal::Buffer::size().
| int gnash::Network::readNet | ( | int | fd, | |
| cygnal::Buffer * | buffer | |||
| ) |
| int gnash::Network::readNet | ( | byte_t * | data, | |
| int | nbytes, | |||
| int | timeout | |||
| ) |
| int gnash::Network::readNet | ( | int | fd, | |
| cygnal::Buffer & | buffer, | |||
| int | timeout | |||
| ) |
| bool gnash::Network::send | ( | const char * | str | ) |
| bool gnash::Network::send | ( | const char * | str | ) |
| void gnash::Network::setFileFd | ( | int | x | ) | [inline] |
| void gnash::Network::setFileFd | ( | int | x | ) | [inline] |
| void gnash::Network::setHost | ( | const std::string & | host | ) | [inline] |
| void gnash::Network::setHost | ( | const std::string & | host | ) | [inline] |
| void gnash::Network::setListenFd | ( | int | x | ) | [inline] |
| void gnash::Network::setListenFd | ( | int | x | ) | [inline] |
| void gnash::Network::setPath | ( | const std::string & | path | ) | [inline] |
References _path.
| void gnash::Network::setPath | ( | const std::string & | path | ) | [inline] |
References _path.
| void gnash::Network::setPort | ( | short | x | ) | [inline] |
| void gnash::Network::setPort | ( | short | x | ) | [inline] |
Referenced by connection_handler().
| void gnash::Network::setPortStr | ( | const std::string & | port | ) | [inline] |
| void gnash::Network::setPortStr | ( | const std::string & | port | ) | [inline] |
| void gnash::Network::setProtocol | ( | const std::string & | proto | ) | [inline] |
| void gnash::Network::setProtocol | ( | const std::string & | proto | ) | [inline] |
| void gnash::Network::setTimeout | ( | int | x | ) | [inline] |
| void gnash::Network::setTimeout | ( | int | x | ) | [inline] |
| void gnash::Network::setURL | ( | const std::string & | url | ) | [inline] |
| void gnash::Network::setURL | ( | const std::string & | url | ) | [inline] |
| size_t gnash::Network::sniffBytesReady | ( | int | fd | ) |
References FIONREAD.
Referenced by cygnal::Handler::parseFirstRequest().
| size_t gnash::Network::sniffBytesReady | ( | int | fd | ) |
| void gnash::Network::toggleDebug | ( | bool | val | ) |
References _debug.
Referenced by connection_handler(), and main().
| void gnash::Network::toggleDebug | ( | bool | val | ) |
| fd_set gnash::Network::waitForNetData | ( | std::vector< int > & | data | ) |
| fd_set gnash::Network::waitForNetData | ( | int | limit, | |
| fd_set | data | |||
| ) |
| fd_set gnash::Network::waitForNetData | ( | std::vector< int > & | data | ) |
| boost::shared_ptr< std::vector< struct pollfd > > gnash::Network::waitForNetData | ( | int | limit, | |
| struct pollfd * | fds | |||
| ) |
Wait for sries of file descriptors for data.
| limit | The max number of file descriptors to wait for. |
References __FUNCTION__, _timeout, gnash::key::i, and POLLRDHUP.
Referenced by event_handler().
| boost::shared_ptr<std::vector<struct pollfd> > gnash::Network::waitForNetData | ( | int | limit, | |
| struct pollfd * | fds | |||
| ) |
Wait for sries of file descriptors for data.
| limit | The max number of file descriptors to wait for. |
| int gnash::Network::writeNet | ( | int | fd, | |
| const byte_t * | buffer, | |||
| int | nbytes | |||
| ) |
| int gnash::Network::writeNet | ( | int | fd, | |
| cygnal::Buffer * | buffer | |||
| ) |
| int gnash::Network::writeNet | ( | int | fd, | |
| cygnal::Buffer * | buffer | |||
| ) |
References cygnal::Buffer::allocated(), cygnal::Buffer::reference(), and writeNet().
| int gnash::Network::writeNet | ( | cygnal::Buffer * | buffer | ) |
Write to the opened connection.
| buffer | A Buffer class holding the data. | |
| timeout | An optional timeout for writing data, in seconds. | |
| fd | The optional file descriptor to write data to from. | |
| nbytes | The number of bytes to try to write.. |
| int gnash::Network::writeNet | ( | int | fd, | |
| cygnal::Buffer & | buffer | |||
| ) |
| int gnash::Network::writeNet | ( | int | fd, | |
| const byte_t * | buffer, | |||
| int | nbytes | |||
| ) |
References _timeout, and writeNet().
| int gnash::Network::writeNet | ( | const byte_t * | data, | |
| int | nbytes | |||
| ) |
| int gnash::Network::writeNet | ( | cygnal::Buffer & | buffer | ) |
References cygnal::Buffer::allocated(), cygnal::Buffer::reference(), and writeNet().
| int gnash::Network::writeNet | ( | cygnal::Buffer * | buffer | ) |
Write to the opened connection.
| buffer | A Buffer class holding the data. | |
| timeout | An optional timeout for writing data, in seconds. | |
| fd | The optional file descriptor to write data to from. | |
| nbytes | The number of bytes to try to write.. |
References cygnal::Buffer::allocated(), and cygnal::Buffer::reference().
Referenced by admin_handler(), gnash::RTMPClient::clientFinish(), gnash::RTMPClient::handShakeRequest(), main(), gnash::DiskStream::play(), cygnal::HTTPServer::processClientRequest(), cygnal::HTTPServer::processGetRequest(), cygnal::HTTPServer::processPostRequest(), gnash::RTMP::sendMsg(), gnash::HTTP::sendMsg(), cygnal::RTMPServer::sendToClient(), and writeNet().
| int gnash::Network::writeNet | ( | cygnal::Buffer & | buffer | ) |
| int gnash::Network::writeNet | ( | int | fd, | |
| const byte_t * | buffer, | |||
| int | nbytes, | |||
| int | timeout | |||
| ) |
| int gnash::Network::writeNet | ( | const std::string & | data | ) |
References writeNet().
| int gnash::Network::writeNet | ( | int | fd, | |
| cygnal::Buffer & | buffer | |||
| ) |
References cygnal::Buffer::allocated(), cygnal::Buffer::reference(), and writeNet().
| int gnash::Network::writeNet | ( | const std::string & | data | ) |
| int gnash::Network::writeNet | ( | const byte_t * | data, | |
| int | nbytes | |||
| ) |
References _timeout, and writeNet().
| int gnash::Network::writeNet | ( | int | fd, | |
| const byte_t * | buffer, | |||
| int | nbytes, | |||
| int | timeout | |||
| ) |
References _, __FUNCTION__, _debug, _net_mutex, _port, errno, gnash::hexify(), and gnash::amf::write().
size_t gnash::Network::_bytes_loaded [protected] |
bool gnash::Network::_connected [protected] |
Referenced by closeConnection(), closeNet(), gnash::Lirc::init(), and operator=().
bool gnash::Network::_debug [protected] |
Referenced by createServer(), newConnection(), operator=(), readNet(), toggleDebug(), and writeNet().
std::map< int, entry_t * > gnash::Network::_handlers [protected] |
Referenced by addEntry(), addPollFD(), and getEntry().
std::string gnash::Network::_host [protected] |
Referenced by operator=().
in_addr_t gnash::Network::_ipaddr [protected] |
Referenced by createServer().
int gnash::Network::_listenfd [protected] |
Referenced by closeConnection(), createServer(), newConnection(), and operator=().
boost::mutex gnash::Network::_net_mutex [protected] |
Referenced by writeNet().
std::string gnash::Network::_path [protected] |
Referenced by operator=().
boost::mutex gnash::Network::_poll_mutex [protected] |
Referenced by addEntry(), addPollFD(), erasePollFD(), getEntry(), getPollFD(), and getPollFDPtr().
std::vector< struct pollfd > gnash::Network::_pollfds [protected] |
Referenced by addPollFD(), erasePollFD(), getPollFD(), and getPollFDPtr().
short gnash::Network::_port [protected] |
Referenced by createClient(), createServer(), newConnection(), operator=(), readNet(), and writeNet().
std::string gnash::Network::_portstr [protected] |
Referenced by operator=().
std::string gnash::Network::_protocol [protected] |
Reimplemented in cygnal::Handler.
Referenced by operator=().
int gnash::Network::_sockfd [protected] |
Referenced by newConnection().
int gnash::Network::_timeout [protected] |
Reimplemented in gnash::RTMP.
Referenced by newConnection(), operator=(), readNet(), waitForNetData(), and writeNet().
std::string gnash::Network::_url [protected] |
Referenced by operator=().
1.7.1