owlapy.meta_classes

Meta classes for OWL objects.

Module Contents

Classes

HasIRI

Simple class to access the IRI.

HasOperands

An interface to objects that have a collection of operands.

HasFiller

An interface to objects that have a filler.

HasCardinality

An interface to objects that have a cardinality.

class owlapy.meta_classes.HasIRI[source]

Simple class to access the IRI.

abstract property iri: IRI

Gets the IRI of this object.

Returns:

The IRI of this object.

abstract property str: str

Gets the string representation of this object

Returns:

The IRI as string

__slots__ = ()
class owlapy.meta_classes.HasOperands[source]

Bases: Generic[_T]

An interface to objects that have a collection of operands.

Parameters:

_T – Operand type.

__slots__ = ()
abstract operands() Iterable[_T][source]

Gets the operands - e.g., the individuals in a sameAs axiom, or the classes in an equivalent classes axiom.

Returns:

The operands.

class owlapy.meta_classes.HasFiller[source]

Bases: Generic[_T]

An interface to objects that have a filler.

Parameters:

_T – Filler type.

__slots__ = ()
abstract get_filler() _T[source]

Gets the filler for this restriction. In the case of an object restriction this will be an individual, in the case of a data restriction this will be a constant (data value). For quantified restriction this will be a class expression or a data range.

Returns:

the value

class owlapy.meta_classes.HasCardinality[source]

An interface to objects that have a cardinality.

__slots__ = ()
abstract get_cardinality() int[source]

Gets the cardinality of a restriction.

Returns:

The cardinality. A non-negative integer.