ModuleListExtensions.

Replace<TModuleList>(TModuleList, string, IModule, string) Method

Summary

Replaces a module with the specified name. The replacement module will have the same name as the module being replaced unless an alternate name is specified.
Assembly
Wyam.Common.dll
Namespace
Wyam.Common.Modules
Containing Type
ModuleListExtensions

Syntax

public static TModuleList Replace<TModuleList>(this TModuleList moduleList, string replaceName, IModule module, string name = null) 
    where TModuleList : IModuleList

Type Parameters

Name Description
TModuleList The type of the module list.

Parameters

Name Type Description
moduleList TModuleList The Wyam.Common.Modules.ModuleList.
replaceName string The name of the module to replace.
module IModule The replacement module.
name string The name of the replacement module.

Return Value

Type Description
TModuleList The current instance.
GitHub