]> git.saurik.com Git - wxWidgets.git/blame - docs/latex/wx/url.tex
cvs debugging
[wxWidgets.git] / docs / latex / wx / url.tex
CommitLineData
e79848ac
GL
1\section{\class{wxURL}}\label{wxurl}
2
3\wxheading{Derived from}
4
5\helpref{wxObject}{wxobject}
6
954b8ae6
JS
7\wxheading{Include files}
8
9<wx/url.h>
10
e79848ac
GL
11\wxheading{See also}
12
42ff6409 13\helpref{wxSocketBase}{wxsocketbase}, \helpref{wxProtocol}{wxprotocol}
e79848ac 14
9a1b2c28
GL
15\wxheading{Example}
16
17\begin{verbatim}
18 wxURL url("http://a.host/a.dir/a.file");
296ec7d3 19 wxInputStream *in_stream;
9a1b2c28 20
296ec7d3
VZ
21 in_stream = url.GetInputStream();
22 // Then, you can use all IO calls of in_stream (See wxStream)
9a1b2c28
GL
23\end{verbatim}
24
e79848ac
GL
25% ----------------------------------------------------------------------------
26% Members
27% ----------------------------------------------------------------------------
296ec7d3
VZ
28
29\latexignore{\rtfignore{\wxheading{Members}}}
e79848ac 30
42ff6409
JS
31\membersection{wxURL::wxURL}\label{wxurlconstr}
32
e79848ac
GL
33\func{}{wxURL}{\param{const wxString\&}{ url}}
34
35Constructs an URL object from the string.
36
37\wxheading{Parameters}
38
39\docparam{url}{Url string to parse.}
40
41\membersection{wxURL::\destruct{wxURL}}
42ff6409 42
e79848ac
GL
43\func{}{\destruct{wxURL}}{\void}
44
45Destroys the URL object.
46
47%
48% GetProtocolName
49%
50\membersection{wxURL::GetProtocolName}
42ff6409 51
e79848ac
GL
52\constfunc{wxString}{GetProtocolName}{\void}
53
54Returns the name of the protocol which will be used to get the URL.
55
56%
57% GetProtocol
58%
59\membersection{wxURL::GetProtocol}
42ff6409 60
e79848ac
GL
61\func{wxProtocol\&}{GetProtocol}{\void}
62
63Returns a reference to the protocol which will be used to get the URL.
64
375abe3d
GL
65%
66% GetPath
67%
68\membersection{wxURL::GetPath}
69
70\func{wxString}{GetPath}{\void}
71
72Returns the path of the file to fetch. This path was encoded in the URL.
73
e79848ac
GL
74%
75% GetError
76%
77\membersection{wxURL::GetError}
42ff6409 78
e79848ac
GL
79\constfunc{wxURLError}{GetError}{\void}
80
81Returns the last error. This error refers to the URL parsing or to the protocol.
82It can be one of these errors:
83
84\twocolwidtha{7cm}
6be663cf 85\begin{twocollist}\itemsep=0pt%
e79848ac
GL
86\twocolitem{{\bf wxURL\_NOERR}}{No error.}
87\twocolitem{{\bf wxURL\_SNTXERR}}{Syntax error in the URL string.}
88\twocolitem{{\bf wxURL\_NOPROTO}}{Found no protocol which can get this URL.}
89\twocolitem{{\bf wxURL\_NOHOST}}{An host name is required for this protocol.}
90\twocolitem{{\bf wxURL\_NOPATH}}{A path is required for this protocol.}
91\twocolitem{{\bf wxURL\_CONNERR}}{Connection error.}
92\twocolitem{{\bf wxURL\_PROTOERR}}{An error occured during negotiation.}
93\end{twocollist}%
94
95%
96% GetInputStream
97%
98\membersection{wxURL::GetInputStream}
42ff6409 99
e79848ac
GL
100\func{wxInputStream *}{GetInputStream}{\void}
101
7d2946d2
GL
102Creates a new input stream on the the specified URL. You can use all but seek
103functionnality of wxStream. Seek isn't available on all stream. For example,
104http or ftp streams doesn't deal with it.
e79848ac 105
42ff6409 106\wxheading{Return value}
e79848ac 107
7d2946d2 108Returns the initialized stream. You will have to delete it yourself.
e79848ac 109
42ff6409 110\wxheading{See also}
e79848ac 111
b82827dd
JS
112%\helpref{wxInputStream}{wxinputstream}
113wxInputStream
e79848ac
GL
114
115%
116% SetDefaultProxy
117%
42ff6409
JS
118\membersection{wxURL::SetDefaultProxy}\label{wxurlsetdefaultproxy}
119
e79848ac
GL
120\func{static void}{SetDefaultProxy}{\param{const wxString\&}{ url\_proxy}}
121
122Sets the default proxy server to use to get the URL. The string specifies
123the proxy like this: <hostname>:<port number>.
124
125\wxheading{Parameters}
126
127\docparam{url\_proxy}{Specifies the proxy to use}
128
129\wxheading{See also}
130
131\helpref{wxURL::SetProxy}{wxurlsetproxy}
132
133%
134% SetProxy
135%
42ff6409
JS
136\membersection{wxURL::SetProxy}\label{wxurlsetproxy}
137
e79848ac
GL
138\func{void}{SetProxy}{\param{const wxString\&}{ url\_proxy}}
139
140Sets the proxy to use for this URL.
141
142\wxheading{See also}
143
144\helpref{wxURL::SetDefaultProxy}{wxurlsetdefaultproxy}
42ff6409 145
5a96d2f4
GL
146%
147% SetProxy
148%
149\membersection{wxURL::ConvertToValidURI}
150
151\func{static wxString}{ConvertToValidURI}{\param{const wxString\&}{ uri}}
152
153It converts a non-standardized URI to a valid network URI. It encodes non
154standard characters.
22d6efa8 155