]>
Commit | Line | Data |
---|---|---|
1 | \section{\class{wxProtocol}}\label{wxprotocol} | |
2 | ||
3 | \wxheading{Derived from} | |
4 | ||
5 | \helpref{wxSocketClient}{wxsocketclient} | |
6 | \helpref{wxSocketBase}{wxsocketbase} | |
7 | \helpref{wxObject}{wxobject} | |
8 | ||
9 | \wxheading{Include files} | |
10 | ||
11 | <wx/protocol/protocol.h> | |
12 | ||
13 | \wxheading{See also} | |
14 | ||
15 | \helpref{wxSocketBase}{wxsocketbase}, \helpref{wxURL}{wxurl} | |
16 | ||
17 | % ---------------------------------------------------------------------------- | |
18 | % Members | |
19 | % ---------------------------------------------------------------------------- | |
20 | ||
21 | \latexignore{\rtfignore{\wxheading{Members}}} | |
22 | ||
23 | \membersection{wxProtocol::Reconnect}\label{wxprotocolreconnect} | |
24 | ||
25 | \func{bool}{Reconnect}{\void} | |
26 | ||
27 | Tries to reestablish a previous opened connection (close and renegotiate connection). | |
28 | ||
29 | \wxheading{Return value} | |
30 | ||
31 | true, if the connection is established, else false. | |
32 | ||
33 | % ---------------------------------------------------------------------------- | |
34 | \membersection{wxProtocol::GetInputStream}\label{wxprotocolgetinput} | |
35 | ||
36 | \func{wxInputStream *}{GetInputStream}{\param{const wxString\&}{ path}} | |
37 | ||
38 | Creates a new input stream on the specified path. You can use all but seek | |
39 | functionality of wxStream. Seek isn't available on all streams. For example, | |
40 | HTTP or FTP streams don't deal with it. Other functions like StreamSize and | |
41 | Tell aren't available for the moment for this sort of stream. | |
42 | You will be notified when the EOF is reached by an error. | |
43 | ||
44 | \wxheading{Return value} | |
45 | ||
46 | Returns the initialized stream. You will have to delete it yourself once you | |
47 | don't use it anymore. The destructor closes the network connection. | |
48 | ||
49 | \wxheading{See also} | |
50 | ||
51 | \helpref{wxInputStream}{wxinputstream} | |
52 | ||
53 | % ---------------------------------------------------------------------------- | |
54 | \membersection{wxProtocol::Abort}\label{wxprotocolabort} | |
55 | ||
56 | \func{bool}{Abort}{\void} | |
57 | ||
58 | Abort the current stream. | |
59 | ||
60 | \wxheading{Warning} | |
61 | ||
62 | It is advised to destroy the input stream instead of aborting the stream this way. | |
63 | ||
64 | \wxheading{Return value} | |
65 | ||
66 | Returns true, if successful, else false. | |
67 | ||
68 | % ---------------------------------------------------------------------------- | |
69 | \membersection{wxProtocol::GetError}\label{wxprotocolgeterror} | |
70 | ||
71 | \func{wxProtocolError}{GetError}{\void} | |
72 | ||
73 | Returns the last occurred error. | |
74 | ||
75 | \twocolwidtha{7cm} | |
76 | \begin{twocollist}\itemsep=0pt | |
77 | \twocolitem{{\bf wxPROTO\_NOERR}}{No error.} | |
78 | \twocolitem{{\bf wxPROTO\_NETERR}}{A generic network error occurred.} | |
79 | \twocolitem{{\bf wxPROTO\_PROTERR}}{An error occurred during negotiation.} | |
80 | \twocolitem{{\bf wxPROTO\_CONNERR}}{The client failed to connect the server.} | |
81 | \twocolitem{{\bf wxPROTO\_INVVAL}}{Invalid value.} | |
82 | \twocolitem{{\bf wxPROTO\_NOHNDLR}}{.} | |
83 | \twocolitem{{\bf wxPROTO\_NOFILE}}{The remote file doesn't exist.} | |
84 | \twocolitem{{\bf wxPROTO\_ABRT}}{Last action aborted.} | |
85 | \twocolitem{{\bf wxPROTO\_RCNCT}}{An error occurred during reconnection.} | |
86 | \twocolitem{{\bf wxPROTO\_STREAM}}{Someone tried to send a command during a transfer.} | |
87 | \end{twocollist} | |
88 | ||
89 | % ---------------------------------------------------------------------------- | |
90 | \membersection{wxProtocol::GetContentType}\label{wxprotocolgetcontenttype} | |
91 | ||
92 | \func{wxString}{GetContentType}{\void} | |
93 | ||
94 | Returns the type of the content of the last opened stream. It is a mime-type. | |
95 | ||
96 | % ---------------------------------------------------------------------------- | |
97 | \membersection{wxProtocol::SetUser}\label{wxprotocolsetuser} | |
98 | ||
99 | \func{void }{SetUser}{\param{const wxString\&}{ user}} | |
100 | ||
101 | Sets the authentication user. It is mainly useful when FTP is used. | |
102 | ||
103 | \membersection{wxProtocol::SetPassword}\label{wxprotocolsetpassword} | |
104 | ||
105 | \func{void}{SetPassword}{\param{const wxString\&}{ user}} | |
106 | ||
107 | Sets the authentication password. It is mainly useful when FTP is used. | |
108 |