File: classWt_1_1WRegExpValidator.html

package info (click to toggle)
witty 3.2.1-2%2Bdeb7u1
  • links: PTS
  • area: main
  • in suites: wheezy
  • size: 70,436 kB
  • sloc: cpp: 117,095; ansic: 77,999; xml: 7,564; sh: 1,037; perl: 208; makefile: 144; java: 86; sql: 14
file content (365 lines) | stat: -rw-r--r-- 23,520 bytes parent folder | download
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
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
<!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>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<title>Wt: Wt::WRegExpValidator Class Reference</title>

<link href="tabs.css" rel="stylesheet" type="text/css"/>
<link href="doxygen.css" rel="stylesheet" type="text/css" />

<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="search/search.js"></script>
<script type="text/javascript">
  $(document).ready(function() { searchBox.OnSelectItem(0); });
</script>

</head>
<body>
<div id="top"><!-- do not remove this div! -->


<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  
  
  <td style="padding-left: 0.5em;">
   <div id="projectname">Wt
   &#160;<span id="projectnumber">3.2.1</span>
   </div>
   
  </td>
  
  
  
 </tr>
 </tbody>
</table>
</div>

<!-- Generated by Doxygen 1.7.5.1 -->
<script type="text/javascript">
var searchBox = new SearchBox("searchBox", "search",false,'Search');
</script>
  <div id="navrow1" class="tabs">
    <ul class="tablist">
      <li><a href="index.html"><span>Main&#160;Page</span></a></li>
      <li><a href="pages.html"><span>Related&#160;Pages</span></a></li>
      <li><a href="modules.html"><span>Modules</span></a></li>
      <li><a href="namespaces.html"><span>Namespaces</span></a></li>
      <li class="current"><a href="annotated.html"><span>Classes</span></a></li>
      <li><a href="files.html"><span>Files</span></a></li>
      <li>
        <div id="MSearchBox" class="MSearchBoxInactive">
        <span class="left">
          <img id="MSearchSelect" src="search/mag_sel.png"
               onmouseover="return searchBox.OnSearchSelectShow()"
               onmouseout="return searchBox.OnSearchSelectHide()"
               alt=""/>
          <input type="text" id="MSearchField" value="Search" accesskey="S"
               onfocus="searchBox.OnSearchFieldFocus(true)" 
               onblur="searchBox.OnSearchFieldFocus(false)" 
               onkeyup="searchBox.OnSearchFieldChange(event)"/>
          </span><span class="right">
            <a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="search/close.png" alt=""/></a>
          </span>
        </div>
      </li>
    </ul>
  </div>
  <div id="navrow2" class="tabs2">
    <ul class="tablist">
      <li><a href="annotated.html"><span>Class&#160;List</span></a></li>
      <li><a href="inherits.html"><span>Class&#160;Hierarchy</span></a></li>
      <li><a href="functions.html"><span>Class&#160;Members</span></a></li>
    </ul>
  </div>
  <div id="nav-path" class="navpath">
    <ul>
      <li class="navelem"><a class="el" href="namespaceWt.html">Wt</a>      </li>
      <li class="navelem"><a class="el" href="classWt_1_1WRegExpValidator.html">WRegExpValidator</a>      </li>
    </ul>
  </div>
</div>
<div class="header">
  <div class="summary">
<a href="#pub-methods">Public Member Functions</a>  </div>
  <div class="headertitle">
<div class="title">Wt::WRegExpValidator Class Reference</div>  </div>
</div>
<div class="contents">
<!-- doxytag: class="Wt::WRegExpValidator" --><!-- doxytag: inherits="Wt::WValidator" -->
<p>A validator that checks user input against a regular expression.  
 <a href="classWt_1_1WRegExpValidator.html#details">More...</a></p>

