- Namespace
- Statiq
.Core - Interfaces
- Base Types
-
- object
- Module
- ParallelConfigModule
<object>
Syntax
public class ExecuteConfig : ParallelConfigModule<object>, IModule, IParallelModule
Remarks
This module is very useful for customizing pipeline execution without having to write an entire module. Returning modules from the config value is also useful for customizing existing modules based on the current set of documents.
If the value is null
this module will output the original input document(s).
If the value is a IDocument
, IEnumerable<T>
, or
IAsyncEnumerable<T>
, the document(s) will be the output(s) of this module.
If the value is a IEnumerable<T>
or IModule
,
the module(s) will be executed with the input document(s) as their input
and the results will be the output(s) of this module.
If the value is an IContentProvider
,
IContentProviderFactory
, or Stream
it will be used to get new content for the
provided document (or create a new document if the provided document is null
).
If config value is anything else, the content of the input document will be
changed to (or a new document created with) the string value.
If the provided config value does not require a document (for example, it's created with the
FromSetting(string, object)
factory method) then it will be invoked once for all input documents.
If the provided config value does require a document (for example, it's created with the
FromDocument(string, object)
factory method) then if will be invoked once for each input document.
Constructors
Name | Summary |
---|---|
ExecuteConfig |
Methods
Name | Return Value | Summary |
---|---|---|
AfterExecution |
void |
Called after each module execution.
Inherited from Module
|
AfterExecutionAsync |
Task |
Called after each module execution.
Inherited from Module
|
BeforeExecution |
void |
Called before each module execution.
Inherited from Module
|
BeforeExecutionAsync |
Task |
Called before each module execution.
Inherited from Module
|
ExecuteAsync |
Task |
This should not be called directly, instead call
IExecutionContext.Execute() if you need to execute a module from within another module.
Inherited from Module
|
ExecuteConfigAsync |
Task |
|
Finally |
void |
Called after each module execution, even if an exception is thrown during execution.
Inherited from Module
|
FinallyAsync |
Task |
Called after each module execution, even if an exception is thrown during execution.
Inherited from Module
|