Skip to content

SWRLAPIOWLAxiomBuiltInLibraries

Martin O'Connor edited this page Aug 6, 2016 · 2 revisions

SWRLAPI OWL Axiom Built-in Libraries

The SWRLAPI provides three SWRL built-in libraries for directly querying OWL axioms using the SQWRL query language.

The three libraries are:

  • ABox Built-in Library Supports querying of ABox axioms. It is documented here.
  • TBox Built-in Library Supports querying of TBox axioms. It is documented here.
  • RBox Built-in Library Supports querying of RBox axioms. It is documented here.
The built-ins in each library can be used individually or together to query OWL axioms.

Note that these built-ins query only asserted axioms.

Examples

List all declared classes:

    tbox:cd(?c) -> sqwrl:select(?c)

List all OWL asserted superclasses of class C1:

    tbox:sca(C1, ?c) -> sqwrl:select(?c) ^ sqwrl:orderBy(?c)

List all pairs of disjoint data properties:

    rbox:djdpa(?dp1, ?dp2) -> sqwrl:select(?dp1, ?dp2) ^ sqwrl:orderBy(?dp1, ?dp2)

List all irreflexive object properties:

    rbox:iropa(?p) -> sqwrl:select(?p) ^ sqwrl:orderBy(?p)

List all data properties with a boolean value of true:

    abox:dpaa(?s, ?p, true) -> sqwrl:select(?p)

List all values of data property hasAge:

    abox:dpaa(?s, hasAge, ?v) -> sqwrl:select(?v)

List all object properties with a domain of Person:

    tbox:opda(?p, Person) -> sqwrl:select(?p)