00001
00002
00003
00004
00005
00006
00007
00008 #ifndef DATE_VALIDATOR_H_
00009 #define DATE_VALIDATOR_H_
00010
00011 #include <boost/date_time/gregorian/gregorian_types.hpp>
00012
00013 #include <Wt/WRegExpValidator>
00014
00015 using namespace Wt;
00016
00021
00033 class DateValidator : public WRegExpValidator
00034 {
00035 public:
00040 DateValidator(const boost::gregorian::date& bottom,
00041 const boost::gregorian::date& top);
00042
00043
00044
00045
00046
00047 virtual State validate(WString& input) const;
00048
00049 private:
00050 boost::gregorian::date bottom_, top_;
00051 };
00052
00055 #endif // DATE_VALIDATOR_H_