<p><code>#include &lt;Wt/WRegExpValidator&gt;</code></p>
<div class="dynheader">
Inheritance diagram for Wt::WRegExpValidator:</div>
<div class="dyncontent">
<div class="center"><img src="classWt_1_1WRegExpValidator__inherit__graph.png" border="0" usemap="#Wt_1_1WRegExpValidator_inherit__map" alt="Inheritance graph"/></div>
<map name="Wt_1_1WRegExpValidator_inherit__map" id="Wt_1_1WRegExpValidator_inherit__map">
<area shape="rect" href="classWt_1_1WValidator.html" title="A validator is used to validate user input according to pre&#45;defined rules." alt="" coords="28,80,137,107"/><area shape="rect" href="classWt_1_1WObject.html" title="A base class for objects that participate in the signal/slot system." alt="" coords="35,5,131,32"/></map>
<center><span class="legend">[<a href="graph_legend.html">legend</a>]</span></center></div>

<p><a href="classWt_1_1WRegExpValidator-members.html">List of all members.</a></p>
<table class="memberdecls">
<tr><td colspan="2"><h2><a name="pub-methods"></a>
Public Member Functions</h2></td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="ac73905fa4427ee0ab0ee83e6eeac0373"></a><!-- doxytag: member="Wt::WRegExpValidator::WRegExpValidator" ref="ac73905fa4427ee0ab0ee83e6eeac0373" args="(WObject *parent=0)" -->
&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WRegExpValidator.html#ac73905fa4427ee0ab0ee83e6eeac0373">WRegExpValidator</a> (<a class="el" href="classWt_1_1WObject.html">WObject</a> *parent=0)</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Sets a new regular expression validator. <br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WRegExpValidator.html#a7536b67e2bedd2dfdb5b89c9dd56602b">WRegExpValidator</a> (const <a class="el" href="classWt_1_1WString.html">WString</a> &amp;pattern, <a class="el" href="classWt_1_1WObject.html">WObject</a> *parent=0)</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Sets a new regular expression validator that accepts input that matches the given regular expression.  <a href="#a7536b67e2bedd2dfdb5b89c9dd56602b"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="aa3a0d2b4c2bec81325eebfab1530d3dc"></a><!-- doxytag: member="Wt::WRegExpValidator::~WRegExpValidator" ref="aa3a0d2b4c2bec81325eebfab1530d3dc" args="()" -->
&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WRegExpValidator.html#aa3a0d2b4c2bec81325eebfab1530d3dc">~WRegExpValidator</a> ()</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Destructor. <br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WRegExpValidator.html#a71190cef122cc6000be16d9703393cd9">setRegExp</a> (const <a class="el" href="classWt_1_1WString.html">WString</a> &amp;pattern)</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Sets the regular expression for valid input.  <a href="#a71190cef122cc6000be16d9703393cd9"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="classWt_1_1WString.html">WString</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WRegExpValidator.html#ad4af69a61c23bf59db1b7c6bedf56311">regExp</a> () const </td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Returns the regular expression for valid input.  <a href="#ad4af69a61c23bf59db1b7c6bedf56311"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a461e39a6e009efe786d3189f5ca91584"></a><!-- doxytag: member="Wt::WRegExpValidator::setFlags" ref="a461e39a6e009efe786d3189f5ca91584" args="(WFlags&lt; RegExpFlag &gt; flags)" -->
void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WRegExpValidator.html#a461e39a6e009efe786d3189f5ca91584">setFlags</a> (WFlags&lt; <a class="el" href="namespaceWt.html#a6bde75e90de6c0a1611951ae632e2ca2">RegExpFlag</a> &gt; flags)</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Sets regular expression matching flags. <br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a50d1c191711ad6d900b274547dd069ef"></a><!-- doxytag: member="Wt::WRegExpValidator::flags" ref="a50d1c191711ad6d900b274547dd069ef" args="() const " -->
WFlags&lt; <a class="el" href="namespaceWt.html#a6bde75e90de6c0a1611951ae632e2ca2">RegExpFlag</a> &gt;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WRegExpValidator.html#a50d1c191711ad6d900b274547dd069ef">flags</a> () const </td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Returns regular expression matching flags. <br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">virtual <a class="el" href="classWt_1_1WValidator_1_1Result.html">Result</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WRegExpValidator.html#a48e12373f8cf76d7e1dfaa2b6f74bea0">validate</a> (const <a class="el" href="classWt_1_1WString.html">WString</a> &amp;input) const </td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Validates the given input.  <a href="#a48e12373f8cf76d7e1dfaa2b6f74bea0"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a6ca44df82213538b13026d27f721669c"></a><!-- doxytag: member="Wt::WRegExpValidator::createExtConfig" ref="a6ca44df82213538b13026d27f721669c" args="(std::ostream &amp;config) const " -->
virtual void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WRegExpValidator.html#a6ca44df82213538b13026d27f721669c">createExtConfig</a> (std::ostream &amp;config) const </td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Provides Ext-compatible config options for client-side validation. <br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WRegExpValidator.html#a41fdea26cc852b40a1f1c16c09624f01">setNoMatchText</a> (const <a class="el" href="classWt_1_1WString.html">WString</a> &amp;text)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WRegExpValidator.html#a41b52e1428a6561c5be695702e20318a">setInvalidNoMatchText</a> (const <a class="el" href="classWt_1_1WString.html">WString</a> &amp;text)</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Sets the message to display when the input does not match.  <a href="#a41b52e1428a6561c5be695702e20318a"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="classWt_1_1WString.html">WString</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WRegExpValidator.html#a144ed2ffa928a0f6f28e456880126397">invalidNoMatchText</a> () const </td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Returns the message displayed when the input does not match.  <a href="#a144ed2ffa928a0f6f28e456880126397"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">virtual std::string&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WRegExpValidator.html#a436a5203db23b5d67eb83d5f3d3232d2">javaScriptValidate</a> () const </td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Creates a Javascript object that validates the input.  <a href="#a436a5203db23b5d67eb83d5f3d3232d2"></a><br/></td></tr>
</table>
<hr/><a name="details" id="details"></a><h2>Detailed Description</h2>
<div class="textblock"><p>A validator that checks user input against a regular expression. </p>
<p>This validator checks whether user input is matched by the given (perl-like) regular expression.</p>
<p>The following perl features are not supported (since client-side validation cannot handle them): </p>
<ul>
<li>
No Lookbehind support, i.e. the constructs (?&lt;=text) and (?&lt;!text).  </li>
<li>
No atomic grouping, i.e. the construct (?&gt;group). </li>
<li>
No conditional expressions, i.e. the consturct (?ifthen|else). </li>
</ul>
<p>Usage example: </p>
<div class="fragment"><pre class="fragment"> <a class="code" href="classWt_1_1WLineEdit.html" title="A widget that provides a single line edit.">Wt::WLineEdit</a> *lineEdit = <span class="keyword">new</span> <a class="code" href="classWt_1_1WLineEdit.html" title="A widget that provides a single line edit.">Wt::WLineEdit</a>(<span class="keyword">this</span>);
 <span class="comment">// an email address validator</span>
 <a class="code" href="classWt_1_1WRegExpValidator.html" title="A validator that checks user input against a regular expression.">Wt::WRegExpValidator</a> *validator = <span class="keyword">new</span> <a class="code" href="classWt_1_1WRegExpValidator.html#ac73905fa4427ee0ab0ee83e6eeac0373" title="Sets a new regular expression validator.">Wt::WRegExpValidator</a>(<span class="stringliteral">&quot;[a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+\\.[a-zA-Z]{2,4}&quot;</span>);
 lineEdit-&gt;<a class="code" href="classWt_1_1WFormWidget.html#aa773d16013d6959149ce5081e84b259c" title="Sets a validator for this field.">setValidator</a>(validator);
 lineEdit-&gt;<a class="code" href="classWt_1_1WLineEdit.html#addb99c6ab5483836adf44a2706a410af" title="Sets the content of the line edit.">setText</a>(<span class="stringliteral">&quot;koen@emweb.be&quot;</span>);
</pre></div><dl class="note"><dt><b>Note:</b></dt><dd>This validator does not fully support unicode: it matches on the UTF8-encoded representation of the string.</dd></dl>
<h3>i18n</h3>
<p>The strings used in this class can be translated by overriding the default values for the following localization keys:</p>
<ul>
<li><a class="el" href="classWt_1_1WValidator.html#a638a1feefca259ea2f806a8add2d18a3aa5bf750faac5f1ca6fb58c8de97bac51" title="The input is invalid.">Wt.WRegExpValidator.Invalid</a>: Invalid input </li>
</ul>
</div><hr/><h2>Constructor &amp; Destructor Documentation</h2>
<a class="anchor" id="a7536b67e2bedd2dfdb5b89c9dd56602b"></a><!-- doxytag: member="Wt::WRegExpValidator::WRegExpValidator" ref="a7536b67e2bedd2dfdb5b89c9dd56602b" args="(const WString &amp;pattern, WObject *parent=0)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">Wt::WRegExpValidator::WRegExpValidator </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="classWt_1_1WString.html">WString</a> &amp;&#160;</td>
          <td class="paramname"><em>pattern</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="classWt_1_1WObject.html">WObject</a> *&#160;</td>
          <td class="paramname"><em>parent</em> = <code>0</code>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Sets a new regular expression validator that accepts input that matches the given regular expression. </p>
<p>This constructs a validator that matches the perl regular expression <code>expr</code>. </p>

</div>
</div>
<hr/><h2>Member Function Documentation</h2>
<a class="anchor" id="a144ed2ffa928a0f6f28e456880126397"></a><!-- doxytag: member="Wt::WRegExpValidator::invalidNoMatchText" ref="a144ed2ffa928a0f6f28e456880126397" args="() const " -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="classWt_1_1WString.html">WString</a> Wt::WRegExpValidator::invalidNoMatchText </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td> const</td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Returns the message displayed when the input does not match. </p>
<dl class="see"><dt><b>See also:</b></dt><dd><a class="el" href="classWt_1_1WRegExpValidator.html#a41b52e1428a6561c5be695702e20318a" title="Sets the message to display when the input does not match.">setInvalidNoMatchText(const WString&amp;)</a> </dd></dl>

</div>
</div>
<a class="anchor" id="a436a5203db23b5d67eb83d5f3d3232d2"></a><!-- doxytag: member="Wt::WRegExpValidator::javaScriptValidate" ref="a436a5203db23b5d67eb83d5f3d3232d2" args="() const " -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">std::string Wt::WRegExpValidator::javaScriptValidate </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td> const<code> [virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Creates a Javascript object that validates the input. </p>
<p>The JavaScript expression should evaluate to an object which contains a <code>validate(text)</code> function, which returns an object that contains the following two fields:</p>
<ul>
<li>fields: a boolean <em>valid</em>,</li>
<li>a <code>message</code> that indicates the problem if not valid.</li>
</ul>
<p>Returns an empty string if the validator does not provide a client-side validation implementationq.</p>
<dl class="note"><dt><b>Note:</b></dt><dd>The signature and contract changed changed in Wt 3.1.9.</dd></dl>
<dl class="see"><dt><b>See also:</b></dt><dd><a class="el" href="classWt_1_1WValidator.html#a1ca29b7eaabf4c1655200ec382a84554" title="Returns a regular expression that filters input.">inputFilter()</a> </dd></dl>

<p>Reimplemented from <a class="el" href="classWt_1_1WValidator.html#a2aca1c34abaf4a35b972c3cf82ce1e48">Wt::WValidator</a>.</p>

</div>
</div>
<a class="anchor" id="ad4af69a61c23bf59db1b7c6bedf56311"></a><!-- doxytag: member="Wt::WRegExpValidator::regExp" ref="ad4af69a61c23bf59db1b7c6bedf56311" args="() const " -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="classWt_1_1WString.html">WString</a> Wt::WRegExpValidator::regExp </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td> const</td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Returns the regular expression for valid input. </p>
<p>Returns the perl regular expression. </p>

</div>
</div>
<a class="anchor" id="a41b52e1428a6561c5be695702e20318a"></a><!-- doxytag: member="Wt::WRegExpValidator::setInvalidNoMatchText" ref="a41b52e1428a6561c5be695702e20318a" args="(const WString &amp;text)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void Wt::WRegExpValidator::setInvalidNoMatchText </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="classWt_1_1WString.html">WString</a> &amp;&#160;</td>
          <td class="paramname"><em>text</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Sets the message to display when the input does not match. </p>
<p>The default value is "Invalid input". </p>

</div>
</div>
<a class="anchor" id="a41fdea26cc852b40a1f1c16c09624f01"></a><!-- doxytag: member="Wt::WRegExpValidator::setNoMatchText" ref="a41fdea26cc852b40a1f1c16c09624f01" args="(const WString &amp;text)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void Wt::WRegExpValidator::setNoMatchText </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="classWt_1_1WString.html">WString</a> &amp;&#160;</td>
          <td class="paramname"><em>text</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div>
<div class="memdoc">
<p>Sets the text to be shown if no match can be found. </p>

</div>
</div>
<a class="anchor" id="a71190cef122cc6000be16d9703393cd9"></a><!-- doxytag: member="Wt::WRegExpValidator::setRegExp" ref="a71190cef122cc6000be16d9703393cd9" args="(const WString &amp;pattern)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void Wt::WRegExpValidator::setRegExp </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="classWt_1_1WString.html">WString</a> &amp;&#160;</td>
          <td class="paramname"><em>pattern</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Sets the regular expression for valid input. </p>
<p>Sets the perl regular expression <code>expr</code>. </p>

</div>
</div>
<a class="anchor" id="a48e12373f8cf76d7e1dfaa2b6f74bea0"></a><!-- doxytag: member="Wt::WRegExpValidator::validate" ref="a48e12373f8cf76d7e1dfaa2b6f74bea0" args="(const WString &amp;input) const " -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="classWt_1_1WValidator_1_1Result.html">WValidator::Result</a> Wt::WRegExpValidator::validate </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="classWt_1_1WString.html">WString</a> &amp;&#160;</td>
          <td class="paramname"><em>input</em></td><td>)</td>
          <td> const<code> [virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Validates the given input. </p>
<p>The input is considered valid only when it is blank for a non-mandatory field, or matches the regular expression. </p>

<p>Reimplemented from <a class="el" href="classWt_1_1WValidator.html#a78808215d68944dedca11ff8889374ed">Wt::WValidator</a>.</p>

</div>
</div>
</div>
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
<a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(0)"><span class="SelectionMark">&#160;</span>All</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(1)"><span class="SelectionMark">&#160;</span>Classes</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(2)"><span class="SelectionMark">&#160;</span>Namespaces</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(3)"><span class="SelectionMark">&#160;</span>Files</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(4)"><span class="SelectionMark">&#160;</span>Functions</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(5)"><span class="SelectionMark">&#160;</span>Variables</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(6)"><span class="SelectionMark">&#160;</span>Typedefs</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(7)"><span class="SelectionMark">&#160;</span>Enumerations</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(8)"><span class="SelectionMark">&#160;</span>Enumerator</a></div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

<hr size="1"><address style="text-align: right; margin: 3px"><small>
Generated on Fri Mar 30 2012 for <a href="http://www.webtoolkit.eu/wt">the
C++ Web Toolkit (Wt)</a> by&nbsp;<a
href="http://www.doxygen.org/index.html"><img src="doxygen.png"
alt="doxygen" border="0" style="vertical-align: middle; display:
inline-block; height: 2em"></a> 1.7.5.1</small></address>
</body>
</html>