axiom.restriction¶
OWL 2 object-property class-expression (restriction) structural elements.
Mirrors the data-property restriction family in
axiom.datatype. Concrete subclasses of
ObjectRestriction declare rdf:type owl:Restriction and pair
owl:onProperty with a filler or cardinality predicate per the OWL 2 RDF
mapping.
Value and universal/existential restrictions:
ObjectSomeValuesFrom—ObjectSomeValuesFrom( OPE CE ).ObjectAllValuesFrom—ObjectAllValuesFrom( OPE CE ).ObjectHasValue—ObjectHasValue( OPE a ).ObjectHasSelf—ObjectHasSelf( OPE ).
Cardinality restrictions (unqualified and qualified via owl:onClass):
Classes¶
Abstract base for OWL 2 class expressions that restrict an object property. |
|
Element |
|
Element |
|
Element |
|
Element |
|
Element |
|
Element |
|
Element |
|
Element |
|
Element |
|
Element |
Module Contents¶
- class axiom.restriction.ObjectRestriction(/, **data: Any)¶
Bases:
axiom.structural_element.StructuralElement,abc.ABCAbstract base for OWL 2 class expressions that restrict an object property.
Not directly instantiable. Each concrete subclass declares a node of
rdf:type owl:Restrictionand pairsowl:onPropertywith a class, individual, self, or cardinality predicate per the OWL 2 RDF mapping.nameis the RDF subject of the restriction node (typically a blank node).- name_value: axiom.common.N3Resource = None¶
- property name: rdflib.IdentifiedNode¶
Restriction node identifier (alias of
name_value).
- property as_triples: collections.abc.Sequence[axiom.common.Triple]¶
Triples representing this element as RDF; MUST NOT recurse into related elements.
- class axiom.restriction.ObjectSomeValuesFrom(/, **data: Any)¶
Bases:
ObjectRestrictionElement
ObjectSomeValuesFrom( OPE CE )in the OWL 2 structural specification.The RDF subject is typically an anonymous blank node (written
_:xbelow).Triples:
_:x rdf:type owl:Restriction . _:x owl:onProperty OPE . _:x owl:someValuesFrom CE .
- kind: Literal['ObjectSomeValuesFrom'] = 'ObjectSomeValuesFrom'¶
- on_property: axiom.common.N3IRIRef¶
- some_values_from: axiom.common.N3Resource¶
- property as_triples: collections.abc.Sequence[axiom.common.Triple]¶
Triples representing this element as RDF; MUST NOT recurse into related elements.
- class axiom.restriction.ObjectAllValuesFrom(/, **data: Any)¶
Bases:
ObjectRestrictionElement
ObjectAllValuesFrom( OPE CE )in the OWL 2 structural specification.The RDF subject is typically an anonymous blank node (written
_:xbelow).Triples:
_:x rdf:type owl:Restriction . _:x owl:onProperty OPE . _:x owl:allValuesFrom CE .
- kind: Literal['ObjectAllValuesFrom'] = 'ObjectAllValuesFrom'¶
- on_property: axiom.common.N3IRIRef¶
- all_values_from: axiom.common.N3Resource¶
- property as_triples: collections.abc.Sequence[axiom.common.Triple]¶
Triples representing this element as RDF; MUST NOT recurse into related elements.
- class axiom.restriction.ObjectHasValue(/, **data: Any)¶
Bases:
ObjectRestrictionElement
ObjectHasValue( OPE a )in the OWL 2 structural specification.The RDF subject is typically an anonymous blank node (written
_:xbelow).has_valueis an individual (IRI or blank node).Triples:
_:x rdf:type owl:Restriction . _:x owl:onProperty OPE . _:x owl:hasValue a .
- kind: Literal['ObjectHasValue'] = 'ObjectHasValue'¶
- on_property: axiom.common.N3IRIRef¶
- has_value: axiom.common.N3Resource¶
- property as_triples: collections.abc.Sequence[axiom.common.Triple]¶
Triples representing this element as RDF; MUST NOT recurse into related elements.
- class axiom.restriction.ObjectHasSelf(/, **data: Any)¶
Bases:
ObjectRestrictionElement
ObjectHasSelf( OPE )in the OWL 2 structural specification.The RDF subject is typically an anonymous blank node (written
_:xbelow). The mapping always uses the boolean literal"true"^^xsd:boolean.Triples:
_:x rdf:type owl:Restriction . _:x owl:onProperty OPE . _:x owl:hasSelf "true"^^xsd:boolean .
- kind: Literal['ObjectHasSelf'] = 'ObjectHasSelf'¶
- on_property: axiom.common.N3IRIRef¶
- property as_triples: collections.abc.Sequence[axiom.common.Triple]¶
Triples representing this element as RDF; MUST NOT recurse into related elements.
- class axiom.restriction.ObjectMinCardinality(/, **data: Any)¶
Bases:
ObjectRestrictionElement
ObjectMinCardinality( n OPE )in the OWL 2 structural specification.Triples:
_:x rdf:type owl:Restriction . _:x owl:onProperty OPE . _:x owl:minCardinality "n"^^xsd:nonNegativeInteger .
- kind: Literal['ObjectMinCardinality'] = 'ObjectMinCardinality'¶
- on_property: axiom.common.N3IRIRef¶
- min_cardinality: axiom.common.N3Node¶
- property as_triples: collections.abc.Sequence[axiom.common.Triple]¶
Triples representing this element as RDF; MUST NOT recurse into related elements.
- class axiom.restriction.ObjectMinCardinalityQualified(/, **data: Any)¶
Bases:
ObjectRestrictionElement
ObjectMinCardinality( n OPE CE )in the OWL 2 structural specification.Triples:
_:x rdf:type owl:Restriction . _:x owl:onProperty OPE . _:x owl:minQualifiedCardinality "n"^^xsd:nonNegativeInteger . _:x owl:onClass CE .
- kind: Literal['ObjectMinCardinalityQualified'] = 'ObjectMinCardinalityQualified'¶
- on_property: axiom.common.N3IRIRef¶
- min_qualified_cardinality: axiom.common.N3Node¶
- on_class: axiom.common.N3Resource¶
- property as_triples: collections.abc.Sequence[axiom.common.Triple]¶
Triples representing this element as RDF; MUST NOT recurse into related elements.
- class axiom.restriction.ObjectMaxCardinality(/, **data: Any)¶
Bases:
ObjectRestrictionElement
ObjectMaxCardinality( n OPE )in the OWL 2 structural specification.Triples:
_:x rdf:type owl:Restriction . _:x owl:onProperty OPE . _:x owl:maxCardinality "n"^^xsd:nonNegativeInteger .
- kind: Literal['ObjectMaxCardinality'] = 'ObjectMaxCardinality'¶
- on_property: axiom.common.N3IRIRef¶
- max_cardinality: axiom.common.N3Node¶
- property as_triples: collections.abc.Sequence[axiom.common.Triple]¶
Triples representing this element as RDF; MUST NOT recurse into related elements.
- class axiom.restriction.ObjectMaxCardinalityQualified(/, **data: Any)¶
Bases:
ObjectRestrictionElement
ObjectMaxCardinality( n OPE CE )in the OWL 2 structural specification.Triples:
_:x rdf:type owl:Restriction . _:x owl:onProperty OPE . _:x owl:maxQualifiedCardinality "n"^^xsd:nonNegativeInteger . _:x owl:onClass CE .
- kind: Literal['ObjectMaxCardinalityQualified'] = 'ObjectMaxCardinalityQualified'¶
- on_property: axiom.common.N3IRIRef¶
- max_qualified_cardinality: axiom.common.N3Node¶
- on_class: axiom.common.N3Resource¶
- property as_triples: collections.abc.Sequence[axiom.common.Triple]¶
Triples representing this element as RDF; MUST NOT recurse into related elements.
- class axiom.restriction.ObjectExactCardinality(/, **data: Any)¶
Bases:
ObjectRestrictionElement
ObjectExactCardinality( n OPE )in the OWL 2 structural specification.Triples:
_:x rdf:type owl:Restriction . _:x owl:onProperty OPE . _:x owl:cardinality "n"^^xsd:nonNegativeInteger .
- kind: Literal['ObjectExactCardinality'] = 'ObjectExactCardinality'¶
- on_property: axiom.common.N3IRIRef¶
- cardinality: axiom.common.N3Node¶
- property as_triples: collections.abc.Sequence[axiom.common.Triple]¶
Triples representing this element as RDF; MUST NOT recurse into related elements.
- class axiom.restriction.ObjectExactCardinalityQualified(/, **data: Any)¶
Bases:
ObjectRestrictionElement
ObjectExactCardinality( n OPE CE )in the OWL 2 structural specification.Triples:
_:x rdf:type owl:Restriction . _:x owl:onProperty OPE . _:x owl:qualifiedCardinality "n"^^xsd:nonNegativeInteger . _:x owl:onClass CE .
- kind: Literal['ObjectExactCardinalityQualified'] = 'ObjectExactCardinalityQualified'¶
- on_property: axiom.common.N3IRIRef¶
- qualified_cardinality: axiom.common.N3Node¶
- on_class: axiom.common.N3Resource¶
- property as_triples: collections.abc.Sequence[axiom.common.Triple]¶
Triples representing this element as RDF; MUST NOT recurse into related elements.