Please enable JavaScript to view this site.

Altova FlowForce Server 2020 

Creates a file if the stream source is a file. Creates a temporary file if the stream source is not a file.

 

Signature

as-file(stream:stream) -> string

 

Parameters

Name

Type

Description

stream

stream

Specifies the stream source.

 

Examples

The following job creates a file called file.txt with one line of text. First, the stream-from-string function generates a stream from the text supplied as argument. Next, the as-file function takes the stream as argument and generates a temporary file from it. To copy the temporary file to a permanent path, the built-in copy function is called from a separate execution step. The file is copied to the working directory of the job (C:\FlowForce) and will be overwritten each time the job runs.

fs_func-example-as-file

See also Validate an XML Document with Error Logging.

© 2020 Altova GmbH