fuzzy_dl_owl2.fuzzydl.concept.interface.has_concepts_interface
An abstract base class that standardizes the storage and management of a collection of conceptual entities within the fuzzy description logic system.
Description
Designed to serve as a reusable building block for complex structures, the class handles the initialization of a collection of conceptual entities by accepting any iterable and converting it into a mutable list. This conversion ensures that the internal state remains consistent and decoupled from the original input source, preventing unintended side effects from external modifications to the provided iterable. Access to the stored collection is managed through a property interface, which allows for both retrieval and dynamic replacement of the underlying list while maintaining encapsulation. Subclasses can leverage this functionality to focus on specific logic operations without needing to implement boilerplate code for managing groups of concepts, such as operands in logical expressions.
Classes
This abstract base class serves as a foundational component for objects that manage a collection of concepts, providing a concrete implementation for storage and access. It initializes with an iterable of concepts and exposes a property that allows for both retrieval and dynamic modification of the underlying list. By handling the conversion of input iterables to a list, it ensures a consistent internal state for subclasses that need to track or represent multiple conceptual entities. |
Module Contents
UML Class Diagram for HasConceptsInterface
- class HasConceptsInterface(concepts: Iterable[fuzzy_dl_owl2.fuzzydl.concept.concept.Concept])
Bases:
abc.ABCThis abstract base class serves as a foundational component for objects that manage a collection of concepts, providing a concrete implementation for storage and access. It initializes with an iterable of concepts and exposes a property that allows for both retrieval and dynamic modification of the underlying list. By handling the conversion of input iterables to a list, it ensures a consistent internal state for subclasses that need to track or represent multiple conceptual entities.
- Parameters:
_concepts (list[Concept]) – Internal storage for the concepts currently represented or manipulated by the class.
- _concepts: list[fuzzy_dl_owl2.fuzzydl.concept.concept.Concept]
- property concepts: list[fuzzy_dl_owl2.fuzzydl.concept.concept.Concept]
Returns the list of concepts held by this object, i.e. the operands that the implementing concept combines. The value is read from the private
_conceptsattribute without modifying the instance.- Returns:
The wrapped operand concepts.
- Return type:
list[Concept]