Difference between revisions of "PrF UG slots slot editor"

From Protege Wiki
Jump to: navigation, search
(Automated import of articles)
 
Line 5: Line 5:
  
 
The Slot Editor can be used to define and edit the attributes,
 
The Slot Editor can be used to define and edit the attributes,
or <i>facets</i>,
+
or <i>facets</i>, of a slot.
of a slot.
+
The Slot Editor for the selected slot is displayed at the right
The Slot Editor for the selected slot is displayed at the right of the
+
of the [[PrF_UG_slots_slots_tab|Slots Tab]].
[[PrF_UG_slots_slots_tab|Slots Tab]].
+
The Slot Editor can also be displayed as a free-standing window, as follows:
The Slot Editor can also be displayed as a free-standing window,
 
as follows:
 
  
 
<ul class='a'>
 
<ul class='a'>
 
   <li><p>
 
   <li><p>
     When you highlight a slot in the
+
     When you highlight a slot in the [[PrF_UG_slots_slots_tab|Slots Tab]]
    [[PrF_UG_slots_slots_tab|Slots Tab]]
 
 
     and then click the View Slot
 
     and then click the View Slot
 
     [[Image:PrF_UG_slots_slot.view_top_level.gif|slots_slot.view_top_level]]
 
     [[Image:PrF_UG_slots_slot.view_top_level.gif|slots_slot.view_top_level]]
Line 22: Line 19:
  
 
   <li><p>
 
   <li><p>
     When you create a new slot for a highlighted class by clicking the <b>Create Slot</b>
+
     When you create a new slot for a highlighted class
     [[Image:PrF_UG_slots_slot.create.gif|slots_slot.create]]
+
    by clicking the <b>Create Slot</b>
     button in the
+
     [[Image:PrF_UG_slots_slot.create.gif|slots_slot.create]] button
    [[PrF_UG_classes_template_slot_pane|Template Slots pane]]
+
     in the [[PrF_UG_classes_template_slot_pane|Template Slots pane]]
     of the
+
     of the [[PrF_UG_classes_classes_tab|Classes tab]].
    [[PrF_UG_classes_classes_tab|Classes tab]].
 
 
     </p>
 
     </p>
  
 
   <li><p>
 
   <li><p>
     When you highlight a slot in the
+
     When you highlight a slot
    [[PrF_UG_classes_template_slot_pane|Template Slots pane]]
+
    in the [[PrF_UG_classes_template_slot_pane|Template Slots pane]]
 
     and then click the <b>View Top-level Slot</b>
 
     and then click the <b>View Top-level Slot</b>
 
     [[Image:PrF_UG_slots_slot.view_top_level.gif|slots_slot.view_top_level]]
 
     [[Image:PrF_UG_slots_slot.view_top_level.gif|slots_slot.view_top_level]]
Line 41: Line 37:
 
</ul>
 
</ul>
  
In the example below,
+
In the example below, the slot <b>urgent</b> for the class <b>Article</b>
the slot <b>urgent</b> for the class <b>Article</b> was double-clicked in the
+
was double-clicked in the [[PrF_UG_classes_template_slot_pane|Template Slots pane]].
[[PrF_UG_classes_template_slot_pane|Template Slots pane]].
 
 
The Slot Editor displays a <b>Boolean</b> Type,
 
The Slot Editor displays a <b>Boolean</b> Type,
 
with <b>Single</b> Cardinality,
 
with <b>Single</b> Cardinality,
Line 51: Line 46:
  
 
A slot can be attached to more than one class.
 
A slot can be attached to more than one class.
Each slot has a top-level
+
Each slot has a top-level (system) description;
(system)
 
description;
 
 
the system description can be specialized,
 
the system description can be specialized,
or
+
or [[PrF_UG_slots_override_slot|overridden]], for a specific class.
[[PrF_UG_slots_override_slot|overridden]],
 
for a specific class.
 
 
The scope of your edits depends on how you access the Slot Editor:
 
The scope of your edits depends on how you access the Slot Editor:
  
Line 63: Line 54:
 
   <li><p>
 
   <li><p>
 
     [[PrF_UG_slots_edit_top_level|Editing a Top-Level Slot]]:
 
     [[PrF_UG_slots_edit_top_level|Editing a Top-Level Slot]]:
     When you access the Slot Editor via the
+
     When you access the Slot Editor
    [[PrF_UG_slots_slots_tab|Slots Tab]]
