![]() ![]() ![]()
|
CHAPTER 2
SIMPROCESS Metamodel EditorThis chapter describes the Metamodel Editor and its operation.Launching the Metamodel EditorThe SIMPROCESS Metamodel Editor is a separate application installed with SIMPROCESS. It can be launched from within SIMPROCESS by choosing Launch Metamodel Editor from the Define/Metadata menu.
When selected, the Metamodel Editor opens to an empty metamodel with a default name. If the Metamodel Editor is already open when Launch Metamodel Editor is selected, a new editor window will open with a default name.
Metamodel Editor DescriptionThe SIMPROCESS Metamodel Editor has two primary sections: the data item tree on the left and the Define Data Item section on the right. The buttons in between operate on the data item tree. (See "Metamodel Editor Buttons" on page 13.) An additional area for finding specific data items is below the data item tree.Data Item TreeThe data item tree contains a hierarchical view of the data item definitions created for the metamodel. The top node of the tree is the name of the metamodel. All data item definitions are subordinate to the metamodel name.
Define Data ItemThe Define Data Item section is used to specify the data item definition of the data item selected in the data item tree. A data item definition consists of· Name· Type - String, Real, Integer, Boolean, URL, Single Selection, Multiple Selection, Include, or Group· Min Occurs - Minimum number of occurrences. Must be an Integer greater than or equal to zero. Zero indicates that no instances of this data item are required.· Max Occurs - Maximum number of occurrences. Must be an Integer greater than or equal to zero. Zero indicates that the number of instances of this data item is unbounded.· SIMPROCESS Model Components - Activity, Entity Type, Resource, Pad, Connector, Model, or Swimlane· Description· Documentation URL/File ValueProperties can be set on every Type exceptGroup. See "Creating a Metamodel," beginning on page 13 for more information on these fields.Find Data ItemBelow the data item tree is the Find Data Item section. The Find Data Item section allows searching for a particular data item by name and type. If Named is selected, a data item name to search for can be entered and Ignore Case is enabled for selection. Wild cards (*) can be used before and/or after the search text to search for similarly named data items. If Of Type is selected,String,Real,Integer,Boolean,URL,Single Selection,Multiple Selection,Include, orGroupcan be selected. The search will then look for data items with a type matching the selected type. When both Named and Of Type are selected, the search is a logical AND search. That is, the search will look for data items that match the entered text and the selected type.Metamodel Editor OperationMetamodel Editor MenusFile Menu
New opens a new metamodel. Note that each opened metamodel, whether new or previously saved, will open in a new Metamodel Editor window.Open opens a previously saved metamodel. Metamodel files have the extension.mdmand must be located in themetamodeldirectory located in the SIMPROCESS installation directory. The Open menu item only displays metamodels located in that directory and only displays metamodels not already open. If a directory with the same name as the opened metamodel does not exist in themetamodeldirectory, it is created during the open process.Open Recent contains a list of up to 5 recently opened metamodels for easy access. The last item on the menu is Clear Menu, which removes all recently opened metamodels from the list.Save saves the metamodel. Note that the first time Save is used on a new metamodel, Save As will be invoked so the default name can be changed to something more meaningful. It is recommended that metamodels not be saved using the default metamodel name. On the first save, a directory with the same name as the metamodel will be created in themetamodeldirectory. This directory is for optional data source or documentation files.Save As saves the metamodel with a different name and only saves to themetamodeldirectory located in the SIMPROCESS installation directory. The.mdmextension will be appended to the file name if omitted. A directory with the new metamodel name is created in themetamodeldirectory. Contents from the previously named metamodel's directory are copied to the new directory.Properties opens a dialog that contains four editable fields: Author, Manager, Company and Max Edit Log Entries. Max Edit Log Entries sets the maximum number of entries that the Edit Log will keep. The value defaults to zero. (Zero indicates that the Edit Log can contain an unlimited number of entries.) The Edit Log contains a list of pairs of User Name and Edit Date. An Edit Log entry is added every time the metamodel is saved. If Max Edit Log Entries contains a number larger than zero, then only the latest entries are kept. The Created and Saved fields cannot be edited. Created contains the date and time that the metamodel was first saved. Saved contains the date and time of the latest save. The Clear Edit Log button removes all entries from the Edit Log.
Close closes the metamodel. If the metamodel has been changed since the last save, there will be a prompt to save the metamodel.Exit close all open metamodels. Each metamodel will prompt for save if necessary. Selecting Cancel on any save prompt will stop the exit process.Edit Menu
Cut removes the selected data items and places them on the clipboard.Copy copies the selected data items to the clipboard.Paste pastes the data item definitions on the clipboard as children of the selected data item definition. Note that the selected data item definition must either be the top level node (name of the metamodel), aGroupdata item definition, or a data item that has been designated to allow children. (See "Defining a Data Item," beginning on page 14 for information on data item definitions that allow child data item definitions.)Clear removes the selected data items and does not place them on the clipboard.Note that Cut, Copy, Paste, and Clear (and their associated tool bar buttons) only apply to data item definitions. To Cut, Copy, Paste, or Clear text fields (such as Data Item Name), the appropriate keyboard commands must be used. (For example, on Windows systems, Control-C is copy.) Also, multiple data item definitions can be selected, but they must be contiguous. Cutting or copying a data item that has child data items will include all child data items.Data Item Menu
Add Data Item adds a new data item to the selected metamodel,Groupdata item, or data item designated as a parent data item. Add Data Item and the Add Data Item button are only enabled when the selected data item is the metamodel name or can have child data items.Remove Data Item removes the selected data items. This and the Remove Data Item button function the same as the Edit/Clear menu item.Window MenuThis menu contains a list of the open metamodels. Selecting a metamodel in the list causes that Metamodel Editor to come to the front.Help Menu
Metamodel Help displays a list of main help topics.SIMPROCESS Manuals opens the SIMPROCESS Metamodel Editor User's Manual or the SIMPROCESS User's Manual. They will open using the application designated for PDF files by the platform on which SIMPROCESS is installed. On Linux systems, there must be aview.propertiesfile as described for the View button on the Documentation tab of Activity and Process properties dialogs. (See the Common Activity Input Fields section of Chapter 2 of the SIMPROCESS User's Manual.)About SIMPROCESS Metamodel Editor displays information about the Metamodel Editor, including the version, the copyright, and technical support information.Metamodel Editor Toolbar
The toolbar buttons have the same action as the menu item of the same name.· New - File/New· Open - File/Open· Save - File/Save· Cut - Edit/Cut· Copy - Edit/Copy· Paste - Edit/Paste· Clear - Edit/Clear· Properties - File/Properties· Help - Help/Metamodel HelpMetamodel Editor ButtonsAdd Data Item adds a new data item as a child of the selected item. This button is only enabled when only one item is selected and the selected item is the metamodel name, aGroupdata item, or a data item that has been designated to allow child data items.Remove Data Item removes the selected data items. This button and the Remove Data Item menu item function the same as the Edit/Clear menu item.Expand All expands the complete data item hierarchy.Collapse All restores the data item hierarchy to the top level.Creating a MetamodelA new metamodel contains only the top node of the tree, the name of which is the default name of the new metamodel.
Since the top node of the tree is selected by default, the Add Data Item button and menu item are active. Selecting either of these adds a new data item definition as a child of the top node. The new data item definition will have a default name. Use the Define Data Item section to set the properties of the new data item definition.Defining a Data ItemThe data item name can be change by editing the Name field. The data item name can consist of any string of characters, numbers, or symbols. However, it is recommended that special characters (especially &, { }, and [ ]) be avoided. Data item names can also be edited directly in the data item tree. Once a data item has been selected, simply click the data item again to enable editing. Alternatively, triple clicking will enable editing of the name, and clicking four times will enabled editing and select the name of the data item being edited.
While a data item name is being edited directly in the data item tree, several menu items and buttons are disabled. The edit is accepted by pressing the Return/Enter key or by removing the focus from the data item with the mouse or the Tab key. The edit is canceled by pressing the Escape key. Note that the data item name must be unique within the data item definition's hierarchy. That is, the new name must not match the name of the metamodel, the name of the parent data item definition, or the names of any sibling or immediate child data item definitions.Type defaults toString, but can be changed toReal,Integer,Boolean,URL,Single Selection,Multiple Selection,Include, orGroup. AURLdata item definition indicates that the metadata entered in a SIMPROCESS model for this data item will point to an object external to SIMPROCESS.Single Selectionindicates that the SIMPROCESS model metadata for this data item will be one item selected from a list of items.Multiple Selectionindicates that the SIMPROCESS model metadata for this data item will be zero or more items selected from a list of items. TheIncludeselection allows another metamodel to be included as a child of this data item when metadata is entered in SIMPROCESS. SelectingGroupas the type allows the data item definition to have child data item definitions and will cause the Add Data Item button and menu item to enable. Also,Groupdisables the Properties button next to the Type selection. The Properties button is used to set optional properties forString,Integer,Real,Boolean, andURLdata items, to define the lists forSingle SelectionandMultiple Selectiondata items, and to set the default metamodel for theIncludetype. The optional properties allow all types exceptIncludeto function similar toGroupdata items by having child data items. (See "Data Item Properties," beginning on page 16 for more information on data item properties including how to setupSingle SelectionandMultiple Selectiondata items.)
Min Occurrs sets the minimum number of actual data items that will appear in the SIMPROCESS model and defaults to one. A value of zero indicates that this data item is optional. Max Occurs sets the maximum number of actual data items that will appear in the SIMPROCESS model and defaults to one. A value of zero indicates that the maximum number is unbounded. For example, if the Name was Street and Min Occurs and Max Occurs were both two, then there would be two data items available to enter Street metadata in an associated SIMPROCESS model. Street [1] might contain something like "200 Corporate Parkway", and Street [2] might contain something like "Suite 100". (Note that the indices will be added automatically. See "Metadata Tree" on page 38.)SIMPROCESS Model Components sets the SIMPROCESS model components that can use this data item definition for metadata. If All is selected (default), then the individual check boxes for Activity, Entity Type, Resource, Pad, Connector, Model, and Swimlane will be disabled. These check boxes are enabled when Select is clicked. Child data item definitions will have every item under SIMPROCESS Model Components disabled since child data item definitions inherit the SIMPROCESS model component selections of the parent data item definition.Description is for an optional short text description of the data item definition.Documentation URL/Field Value is optional. Supporting documentation for the data item definition can be entered here. Information entered here will not appear in any SIMPROCESS model where the metamodel is used for metadata entry. If the entry is a URL, the View button will launch the preferred web browser. Is File must be selected if the entry is a file. The Is File option will be disabled until the metamodel is saved for the first time. This is because supporting documentation files must be located in the directory with the same name as the metamodel, and this directory is not created until the first save. When Is File is enabled and selected, the Select File button can be used to select a file from the directory of the metamodel. Note that supporting files must be manually copied into the directory named for the metamodel.Data Item PropertiesAll Type properties are set or changed by clicking the Properties button. Default values can be set for all data types. The default values are applied when the metamodel is assigned to a SIMPROCESS model and metadata is entered. (See "Applying Default Values," beginning on page 46 for information on how default values are applied in a SIMPROCESS model, and see "Assigning Metamodels," beginning on page 25 for more information on assigning metamodels to a SIMPROCESS model.)RealandIntegerdata items also allow constraints to be set on the values that can be entered in a SIMPROCESS model. Every Type for which properties can be set exceptIncludecan be designated to allow child data items. Thus, data items with a Type other thanGroupcan have child data items. This capability is enabled by selecting the Allow Child Data Items checkbox on the properties dialog.String Data Item PropertiesTheStringType properties dialog has a field for entering the default value.
Real Data Item PropertiesTheRealType properties dialog Real Constraints fields allow minimum and maximum values to be entered. The minimum must be less than the maximum.Infinityis assumed if the upper value field is empty. If the lower value field is empty,-Infinityis assumed. Below Real Constraints is the Default Value field. Leave this field emtpy if no default value should be used.
Integer Data Item PropertiesTheIntegerType properties dialog contains three buttons for setting constraints: Integer, Long Integer, and Custom Integer. Integer is the default selection. Select Custom Integer to set a unique range of allowable values. When selected, the fields to the right will enable allowing minimum and maximum values to be entered. The minimum must be less than the maximum. Below the Integer Constraints area is the Default Value field. Leave this field empty if no default value should be used.
Boolean Data Item PropertiesTheBooleanType properties dialog contains a single selection box from which True or False can be selected as the default value.
URL Data Item PropertiesTheURLType properties dialog contains a field for the default URL. Is File should be selected if the URL represents a file. The Select File button enables when Is File is selected. Is File will be disabled until the model is saved for the first time since supporting files must be located in the directory with the same name as the metamodel.
Single and Multiple Selection Data Item PropertiesSingle SelectionandMultiple SelectionTypes offer a list of items from which to choose. In SIMPROCESS, theSingle SelectionType displays a selection box (like the Type selection box) from which only one item can be selected. TheMultiple SelectionType displays a scrollable list from which one or more items can be selected. Note that there is no limit to the number of items that can be on a selection list; however, very large lists could cause performance issues when used in a SIMPROCESS model.When the Properties button next to Type is selected, a dialog displays that allows the list to be populated.
There are three tabs: File, Spreadsheet, and Database. These tabs represent the three types of data sources that can populate the list. One or more types of data source can be used. However, only one list will be created. Thus, if more than one data source is used, the data from all selected sources are combined into one list.The File tab is used to specify an ASCII file as the data source. Use File Data Source must be selected to use this type of data source. The Select File button can be used to locate the file. Each line of the file will be considered an item of the list. Data source files must be located in the directory with the same name as the metamodel. Thus, the Select File button will be disabled until the metamodel is saved for the first time.
The Spreadsheet tab specifies a spreadsheet as a data source. The Spreadsheet can be a Workbook file or an XML Spreadsheet. Once Use Spreadsheet Data Source has been selected, four fields are required: File Name, Sheet Name, Starting Row, and Column. The Select File button can be used to locate the spreadsheet file. As with the File tab, the Select File button will be disabled until the metamodel is saved for the first time. Enter the name of the worksheet in the Sheet Name field. Starting Row should have the row number (rows start with 1) that contains the first value. Column should have the column number (column A would be column number 1) of the sample data. The data must be in a single column with no empty cells. The data is read beginning at the Starting Row and continues until an empty cell is reached.
The Database tab is used to specify an SQL database as the data source. Use Database Data Source must be selected to use this type of data source. Two items are required: DSN/Properties File and SQL Query. DSN/Properties File must contain the database location/connection information. DSN stands for Data Source Name and is the DSN established in the Windows ODBC Control Panel. (See the Setting Up Database Using Windows and Open Database Connectivity (ODBC) section of Chapter 10 of the SIMPROCESS User's Manual for more information on using a DSN.) Properties File is the name of the properties file that contains the JDBC url and driver information and, if necessary, username and password. A Properties File must be used on a non-Windows system. After the metamodel has been saved for the first time, the Select File button can be used to locate the properties file. SQL Query must contain the query that returns the items to populate the list. Note that if the query returns multiple columns, only the first column will be read for list data.
The list must be populated in the Metamodel Editor since it cannot be populated from SIMPROCESS. Empty lists will be displayed in SIMPROCESS if the list items have not been retrieved from the data sources. Note that an empty data display area indicates an emtpy list. The Get Data button clears the current list then retrieves list items from the selected data sources.
When items exist in the list, the Clear button is enabled. Clear removes all items from the list. When items in the list are selected, the Remove button is enabled. Remove removes the selected items from the list. Multiple items can be selected by holding down the Control key (or appropriate non-Windows system equivalent) during selection. If the list is lengthy, Remove can be used to eliminate unnecessary items to improve performance.Any items selected in the list when OK is clicked will be considered the default selections for this data item. An error will occur if there is more than one item selected in the list for aSingle Selectiondata item. To remove a selection without selecting another item, hold down the Control key (or appropriate non-Windows system equivalent) and click the selected item.If Max Occurs is greater than one forSingle SelectionorMultiple SelectionTypes, the same list will be used for each instance, but different selections can be made.Include Data Item PropertiesTheIncludeType properties dialog displays a list of the metamodels in themetamodeldirectory.
A single metamodel can be selected from the list. The selected metamodel is the default metamodel for this data item. When a metamodel is selected, the Lock Default Metamodel Selection checkbox enables.
If Lock Default Metamodel Selection is selected, the selected default metamodel cannot be changed in SIMPROCESS.Group Data Item PropertiesAdditional properties cannot be set onGroupdata items. Their purpose is to collect related data items under a single data item.Moving Data ItemsData items can be rearranged by selecting one or more data items in the data item tree and dragging them to a new location in the data item tree. If more than one data item is selected, the selected data items must be contiguous. Note that before a move can begin the item (or items) to be moved must be selected, then clicked on a second time to actually drag. Data items can be moved within the same level or to a different level. When moving a data item to a different level, only the metamodel name and data items that can have child data items will highlight. When a data item is dropped on a highlighted data item, the moved data item is appended to the end of the data items that are direct descendants of the highlighted data item. Data items can be moved to a specific location by inserting the moved data item between two existing data items. Note that aGroupdata item or any data item with child data items cannot be moved to within its own descendants. A move can be canceled by returning the moved item to its original location or by moving the item off of the Metamodel Editor application. Data items cannot be moved between open metamodels. Cut and Paste must be used to move a data item from one metamodel to another.Metamodel ExampleIn the example below, the default Name, Data Item 1, was changed to Department. Type was set toSingle Selection, and Min Occurs and Max Occurs were both left at the default of one. SIMPROCESS Model Components was set so this data item definition will only apply to SIMPROCESS Activities, and a Description was entered.Marketing.xlswas selected as the documention file for Documentation URL/File Values after the metamodel was saved with the name CorporateInformation. In the Properties for Department, Allow Child Data Items was selected.
Even though the Type of Department is notGroup, Department can have child data items so the Add Data Item button and menu item are active. To add another data item definition, the top node (CorporateInformation) must be selected. In the example below, three other data item definitions were added and their properties set. The data item Regions was added and its Type set toMultiple Selection. The data item definition Location could be defined by setting its Type toGroupand adding several child data item definitions (Street, City, State, and Zip Code). However, the metamodel AddressModel contains the same data item definitions so the Type of Location was set toIncludeand AddressModel was selected in the properties. Although not visible, in AddressModel Street has Min Occurs set to one and Max Occurs set to two, and State has Type set toSingle Selection.
Another data item definition was added to the top node. This data item definition was named Contact Info and its Type was set toGroup. Its Min Occurs and Max Occurs were both set to zero. Thus, this data item is optional and the number allowed is unbounded. Three child data item definitions were added to Contact Info: Name, Phone, and Email. The last data item definition is Support, which is anIncludeType data item. No default metamodel was set.To complete the metamodel, Location and Contact Info were copied and pasted on the Department data item definition. This allows for separate location and contact information for the Department.The completed CorporateInformation metamodel, which is included in the SIMPROCESS installation in themetamodeldirectory, is shown below.
|
Quadralay Corporation http://www.webworks.com Voice: (512) 719-3399 Fax: (512) 719-3606 sales@webworks.com |
![]() ![]() ![]()
|