IN stage v1.3

Pipelines v2.1

 

Purpose, Operands, Streams, Usage, Examples, Related

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

 

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

 

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

 

1.

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

 

environ.rex

 

   **** Top of file ****
 1 Address Rxpipe
 2
 3 'pipe in',
 4      '| split at str /;/',
 5      '| specs ws /=/ w-1 1',
 6      '| cons'
 7
 8 Exit 0
   **** End of file ****
 
C:\>path | environ.rex
 
output:
C:\WINDOWS\system32
C:\WINDOWS
C:\WINDOWS\System32\Wbem
C:\Program files\TenFiftyTwo\Pipelines

 

2.

Max length

3.

Parse CSV

4.

EBCDIC to ASCII

 

Related

 
CALLPIPE, CONSOLE, OUT, RUNPIPE
 

History

 

Version

 

Date

Action

Description

Pipelines

1.3

26.12.2021

changed

Application-wide rewrite.

2.1

1.2

04.02.2012

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.

2.0

1.1

22.04.2008

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.5

1.0

06.09.2007

created

First version.

1.0