28.11.2012 Views

IBM Tivoli NetView for z/OS Programming: Pipes - IBM notice

IBM Tivoli NetView for z/OS Programming: Pipes - IBM notice

IBM Tivoli NetView for z/OS Programming: Pipes - IBM notice

SHOW MORE
SHOW LESS

Create successful ePaper yourself

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

Device drivers are stages that interact with devices or other system resources. They<br />

are used to get data into or out of the pipeline.<br />

Filters work on data already in the pipeline.<br />

Device Drivers<br />

When we speak of device drivers, we define a device loosely as a disk file, a<br />

terminal, a command procedure variable, or the system environment. Although not<br />

all of these are true devices, they all are entities with which a device driver<br />

interacts to read or write data.<br />

Filters<br />

Device drivers do not act on data; they merely transport it. In general, device<br />

drivers write their input stream to their output stream.<br />

The simplest pipeline consists of two device drivers. Data read from one device<br />

moves through the pipeline to the other device, as shown in Figure 11.<br />

File<br />

containing<br />

test data<br />

This PIPE command per<strong>for</strong>ms the functions shown in Figure 11.<br />

PIPE < TESTDATA | CONSOLE<br />

< TESTDATA CONSOLE<br />

Figure 11. Map of a Pipeline with Two Device Drivers<br />

Introduction and Concepts<br />

The < (From Disk) stage reads data from DASD into the pipeline where each<br />

record becomes a message, receiving the attributes of a message. Then the < (From<br />

Disk) stage writes each message to its output stream. In Figure 11, the output of<br />

the < stage is the input of the CONSOLE stage. The CONSOLE stage reads the<br />

messages from its input stream, displays them on the screen and copies them to its<br />

output stream, if one exists.<br />

Device drivers get data into and out of a pipeline; filters, also known as selection<br />

stages, work on data (that is, messages) already in the pipeline. There<strong>for</strong>e, a filter<br />

must be used with at least two device drivers: one to provide the input stream to<br />

the filter and one to receive the output stream from the filter.<br />

Chapter 1. <strong>NetView</strong> Pipelines Introduction and General Concepts 11

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

Saved successfully!

Ooh no, something went wrong!