File: socketbase.yo

package info (click to toggle)
bobcat 1.18.1-1
  • links: PTS
  • area: main
  • in suites: lenny
  • size: 3,920 kB
  • ctags: 575
  • sloc: makefile: 12,973; cpp: 6,284; perl: 401; ansic: 68; sh: 52
file content (77 lines) | stat: -rw-r--r-- 3,122 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
includefile(header.inc)

COMMENT(manpage, section, releasedate, archive, short name)
manpage(FBB::SocketBase)(3bobcat)(_CurYrs_)(libbobcat1-dev__CurVers_-x.tar.gz)
                    (Base class for sockets)

manpagename(FBB::SocketBase)(Base class for socket-constructing classes)

manpagesynopsis()
    bf(#include <bobcat/socketbase>)nl()
    Linking option: tt(-lbobcat) 

manpagedescription()
    This class is a base class for the bf(FBB::ServerSocket) and
bf(FBB::ClientSocket) classes. Since it is designed as a base class, all its
constructors are protected.

includefile(namespace.inc)

manpagesection(INHERITS FROM)
    bf(FBB::InetAddress)

manpagesection(PROTECTED CONSTRUCTORS)
    itemization(
    itb(SocketBase(size_t port) throw (FBB::Errno)) 
        This constructor creates a bf(SocketBase) to be used with
bf(ServerSocket)-objects, listening on tt(port). If the socket could
not be constructed, an bf(FBB::Errno) exception is thrown.
    itb(SocketBase(std::string const &host, unit_16_t port)) 
        This constructor creates a bf(FBB::SocketBase) to be used with a
bf(ClientSocket)-object, connecting to tt(hostname), at port `tt(port)'.  If
the socket could not be constructed or if the host's address information could
not be determined, an bf(FBB::Errno) exception is thrown.
    itb(SocketBase(int socket, sockaddr_in const &address))
        This constructor constructs a bf(FBB::SocketBase) object initializing
its socket and bf(FBB::InetAddress) part from available external objects.
    )
    The copy constructor is not available.

manpagesection(MEMBER FUNCTIONS)
     All members of bf(FBB::InetAddress) are
available, as bf(FBB::SocketBase) inherits from this class.
    itemization(
    itb(bool debug() const throw(Errno))
        This accessor returns bf(true) if the socket's em(debug)
(bf(SO_DEBUG)) socket option is active. It throws an bf(FBB::Errno) exception
if the status of the debug option could not be determined.
    itb(bool reuse() const throw(Errno))
        This accessor returns bf(true) if the socket's em(reuse)
(bf(SO_REUSEADDR)) socket option is active. It throws an bf(FBB::Errno)
exception if the status of the reuse option could not be determined.
    itb(void setDebug(bool trueIsOn) const throw(Errno))
        This member may be used to modify the socket's em(debug)
(bf(SO_DEBUG)) socket option. It throws an bf(FBB::Errno) exception
if the socket's debug option could not be modified.
    itb(void setReuse(bool trueIsOn) const throw(Errno))
        This member may be used to modify the socket's em(reuse)
(bf(SO_REUSEADDR)) socket option. It throws an bf(FBB::Errno) exception
if the socket's reuse option could not be modified.
    itb(int socket() const)
        This accessor returns the bf(FBB::SocketBase)'s socket value.
    )

manpagesection(EXAMPLE)
    To do

manpagefiles()
    em(bobcat/socketbase) - defines the class interface

manpageseealso()
    bf(bobcat)(7), bf(clientsocket)(3bobcat), bf(inetaddress)(3bobcat),
    bf(localsocketbase)(3bobcat), bf(serversocket)(3bobcat)

manpagebugs()
    None Reported.

includefile(trailer.inc)