pub enum ClassExpression<L = OwlLiteral, B = BlankNodeId> {
Show 18 variants
Named(Iri<String>),
ObjectIntersectionOf(OperandSet<Self, 2>),
ObjectUnionOf(OperandSet<Self, 2>),
ObjectComplementOf(Box<Self>),
ObjectOneOf(OperandSet<Individual<B>, 1>),
ObjectSomeValuesFrom {
property: ObjectPropertyExpression,
filler: Box<Self>,
},
ObjectAllValuesFrom {
property: ObjectPropertyExpression,
filler: Box<Self>,
},
ObjectHasValue {
property: ObjectPropertyExpression,
individual: Individual<B>,
},
ObjectHasSelf {
property: ObjectPropertyExpression,
},
ObjectMinCardinality {
cardinality: Cardinality,
property: ObjectPropertyExpression,
filler: Box<Self>,
},
ObjectMaxCardinality {
cardinality: Cardinality,
property: ObjectPropertyExpression,
filler: Box<Self>,
},
ObjectExactCardinality {
cardinality: Cardinality,
property: ObjectPropertyExpression,
filler: Box<Self>,
},
DataSomeValuesFrom {
properties: OperandList<Iri<String>, 1>,
range: DataRange<L>,
},
DataAllValuesFrom {
properties: OperandList<Iri<String>, 1>,
range: DataRange<L>,
},
DataHasValue {
property: Iri<String>,
value: L,
},
DataMinCardinality {
cardinality: Cardinality,
property: Iri<String>,
range: DataRange<L>,
},
DataMaxCardinality {
cardinality: Cardinality,
property: Iri<String>,
range: DataRange<L>,
},
DataExactCardinality {
cardinality: Cardinality,
property: Iri<String>,
range: DataRange<L>,
},
}Expand description
All 18 OWL 2 class-expression forms.
Variants§
Named(Iri<String>)
A named class, including owl:Thing and owl:Nothing.
ObjectIntersectionOf(OperandSet<Self, 2>)
Intersection of at least two source occurrences.
ObjectUnionOf(OperandSet<Self, 2>)
Union of at least two source occurrences.
ObjectComplementOf(Box<Self>)
Complement of one class expression.
ObjectOneOf(OperandSet<Individual<B>, 1>)
Enumeration of individuals.
ObjectSomeValuesFrom
Existential object restriction.
Fields
property: ObjectPropertyExpressionThe property operand.
ObjectAllValuesFrom
Universal object restriction.
Fields
property: ObjectPropertyExpressionThe property operand.
ObjectHasValue
Object value restriction.
Fields
property: ObjectPropertyExpressionThe property operand.
individual: Individual<B>The individual operand.
ObjectHasSelf
Object self restriction.
Fields
property: ObjectPropertyExpressionThe property operand.
ObjectMinCardinality
Minimum object cardinality restriction.
Fields
cardinality: CardinalityThe cardinality operand.
property: ObjectPropertyExpressionThe property operand.
ObjectMaxCardinality
Maximum object cardinality restriction.
Fields
cardinality: CardinalityThe cardinality operand.
property: ObjectPropertyExpressionThe property operand.
ObjectExactCardinality
Exact object cardinality restriction.
Fields
cardinality: CardinalityThe cardinality operand.
property: ObjectPropertyExpressionThe property operand.
DataSomeValuesFrom
Some data-value restriction, with ordered property positions.
Fields
properties: OperandList<Iri<String>, 1>The properties operand.
DataAllValuesFrom
All data-value restriction, with ordered property positions.
Fields
properties: OperandList<Iri<String>, 1>The properties operand.
DataHasValue
Data value restriction.
DataMinCardinality
Min data cardinality restriction.
Fields
cardinality: CardinalityThe cardinality operand.
DataMaxCardinality
Max data cardinality restriction.
Fields
cardinality: CardinalityThe cardinality operand.
DataExactCardinality
Exact data cardinality restriction.
Implementations§
Source§impl<L, B> ClassExpression<L, B>
impl<L, B> ClassExpression<L, B>
Sourcepub fn is_nothing(&self) -> bool
pub fn is_nothing(&self) -> bool
Return whether this expression is the named empty class.
Sourcepub fn object_intersection_of(
operands: Vec<Self>,
) -> Result<Self, StructuralModelError>
pub fn object_intersection_of( operands: Vec<Self>, ) -> Result<Self, StructuralModelError>
Sourcepub fn object_union_of(
operands: Vec<Self>,
) -> Result<Self, StructuralModelError>
pub fn object_union_of( operands: Vec<Self>, ) -> Result<Self, StructuralModelError>
Sourcepub fn object_complement_of(operand: Self) -> Self
pub fn object_complement_of(operand: Self) -> Self
Create a complement expression.
Sourcepub fn object_one_of(
individuals: Vec<Individual<B>>,
) -> Result<Self, StructuralModelError>
pub fn object_one_of( individuals: Vec<Individual<B>>, ) -> Result<Self, StructuralModelError>
Sourcepub fn object_some_values_from(
property: ObjectPropertyExpression,
filler: Self,
) -> Self
pub fn object_some_values_from( property: ObjectPropertyExpression, filler: Self, ) -> Self
Create an object some-values restriction.
Sourcepub fn object_all_values_from(
property: ObjectPropertyExpression,
filler: Self,
) -> Self
pub fn object_all_values_from( property: ObjectPropertyExpression, filler: Self, ) -> Self
Create an object all-values restriction.
Sourcepub fn object_has_value(
property: ObjectPropertyExpression,
individual: Individual<B>,
) -> Self
pub fn object_has_value( property: ObjectPropertyExpression, individual: Individual<B>, ) -> Self
Create an object value restriction.
Sourcepub fn object_has_self(property: ObjectPropertyExpression) -> Self
pub fn object_has_self(property: ObjectPropertyExpression) -> Self
Create a self restriction.
Source§impl<L, B> ClassExpression<L, B>
impl<L, B> ClassExpression<L, B>
Sourcepub fn kind(&self) -> ClassExpressionKind
pub fn kind(&self) -> ClassExpressionKind
Return the structural expression kind without evaluating it.
Source§impl<L, B> ClassExpression<L, B>
impl<L, B> ClassExpression<L, B>
Sourcepub fn object_min_cardinality(
cardinality: Cardinality,
property: ObjectPropertyExpression,
filler: Option<Self>,
) -> Self
pub fn object_min_cardinality( cardinality: Cardinality, property: ObjectPropertyExpression, filler: Option<Self>, ) -> Self
Create an object minimum cardinality restriction; no filler means owl:Thing.
Sourcepub fn object_max_cardinality(
cardinality: Cardinality,
property: ObjectPropertyExpression,
filler: Option<Self>,
) -> Self
pub fn object_max_cardinality( cardinality: Cardinality, property: ObjectPropertyExpression, filler: Option<Self>, ) -> Self
Create an object maximum cardinality restriction; no filler means owl:Thing.
Sourcepub fn object_exact_cardinality(
cardinality: Cardinality,
property: ObjectPropertyExpression,
filler: Option<Self>,
) -> Self
pub fn object_exact_cardinality( cardinality: Cardinality, property: ObjectPropertyExpression, filler: Option<Self>, ) -> Self
Create an object exact cardinality restriction; no filler means owl:Thing.
Sourcepub fn data_some_values_from(
properties: Vec<Iri<String>>,
range: DataRange<L>,
) -> Result<Self, StructuralModelError>
pub fn data_some_values_from( properties: Vec<Iri<String>>, range: DataRange<L>, ) -> Result<Self, StructuralModelError>
Create a data some-values restriction with ordered property positions.
§Errors
Rejects an empty property list. Datatype arity is checked by semantic validators.
Sourcepub fn data_all_values_from(
properties: Vec<Iri<String>>,
range: DataRange<L>,
) -> Result<Self, StructuralModelError>
pub fn data_all_values_from( properties: Vec<Iri<String>>, range: DataRange<L>, ) -> Result<Self, StructuralModelError>
Create a data all-values restriction with ordered property positions.
§Errors
Rejects an empty property list. Datatype arity is checked by semantic validators.
Sourcepub fn data_has_value(property: Iri<String>, value: L) -> Self
pub fn data_has_value(property: Iri<String>, value: L) -> Self
Create a data-value restriction without evaluating the literal.
Sourcepub fn data_min_cardinality(
cardinality: Cardinality,
property: Iri<String>,
range: Option<DataRange<L>>,
) -> Self
pub fn data_min_cardinality( cardinality: Cardinality, property: Iri<String>, range: Option<DataRange<L>>, ) -> Self
Create a data minimum cardinality restriction; no range means rdfs:Literal.
Sourcepub fn data_max_cardinality(
cardinality: Cardinality,
property: Iri<String>,
range: Option<DataRange<L>>,
) -> Self
pub fn data_max_cardinality( cardinality: Cardinality, property: Iri<String>, range: Option<DataRange<L>>, ) -> Self
Create a data maximum cardinality restriction; no range means rdfs:Literal.
Sourcepub fn data_exact_cardinality(
cardinality: Cardinality,
property: Iri<String>,
range: Option<DataRange<L>>,
) -> Self
pub fn data_exact_cardinality( cardinality: Cardinality, property: Iri<String>, range: Option<DataRange<L>>, ) -> Self
Create a data exact cardinality restriction; no range means rdfs:Literal.