kdgantt2
#include <kdganttconstraintmodel.h>
Classes | |
class | Private |
Signals | |
void | constraintAdded (const Constraint &) |
void | constraintRemoved (const Constraint &) |
Public Member Functions | |
ConstraintModel (QObject *parent=0) | |
virtual | ~ConstraintModel () |
void | addConstraint (const Constraint &c) |
void | cleanup () |
void | clear () |
QList< Constraint > | constraints () const |
QList< Constraint > | constraintsForIndex (const QModelIndex &) const |
bool | hasConstraint (const Constraint &c) const |
bool | hasConstraint (const QModelIndex &s, const QModelIndex &e) const |
bool | removeConstraint (const Constraint &c) |
Detailed Description
The ConstraintModel keeps track of the interdependencies between gantt items in a View.
Definition at line 35 of file kdganttconstraintmodel.h.
Constructor & Destructor Documentation
|
explicit |
Constructor. Creates an empty ConstraintModel with parent parent
Definition at line 72 of file kdganttconstraintmodel.cpp.
|
virtual |
Destroys this ConstraintModel
Definition at line 86 of file kdganttconstraintmodel.cpp.
Member Function Documentation
void ConstraintModel::addConstraint | ( | const Constraint & | c | ) |
Adds the constraint c to this ConstraintModel If the Constraint c is already in this ConstraintModel, nothing happens.
Definition at line 101 of file kdganttconstraintmodel.cpp.
void ConstraintModel::cleanup | ( | ) |
Not used
Definition at line 148 of file kdganttconstraintmodel.cpp.
void ConstraintModel::clear | ( | ) |
Removes all Constraints from this model The signal constraintRemoved(const Constraint&) is emitted for every Constraint that is removed.
Definition at line 139 of file kdganttconstraintmodel.cpp.
|
signal |
|
signal |
QList< Constraint > ConstraintModel::constraints | ( | ) | const |
- Returns
- A list of all Constraints in this ConstraintModel.
Definition at line 163 of file kdganttconstraintmodel.cpp.
QList< Constraint > ConstraintModel::constraintsForIndex | ( | const QModelIndex & | idx | ) | const |
- Returns
- A list of all Constraints in this ConstraintModel that have an endpoint at idx.
Definition at line 172 of file kdganttconstraintmodel.cpp.
bool ConstraintModel::hasConstraint | ( | const Constraint & | c | ) | const |
Returns true if a Constraint with start s and end e exists, otherwise false.
Definition at line 196 of file kdganttconstraintmodel.cpp.
|
inline |
Definition at line 66 of file kdganttconstraintmodel.h.
bool ConstraintModel::removeConstraint | ( | const Constraint & | c | ) |
Removes the Constraint c from this ConstraintModel. If c was found and removed, the signal constraintRemoved(const Constraint&) is emitted.
- Returns
- If c was found and removed, it returns true, otherwise it returns false.
Definition at line 122 of file kdganttconstraintmodel.cpp.
The documentation for this class was generated from the following files:
Documentation copyright © 1996-2014 The KDE developers.
Generated on Tue Oct 14 2014 22:55:05 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.