Medical Imaging Interaction Toolkit
2018.4.99-389bf124
Medical Imaging Interaction Toolkit
|
Interface of property relations service. More...
#include <mitkIPropertyRelations.h>
Public Types | |
using | RuleResultVectorType = std::list< PropertyRelationRuleBase::ConstPointer > |
using | RuleIDType = PropertyRelationRuleBase::RuleIDType |
using | RuleIDVectorType = std::vector< RuleIDType > |
Public Member Functions | |
virtual | ~IPropertyRelations () |
virtual bool | AddRule (const PropertyRelationRuleBase *rule, bool overwrite=false)=0 |
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... | |
virtual RuleResultVectorType | GetRulesForSource (const IPropertyProvider *source) const =0 |
Get all relation rules the passed source is really a source of. (PropertyRelationRuleBase::IsSource() would return true) More... | |
virtual RuleResultVectorType | GetRulesForSourceCandidate (const IPropertyProvider *sourceCandidate) const =0 |
Get all relation rules that would accept the passed IPropertOwner as source. More... | |
virtual RuleResultVectorType | GetRulesForDestinationCandidate (const IPropertyProvider *destCandidate) const =0 |
Get all relation rules that would accept the passed IPropertOwner as destination. More... | |
virtual PropertyRelationRuleBase::ConstPointer | GetRule (const RuleIDType &ruleID) const =0 |
Get the relation rule that has the specfied ruleID. More... | |
virtual RuleIDVectorType | GetRuleIDs () const =0 |
Get all IDs of registered rules. More... | |
virtual bool | HasRuleForSource (const IPropertyProvider *source) const =0 |
Check if a passed instance has defined relation covered by the registered rules. More... | |
virtual void | RemoveAllRules ()=0 |
Remove all relation rules. More... | |
virtual void | RemoveRule (const RuleIDType &ruleID)=0 |
Remove relation rule instance with the passed ID. If rule does not exist nothing happens. More... | |
Interface of property relations service.
This service allows you to manage relations between property provider based on properties. Property relations are managed by rule classes derived from PropertyRelationRuleBase.
Definition at line 28 of file mitkIPropertyRelations.h.
Definition at line 34 of file mitkIPropertyRelations.h.
using mitk::IPropertyRelations::RuleIDVectorType = std::vector<RuleIDType> |
Definition at line 35 of file mitkIPropertyRelations.h.
using mitk::IPropertyRelations::RuleResultVectorType = std::list<PropertyRelationRuleBase::ConstPointer> |
Definition at line 33 of file mitkIPropertyRelations.h.
|
virtual |
Definition at line 15 of file mitkIPropertyRelations.cpp.
|
pure virtual |
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. |
Implemented in mitk::PropertyRelations.
|
pure virtual |
Get the relation rule that has the specfied ruleID.
Implemented in mitk::PropertyRelations.
|
pure virtual |
Get all IDs of registered rules.
Implemented in mitk::PropertyRelations.
|
pure virtual |
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. |
Implemented in mitk::PropertyRelations.
|
pure virtual |
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. |
Implemented in mitk::PropertyRelations.
|
pure virtual |
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. |
Implemented in mitk::PropertyRelations.
|
pure virtual |
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. |
Implemented in mitk::PropertyRelations.
|
pure virtual |
Remove all relation rules.
Implemented in mitk::PropertyRelations.
|
pure virtual |
Remove relation rule instance with the passed ID. If rule does not exist nothing happens.
Implemented in mitk::PropertyRelations.