24.08.2015 Views

Oxygen XML Author plugin 13.2.0

Oxygen XML Author plugin 13.2.0

Oxygen XML Author plugin 13.2.0

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

<strong>Author</strong> Developer Guide | 198You can also use editor variables in the template files' content and they will be expanded when the files are opened.3. Open the Document Type dialog for the SDF framework and click on the Templates tab. Enter in the Templatesdirectory text field the value ${frameworksDir} / sdf / templates. As you already seen before, it isrecommended that all the file references made from a Document Type Association to be relative to the${frameworksDir} directory. Binding a Document Type Association to an absolute file (e. g.:"C:\some_dir\templates") makes the association difficult to share between users.4. To test the templates settings, press the File/New menu item to display the New dialog. The names of the twotemplates are prefixed with the name of the Document Type Association, in our case SDF. Selecting one of themshould create a new <strong>XML</strong> file with the content specified in the template file.Editor VariablesAn editor variable is a shorthand notation for context-dependent information, like a file or folder path, a timestamp ora date. It is used in the definition of a command (for example the input URL of a transformation, the output file path ofa transformation, the command line of an external tool) to make a command or a parameter generic and reusable withother input files. When the same command is applied to different files, the notation is expanded at the execution of thecommand so that the same command has different effects depending on the actual file.The following editor variables can be used in <strong>Oxygen</strong> <strong>XML</strong> <strong>Author</strong> <strong>plugin</strong> commands of external engines or otherexternal tools, in transformation scenarios, validation scenarios and <strong>Author</strong> operations:• ${oxygenHome} - <strong>Oxygen</strong> <strong>XML</strong> <strong>Author</strong> <strong>plugin</strong> installation folder as URL.• ${oxygenInstallDir} - <strong>Oxygen</strong> <strong>XML</strong> <strong>Author</strong> <strong>plugin</strong> installation folder as file path.• ${frameworks} - The path (as URL) of the frameworks subfolder of the <strong>Oxygen</strong> <strong>XML</strong> <strong>Author</strong> <strong>plugin</strong> installfolder.• ${frameworksDir} - The path (as file path) of the frameworks subfolder of the <strong>Oxygen</strong> <strong>XML</strong> <strong>Author</strong> <strong>plugin</strong>installation folder.• ${home} - The path (as URL) of the user home folder.• ${homeDir} - The path (as file path) of the user home folder.• ${pdu} - Current project folder as URL.• ${pd} - Current project folder as file path.• ${pn} - Current project name.• ${cfdu} - Current file folder as URL, that is the path of the current edited document up to the name of the parentfolder, represented as a URL.• ${cfd} - Current file folder as file path, that is the path of the current edited document up to the name of the parentfolder.• ${cfn} - Current file name without extension and without parent folder.• ${cfne} - Current file name with extension.• ${cf} - Current file as file path, that is the absolute file path of the current edited document.• ${cfu} - The path of the current file as a URL.• ${af} - The file path of the zip archive that includes the current transformed file (this variable is available only in atransformation scenario).• ${afu} - The URL of the zip archive that includes the current transformed file (this variable is available only in atransformation scenario).• ${afd} - The directory of the zip archive that includes the current transformed file (this variable is available only ina transformation scenario).• ${afdu} - The URL of the directory of the zip archive that includes the current transformed file (this variable isavailable only in a transformation scenario).• ${afn} - The file name (without parent directory and without file extension) of the zip archive that includes thecurrent transformed file (this variable is available only in a transformation scenario).

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!