Decompiler

Goal

Generates Companion for Delivery Excel, CSV or XML files from any STEPXML file:

From local file

Decompile from file can be launched with the following maven command:

mvn c4d:decompile -Dinput=<STEPXML file> -DoutputDirectory=<folder>

From Step

Decompile from Step can be launched with the following maven command :

mvn c4d:decompile -DexportConfiguration=<Export Configuration ID> -DoutputDirectory=<folder> -P my-env-profile

This feature is available with STEP Rest API V1 (default) and STEP Rest API V2 STEP 10.0.

Parameters

Mandatory parameters :

  • input STEPXML (input either exportConfiguration, only one is required) :
    • input path to STEPXML file
    • exportConfiguration id of export configuration used to export STEPXML
  • outputDirectory path to the folder where the files are decompiled

Decompiler assume multiple other parameters:

  • outputFormat
    • Description: Used to generate only CSV or XLSX file when decompiling datamodel STEPXML file.
    • Allowed values:
      • CSV (default value): Files are decompiled in CSV except for those forced in XML
      • XLSX : Files are decompiled in XLSX except for those forced in XML
      • BOTH (deprecated) replaced by CSV_XLSX
      • CSV_XLSX : Files are decompiled in CSV and XLSX except for those forced in XML
      • XML : Files are decompiled in XML
      • SPLIT_XML : The files are decompiled in XML and split at the highest level to make one file per element
  • attributeGroupBy
    • Description: Used to choose how to split attributes files when decompiling STEPXML file.
    • Allowed values: None (default value), AttributeGroup, UserType, BOTH.
  • packageName
    • Description: Used to store file in proper hierarchy and to generate file imports.
    • Example: fr.cantor.step.
  • splitLov
    • Description: Used to separate lists of values in multiple files.
    • Allowed values: true (default value), false.
  • addBOM
    • Description: Used to add a BOMopen in new window to the generated CSV files so that Excel opens the files with the correct encoding.
    • Allowed values: true, false (default value).
  • flattenByType
    • Description: Used to decompile without using the hierarchy to distribute decompiled elements in different directories.
    • Allowed values: true, false (default value).
  • useTemplate (Companion for delivery >= 5.3.0 and Companion Twirl Templates >= 4.0.0)
    • Description: Used to generate .companion.xml files that use companion twirl templates when it's possible. See Companion Twirl Templates changelog to see which ones are supported.
    • Allowed values: true, false (default value).

TIP

Decompiled files are stored in directories corresponding to package name, file types and setup group hierarchy.

WARNING

CSV and Excel file need rework after generation.
Moving XML files can break imports.

Use case

Existing project recovery

From an export of all your STEP configuration, launch the Companion for Delivery decompiler to generate Companion for Delivery files.
Files can be added to a Companion for Delivery project and stored in a Version control systems.

Maintain STEP configuration

Some configuration can be maintained inside of STEP, like web-ui, and be easily decompiled to be saved in a Version control systems.

Companion for Delivery file example

Decompiling a STEPXML file allows you to have an example of a new Companion for Delivery file format.

Last Updated: