Public Member Functions | Protected Attributes | Private Attributes
Socket Class Reference

#include <Socket.h>

Inheritance diagram for Socket:
Inheritance graph
[legend]

List of all members.

Public Member Functions

bool Accept (Socket &s) const
bool Accept (Socket *s) const
bool Bind (const int port)
bool Close ()
bool Connect (const char *host, const int port)
bool Create ()
void hideErrors ()
bool IsBroken () const
bool IsOpen () const
bool Listen ()
bool Open (Socket *newsocket)
bool Open ()
bool PrepareServer ()
size_t Receive (unsigned char *s, size_t max_size)
size_t Send (const unsigned char *s, size_t size)
bool SendAll (const unsigned char *s, size_t size, size_t millisec)
void SetNonBlocking (const bool)
void showErrors ()
 Socket ()
 Socket (const char *_host, int _port)
 Socket (int port)
bool WaitBuffer (unsigned char *s, size_t size, size_t millisec)
bool WaitData (size_t millisec)
 ~Socket ()

Protected Attributes

bool accepting
bool broken_pipe
char * host
bool outputErrors
int port
bool server

Private Attributes

sockaddr_in m_addr
int m_sock
fd_set rfs

Detailed Description

Definition at line 27 of file Socket.h.


Constructor & Destructor Documentation

Signature> Author : Cedric Pradalier Universite : INRIA - GRAVIR - INPG Email : cedric.pradalier@inrialpes.fr Contexte : These MESR Date : 2001 - 2004 License : Libre (???) <Signature

Definition at line 27 of file Socket.cpp.

Socket::Socket ( const char *  _host,
int  _port 
)

Definition at line 42 of file Socket.cpp.

Socket::Socket ( int  port)

Definition at line 54 of file Socket.cpp.

Definition at line 67 of file Socket.cpp.


Member Function Documentation

bool Socket::Accept ( Socket s) const [inline]

Definition at line 39 of file Socket.h.

bool Socket::Accept ( Socket s) const

Definition at line 162 of file Socket.cpp.

bool Socket::Bind ( const int  port)

Definition at line 118 of file Socket.cpp.

bool Socket::Close ( )

Definition at line 80 of file Socket.cpp.

bool Socket::Connect ( const char *  host,
const int  port 
)

Definition at line 229 of file Socket.cpp.

bool Socket::Create ( void  )

Definition at line 88 of file Socket.cpp.

void Socket::hideErrors ( ) [inline]

Definition at line 31 of file Socket.h.

bool Socket::IsBroken ( ) const [inline]

Definition at line 68 of file Socket.h.

bool Socket::IsOpen ( ) const [inline]

Definition at line 67 of file Socket.h.

bool Socket::Listen ( )

Definition at line 145 of file Socket.cpp.

bool Socket::Open ( Socket newsocket)

Reimplemented in SocketCom.

Definition at line 403 of file Socket.cpp.

bool Socket::Open ( )

Reimplemented in SocketCom.

Definition at line 415 of file Socket.cpp.

Reimplemented in SocketCom.

Definition at line 382 of file Socket.cpp.

size_t Socket::Receive ( unsigned char *  s,
size_t  max_size 
)

Definition at line 199 of file Socket.cpp.

size_t Socket::Send ( const unsigned char *  s,
size_t  size 
)

Definition at line 171 of file Socket.cpp.

bool Socket::SendAll ( const unsigned char *  s,
size_t  size,
size_t  millisec 
)

Definition at line 355 of file Socket.cpp.

void Socket::SetNonBlocking ( const bool  b)

Definition at line 261 of file Socket.cpp.

void Socket::showErrors ( ) [inline]

Definition at line 30 of file Socket.h.

bool Socket::WaitBuffer ( unsigned char *  s,
size_t  size,
size_t  millisec 
)

Definition at line 307 of file Socket.cpp.

bool Socket::WaitData ( size_t  millisec)

Definition at line 283 of file Socket.cpp.


Member Data Documentation

bool Socket::accepting [protected]

Definition at line 74 of file Socket.h.

bool Socket::broken_pipe [protected]

Definition at line 75 of file Socket.h.

char* Socket::host [protected]

Reimplemented in SocketCom.

Definition at line 78 of file Socket.h.

sockaddr_in Socket::m_addr [private]

Definition at line 84 of file Socket.h.

int Socket::m_sock [private]

Definition at line 83 of file Socket.h.

bool Socket::outputErrors [protected]

Definition at line 33 of file Socket.h.

int Socket::port [protected]

Reimplemented in SocketCom.

Definition at line 77 of file Socket.h.

fd_set Socket::rfs [private]

Definition at line 82 of file Socket.h.

bool Socket::server [protected]

Reimplemented in SocketCom.

Definition at line 79 of file Socket.h.


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


canon_vbc50i
Author(s): Cedric Pradalier
autogenerated on Mon Jan 6 2014 11:18:28