IN stage v1.2

Pipelines v2.0

 

Purpose, Operands, Streams used, Usage notes, Examples, See also

Home

 

Syntax

 

>>__IN_________________________________________________________________________________><

 

Purpose

 

IN is dual purpose. When IN is specified in a pipeline that is launched through the CALLPIPE stage command; IN reads records from that calling pipeline. When IN is specified in a pipeline that is connected to the STDOUT stream of another WIN32 process; IN reads records from its STDIN stream. IN splits its input at Line-Feed characters; discarding both individual and groups of Carriage-Return characters and writes the resulting records to its primary output stream.

 

Operands

 

None.

 

Streams used

 

The following streams are used by the IN stage:

 

Stream

Action

 

 

Input streams

IN reads records from the CALLPIPE stage command of the calling pipeline or from its STDIN stream.

Primary output stream

IN writes records to its primary output stream.

 

Usage notes

 

     1)

IN does not delay the records.

 

     2)

When IN reads from its STDIN stream, it reads its input records one at a time; waiting for each one to be consumed from its primary output stream before reading another. When IN reaches end-of-file on its STDIN stream, IN disconnects its primary output stream and the stage ends.

 

     3)

IN splits its input at Line-Feed characters; discarding both individual and groups of Carriage-Return characters and writes the resulting records to its primary output stream. IN discards the last Line-Feed character of its input where this would produce a null output record.

 

     4)

You should only specify the IN stage command once in a pipeline; otherwise the results will be unpredictable.

 

     5)

IN verifies that its secondary input and secondary output streams are not connected and then begins execution.

 

Examples

 

The following pipeline shows the path environment variable parsed into its individual values.

 

environ.rex

 

**** Top of file ****
01 Address Rxpipe
02
03 ‘pipe in | split at str /;/ | specs ws /=/ w-1 1 | cons
04
05 Exit 0
**** End of file ****
 
C:\>path | environ.rex
 
Output:
C:\WINDOWS\system32
C:\WINDOWS
C:\WINDOWS\System32\Wbem
C:\Program files\TenFiftyTwo\Pipelines

 

See also

 
Reference the following links for additional information:
 
CALLPIPE, CONSOLE, OUT
 

History of change

 

Version

Action

Description

 

 

 

1.1

Changed

IN splits its input at Line-Feed characters; discarding both individual and groups of Carriage-Return characters and writes the resulting records to its primary output stream. IN discards the last Line-Feed character of its input where this would produce a null output record.

1.2

Changed

IN reads input records from the CALLPIPE stage command of the calling pipeline (through a shared file segment) or from its STDIN stream; when it is specified in a pipeline that is connected to the STDOUT stream of another WIN32 process.