Class to Text -> File Transformation

This transformation accepts a UML class, a package, or a model as its source and writes the names of the classes and their attributes and operations, and the parameters of the operations to a file. If you choose a model or a package as the source, the transformation writes the details of all the classes that the model or package contains.

Running the Transformation

To run the transformation:

  1. Start the run-time workbench.
  2. In the run-time workbench, create a UML model that contains a package with one or more classes.
  3. Switch to the Modeling perspective.
  4. Right-click a class, package, or the model; then click Transform > Run Transformation > Class to Text -> File.
  5. In the Run Transform window, on the Target page, specify the project in which to write the output file for the transformation.
  6. Click Run.

By default, the transformation stores the results in an output file named class2text.txt, in a folder named ClassToTextOutput. Open a Navigator view to view the output file.

To specify a different name for the output file, in the Run Transform window, click the Properties tab. On the Properties page, in the Target File Name field, specify a new name and click Apply.

Transformation Details

Transformation Source

This transformation accepts an UML model or an UML package or one or more UML classes as the source.

Transformation Target

This transformation accepts a project as its target.