Create Association Types |
Top Previous Next |
For each association you identified between two topic types, you will need to create three topics and specify the association schema. The three topics define the type of the association itself and the type of role played by each of the two topics in the association. You can give these three topics any kind of name you like, but we recommend the following pattern:
If you follow this pattern, it has the effect of making it very easy to locate the role types for an association and in a sorted list, the association type and the role types should always appear grouped together. This makes it much easier to enter and manipulate your ontology as you work. Regardless of the names you assign to the association type topics, you must flag the topic for the association type as such using the NPCL panel of TMEditor, and the other two topics must be assigned as Role Types. This is shown in the screenshots below: For efficiency, it is recommended to create the role types first. Marking a role type Marking an association type This tells the ontology editor that these topics can be used to construct association schema information. When you have created the first topic and set its name and type, use the New Topic button on the Topic Editor page to create a new topic without having to return to the Topic Selector page. Having created these three topics, you must now return to edit the topic for the association type. You can find this topic by returning to the Topic Selector Page (using the Change Topic button on the Topic Editor page), then select Association Type from the left-hand list and your new association type should be displayed in the right-hand list, select this topic and then click the Edit button to edit the topic. On the Topic Editor page for the topic there should be an additional button in the menu bar labelled Define Schema. Click this button to go to the Association Type Editor page. To specify that the topic types Company Employee and Company are included in the association as role players for the role types Employee and Employer, as well as the association Company Employs Person, these must be specified as Role Player Constraints for each topic type. In the screenshot below the Company Employee topic type has a specified Role Player Constraint showing the role of Employee and association Company Employs Person have been added as a role player constraint. Similarly, for the Company topic type the same association would be specified as a role player constraint but the role would be Employer. Adding Role Player Constraints to Company Employee topic type |