Wt::WLengthValidator Class Reference

A validator that checks the string length of user input. More...

#include <WLengthValidator>

Inheritance diagram for Wt::WLengthValidator:

Inheritance graph
[legend]

List of all members.

Public Member Functions

 WLengthValidator (int minLength=0, int maxLength=std::numeric_limits< int >::min())
 Create a new validator.
double minimumLength () const
 Return the minimum length.
void setMinimumLength (int minimum)
 Set the minimum length.
void setInvalidTooShortText (const WString &text)
 Set message to display when the input is too short.
double maximumLength () const
 Return the maximum length.
void setMaximumLength (int maximum)
 Set the maximum length.
void setInvalidTooLongText (const WString &text)
 Set message to display when the input is too long.
virtual State validate (WString &input, int &pos) const
 Validate the input as an double within the given range.
virtual void createExtConfig (std::ostream &config) const
 Provide Ext-compatible config options for client-side validation.


Detailed Description

A validator that checks the string length of user input.

This validator checks whether user input is within the specified range of accepted string lengths


Member Function Documentation

WValidator::State Wt::WLengthValidator::validate ( WString input,
int &  pos 
) const [virtual]

Validate the input as an double within the given range.

Returns Valid if the input is an double in the given range. Returns Invalid if the input is not an double, or outside of the given range.

Reimplemented from Wt::WValidator.


The documentation for this class was generated from the following files:
Generated on Mon Apr 14 15:15:01 2008 for Wt by doxygen 1.5.3