ComponentUtilitiesCreateComponentContainer Method
This is used to return a composition container filled with the available build components (SHFB
plug-ins, presentation styles, BuildAssembler components, and syntax generators).
Namespace: Sandcastle.CoreAssembly: Sandcastle.Core (in Sandcastle.Core.dll) Version: 2024.12.21.0
public static CompositionContainer CreateComponentContainer(
IEnumerable<string> folders,
ComponentAssemblyResolver resolver,
CancellationToken cancellationToken
)
Public Shared Function CreateComponentContainer (
folders As IEnumerable(Of String),
resolver As ComponentAssemblyResolver,
cancellationToken As CancellationToken
) As CompositionContainer
public:
static CompositionContainer^ CreateComponentContainer(
IEnumerable<String^>^ folders,
ComponentAssemblyResolver^ resolver,
CancellationToken cancellationToken
)
static member CreateComponentContainer :
folders : IEnumerable<string> *
resolver : ComponentAssemblyResolver *
cancellationToken : CancellationToken -> CompositionContainer
- folders IEnumerableString
- An enumerable list of additional folders to search recursively for components.
- resolver ComponentAssemblyResolver
- A component assembly resolver to use or null to use a temporary one
- cancellationToken CancellationToken
- An optional cancellation token or null if not supported by the caller.
CompositionContainerThe a composition container that contains all of the available components
The following folders are searched in the following order. If the given folder has not been
specified or does not exist, it is ignored.
- The enumerable list of additional folders - This is typically the current project's
NuGet packages (package tool paths from the SHFBComponentPath item in their properties file),
the project's ComponentPath folder, and the current project's folder. This allows for
project-specific build components. Paths are searched in the order given above if specified.
- Common application data folder - The help file builder's common application data folder
where third-party build components are typically installed.
- SHFBROOT core components folder - The core Sandcastle Help File Builder components
folder and its subfolders. This allows for XCOPY deployments that keep everything together.
All folders and their subfolders are search recursively for assemblies (*.dll). There may be
duplicate component IDs across the assemblies found. Only the first component for a unique
ID will be used. As such, assemblies in a folder with a higher search precedence can override
copies in folders lower in the search order.