]> git.saurik.com Git - wxWidgets.git/blame - docs/latex/wx/inputstr.tex
wxLog::FlushActive added
[wxWidgets.git] / docs / latex / wx / inputstr.tex
CommitLineData
e2a6f233
JS
1% -----------------------------------------------------------------------------
2% wxInputStream
3% -----------------------------------------------------------------------------
4\section{\class{wxInputStream}}\label{wxinputstream}
5
6\wxheading{Derived from}
7
8\helpref{wxStreamBase}{wxstreambase}
9
954b8ae6
JS
10\wxheading{Include files}
11
12<wx/stream.h>
13
e2a6f233
JS
14% -----------
15% ctor & dtor
16% -----------
17\membersection{wxInputStream::wxInputStream}
18
19\func{}{wxInputStream}{\void}
20
21Creates a dummy input stream.
22
e2a6f233
JS
23\membersection{wxInputStream::\destruct{wxInputStream}}
24
25\func{}{\destruct{wxInputStream}}{\void}
26
27Destructor.
28
e2a6f233
JS
29\membersection{wxInputStream::GetC}
30
31\func{char}{GetC}{\void}
32
33Returns the first character in the input queue and removes it.
34
39b91eca 35\membersection{wxInputStream::LastRead}\label{wxinputstreamlastread}
40b480c3
JS
36
37\constfunc{size\_t}{LastRead}{\void}
38
39Returns the last number of bytes read.
40
41\membersection{wxInputStream::Peek}
42
43\func{char}{Peek}{\void}
44
45Returns the first character in the input queue without removing it.
46
e2a6f233
JS
47\membersection{wxInputStream::Read}
48
40b480c3 49\func{wxInputStream\&}{Read}{\param{void *}{buffer}, \param{size\_t}{ size}}
e2a6f233
JS
50
51Reads the specified amount of bytes and stores the data in \it{buffer}.
52
da3aea64
GL
53\wxheading{Warning}
54
55The buffer absolutely needs to have at least the specified size.
56
57\wxheading{Return value}
e2a6f233
JS
58
59This function returns a reference on the current object, so the user can test
60any states of the stream right away.
61
294e9a7a 62\func{wxInputStream\&}{Read}{\param{wxOutputStream\&}{ stream\_out}}
e2a6f233
JS
63
64Reads data from the input queue and stores it in the specified output stream.
65The data is read until an error is raised by one of the two streams.
66
da3aea64
GL
67\wxheading{Return value}
68
69This function returns a reference on the current object, so the user can test
70any states of the stream right away.
71
e2a6f233
JS
72\membersection{wxInputStream::SeekI}
73
40b480c3 74\func{off\_t}{SeekI}{\param{off\_t}{ pos}, \param{wxSeekMode}{ mode = wxFromStart}}
e2a6f233
JS
75
76Changes the stream current position.
77
78\membersection{wxInputStream::TellI}
79
40b480c3 80\constfunc{off\_t}{TellI}{\void}
e2a6f233
JS
81
82Returns the current stream position.
83
c7d9131a
GL
84\membersection{wxInputStream::Ungetch}\label{wxinputstream_ungetch}
85
86\func{size\_t}{Ungetch}{\param{const char*}{ buffer}, \param{size\_t}{ size}}
87
88This function is only useful in \it{read} mode. It is the manager of the "Write-Back"
89buffer. This buffer acts like a temporary buffer where datas which has to be
90read during the next read IO call are put. This is useful when you get a big
91block of data which you didn't want to read: you can replace them at the top
92of the input queue by this way.
93
94\wxheading{Return value}
95
96Returns the amount of bytes saved in the Write-Back buffer.
97
98\func{bool}{Ungetch}{\param{char }{c}}
99
100This function acts like the previous one except that it takes only one
101character: it is sometimes shorter to use than the generic function.
102