25 #ifndef WPROPERTYCONSTRAINTISVALID_H
26 #define WPROPERTYCONSTRAINTISVALID_H
28 #include "../WPropertyTypes.h"
29 #include "WPropertyConstraintTypes.h"
35 template<
typename T >
64 virtual PROPERTYCONSTRAINT_TYPE
getType();
71 virtual boost::shared_ptr< typename WPropertyVariable< T >::PropertyConstraint >
clone();
76 template <
typename T >
81 template <
typename T >
86 template <
typename T >
89 return value.isValid();
92 template <
typename T >
98 template <
typename T >
104 #endif // WPROPERTYCONSTRAINTISVALID_H
virtual PROPERTYCONSTRAINT_TYPE getType()
Allows simple identification of the real constraint type.
virtual boost::shared_ptr< typename WPropertyVariable< T >::PropertyConstraint > clone()
Method to clone the constraint and create a new one with the correct dynamic type.
A named property class with a concrete type.
virtual ~WPropertyConstraintIsValid()
Destructor.
This class allows constraining properties to only be set if a isValid method returns true...
virtual bool accept(boost::shared_ptr< WPropertyVariable< T > > property, const T &value)
Checks whether the specified new value is a valid, using T::isValid.
WPropertyConstraintIsValid()
Constructor.
PropertyConstraint()
Default constructor.