PostSharp SDK 2023.0 / / Class Reference / Post­Sharp.​Sdk.​Aspect­Infrastructure Namespace / Type­Initialization­Manager Class / Type­Initialization­Manager Methods / Type­Initialization­Manager.​Register­Client Method / Type­Initialization­Manager.​Register­Client Method (IType­Initialization­Client, Type­Initialization­Client­Scopes)

TypeInitializationManager.RegisterClient Method (ITypeInitializationClient, TypeInitializationClientScopes)

Registers a client with scope Module, and only as a module initializer. Any other scope is ignored.

Namespace:  PostSharp.Sdk.AspectInfrastructure
Assembly:  PostSharp.Compiler.Engine (in PostSharp.Compiler.Engine.dll) Version: 2023.0.3.0 (2023.0.3.0)
Syntax
C#
public void RegisterClient(
	ITypeInitializationClient client,
	TypeInitializationClientScopes scopes
)

Parameters

client
Type: PostSharp.Sdk.AspectInfrastructure.ITypeInitializationClient
A module initializer-scoped client.
scopes
Type: PostSharp.Sdk.AspectInfrastructure.TypeInitializationClientScopes
Must contain Module or nothing will happen.
See Also