Table of Contents

Interface IServiceManager

Namespace
Anvil.Services
Assembly
NWN.Anvil.dll

The interface that manages all core, anvil and plugin services.

public interface IServiceManager
Extension Methods

Properties

AnvilServiceContainer

The container holding services for anvil and anvil plugins.

CoreServiceContainer

The container holding internal core services. (logging, function hooking, etc).

Methods

CreatePluginContainer(Plugin)

Invoked by the plugin manager when loading an isolated plugin. Creates a new isolated container for the plugin.

DisposePluginContainer(IServiceContainer, Plugin, bool)

Invoked by the plugin manager when unloading an isolated plugin. Disposes/shutdowns plugin services.

Init()

Called during NWNX initialization. Core services should be initialized here.

InjectProperties(object?)

Invoked by the injection service. Implementation for services injected into an object at runtime.

Load()

Called after module load. All other anvil/plugin services should be populated in the container here.

Shutdown()

Called after the server is shut down/destroyed. Core services should be unloaded here.

Start()

Called after all services have been loaded and just before the module is ready to play. Run any last routines on all services here.

Unload()

Called before the server is shutting down/reloading. Anvil/plugin services should be unloaded here.

Events

OnContainerCreate

Called when a service container is created.

OnContainerDispose

Called when a service container is about to be disposed.

OnContainerPostDispose

Called when a service container has been disposed.