D3PLOT 22.1

Select Models From Database

Select Models From Database

From D3PLOT 10.0 onwards, D3PLOT can select models from a model database. The database file is an XML format file that contains information on where models are located along with a brief description of each model, (see Database Format for more details on the file format)

To select a model database either enter it's name in the text box or use the file selector.

The default model database can be specified as a command line argument (see Command Line Options for more details). The default database filename and location can also be specified in the preference file (see Appendix B for more details)

d3plot*database_dir:
d3plot*database_file:

After a database file has been selected it's contents will be read and D3PLOT will display a Tree Like menu showing the contents of the database.

As each item is displayed D3PLOT will check to see if the files that it refers to exist.

If a file does exist then a green tick will be displayed

If a file does not exist then a red cross will be displayed

The number of levels in the database that are automatically expanded when it is first displayed can be specified in the preference file (see Appendix B for more details)

d3plot*database_expand:

After selecting the required models use Apply to close the database window and return to the main menu where the selected models will be displayed along with the model numbers they will be read in as.

Selecting Models

Models can be selected and deselected by clicking on each row. Multiple model can be selected by clicking on the 1st model and holding down SHIFT while selecting the last model in the range.

As each model is selected the model number than it will be read in as is automatically displayed alongside the model description.


A complete branch can be selected/deselected by selecting the branch label (Iteration 1).

Modifying the Database

Database entries can be added, removed and modified by right clicking on a branch label or a model description

Right clicking on a branch label will display 4 options

Modify ... Modify the branch label.
Add Model ... Add a new model into the selected branch.

A menu will be displayed to select a new model and to define the model description that is displayed for the new model.
Insert ... Insert a new branch within the selected branch.
Delete Delete this branch and everything within it.

Right clicking on a model description will display 3 options

Modify ... Modify the model location and description.
Insert ... Insert a new branch.

The selected model will be moved into the new branch.
Delete Delete the model

Saving the Database

After modifying the database use the Save option to save the changes for future sessions.

Creating a new Database

If you do not have a database or if you want to create a new one then D3PLOT can create the new database for you. To create a new database click the CREATE button and simply enter the name of the new database file in the text box that appears, D3PLOT will then check that the file does not already exist and if it doesn't it will create a new empty database.

Alternatively if you type in the name of a file in the main Open Plot File window that does not exist then D3PLOT will ask if you want to create a new empty database using that filename.

Once you have done this you can use the Modify options above to add items into the database and then save the file before exiting.

Database Format

The Model Database uses an ASCII XML file format.

All items with the database are either branches or models. Each database entry has an XML name  and a LABEL element. Models also contain a model element that contains the full pathname of one of the files belonging to the model.

The XML name  should be unique and should obey the following rules

  • Names can contain letters, numbers, and other characters
  • Names must not start with a number or punctuation character
  • Names must not start with the letters xml (or XML, or Xml, etc)
  • Names cannot contain space

  • The LABEL is the string used to display an item within the tree view. Unlike the XML name  the LABEL can contain any ASCII character.

    XML
    <model_database version="10.000000">
    <Template_Demolabel="Template Demo">
    <iteration_1label="Iteration 1">
    <baselabel="Base"
    model="e:\release meeting\crush\base\base.ptf"/>
    <run_1 label="Run 1"
    model="e:\release meeting\crush\run1\run1.ptf"/>
    <run_2 label="Run 2"
    model="e:\release meeting\crush\run2\run2.ptf"/>
    <run_3label="Run 3" model="e:\release meeting\crush\run3\run3.ptf"/>
    <run_4label="Run 4"
    model="e:\release meeting\crush\run4\run4.ptf"/>
    </iteration_1>
    <iteration_2label="Iteration 2">
    <baselabel="Base"
    model="e:\test\crush2\base\base.ptf"/>
    <run_1 label="Run 1"
    model="e:\test\crush2\run1\run1.ptf"/>
    <run_2label="Run 2"
    model="e:\test\crush2\run2\run2.ptf"/>
    <run_3label="Run 3"
    model="e:\test\crush2\run3\run3.ptf"/>
    <run_4label="Run 4" model="e:\test\crush2\run4\run4.ptf"/>
    </iteration_2>
    </Template_Demo>
    </model_database>