PipelineExtensions.

WithProcessDocumentsOnce(IPipeline, bool) Method

Summary

Specifies that a given pipeline doesn't use data from other pipelines and prevents reprocessing of documents after the first pass.
Assembly
Wyam.Common.dll
Namespace
Wyam.Common.Execution
Containing Type
PipelineExtensions

Syntax

public static IPipeline WithProcessDocumentsOnce(this IPipeline pipeline, bool processDocumentsOnce = true)

Remarks

when set, the pipeline looks for the first occurrence of a given Wyam.Common.Documents.IDocument.Source and then caches all final result documents that have the same source. On subsequent executions, if a document with a previously seen Wyam.Common.Documents.IDocument.Source is found and it has the same content, that document is removed from the module output and therefore won't get passed to the next module. At the end of the pipeline, all the documents from the first pass that have the same source as the removed one are added back to the result set (so later pipelines can still access them in the documents collection if needed).

Parameters

Name Type Description
pipeline IPipeline The pipeline to set.
processDocumentsOnce bool true to process documents once, false for the default behavior.

Return Value

Type Description
IPipeline The specified pipeline.
GitHub