• No results found

Import Document Objects

In document Aligned Elements User Manual V (Page 91-97)

It is possible to import Document Object from files exported using the default xml Transformation as described in 3.25 or manually/externally created. Importing Document Objects is only possible from the Project Explorer.

To import Document Objects:

1. Select the target chapter or book in the Project Explorer. 2. Click Import Objects in the context menu.

3. You will now be prompted to select the files to import. The Directory Browser is set to display xml files. Note that you can import several files at a time.

4. The Import Dialog will now be displayed. The top drop down box contains the objects that have been selected for Document Objects to copy. The following options are available:

Change Comment

You can here customize the initial change comment (set for revision 1) used when the objects are created e.g. “Imported from internal system so-and-so”.

Recreate chapters

By default, exported Document Objects also contain their original chapter path. With this option selected, the chapter path is recreated (if it does not already exists) and the imported object is automatically placed in that chapter.

Trace information are also, by default, included in the export object description and traces can be recreated if the options are selected. “Internal traces” signifies traces that exist between the imported objects. Outgoing traces are traces from the imported objects to other objects. Incoming traces are traces from other objects to the imported objects.

Note!

When setting Internal Traces, only the “outgoing” traces in the import file are considered. Traces are only recreated if the ID AND revision matches.

For outgoing and incoming traces to be set, these objects must be loaded and available at the time of import.

The following rules apply to importing:

 Document Objects of the same type as the target chapter will be placed in the target chapter. Document Objects of different types are placed in the applicable book (under the root chapter).

 The Document Objects will receive new IDs as they are imported.

 If a Document Object is imported several times, a copy with a new ID of the object is created each time.

Note! On exporting and importing Failure modes, it is recommended that the corresponding Hazards are exported and imported in the same operation, since the cause, effect, probability, severity and visibility information is stored in the Hazard. Use “Keep Internal Traces” at import. Synchronized Import

Synchronized import implies that the data of an existing object is overwritten with the data of an imported object. Aligned Elements offer two modes of synchronized import:

Note! Only Document Object attribute data are synchronized, not traces. A new revision is created for the target Document Object when it is synchronized.

Without Synchronization Map File

For each imported object the user manually selects which existing objects that shall be overwritten.

For this option there is the additional option of Auto-proposition of the synch object. If the imported object has an equivalent ID in the book of import, that object is automatically suggested as the object to synchronize with.

Synchronization without map file has the additional options when the user select not to map the imported object to an existing object.:

 Skip import of object – The object is NOT imported.

 Import as normal – The object is simply imported as a new object.

A Synchronization Map is an xml file that contains ID-mapping information from previous import sessions. It is a key-value collection where:

 The key is the ID of the object in the import file (i.e. from the exported object)

 The value is the ID created for the object when imported.

It is assumed that these object IDs are contained in the imported files and the target project respectively. If the Synchronization is done regularly for the same objects set, this mode is clearly preferable. Consequentially, there also exists an option to “Create Synchronization Map File” at import.

Synchronization with a Map file has the additional options for objects that are found in the import file but not found in Map file:

 Import as normal – The object is simply imported as a new object.

 Skip import of object – The object is NOT imported.

 Manually select the map target – Prompts the user with the option to manually designate an object to overwrite with the imported data.

Merge Synchronization Map Files after Import

In the case where synchronized imports are done regularly and where new Document Objects are added to the import set, it can be of interest to update the synch map file with these new

Document Objects using the “Merge Synchronization Map Files after Import”. This is done in the following manner:

1. Check the “Create Synchronization Map File” to generate the import map for the new Document Objects which shall be merged with the existing map files.

2. Load the Synch Map file(s) to be used during import for the existing mapping. 3. Check the “Merge Synchronization Map Files after Import”.

As a result, the generated map file for the new Document Objects will be merged with the existing Synch Map files, creating a new, updated Synch Map file.

The Import Process

Regardless of the type of import, to start the import, click OK in the Import Dialog. Initially, the user also has the option to deselect Document Objects from the import file.

Selecting the second option takes you to a dialog where you can deselect Document Objects from the import set. The deselected objects are not imported.

3.26.1 Import mapping of unknown Object Types

If the imported Document Object is of a type that is not available in the target projects template directory, the user will be asked to map the unknown type to a known type (i.e. a type available in the template directory).

If the user selects to map to a valid, existing type, all subsequent objects of the unknown type found in the input session will automatically be mapped to the selected type.

If the user declines to map the object of the unknown type to an existing type, all subsequent objects of the unknown type found in the input session will be discarded / not imported.

3.26.2 Import mapping of unknown Attribute

If the imported Document Object contains an Attribute of a name and type that does not match an existing Attribute in the given Document Object Type, the user will be asked to map the unknown attribute to a known/existing attribute of the same attribute type.

If the user selects to map to a valid, existing attribute of the same attribute type, the attribute in all subsequent objects found in the input session will automatically be mapped to the selected

attribute.

If the user declines to map the unknown attribute to an existing attribute type, the unknown attribute in all subsequent objects found in the input session will be discarded / not imported.

3.26.3 Import mapping of unknown Attribute Enum Value

If the imported Document Object contains an Enum or UserEnum Attribute Value that does not match an existing Attribute Value in the given Document Object Type, the user will be asked to map the unknown value to a known/existing value.

The user has to map the unknown attribute value to a valid, existing value and consequently the unknown attribute value in all subsequent objects found in the input session will automatically be mapped to the selected attribute value.

3.26.4 Applying xsl-transformations on the import file

If the import file is not conformant to the default import-xml schema, the user is inquired if an import transformation should be applied. If applicable, the user will be asked to supply a valid xsl- file defining the transformation.

In document Aligned Elements User Manual V (Page 91-97)

Related documents