File: Poco.Token.html

package info (click to toggle)
poco-doc 1.3.6-1
  • links: PTS
  • area: main
  • in suites: buster, jessie, jessie-kfreebsd, squeeze, stretch, wheezy
  • size: 10,076 kB
  • ctags: 9,611
  • sloc: makefile: 31
file content (176 lines) | stat: -rw-r--r-- 8,475 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
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>Class Poco::Token</title>
<meta http-equiv="content-type" content="text/html; charset=utf-8"/>
<meta name="author" content="Applied Informatics Software Engineering GmbH and Contributors"/>
<meta name="publisher" content="Applied Informatics Software Engineering GmbH and Contributors"/>
<meta name="copyright" content="Copyright (c) 2009, Applied Informatics Software Engineering GmbH and Contributors"/>
<meta name="language" content="en"/>
<meta name="date" content="2009-11-24"/>
<meta name="generator" content="PocoDoc"/>
<link rel="stylesheet" href="css/styles.css" type="text/css"/>
</head>
<body bgcolor="#ffffff" leftmargin="0" topmargin="0">
<div class="header">
<h1 class="namespace"><a href="Poco.html" class="namespace">Poco</a></h1>
<h1 class="symbol">class Token</h1>
</div>
<div class="body">
<p>
<b>Library:</b> Foundation<br />
<b>Package:</b> Streams<br />
<b>Header:</b> Poco/Token.h</p>
<h2>Description</h2>
<div class="description">
<p>The base class for all token classes that can be registered with the <a href="Poco.StreamTokenizer.html" title="class Poco::StreamTokenizer">StreamTokenizer</a>. </p>
</div>
<h2>Inheritance</h2>
<p><b>Known Derived Classes: </b><a href="Poco.InvalidToken.html" title="class Poco::InvalidToken">InvalidToken</a>, <a href="Poco.EOFToken.html" title="class Poco::EOFToken">EOFToken</a>, <a href="Poco.WhitespaceToken.html" title="class Poco::WhitespaceToken">WhitespaceToken</a></p>
<h2>Member Summary</h2>
<p><b>Member Functions: </b><a href="Poco.Token.html#11242" title="Poco::Token::asChar()">asChar</a>, <a href="Poco.Token.html#11241" title="Poco::Token::asFloat()">asFloat</a>, <a href="Poco.Token.html#11240" title="Poco::Token::asInteger()">asInteger</a>, <a href="Poco.Token.html#11239" title="Poco::Token::asString()">asString</a>, <a href="Poco.Token.html#11235" title="Poco::Token::finish()">finish</a>, <a href="Poco.Token.html#11243" title="Poco::Token::is()">is</a>, <a href="Poco.Token.html#11232" title="Poco::Token::start()">start</a>, <a href="Poco.Token.html#11237" title="Poco::Token::tokenClass()">tokenClass</a>, <a href="Poco.Token.html#11238" title="Poco::Token::tokenString()">tokenString</a></p>
<h2>Enumerations</h2>
<h3><a name="11212">Class</a></h3>
<div class="description">
<p></p>
</div>
<p class="decl"><a name="11213">IDENTIFIER_TOKEN</a></p>
<div class="description">
<p></p>
</div>
<p class="decl"><a name="11214">KEYWORD_TOKEN</a></p>
<div class="description">
<p></p>
</div>
<p class="decl"><a name="11215">SEPARATOR_TOKEN</a></p>
<div class="description">
<p></p>
</div>
<p class="decl"><a name="11216">OPERATOR_TOKEN</a></p>
<div class="description">
<p></p>
</div>
<p class="decl"><a name="11217">STRING_LITERAL_TOKEN</a></p>
<div class="description">
<p></p>
</div>
<p class="decl"><a name="11218">CHAR_LITERAL_TOKEN</a></p>
<div class="description">
<p></p>
</div>
<p class="decl"><a name="11219">INTEGER_LITERAL_TOKEN</a></p>
<div class="description">
<p></p>
</div>
<p class="decl"><a name="11220">LONG_INTEGER_LITERAL_TOKEN</a></p>
<div class="description">
<p></p>
</div>
<p class="decl"><a name="11221">FLOAT_LITERAL_TOKEN</a></p>
<div class="description">
<p></p>
</div>
<p class="decl"><a name="11222">DOUBLE_LITERAL_TOKEN</a></p>
<div class="description">
<p></p>
</div>
<p class="decl"><a name="11223">COMMENT_TOKEN</a></p>
<div class="description">
<p></p>
</div>
<p class="decl"><a name="11224">SPECIAL_COMMENT_TOKEN</a></p>
<div class="description">
<p></p>
</div>
<p class="decl"><a name="11225">PREPROCESSOR_TOKEN</a></p>
<div class="description">
<p></p>
</div>
<p class="decl"><a name="11226">WHITESPACE_TOKEN</a></p>
<div class="description">
<p></p>
</div>
<p class="decl"><a name="11227">EOF_TOKEN</a></p>
<div class="description">
<p></p>
</div>
<p class="decl"><a name="11228">INVALID_TOKEN</a></p>
<div class="description">
<p></p>
</div>
<p class="decl"><a name="11229">USER_TOKEN</a></p>
<div class="description">
<p></p>
</div>
<h2>Constructors</h2>
<h3><a name="11230">Token</a></h3>
<p class="decl"><a href="Poco.Token.html" title="class Poco::Token">Token</a>();</p>
<div class="description">
<p>Creates the <a href="Poco.Token.html" title="class Poco::Token">Token</a>. </p>
</div>
<h2>Destructor</h2>
<h3><a name="11231">~Token</a> <img src="images/virtual.gif" alt="virtual" title="virtual" style="vertical-align:baseline;" border="0" /> </h3>
<p class="decl">virtual ~<a href="Poco.Token.html" title="class Poco::Token">Token</a>();</p>
<div class="description">
<p>Destroys the <a href="Poco.Token.html" title="class Poco::Token">Token</a>. </p>
</div>
<h2>Member Functions</h2>
<h3><a name="11242">asChar</a> <img src="images/virtual.gif" alt="virtual" title="virtual" style="vertical-align:baseline;" border="0" /> </h3>
<p class="decl">virtual char asChar() const;</p>
<div class="description">
<p>Returns a char representation of the token. </p>
</div>
<h3><a name="11241">asFloat</a> <img src="images/virtual.gif" alt="virtual" title="virtual" style="vertical-align:baseline;" border="0" /> </h3>
<p class="decl">virtual double asFloat() const;</p>
<div class="description">
<p>Returns a floating-point representation of the token. </p>
</div>
<h3><a name="11240">asInteger</a> <img src="images/virtual.gif" alt="virtual" title="virtual" style="vertical-align:baseline;" border="0" /> </h3>
<p class="decl">virtual int asInteger() const;</p>
<div class="description">
<p>Returns an integer representation of the token. </p>
</div>
<h3><a name="11239">asString</a> <img src="images/virtual.gif" alt="virtual" title="virtual" style="vertical-align:baseline;" border="0" /> </h3>
<p class="decl">virtual std::string asString() const;</p>
<div class="description">
<p>Returns a string representation of the token. </p>
</div>
<h3><a name="11235">finish</a> <img src="images/virtual.gif" alt="virtual" title="virtual" style="vertical-align:baseline;" border="0" /> </h3>
<p class="decl">virtual void finish(<br />&nbsp;&nbsp;&nbsp;&nbsp;std::istream &amp; istr<br />);</p>
<div class="description">
<p>Builds the token by reading and appending  the remaining characters from istr. </p>
</div>
<h3><a name="11243">is</a> <img src="images/inline.gif" alt="inline" title="inline" style="vertical-align:baseline;" border="0" /> </h3>
<p class="decl">bool is(<br />&nbsp;&nbsp;&nbsp;&nbsp;<a href="Poco.Token.html#11212" title="enum  Poco::Token::Class">Class</a> tokenClass<br />) const;</p>
<div class="description">
<p>Returns true if and only if the token has the given class. </p>
</div>
<h3><a name="11232">start</a> <img src="images/virtual.gif" alt="virtual" title="virtual" style="vertical-align:baseline;" border="0" /> </h3>
<p class="decl">virtual bool start(<br />&nbsp;&nbsp;&nbsp;&nbsp;char c,<br />&nbsp;&nbsp;&nbsp;&nbsp;std::istream &amp; istr<br />);</p>
<div class="description">
<p>Checks if the given character (and, optionally, the next character in the input stream) start a valid token. Returns true if so, false otherwise. </p>
<p>The current read position in istr must not be changed. In other words, only the peek() method of istream may be used. </p>
<p>If the character starts the token, it should be set as the token's value. </p>
</div>
<h3><a name="11237">tokenClass</a> <img src="images/virtual.gif" alt="virtual" title="virtual" style="vertical-align:baseline;" border="0" /> </h3>
<p class="decl">virtual <a href="Poco.Token.html#11212" title="enum  Poco::Token::Class">Class</a> tokenClass() const;</p>
<div class="description">
<p>Returns the kind of the token. </p>
</div>
<h3><a name="11238">tokenString</a> <img src="images/inline.gif" alt="inline" title="inline" style="vertical-align:baseline;" border="0" /> </h3>
<p class="decl">const std::string &amp; tokenString() const;</p>
<div class="description">
<p>Returns the token's raw string. </p>
</div>
<h2>Variables</h2>
<h3><a name="11245">_value</a> <img src="images/protected.gif" alt="protected" title="protected" style="vertical-align:baseline;" border="0" /> </h3>
<p class="decl">std::string _value;</p>
<div class="description">
<p></p>
</div>
<p class="footer">POCO C++ Libraries 1.3.6-all<br />
Copyright &copy; 2009, <a href="http://pocoproject.org/" target="_blank">Applied Informatics Software Engineering GmbH and Contributors</a></p>

</div>
</body>
</html>