PrF UG slots creating subslot

From Protege Wiki

Jump to: navigation, search

Working with Subslots


Protege-Frames User's Guide
Slots
The Slots Tab
The Slot Browser
The Slot Buttons
The Slot Menu
The Slot Editor
The Value Type Menu
The Any Value Type
The Boolean Value Type
The Class Value Type
The Float Value Type
The Instance Value Type
The Integer Value Type
The String Value Type
The Symbol Value Type
Creating a New Slot
Viewing a Slot
Editing a Top-Level Slot
Overriding Slot Properties at a Class
Editing Slot Properties
Removing a Slot from a Class
Deleting a Slot from the Project
Adding a Slot to a Class
Removing Overrides From a Slot
Understanding Inverse Slots
Creating an Inverse Slot Relationship
Working with Subslots
Finding a Slot
The Slot Hierarchy Window
The Slot Icons
The Superslots Pane
Glossary, Editing Help

Normally, whenever you create a new slot, it is a top-level slot. However, you can also create a subslot of an existing slot.

Understanding Subslots

Subslots have the following characteristics:

  • When you first create a subslot, the subslot inherits the properties of the superslot. Only the name is different.

  • You can only modify a subslot to make it more restrictive than its superslot. You cannot make it less restrictive.

  • When you attach a superslot to a class, all of its subslots are attached.

Subslots allow you to do the following:

  • You can create two (or more) slots which share information, but where one slot (the subslot) is more restrictive.

  • You can attach multiple related properties, using a single slot. To do this, create a single superslot and then create subslots that define characteristics of the superslot. By attaching the superslot to a class, you automatically attach all of its subslots.

Creating a Subslot

To create a subslot of a slot:

  1. In the Slot tab, select the slot that you want as the superslot of your subslot.

  2. Click the right mouse button.

  3. Select Create Subslot from the Slot menu.

    Slot menu, "Create Subslot" selected
  4. The new slot is created as a subslot of the selected slot. Except for the name, when created, it has the same properties as its parent slot.

  5. You can use the Slot Editor to edit the properties of the new slot.

Restrictions on Edits

When you create a subslot, there are restrictions on the possible edits:

  • For Cardinality, the slot may be changed from Multiple to Single, but not vice versa. The at least value may be increased; the at most value may be decreased.

  • For certain value types, some restrictions apply:

    • For a slot of type Any, the slot may be restricted to one of the other types (Boolean, Class, Float, Instance, Integer, String, or Symbol). You cannot change the type of slots other than type Any.

    • For a slot of type Class or Instance, you cannot change the allowed classes.

  • A Minimum value (for types Integer or Float) may be created or increased.

  • A Maximum value (for types Integer or Float) may be created or decreased.

  • Default values cannot be removed.

These restrictions are similar to the restrictions on slot overrides, except that you can change the name of a subslot, and you cannot make any changes to the allowed classes of a subslot.


Personal tools