Building a supporting user object

So far you have seen how your Pipeline object defines the details of the data and access for a pipeline, but a Pipeline object does not include the logistical supports—properties, events, and functions—that an application requires to handle pipeline execution and control.

About the Pipeline system object

To provide these logistical supports, you must build an appropriate user object inherited from the PowerBuilder Pipeline system object. Table 17-1 shows some of the system object’s properties, events, and functions that enable your application to manage a Pipeline object at runtime.

Table 17-1: Pipeline system object properties, events, and functions

Properties

Events

Functions

DataObject

RowsRead

RowsWritten

RowsInError

Syntax

PipeStart

PipeMeter

PipeEnd

Start

Repair

Cancel

A little later in this chapter you will learn how to use most of these properties, events, and functions in your application.

StepsTo build the supporting user object for a pipeline:

  1. Select Standard Class from the PB Object tab of the New dialog box.

    The Select Standard Class Type dialog box displays, prompting you to specify the name of the PowerBuilder system object (class) from which you want to inherit your new user object:

    The sample Select Standard Class Type dialog box displays the title Types : and a scrollable list  of PowerBuilder system objects. The pipeline system object is highlighted. On the right are three buttons, O K, Cancel, and Help.
  2. Select pipeline and click OK.

  3. Make any changes you want to the user object (although none are required). This might involve coding events, functions, or variables for use in your application.

    To learn about one particularly useful specialization you can make to your user object, see “Monitoring pipeline progress”.

  4. Save the user object.

For more information on working with the User Object painter, see the PowerBuilder Users Guide.