This site is work in progress and does not yet describe all available steps.

 p:sink (3.0) 

Discards all source documents.

Summary

<p:declare-step type="p:sink">
  <input port="source" primary="true" content-types="any" sequence="true"/>
</p:declare-step>

The p:sink step discards all documents that appear on its source port.

Ports:

Type

Port

Primary?

Content types

Seq?

Description

input

source

true

any

true

The document(s) to discard.

Description

The p:sink step eats all documents that appear on its source port and makes them disappear.

This step is a bit of a left-over from bygone days. In XProc 1.0, primary output ports had to be connected to something. So if you didn’t need the output of some step you had to discard its results by using p:sink. Starting XProc 3.0 this is no longer the case: primary output ports that are not connected discard their outputs automatically. The only reason to use p:sink nowadays is to make this more explicit.

Reference information

This description of the p:sink step is for XProc version: 3.0. This is a required step (an XProc 3.0 processor must support this).

The formal specification for the p:sink step can be found here.

The p:sink step is part of categories:

The p:sink step is also present in version: 3.1.