Module Class
A common base class for modules.
graph BT Type-->Base0["object"] Type-.->Interface0["IModule"] click Interface0 "/api/Statiq.Common/IModule" Type["Module"] class Type type-node Derived0["CompileLess"]-->Type click Derived0 "/api/Statiq.Less/CompileLess" Derived1["SyncModule"]-->Type click Derived1 "/api/Statiq.Common/SyncModule" Derived2["RenderRazor"]-->Type click Derived2 "/api/Statiq.Razor/RenderRazor" Derived3["ReadXmp"]-->Type click Derived3 "/api/Statiq.Xmp/ReadXmp" Derived4["ExecuteIf"]-->Type click Derived4 "/api/Statiq.Core/ExecuteIf" Derived5["ExecutionPipeline"]-->Type click Derived5 "/api/Statiq.Core/ExecutionPipeline" Derived6["FilterDocuments"]-->Type click Derived6 "/api/Statiq.Core/FilterDocuments" Derived7["CombineDocuments"]-->Type click Derived7 "/api/Statiq.Core/CombineDocuments" Derived8["CountModule"]-->Type click Derived8 "/api/Statiq.Testing/CountModule" Derived9["ConfigModule<TValue>"]-->Type click Derived9 "/api/Statiq.Common/ConfigModule_1" Derived10["ParallelSyncModule"]-->Type click Derived10 "/api/Statiq.Common/ParallelSyncModule" Derived11["ExecuteSwitch"]-->Type click Derived11 "/api/Statiq.Core/ExecuteSwitch" Derived12["MirrorResources"]-->Type click Derived12 "/api/Statiq.Core/MirrorResources" Derived13["ResolveXrefs"]-->Type click Derived13 "/api/Statiq.Web.Modules/ResolveXrefs" Derived14["ParentModule"]-->Type click Derived14 "/api/Statiq.Common/ParentModule" Derived15["MultiConfigModuleBase"]-->Type click Derived15 "/api/Statiq.Common/MultiConfigModuleBase" Derived16["WriteFiles"]-->Type click Derived16 "/api/Statiq.Core/WriteFiles" Derived17["OrderDocuments"]-->Type click Derived17 "/api/Statiq.Core/OrderDocuments" Derived18["HighlightCode"]-->Type click Derived18 "/api/Statiq.Highlight/HighlightCode" Derived19["GenerateSitemap"]-->Type click Derived19 "/api/Statiq.Core/GenerateSitemap" Derived20["GenerateFeeds"]-->Type click Derived20 "/api/Statiq.Feeds/GenerateFeeds" Derived21["AddIndexes"]-->Type click Derived21 "/api/Statiq.Core/AddIndexes" Derived22["ParallelModule"]-->Type click Derived22 "/api/Statiq.Common/ParallelModule" Derived23["JoinDocuments"]-->Type click Derived23 "/api/Statiq.Core/JoinDocuments" Derived24["GroupDocuments"]-->Type click Derived24 "/api/Statiq.Core/GroupDocuments" Derived25["ParallelConfigModule<TValue>"]-->Type click Derived25 "/api/Statiq.Common/ParallelConfigModule_1" Derived26["ClearDocuments"]-->Type click Derived26 "/api/Statiq.Core/ClearDocuments" Derived27["ExecuteBranch"]-->Type click Derived27 "/api/Statiq.Core/ExecuteBranch" Derived28["ReadWeb"]-->Type click Derived28 "/api/Statiq.Core/ReadWeb" Derived29["ValidateMetadata<T>"]-->Type click Derived29 "/api/Statiq.Core/ValidateMetadata_1" Derived30["GenerateRedirects"]-->Type click Derived30 "/api/Statiq.Core/GenerateRedirects" Derived31["GenerateLunrIndex"]-->Type click Derived31 "/api/Statiq.Lunr/GenerateLunrIndex" Derived32["AnalyzeCSharp"]-->Type click Derived32 "/api/Statiq.CodeAnalysis/AnalyzeCSharp" Derived33["GenerateCloudSearchData"]-->Type click Derived33 "/api/Statiq.Web.Aws/GenerateCloudSearchData" Derived34["CreateTree"]-->Type click Derived34 "/api/Statiq.Core/CreateTree"

Syntax

public abstract class Module : IModule

Remarks

Documents can either be processed one at a time by overriding ExecuteInputAsync(IDocument, IExecutionContext) or all at once by overriding ExecuteContextAsync(IExecutionContext).

Methods

Name Return Value Summary
AfterExecution(IExecutionContext, ExecutionOutputs) void
Called after each module execution.
AfterExecutionAsync(IExecutionContext, ExecutionOutputs) Task
Called after each module execution.
BeforeExecution(IExecutionContext) void
Called before each module execution.
BeforeExecutionAsync(IExecutionContext) Task
Called before each module execution.
ExecuteAsync(IExecutionContext) Task<IEnumerable<IDocument>>
This should not be called directly, instead call IExecutionContext.Execute() if you need to execute a module from within another module.
ExecuteContextAsync(IExecutionContext) Task<IEnumerable<IDocument>>
Executes the module once for all input documents.
ExecuteInputAsync(IDocument, IExecutionContext) Task<IEnumerable<IDocument>>
Executes the module.
Finally(IExecutionContext) void
Called after each module execution, even if an exception is thrown during execution.
FinallyAsync(IExecutionContext) Task
Called after each module execution, even if an exception is thrown during execution.

Extension Methods