Courier Editor
Overview
This page describes how to use CourierEditor.
CourierEditor is an editor for editing XML files required for Courier. This page mainly explains how to create a data binding source. A data binding source can have multiple data binding items. The created data binding source is saved as an .xcdl file. Additionally, Scene Composer allows you to bind arbitrary properties and data binding items.
Please refer to data binding basics here.
Please refer to data binding with Scene Composer here.
For more information about data binding items that you configure within a data binding source, see the Xml Courier Definition Language (XCDL) schema documentation (cgi_studio_courier\doc\CGI_Studio_Courier_XCDL.chm).
Starting Courier Editor
Courier Editorion can be started following process.
- Open "Courier Editor Parameters" dialog via menu "File" > "Define application specification".
- Select the "Edit...".


Courier Editor main window
CourierEditor user interface
Menu bar
Please see the table below for details on CourierEditor menu bar.
| Menu name |
Description | |
| File |
New | Create a new data binding source. |
| Open | Open an existing data binding source. | |
| Close | Closes the currently open data binding source. | |
| Save |
Overwrites the currently open data binding source. |
|
| Save As |
Save the currently open data binding source as. |
|
| Edit |
Undo | Undo the previous operation. |
| Redo | Redo the previous operation. | |
| Validate | Validate the currently open data binding source. | |
| Add Include | Add another data binding source to "include". | |
| Add Message | Add a message item to "messages". | |
| Add Message Group | Add a group item to "messages". | |
| Add Compound | Add the compound item to "types". | |
| Add Binding Source | Add a bindingSource item to "bindingSources". | |
| Help | View Schema Help | Open an "Xml Courier Definition Language (XCDL) schema documentation". |
UI item
Details of the UI items on CourierEditor main window. The numbers in the diagram match the numbers in the explanations for each item below.

| UI item |
Description |
| 1. Data binding source path information |
|
| Include Path | Set the save destination of the referenced Data binding source. |
| File path | Set the save destination of the Data binding source. |
| 2. Data binding item editing area The top row of tabs is for selecting the data binding source. (When setting Include path) |
|
| Raw XML tab |
Information on all items included in the Data binding source is displayed. |
| Types tab | Only items included in "types" in Raw XML are displayed in list format. You can add/edit/delete items. |
| Binding Sources tab | Only items included in "bindingSources" in Raw XML are displayed in list format. You can add/edit/delete items. |
| 3. Verification result view |
|
| ー | The data binding source validation results are displayed. |
Create new definition
Create a Data binding source from [ File > New ] on the CourierEditor menu bar.

In the "New File" dialog, set the destination and name for the new data binding source, then click [ Save ].

Open existing definition
In the Open dialog, select an existing data binding source, then click [ Open ]..

In addition to the steps above, you can also open an existing data binding source from the CourierEditor main window. Click the [...] button at the right end of File Path to set the path required to open an existing data binding source. The [Open] button will appear at the right end of File Path, so click it.

Setting the Include Path
You can set an Include Path for a Data binding source. Include path allows you to pre-include the contents of a specific Data binding source in the Data binding source you are editing by setting the path of the specific Data binding source. For example, by setting a Data binding source that is used for general purposes to a Include Path, there are advantages such as eliminating the need to create a similar Data binding source for each solution.
How to set Include Path
To set the Include Path, click the [ ... ] button at the right end of the Include Path in the CourierEditor dialog to open the "Include path" dialog.

The details of the Include path dialog are as follows. Use [ Add path ] to set the destination for any Data binding source.

| UI item | Description |
| Add path | Sets the path for a specific Data binding source. |
| Remove path | Removes the path selected in the Include path dialog. |
| Move up | Moves the display order of the paths selected in the Include path dialog in ascending order. |
| Move down | Moves the display order of paths set in the Include path dialog in descending order. |
| OK | Finish setting Include path and proceed to the next step. |
After setting the Include Path in the Include path dialog, perform the following operations in the editing area of the Data binding item.
-
Add an include element by selecting [ Add new include ] from the context menu of include in the Raw XML tab.

- Enter the file name of specific Data binding source in [ href ] of the added include element.

- From the context menu of the added include element, choose [ Edit (filename of specific Data binding source) ].

- The "(specific Data binding source name).xcdl" tab is displayed at the top of the Data binding item editing area.

By performing the above operations, specific Data binding source can be included in the Data binding source being edited.
Edit definition
Adding new item
Add a new item by selecting [ Add new (addable item name) ] from each item context menu.

Deleting the item
Select [ Delete (item name you want to delete) ] from the context menu of the item you want to delete.

Types / Binding Sources tabs
The Types and Binding Sources tabs are duplicates of the Raw XML tab's types and bindingSources. By using the Types tab and Binding Sources tab, you can edit the types and bindingSources items in the Raw XML tab, and display them in a list. Edits in the Raw XML tab and the Types/Binding Sources tab are synchronized with each other.

Raw XML tab and Type tab

Raw XML tab and Binding Sources tab
Defining the data type of a data binding item
In the Binding Sources tab, you can define the data type of a data binding item. You can select a pre-defined data type from the item > type pull-down menu.

You can define a custom data type by selecting <Add Type> from the type pull-down menu. When you select <Add Type>, the "Type" dialog opens, so click the [ + ] icon in the upper left. A new data type will be added, so enter the data type information and click [ OK ].

The added custom data type will be selectable from the pull-down menu of type.

To make the information easier to understand, the Types and Binding Sources tabs display only the important properties of the Raw XML tab.
Specify optional artifacts like the message distribution
- Check the checkbox to the left of each artifact to set the value.
- Note:
- If not specified the inherited distribution is used
- The broadcast value is edited by the checkbox on the right side
- Uid will be automatically created by the editor

Choose references from the dropdown list e. g.
- The definition contains a message „Test“
- The messageRef of a pool is not set which resluts in a validation error
- Click the dropdown lost to select the message „Test“
- The messageRef will be set to the uid of message „Test“

Validation
Validation can be performed in two ways.
- Activate validation the Edit menu
- Using the shortcut Alt+V
Validation output is shown on the lower part.
