Class P4::OutputHandler

Description

The P4::OutputHandler class provides access to streaming output from the server. After defining the output handler, call P4::SetHandler() with your implementation of P4::OutputHandler.

Because P4Perl does not provide a template or superclass, your output handler must implement all five of the following methods: OutputMessage(), OutputText(), OutputInfo(), OutputBinary(), and OutputStat(), even if the implementation consists of trivially returning 0 (report only: don’t handle output, don’t cancel operation).

These methods must return one of the following four values:

Value Meaning

0

Messages added to output (don’t handle, don’t cancel).

1

Output is handled by class (don’t add message to output).

2

Operation is marked for cancel, message is added to output.

3

Operation is marked for cancel, message not added to output.

Class Methods

None.

Instance Methods

$handler.OutputBinary() -> int

Process binary data.

$handler.OutputInfo() -> int

Process tabular data.

$handler.OutputMessage() -> int

Process informational or error messages.

$handler.OutputStat()-> int

Process tagged data.

$handler.OutputText() -> int

Process text data.