Develop and Download Open Source Software

Browse Subversion Repository

Contents of /connection/TcpipAccept.h

Parent Directory Parent Directory | Revision Log Revision Log


Revision 383 - (show annotations) (download) (as text)
Tue Dec 11 07:55:09 2012 UTC (11 years, 4 months ago) by satofumi
File MIME type: text/x-chdr
File size: 1348 byte(s)
fix compile error
1 #ifndef TCPIP_ACCEPT_H
2 #define TCPIP_ACCEPT_H
3
4 /*!
5 \file
6 \brief TCP/IP 接続用ポート
7
8 \author Satofumi KAMIMURA
9
10 $Id$
11 */
12
13 #include <memory>
14 #include <cstddef>
15
16
17 namespace beego {
18 class TcpipCtrl;
19 class SocketSet;
20
21
22 /*!
23 \brief TCP/IP 接続のサーバ
24 */
25 class TcpipAccept {
26 TcpipAccept(const TcpipAccept& rhs);
27 TcpipAccept& operator = (const TcpipAccept& rhs);
28
29 struct pImpl;
30 const std::auto_ptr<pImpl> pimpl;
31
32 public:
33 TcpipAccept(void);
34 ~TcpipAccept(void);
35
36 /*!
37 \brief 内部状態を返す
38
39 \return 内部状態を示す文字列
40 */
41 const char* what(void);
42
43 /*!
44 \brief 接続ポートの有効化
45
46 \param port [i] ポート番号
47
48 \retval true 有効化に成功
49 \retval false 有効化に失敗
50 */
51 bool activate(unsigned short port);
52
53 /*!
54 \brief 接続ポートの無効化
55 */
56 void deactivate(void);
57
58 /*!
59 \brief 接続ポートが有効かどうか
60
61 \retval true 有効
62 \retval false 無効
63 */
64 bool isActivated(void);
65
66 /*!
67 \brief 接続処理
68
69 \param timeout [i] タイムアウト時間 [msec]
70 \param socketSet [i] 通信ソケットの管理オブジェクト
71
72 \retval ! NULL 新たに生成された TcpipCtrl オブジェクトを返す
73 \retval NULL 接続失敗
74 */
75 TcpipCtrl* accept(int timeout, SocketSet* socketSet = NULL);
76 };
77 };
78
79 #endif /* !TCPIP_ACCEPT_H */

Back to OSDN">Back to OSDN
ViewVC Help
Powered by ViewVC 1.1.26