Constraint integer properties This property fullfill the need of constraint integer. More...
#include <PropertyStandard.h>
Classes | |
struct | Constraints |
Constraint methods. More... | |
Public Member Functions | |
virtual const char * | getEditorName (void) const |
Get the class name of the associated property editor item. | |
virtual Base::Type | getTypeId (void) const |
PropertyIntegerConstraint () | |
Standard constructor. | |
virtual void | setPyObject (PyObject *) |
~PropertyIntegerConstraint () | |
destructor | |
const Constraints * | getConstraints (void) const |
get the constraint struct | |
void | setConstraints (const Constraints *sConstraint) |
setting the boundaries This sets the constraint struct. | |
Static Public Member Functions | |
static void * | create (void) |
static Base::Type | getClassTypeId (void) |
static void | init (void) |
Protected Attributes | |
const Constraints * | _ConstStruct |
Constraint integer properties This property fullfill the need of constraint integer.
It holds basicly a state (integer) and a struct of boundaries. If the boundaries is not set it act basicly like a IntegerProperty and do no checking. The constraints struct can be created on the heap or build in.
Definition at line 196 of file PropertyStandard.h.
PropertyIntegerConstraint::PropertyIntegerConstraint | ( | ) |
Standard constructor.
Definition at line 523 of file PropertyStandard.cpp.
PropertyIntegerConstraint::~PropertyIntegerConstraint | ( | ) |
destructor
Definition at line 530 of file PropertyStandard.cpp.
void * App::PropertyIntegerConstraint::create | ( | void | ) | [static] |
Reimplemented from App::PropertyInteger.
Reimplemented in App::PropertyPercent.
Definition at line 517 of file PropertyStandard.cpp.
Base::Type App::PropertyIntegerConstraint::getClassTypeId | ( | void | ) | [static] |
Reimplemented from App::PropertyInteger.
Reimplemented in App::PropertyPercent.
Definition at line 517 of file PropertyStandard.cpp.
Referenced by Gui::PropertyEditor::PropertyIntegerConstraintItem::value().
const PropertyIntegerConstraint::Constraints * PropertyIntegerConstraint::getConstraints | ( | void | ) | const |
get the constraint struct
Definition at line 540 of file PropertyStandard.cpp.
References _ConstStruct.
virtual const char* App::PropertyIntegerConstraint::getEditorName | ( | void | ) | const [inline, virtual] |
Get the class name of the associated property editor item.
Reimplemented from App::PropertyInteger.
Definition at line 226 of file PropertyStandard.h.
Base::Type App::PropertyIntegerConstraint::getTypeId | ( | void | ) | const [virtual] |
Reimplemented from App::PropertyInteger.
Reimplemented in App::PropertyPercent.
Definition at line 517 of file PropertyStandard.cpp.
void App::PropertyIntegerConstraint::init | ( | void | ) | [static] |
Reimplemented from App::PropertyInteger.
Reimplemented in App::PropertyPercent.
Definition at line 517 of file PropertyStandard.cpp.
void PropertyIntegerConstraint::setConstraints | ( | const Constraints * | sConstraint | ) |
setting the boundaries This sets the constraint struct.
It can be dynamcly allocated or set as an static in the class the property blongs to:
const Constraints percent = {0,100,1}
Definition at line 535 of file PropertyStandard.cpp.
References _ConstStruct.
Referenced by App::FeatureTest::FeatureTest(), and Gui::ViewProviderGeometryObject::ViewProviderGeometryObject().
void PropertyIntegerConstraint::setPyObject | ( | PyObject * | value | ) | [virtual] |
Reimplemented from App::PropertyInteger.
Definition at line 545 of file PropertyStandard.cpp.
References _ConstStruct, App::PropertyInteger::_lValue, App::Property::aboutToSetValue(), draftlibs::dxfReader::error(), App::Property::hasSetValue(), App::PropertyIntegerConstraint::Constraints::LowerBound, and App::PropertyIntegerConstraint::Constraints::UpperBound.
const Constraints* App::PropertyIntegerConstraint::_ConstStruct [protected] |
Definition at line 230 of file PropertyStandard.h.
Referenced by getConstraints(), App::PropertyPercent::PropertyPercent(), setConstraints(), and setPyObject().