+
    via the [[PrF_UG_slots_slots_tab|Slots Tab]]
 
     or via the <b>View Top-level Slot</b>
 
     or via the <b>View Top-level Slot</b>
     [[Image:PrF_UG_slots_slot.view_top_level.gif|slots_slot.view_top_level]]
+
     [[Image:PrF_UG_slots_slot.view_top_level.gif|slots_slot.view_top_level]] button
     button in the
+
     in the [[PrF_UG_classes_template_slot_pane|Template Slots pane]]
    [[PrF_UG_classes_template_slot_pane|Template Slots pane]]
+
     of the [[PrF_UG_classes_classes_tab|Classes tab]],
     of the
 
    [[PrF_UG_classes_classes_tab|Classes tab]],
 
 
     you can view and edit the top-level description;
 
     you can view and edit the top-level description;
 
     these modifications affect the slot for any class where it occurs.
 
     these modifications affect the slot for any class where it occurs.
Line 78: Line 67:
 
     [[PrF_UG_slots_override_slot|Overriding Slot Properties at a Class]]:
 
     [[PrF_UG_slots_override_slot|Overriding Slot Properties at a Class]]:
 
     When you access the Slot Editor via the <b>View Slot Overrides</b>
 
     When you access the Slot Editor via the <b>View Slot Overrides</b>
     [[Image:PrF_UG_slots_slot.view_overrides.gif|slots_slot.view_overrides]]
+
     [[Image:PrF_UG_slots_slot.view_overrides.gif|slots_slot.view_overrides]] button
     button in the
+
     in the [[PrF_UG_classes_template_slot_pane|Template Slots pane]]
    [[PrF_UG_classes_template_slot_pane|Template Slots pane]]
+
     of the [[PrF_UG_classes_classes_tab|Classes tab]],
     of the
 
    [[PrF_UG_classes_classes_tab|Classes tab]],
 
 
     you can view and edit the slot properties for the currently highlighted class.
 
     you can view and edit the slot properties for the currently highlighted class.
     Class-level modifications,
+
     Class-level modifications, called <i>overrides</i>,
    called <i>overrides</i>,
 
 
     only affect the slot at the current class and its subclasses.
 
     only affect the slot at the current class and its subclasses.
 
     </p>
 
     </p>
Line 94: Line 80:
 
<ol class='a'>
 
