Click or drag to resize
Akka.NETActorSystemWithExtensionsWithExtensionT Method (ActorSystem, Type)
Retrieves the extension specified by a given type, T, from a given actor system. If the extension does not exist within the actor system, then the extension specified by extensionId is registered to the actor system.

Namespace:  Akka.Actor
Assembly:  Akka (in Akka.dll) Version: 1.2.3.42 (1.2.3.42)
Syntax
public static T WithExtension<T>(
	this ActorSystem system,
	Type extensionId
)
where T : class, IExtension

Parameters

system
Type: Akka.ActorActorSystem
The actor system from which to retrieve the extension or to register with if it does not exist.
extensionId
Type: SystemType
The type of the extension to register if it does not exist in the given actor system.

Type Parameters

T
The type associated with the extension to retrieve.

Return Value

Type: T
The extension retrieved from the given actor system.

Usage Note

In Visual Basic and C#, you can call this method as an instance method on any object of type ActorSystem. When you use instance method syntax to call this method, omit the first parameter. For more information, see Extension Methods (Visual Basic) or Extension Methods (C# Programming Guide).
See Also