Options
All
  • Public
  • Public/Protected
  • All
Menu

Interface CommandOutputBindingProperties

Auto-generated interface for https://w3id.org/cwl/cwl#CommandOutputBinding

Describes how to generate an output parameter based on the files produced by a CommandLineTool.

The output parameter value is generated by applying these operations in the following order:

  • glob
  • loadContents
  • outputEval
  • secondaryFiles

Hierarchy

Implemented by

Index

Properties

Optional extensionFields

extensionFields?: Dictionary<any>

Optional glob

glob?: string | string[]

Find files or directories relative to the output directory, using POSIX glob(3) pathname matching. If an array is provided, find files or directories that match any pattern in the array. If an expression is provided, the expression must return a string or an array of strings, which will then be evaluated as one or more glob patterns. Must only match and return files/directories which actually exist.

If the value of glob is a relative path pattern (does not begin with a slash '/') then it is resolved relative to the output directory. If the value of the glob is an absolute path pattern (it does begin with a slash '/') then it must refer to a path within the output directory. It is an error if any glob resolves to a path outside the output directory. Specifically this means globs that resolve to paths outside the output directory are illegal.

A glob may match a path within the output directory which is actually a symlink to another file. In this case, the expected behavior is for the resulting File/Directory object to take the basename (and corresponding nameroot and nameext) of the symlink. The location of the File/Directory is implementation dependent, but logically the File/Directory should have the same content as the symlink target. Platforms may stage output files/directories to cloud storage that lack the concept of a symlink. In this case file content and directories may be duplicated, or (to avoid duplication) the File/Directory location may refer to the symlink target.

It is an error if a symlink in the output directory (or any symlink in a chain of links) refers to any file or directory that is not under an input or output directory.

Implementations may shut down a container before globbing output, so globs and expressions must not assume access to the container filesystem except for declared input and output.

Optional loadContents

loadContents?: boolean

Only valid when type: File or is an array of items: File.

If true, the file (or each file in the array) must be a UTF-8 text file 64 KiB or smaller, and the implementation must read the entire contents of the file (or file array) and place it in the contents field of the File object for use by expressions. If the size of the file is greater than 64 KiB, the implementation must raise a fatal error.

Optional loadListing

loadListing?: LoadListingEnum

Only valid when type: Directory or is an array of items: Directory.

Specify the desired behavior for loading the listing field of a Directory object for use by expressions.

The order of precedence for loadListing is:

  1. loadListing on an individual parameter
  2. Inherited from LoadListingRequirement
  3. By default: no_listing

Optional outputEval

outputEval?: string

Evaluate an expression to generate the output value. If glob was specified, the value of self must be an array containing file objects that were matched. If no files were matched, self must be a zero length array; if a single file was matched, the value of self is an array of a single element. The exit code of the process is available in the expression as runtime.exitCode.

Additionally if loadContents is true, the file must be a UTF-8 text file 64 KiB or smaller, and the implementation must read the entire contents of the file (or file array) and place it in the contents field of the File object for use in outputEval. If the size of the file is greater than 64 KiB, the implementation must raise a fatal error.

If a tool needs to return a large amount of structured data to the workflow, loading the output object from cwl.output.json bypasses outputEval and is not subject to the 64 KiB loadContents limit.

Generated using TypeDoc