<ol class='a'>
 
   <li><p>
 
   <li><p>
     [[#Note_Icons|Note Icons]],
+
     [[#Note_Icons|Note Icons]], which allow you to add notes.
    which allow you to add notes.
 
 
     </p>
 
     </p>
  
 
   <li><p>
 
   <li><p>
     [[#Slot_Name|Name]]
+
     [[#Slot_Name|Name]] of the slot.
    of the slot.
 
 
     </p>
 
     </p>
  
 
   <li><p>
 
   <li><p>
     [[#Value_Type_Menu|Value Type]]
+
     [[#Value_Type_Menu|Value Type]] of the slot.
    of the slot.
 
 
     </p>
 
     </p>
  
 
   <li><p>
 
   <li><p>
     [[#Cardinality|Cardinality]]
+
     [[#Cardinality|Cardinality]] of the slot.
    of the slot.
 
 
     </p>
 
     </p>
  
 
   <li><p>
 
   <li><p>
 
     (optional)
 
     (optional)
     [[#Minimum_optional_|Minimum]]
+
     [[#Minimum_optional_|Minimum]] and [[#Maximum_optional_|Maximum]] values
    and
+
     for the slot (slots of type [[PrF_UG_slots_value_type_integer|Integer]]
    [[#Maximum_optional_|Maximum]]
+
     or [[PrF_UG_slots_value_type_float|Float]] only).
     values for the slot (slots of type
 
    [[PrF_UG_slots_value_type_integer|Integer]]
 
     or
 
    [[PrF_UG_slots_value_type_float|Float]]
 
    only).
 
 
     </p>
 
     </p>
  
 
   <li><p>
 
   <li><p>
     (optional) Any
+
     (optional)
     [[#Documentation_optional_|Documentation]]
+
     Any [[#Documentation_optional_|Documentation]]
 
     that has been entered for the slot.
 
     that has been entered for the slot.
 
     </p>
 
     </p>
  
 
   <li><p>
 
   <li><p>
     (optional) An
+
     (optional)
     [[#Inverse_Slot_optional_|Inverse Slot]]
+
     An [[#Inverse_Slot_optional_|Inverse Slot]] for the slot
    for the slot (slots of type
+
    (slots of type [[PrF_UG_slots_value_type_class|Class]]
    [[PrF_UG_slots_value_type_class|Class]]
+
     or [[PrF_UG_slots_value_type_instance|Instance]]).
     or
 
    [[PrF_UG_slots_value_type_instance|Instance]]).
 
 
     </p>
 
     </p>
  
 
   <li><p>
 
   <li><p>
     (optional) Any
+
     (optional)
     [[#Template_Values_optional_|Template Values]]
+
     Any [[#Template_Values_optional_|Template Values]]
 
     that have been defined for the slot.
 
     that have been defined for the slot.
 
     </p>
 
     </p>
  
 
   <li><p>
 
   <li><p>
     (optional) Any
+
     (optional)
     [[#Defaults_optional_|Defaults]]
+
     Any [[#Defaults_optional_|Defaults]]
 
     that have been defined for the slot.
 
     that have been defined for the slot.
 
     </p>
 
     </p>
  
 
   <li><p>
 
   <li><p>
     [[#Domain|Domain]]
+
     [[#Domain|Domain]] of the slot.
    of the slot.
 
 
     </p>
 
     </p>
 
</ol>
 
</ol>
  
For certain value types,
+
For certain value types, an additional pane appears below the <b>Value Type</b> pane:
an additional pane appears below the <b>Value Type</b> pane:
 
  
 
<ol class='a'>
 
<ol class='a'>
 
   <li><p>
 
   <li><p>
     For type Class,
+
     For type Class, the <b>Allowed Superclasses</b> pane appears.
    the <b>Allowed Superclasses</b> pane appears.
 
 
     </p>
 
     </p>
  
 
   <li><p>
 
   <li><p>
     For type Instance,
+
     For type Instance, the <b>Allowed Classes</b> pane appears.
    the <b>Allowed Classes</b> pane appears.
 
 
     </p>
 
     </p>
  
 
   <li><p>
 
   <li><p>
     For type Symbol,
+
     For type Symbol, the <b>Allowed Symbols</b> pane appears.
    the <b>Allowed Symbols</b> pane appears.
 
 
     </p>
 
     </p>
 
</ol>
 
</ol>
Line 181: Line 151:
  
 
The note icons,
 
The note icons,
<div>[[Image:PrF_UG_windows_slot_note.hide.gif|windows_slot_note.hide]]</div>
+
[[Image:PrF_UG_windows_slot_note.hide.gif|windows_slot_note.hide]]
 
[[Image:PrF_UG_windows_slot_note.create.gif|windows_slot_note.create]]
 
[[Image:PrF_UG_windows_slot_note.create.gif|windows_slot_note.create]]
 
[[Image:PrF_UG_windows_slot_note.delete.gif|windows_slot_note.delete]],
 
[[Image:PrF_UG_windows_slot_note.delete.gif|windows_slot_note.delete]],
 
at the upper right of the Editor,
 
at the upper right of the Editor,
 
allow you to add and remove yellow sticky notes to your slot.
 
allow you to add and remove yellow sticky notes to your slot.
These notes,
+
These notes, which are not part of your ontology,
which are not part of your ontology,
+
are displayed when the slot is selected
are displayed when the slot is selected at the
+
at the [[PrF_UG_slots_slots_tab|Slots Tab]].
[[PrF_UG_slots_slots_tab|Slots Tab]].
+
For information on how to add notes to any frame
For information on how to add notes to any frame (class,
+
(class, instance, or slot),
instance,
+
see [[PrF_UG_windows_yellow_stickies|Working with Notes]].
or slot),
 
see
 
[[PrF_UG_windows_yellow_stickies|Working with Notes]].
 
  
 
=== Slot Name ===
 
=== Slot Name ===
Line 208: Line 175:
 
which determines the kind of values that the slot may hold.
 
which determines the kind of values that the slot may hold.
 
When you are creating instances for a slot,
 
When you are creating instances for a slot,
the slot type also determines how the slot is displayed in the
+
the slot type also determines how the slot is displayed
[[PrF_UG_inst_instance_editor|Instance Editor]].
+
in the [[PrF_UG_inst_instance_editor|Instance Editor]].
See the
+
See the [[PrF_UG_inst_standard_fields|Standard Widgets]]
[[PrF_UG_inst_standard_fields|Standard Widgets]]
 
 
for more information about instances and type.
 
for more information about instances and type.
  
Line 217: Line 183:
  
 
The following table summarizes the value types.
 
The following table summarizes the value types.
For a full description,
+
For a full description, click on the type name:
click on the type name:
 
  
 
{| summary="value types"
 
{| summary="value types"
Line 227: Line 192:
 
|
 
|
 
[[PrF_UG_slots_value_type_any|Any]]
 
[[PrF_UG_slots_value_type_any|Any]]
| any of the types below (logical Union)
+
|
 +
any of the types below (logical Union)
 
|
 
|
 
|-
 
|-
 
|
 
|
 
[[PrF_UG_slots_value_type_boolean|Boolean]]
 
[[PrF_UG_slots_value_type_boolean|Boolean]]
| a logical,
+
|
Boolean value;
+
a logical, Boolean value;
i.e.,
+
i.e., a value that is either true or false
a value that is either true or false
+
|
| true,
+
true, false
false
 
 
|-
 
|-
 
|
 
|
Line 247: Line 212:
 
[[PrF_UG_slots_value_type_float|Float]]
 
[[PrF_UG_slots_value_type_float|Float]]
 
| a floating-point number (number with a decimal point)
 
| a floating-point number (number with a decimal point)
| 1.0,
+
| 1.0, 3.4e10, -0.3e-3
3.4e10, -0.3e-3
 
 
|-
 
|-
 
|
 
|
Line 258: Line 222:
 
[[PrF_UG_slots_value_type_integer|Integer]]
 
[[PrF_UG_slots_value_type_integer|Integer]]
 
| an integer (a whole number)
 
| an integer (a whole number)
| 1,
+
| 1, 2, -4, 0
2, -4,
 
0
 
 
|-
 
|-
 
|
 
|
 
[[PrF_UG_slots_value_type_string|String]]
 
[[PrF_UG_slots_value_type_string|String]]
| String of alphanumeric
+
| String of alphanumeric (ASCII) characters, possibly including spaces
(ASCII)
 
characters,
 
possibly including spaces
 
 
| "Mars Mission"
 
| "Mars Mission"
 
|-
 
|-
Line 273: Line 232:
 
[[PrF_UG_slots_value_type_symbol|Symbol]]
 
[[PrF_UG_slots_value_type_symbol|Symbol]]
 
| the slot takes values from a list of strings you define
 
| the slot takes values from a list of strings you define
| {red,
+
| {red, blue, green}
blue,
 
green}
 
 
|}
 
|}
  
When a value type of <b>Class</b>,
+
When a value type of <b>Class</b>, <b>Instance</b>, or <b>Symbol</b> is selected,
<b>Instance</b>,
 
or <b>Symbol</b> is selected,
 
 
an additional pane appears below the <b>Value Type</b> menu.
 
an additional pane appears below the <b>Value Type</b> menu.
 
This pane allows you to select or create the values for the slot.
 
This pane allows you to select or create the values for the slot.
Line 288: Line 243:
 
=== Cardinality ===
 
=== Cardinality ===
  
The <b>Cardinality</b> field allows you to specify the number of values allowed or required for the slot.
+
The <b>Cardinality</b> field allows you to specify the number of values
 +
allowed or required for the slot.
 
This supplies the following options:
 
This supplies the following options:
  
Line 294: Line 250:
  
 
The default configuration allows the slot to have at most one value;
 
The default configuration allows the slot to have at most one value;
that is,
+
that is, it can have one value or no value.
it can have one value or no value.
+
You can change the default by entering a positive whole number
You can change the default by entering a positive whole number in the <b>at least</b> and/or <b>at most</b> options,
+
in the <b>at least</b> and/or <b>at most</b> options,
 
or by selecting the <b>multiple</b> option:
 
or by selecting the <b>multiple</b> option:
  
 
<ul class='a'>
 
<ul class='a'>
 
   <li><p>
 
   <li><p>
     <b>required/at least:</b> Sets the minimum number of values for the slot.
+
     <b>required/at least:</b>
     To use,
+
    Sets the minimum number of values for the slot.
    enter a positive whole number in the <b>at least</b> entry bar:
+
     To use, enter a positive whole number in the <b>at least</b> entry bar:
 
     </p>
 
     </p>
  
Line 321: Line 277:
 
    
 
    
 
     <li><p>
 
     <li><p>
       Setting <b>at least</b> equal to 1 <i>and</i> <b>at most</b> equal to 1 specifies that the slot must have exactly one value.
+
       Setting <b>at least</b> equal to 1 <i>and</i> <b>at most</b> equal to 1
 +
      specifies that the slot must have exactly one value.
 
       </p>
 
       </p>
 
   </ul>
 
   </ul>
Line 328: Line 285:
 
     <b>at most</b>:
 
     <b>at most</b>:
 
     Sets the maximum number of values for the slot.
 
     Sets the maximum number of values for the slot.
     To use,
+
     To use, enter a positive whole number in the <b>at most</b> entry bar:
    enter a positive whole number in the <b>at most</b> entry bar:
 
 
     </p>
 
     </p>
  
Line 353: Line 309:
 
   <ul>
 
   <ul>
 
     <li><p>
 
     <li><p>
       As above,
+
       As above, to set a minimum number of values, set the <b>at least</b> value.
      to set a minimum number of values,
 
      set the <b>at least</b> value.
 
 
       </p>
 
       </p>
 
    
 
    
 
     <li><p>
 
     <li><p>
       As above,
+
       As above, to set a maximum number of values, set the <b>at most</b> value.
      to set a maximum number of values,
 
      set the <b>at most</b> value.
 
 
       </p>
 
       </p>
 
    
 
    
 
     <li><p>
 
     <li><p>
       The lack of an <b>at most</b> value indicates that there is no limit to the number of items the slot may contain.
+
       The lack of an <b>at most</b> value indicates that there is no limit
 +
      to the number of items the slot may contain.
 
       </p>
 
       </p>
 
    
 
    
 
     <li><p>
 
     <li><p>
       Duplicate values are allowed,
+
       Duplicate values are allowed, although their use is uncommon
      although their use is uncommon
 
 
       </p>
 
       </p>
 
   </ul>
 
   </ul>
Line 377: Line 329:
 
=== Minimum (optional) ===
 
=== Minimum (optional) ===
  
This field is applicable only to slots of type
+
This field is applicable only to slots
[[PrF_UG_slots_value_type_integer|Integer]]
+
of type [[PrF_UG_slots_value_type_integer|Integer]]
or
+
or [[PrF_UG_slots_value_type_float|Float]].
[[PrF_UG_slots_value_type_float|Float]].
 
  
 
<b>Minimum</b> allows you to specify a minimum value for your slot.
 
<b>Minimum</b> allows you to specify a minimum value for your slot.
When present,
+
When present, the <b>Minimum</b> value is displayed in the Other Facets column
the <b>Minimum</b> value is displayed in the Other Facets column of the
+
of the [[PrF_UG_classes_template_slot_pane|Template Slots pane]].
[[PrF_UG_classes_template_slot_pane|Template Slots pane]].
 
  
 
When an instance is created for a class with this slot,
 
When an instance is created for a class with this slot,
 
the value of the slot must be greater than or equal to the minimum.
 
the value of the slot must be greater than or equal to the minimum.
For example,
+
For example, a minimum of zero means instances cannot have negative values.
a minimum of zero means instances cannot have negative values.
 
  
Together,
+
Together, <b>Minimum</b> and <b>Maximum</b> can be used to define an allowable range.
<b>Minimum</b> and <b>Maximum</b> can be used to define an allowable range.
 
  
 
=== Maximum (optional) ===
 
=== Maximum (optional) ===
  
This field is applicable only to slots of type
+
This field is applicable only to slots
[[PrF_UG_slots_value_type_integer|Integer]]
+
of type [[PrF_UG_slots_value_type_integer|Integer]]
or
+
or [[PrF_UG_slots_value_type_float|Float]].
[[PrF_UG_slots_value_type_float|Float]].
 
  
 
<b>Maximum</b> allows you to specify a maximum value for your slot.
 
<b>Maximum</b> allows you to specify a maximum value for your slot.
When present,
+
When present, the <b>Maximum</b> value is displayed in the Other Facets column
the <b>Maximum</b> value is displayed in the Other Facets column of the
+
of the [[PrF_UG_classes_template_slot_pane|Template Slots pane]].
[[PrF_UG_classes_template_slot_pane|Template Slots pane]].
 
  
 
When an instance is created for a class with this slot,
 
When an instance is created for a class with this slot,
 
the value of the slot must be less than or equal to the maximum.
 
the value of the slot must be less than or equal to the maximum.
Together,
+
Together, <b>Minimum</b> and <b>Maximum</b> can be used to define an allowable range.
<b>Minimum</b> and <b>Maximum</b> can be used to define an allowable range.
 
  
 
=== Documentation (optional) ===
 
=== Documentation (optional) ===
Line 421: Line 366:
 
=== Inverse Slot (optional) ===
 
=== Inverse Slot (optional) ===
  
Only available for slots of type
+
Only available for slots
[[PrF_UG_slots_value_type_class|Class]]
+
of type [[PrF_UG_slots_value_type_class|Class]]
or
+
or [[PrF_UG_slots_value_type_instance|Instance]].
[[PrF_UG_slots_value_type_instance|Instance]].
 
  
 
Allows you to create a reciprocal relationship between two slots.
 
Allows you to create a reciprocal relationship between two slots.
If this relationship is set up correctly,
+
If this relationship is set up correctly, assigning a value
assigning a value
+
(i.e., a specific class or instance) to the slot for one instance
(i.e.,
+
automatically assigns the instance as a value to the appropriate inverse slot.
a specific class or instance)
+
For example, the "direct superclass/direct subclass" relationship
to the slot for one instance automatically assigns the instance as a value to the appropriate inverse slot.
+
is actually an inverse slot relationship.
For example,
+
See [[PrF_UG_slots_inverse_slots|Understanding Inverse Slots]]
the "direct superclass/direct subclass" relationship is actually an inverse slot relationship.
+
and [[PrF_UG_slots_make_inverse_slot|Creating an Inverse Slot Relationship]]
See
 
[[PrF_UG_slots_inverse_slots|Understanding Inverse Slots]]
 
and
 
[[PrF_UG_slots_make_inverse_slot|Creating an Inverse Slot Relationship]]
 
 
for more information.
 
for more information.
  
If a slot has an inverse slot,
+
If a slot has an inverse slot, the name of the inverse slot is shown after the slot name
the name of the inverse slot is shown after the slot name at the
+
at the [[PrF_UG_slots_slots_tab|Slots Tab]].
[[PrF_UG_slots_slots_tab|Slots Tab]].
 
  
 
=== Template Values (optional) ===
 
=== Template Values (optional) ===
Line 450: Line 389:
 
<ul class='a'>
 
<ul class='a'>
 
   <li><p>
 
   <li><p>
     The template value is a required,
+
     The template value is a required, uneditable value
     uneditable value that is filled in for all classes and instances that use or inherit the slot.
+
     that is filled in for all classes and instances that use or inherit the slot.
 
     </p>
 
     </p>
  
Line 459: Line 398:
  
 
   <li><p>
 
   <li><p>
     The number of <b>Template Values</b> should not exceed the <b>at most</b> value for the
+
     The number of <b>Template Values</b> should not exceed the <b>at most</b> value
    [[#Cardinality|Cardinality]]
+
    for the [[#Cardinality|Cardinality]] of the slot.
    of the slot.
 
 
     </p>
 
     </p>
 
</ul>
 
</ul>
  
For a value that can be overridden,
+
For a value that can be overridden, use <b>Defaults</b> instead.
use <b>Defaults</b> instead.
 
  
When present,
+
When present, any <b>Template Values</b> are displayed in the Other Facets column
any <b>Template Values</b> are displayed in the Other Facets column of the
+
of the [[PrF_UG_classes_template_slot_pane|Template Slots pane]]
[[PrF_UG_classes_template_slot_pane|Template Slots pane]]
+
in the [[PrF_UG_classes_classes_tab|Classes tab]].
in the
 
[[PrF_UG_classes_classes_tab|Classes tab]].
 
  
 
=== Defaults (optional) ===
 
=== Defaults (optional) ===
Line 489: Line 424:
  
 
   <li><p>
 
   <li><p>
     The number of defaults should not exceed the <b>at most</b> value for the
+
     The number of defaults should not exceed the <b>at most</b> value
    [[#Cardinality|Cardinality]]
+
    for the [[#Cardinality|Cardinality]] of the slot.
    of the slot.
 
 
     </p>
 
     </p>
 
</ul>
 
</ul>
  
When present,
+
When present, any <b>Defaults</b> are displayed in the Other Facets column
any <b>Defaults</b> are displayed in the Other Facets column of the
+
of the [[PrF_UG_classes_template_slot_pane|Template Slots pane]]
[[PrF_UG_classes_template_slot_pane|Template Slots pane]]
+
in the [[PrF_UG_classes_classes_tab|Classes tab]].
in the
 
[[PrF_UG_classes_classes_tab|Classes tab]].
 
  
 
=== Domain ===
 
=== Domain ===
  
 
The set of classes where the slot is attached is called the <i>domain</i> of the slot.
 
The set of classes where the slot is attached is called the <i>domain</i> of the slot.
For example,
+
For example, the slot <i>urgent</i> is attached to a single class, <b>Content</b>,
the slot <i>urgent</i> is attached to a single class,
 
<b>Content</b>,
 
 
while the slot <i>name</i> is attached to a number of classes:
 
while the slot <i>name</i> is attached to a number of classes:
  
Line 512: Line 442:
 
[[Image:PrF_UG_slots_slot_domain_name.png|slots_slot_domain_name]]
 
[[Image:PrF_UG_slots_slot_domain_name.png|slots_slot_domain_name]]
  
See
+
See [[PrF_UG_slots_attach_slot|Adding a Slot to a Class]]
[[PrF_UG_slots_attach_slot|Adding a Slot to a Class]]
 
 
for more information about editing the domain of a slot.
 
for more information about editing the domain of a slot.
  

Revision as of 15:28, October 16, 2008

The Slot Editor


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

The Slot Editor can be used to define and edit the attributes, or facets, of a slot. The Slot Editor for the selected slot is displayed at the right of the Slots Tab. The Slot Editor can also be displayed as a free-standing window, as follows:

In the example below, the slot urgent for the class Article was double-clicked in the Template Slots pane. The Slot Editor displays a Boolean Type, with Single Cardinality, and a text documentation pane of the urgent slot.

slots_slot_editor1

A slot can be attached to more than one class. Each slot has a top-level (system) description; the system description can be specialized, or overridden, for a specific class. The scope of your edits depends on how you access the Slot Editor:

The Slot Editor displays the following information for a slot:

  1. Note Icons, which allow you to add notes.

  2. Name of the slot.

  3. Value Type of the slot.

  4. Cardinality of the slot.

  5. (optional) Minimum and Maximum values for the slot (slots of type Integer or Float only).

  6. (optional) Any Documentation that has been entered for the slot.

  7. (optional) An Inverse Slot for the slot (slots of type Class or Instance).

  8. (optional) Any Template Values that have been defined for the slot.

  9. (optional) Any Defaults that have been defined for the slot.

  10. Domain of the slot.

For certain value types, an additional pane appears below the Value Type pane:

  1. For type Class, the Allowed Superclasses pane appears.

  2. For type Instance, the Allowed Classes pane appears.

  3. For type Symbol, the Allowed Symbols pane appears.

Note Icons

The note icons, windows_slot_note.hide windows_slot_note.create windows_slot_note.delete, at the upper right of the Editor, allow you to add and remove yellow sticky notes to your slot. These notes, which are not part of your ontology, are displayed when the slot is selected at the Slots Tab. For information on how to add notes to any frame (class, instance, or slot), see Working with Notes.

Slot Name

You can edit the slot name directly in the Name field. Slot names are case-sensitive. A recommended convention is to make slot names lowercase, separating adjacent words with an underscore (_).

Value Type Menu

The Value Type menu allows you to select the slot value type, which determines the kind of values that the slot may hold. When you are creating instances for a slot, the slot type also determines how the slot is displayed in the Instance Editor. See the Standard Widgets for more information about instances and type.

slots_value_type_menu

The following table summarizes the value types. For a full description, click on the type name:

Type Description Examples

Any

any of the types below (logical Union)

Boolean

a logical, Boolean value; i.e., a value that is either true or false

true, false

Class

the slot takes one or more classes as values Editor

Float

a floating-point number (number with a decimal point) 1.0, 3.4e10, -0.3e-3

Instance

the slot takes one or more instances as values Head Honcho

Integer

an integer (a whole number) 1, 2, -4, 0

String

String of alphanumeric (ASCII) characters, possibly including spaces "Mars Mission"

Symbol

the slot takes values from a list of strings you define {red, blue, green}

When a value type of Class, Instance, or Symbol is selected, an additional pane appears below the Value Type menu. This pane allows you to select or create the values for the slot.

slots_allowed_superclasses

Cardinality

The Cardinality field allows you to specify the number of values allowed or required for the slot. This supplies the following options:

slots_cardinality

The default configuration allows the slot to have at most one value; that is, it can have one value or no value. You can change the default by entering a positive whole number in the at least and/or at most options, or by selecting the multiple option:

  • required/at least: Sets the minimum number of values for the slot. To use, enter a positive whole number in the at least entry bar:

    • If you enter a value for at least, required is automatically selected.

    • Setting at least equal to one (1) means a value is required for the slot.

    • Setting at least greater than one automatically selects multiple as well.

    • Setting at least equal to 1 and at most equal to 1 specifies that the slot must have exactly one value.

  • at most: Sets the maximum number of values for the slot. To use, enter a positive whole number in the at most entry bar:

    • Setting at most equal to one (1) means that the slot can have at most one value; this is called a single slot.

    • Setting at most greater than one automatically selects multiple. The slot can contain multiple values, but there is a limit to the number of values.

  • multiple: Allows the slot to have more than one value; multiple values are stored and displayed as a list:

    • As above, to set a minimum number of values, set the at least value.

    • As above, to set a maximum number of values, set the at most value.

    • The lack of an at most value indicates that there is no limit to the number of items the slot may contain.

    • Duplicate values are allowed, although their use is uncommon

Minimum (optional)

This field is applicable only to slots of type Integer or Float.

Minimum allows you to specify a minimum value for your slot. When present, the Minimum value is displayed in the Other Facets column of the Template Slots pane.

When an instance is created for a class with this slot, the value of the slot must be greater than or equal to the minimum. For example, a minimum of zero means instances cannot have negative values.

Together, Minimum and Maximum can be used to define an allowable range.

Maximum (optional)

This field is applicable only to slots of type Integer or Float.

Maximum allows you to specify a maximum value for your slot. When present, the Maximum value is displayed in the Other Facets column of the Template Slots pane.

When an instance is created for a class with this slot, the value of the slot must be less than or equal to the maximum. Together, Minimum and Maximum can be used to define an allowable range.

Documentation (optional)

The Documentation field allows you to enter a text description of the slot. Filling in this field is optional, but is recommended to make maintaining the knowledge base easier. This documentation is part of your knowledge base.

Inverse Slot (optional)

Only available for slots of type Class or Instance.

Allows you to create a reciprocal relationship between two slots. If this relationship is set up correctly, assigning a value (i.e., a specific class or instance) to the slot for one instance automatically assigns the instance as a value to the appropriate inverse slot. For example, the "direct superclass/direct subclass" relationship is actually an inverse slot relationship. See Understanding Inverse Slots and Creating an Inverse Slot Relationship for more information.

If a slot has an inverse slot, the name of the inverse slot is shown after the slot name at the Slots Tab.

Template Values (optional)

Allows you to specify the value(s) for a slot at the class level:

  • The template value is a required, uneditable value that is filled in for all classes and instances that use or inherit the slot.

  • The template value can not be changed or overridden at the instance level.

  • The number of Template Values should not exceed the at most value for the Cardinality of the slot.

For a value that can be overridden, use Defaults instead.

When present, any Template Values are displayed in the Other Facets column of the Template Slots pane in the Classes tab.

Defaults (optional)

Allows you to specify default value(s) for a slot:

  • When an instance is created for a class that has this slot, the default is automatically entered as the value of the slot.

  • The default value can be changed or overwritten.

  • The number of defaults should not exceed the at most value for the Cardinality of the slot.

When present, any Defaults are displayed in the Other Facets column of the Template Slots pane in the Classes tab.

Domain

The set of classes where the slot is attached is called the domain of the slot. For example, the slot urgent is attached to a single class, Content, while the slot name is attached to a number of classes:

slots_slot_domain_urgent

slots_slot_domain_name

See Adding a Slot to a Class for more information about editing the domain of a slot.

Viewing Several Slots

To view the information for several slots at once, select the slots at the Slots Tab and click the View

slots_slot.view_top_level

slot button to open the Slot Editor for each slot. To highlight multiple slots, hold down the Ctrl (Cmd) key while clicking each slot. To highlight a range of slots, click the first slot, then hold down the Shift key and click the last slot in the range. You can also view multiple slots using the View Top-level Slot slots_slot.view_top_level or View Slot Overrides slots_slot.view_overrides template slots buttons in the Template Slots pane.

Opening a new Slot Editor does not close the previous Editor. This allows you to compare the attributes for two or more slots. Edits can be made directly in any open Editor.

If you have multiple forms open, you can manage them as follows:

  • Cascade multiple forms by clicking the Cascade windows_cascade_windows.gray button below the main menu bar, or by selecting Cascade Windows from the Windows menu.

  • Close all open forms by clicking the CloseAllWindows windows_close_all_windows button below the main menu bar, or by selecting Close All Windows from the Windows menu.