Skip to main content

Create Custom Classes

Abstract

Create Custom Classes

This section contains a short guide on how to create a new custom class.

Prerequisites for Creating a Custom ClassHow to Create a New Custom Class in a Custom Ontology

To create a new class:

  1. Open your custom ontology.

  2. Either right-click New Class in the Hierarchy Tree.

  3. Or press New Class in Details View.

  4. The New Class dialogue opens. In the New Class dialogue you have the following options:

    • Label: enter the name of the class (mandatory).

      Available classes from all active predefined and custom ontologies are displayed as you start typing in the Labelfield, via autocomplete. That way you can reuse existing classes.

    • URI: the URI will be filled withURI pattern defined creating your custom ontology. The pattern is greyed out per default and will be extended by the specified label which will be used without spaces.You can click in the URI field to make it active and define a specific URI if needed.

    • Subclass Of: choose this option if a class is a subclass of another class. Select the parent class from the drop down.

    • Disjoint With: select this option, if the current class and another class cannot share an instance regardless of how the classes are interpreted.

  5. Click Create.

  6. You have more options in the Description tab where you can add a description for the new class.

  7. Select a Language (7) of the description. This list depends on the language settings for the project.

    51732596.png

23898884.pngBelow, you can find the owl statements created for a class. As you can see a class is defined as an owl:Class and rdfs:label is used for the name. The rdfs:subClassOf relation is used to specify the sub-class relation and owl:disjointWith to specify the disjoint classes. Finally, rdfs:comment is used for the description.

<http://doku.poolparty.biz/cocktail-ontology/Syrup> a owl:Class;
  dcterms:created "2019-02-03T12:16:12.662Z"^^xsd:dateTime;
  dcterms:creator <http://resource.semantic-web.at/user/admin>;
  rdfs:label "Syrup"@en;
  rdfs:comment "A condiment that is a thick, viscous liquid consisting primarily of a solution of sugar in water."@en
  rdfs:subClassOf <http://doku.poolparty.biz/cocktail-ontology/Sweeteners>;
  owl:disjointWith <http://doku.poolparty.biz/cocktail-ontology/Souces> .

Tip

If you would like to learn more about this topic, please watch this PoolParty Academy Tutorial video:

2.9 Extending Your Taxonomy With Custom Schemes & Ontologies

When the video is not available, you can sign up to the PoolParty Academy