Medical Imaging Interaction Toolkit
2018.4.99-389bf124
Medical Imaging Interaction Toolkit
|
#include <mitkPropertyRelations.h>
Public Types | |
using | RuleResultVectorType = IPropertyRelations::RuleResultVectorType |
using | RuleIDType = IPropertyRelations::RuleIDType |
using | RuleIDVectorType = IPropertyRelations::RuleIDVectorType |
![]() | |
using | RuleResultVectorType = std::list< PropertyRelationRuleBase::ConstPointer > |
using | RuleIDType = PropertyRelationRuleBase::RuleIDType |
using | RuleIDVectorType = std::vector< RuleIDType > |
Public Member Functions | |
PropertyRelations () | |
~PropertyRelations () override | |
bool | AddRule (const PropertyRelationRuleBase *rule, bool overwrite=false) override |
Add rule for a specific relation. If there is already a property rule instance it won't be added. Rule instances are regarded equal, if the rule ID is equal. You may enforce to overwrite the old equal rule by the overwrite parameter. More... | |
RuleResultVectorType | GetRulesForSource (const IPropertyProvider *source) const override |
Get all relation rules the passed source is really a source of. (PropertyRelationRuleBase::IsSource() would return true) More... | |
RuleResultVectorType | GetRulesForSourceCandidate (const IPropertyProvider *sourceCandidate) const override |
Get all relation rules that would accept the passed IPropertOwner as source. More... | |
RuleResultVectorType | GetRulesForDestinationCandidate (const IPropertyProvider *destCandidate) const override |
Get all relation rules that would accept the passed IPropertOwner as destination. More... | |
PropertyRelationRuleBase::ConstPointer | GetRule (const RuleIDType &ruleID) const override |
Get the relation rule that has the specfied ruleID. More... | |
RuleIDVectorType | GetRuleIDs () const override |
Get all IDs of registered rules. More... | |
bool | HasRuleForSource (const IPropertyProvider *source) const override |
Check if a passed instance has defined relation covered by the registered rules. More... | |
void | RemoveAllRules () override |
Remove all relation rules. More... | |
void | RemoveRule (const RuleIDType &ruleID) override |
Remove relation rule instance with the passed ID. If rule does not exist nothing happens. More... | |
![]() | |
virtual | ~IPropertyRelations () |
Definition at line 21 of file mitkPropertyRelations.h.
Definition at line 28 of file mitkPropertyRelations.h.
Definition at line 29 of file mitkPropertyRelations.h.
Definition at line 27 of file mitkPropertyRelations.h.
mitk::PropertyRelations::PropertyRelations | ( | ) |
Definition at line 19 of file mitkPropertyRelations.cpp.
Referenced by mitk::CreateTestInstancePropertyRelations().
|
override |
Definition at line 23 of file mitkPropertyRelations.cpp.
|
overridevirtual |
Add rule for a specific relation. If there is already a property rule instance it won't be added. Rule instances are regarded equal, if the rule ID is equal. You may enforce to overwrite the old equal rule by the overwrite parameter.
[in] | rule | Relation rule of the property. |
[in] | overwrite | Overwrite already existing relation rule. |
Implements mitk::IPropertyRelations.
Definition at line 27 of file mitkPropertyRelations.cpp.
References mitk::PropertyRelationRuleBase::GetRuleID().
|
overridevirtual |
Get the relation rule that has the specfied ruleID.
Implements mitk::IPropertyRelations.
Definition at line 104 of file mitkPropertyRelations.cpp.
|
overridevirtual |
Get all IDs of registered rules.
Implements mitk::IPropertyRelations.
Definition at line 118 of file mitkPropertyRelations.cpp.
|
overridevirtual |
Get all relation rules that would accept the passed IPropertOwner as destination.
[in] | destCandidate | Pointer to the instance that should be checked to be a suitable destination. |
Implements mitk::IPropertyRelations.
Definition at line 89 of file mitkPropertyRelations.cpp.
|
overridevirtual |
Get all relation rules the passed source is really a source of. (PropertyRelationRuleBase::IsSource() would return true)
[in] | source | Pointer to the instance that should be checked as source for the searched rules. |
Implements mitk::IPropertyRelations.
Definition at line 56 of file mitkPropertyRelations.cpp.
Referenced by HasRuleForSource().
|
overridevirtual |
Get all relation rules that would accept the passed IPropertOwner as source.
[in] | sourceCandidate | Pointer to the instance that should be checked to be a suitable source. |
Implements mitk::IPropertyRelations.
Definition at line 74 of file mitkPropertyRelations.cpp.
|
overridevirtual |
Check if a passed instance has defined relation covered by the registered rules.
[in] | source | Pointer to the instance that should be checked as source for the searched rules. |
Implements mitk::IPropertyRelations.
Definition at line 130 of file mitkPropertyRelations.cpp.
References GetRulesForSource().
|
overridevirtual |
Remove all relation rules.
Implements mitk::IPropertyRelations.
Definition at line 135 of file mitkPropertyRelations.cpp.
|
overridevirtual |
Remove relation rule instance with the passed ID. If rule does not exist nothing happens.
Implements mitk::IPropertyRelations.
Definition at line 140 of file mitkPropertyRelations.cpp.