1 iw4madminapplication ApplicationManager
RaidMax edited this page 2023-05-20 22:09:21 -05:00

ApplicationManager Public class

Diagram

  flowchart LR
  classDef interfaceStyle stroke-dasharray: 5 5;
  classDef abstractStyle stroke-width:4px
  subgraph IW4MAdmin.Application
  IW4MAdmin.Application.ApplicationManager[[ApplicationManager]]
  end
  subgraph SharedLibraryCore.Interfaces
  SharedLibraryCore.Interfaces.IManager[[IManager]]
  class SharedLibraryCore.Interfaces.IManager interfaceStyle;
  end
SharedLibraryCore.Interfaces.IManager --> IW4MAdmin.Application.ApplicationManager

Members

Properties

Public properties

Type Name Methods
IList<IEventParser> AdditionalEventParsers get
IList<IRConParser> AdditionalRConParsers get
IAlertManager AlertManager get
CancellationToken CancellationToken get
IList<Func<GameEvent, bool>> CommandInterceptors get, set
IReadOnlyList<IManagerCommand> Commands get
string ExternalIPAddress get, private set
IInteractionRegistration InteractionRegistration get
bool IsInitialized get, private set
bool IsRestartRequested get, private set
bool IsRunning get, private set
ILogger Logger get
IMiddlewareActionHandler MiddlewareActionHandler get
IEnumerable<IPlugin> Plugins get
ConcurrentDictionary<long, GameEvent> ProcessingEvents get
List<Server> Servers get
DateTime StartTime get, private set
ITokenAuthentication TokenAuthenticator get
string Version get

Methods

Public methods

Returns Name
void AddAdditionalCommand(IManagerCommand command)
void AddEvent(GameEvent gameEvent)
Task ExecuteEvent(GameEvent newEvent)
Task<IList<T>> ExecuteSharedDatabaseOperation(string operationName)
EFClient FindActiveClient(EFClient client)
IEventParser GenerateDynamicEventParser(string name)
IRConParser GenerateDynamicRConParser(string name)
IList<EFClient> GetActiveClients()
IConfigurationHandler<ApplicationConfiguration> GetApplicationSettings()
ClientService GetClientService()
IList<IManagerCommand> GetCommands()
ILogger GetLogger(long serverId)
IList<MessageToken> GetMessageTokens()
IPageList GetPageList()
PenaltyService GetPenaltyService()
IList<Server> GetServers()
Task Init()
void QueueEvent(CoreEvent coreEvent)
void RegisterSharedDatabaseOperation(Task<IList> operation, string operationName)
void RemoveCommandByName(string commandName)
Task Restart()
Task Start()
Task Stop()

Details

Inheritance

Constructors

ApplicationManager

Source code

public ApplicationManager(ILogger<ApplicationManager> logger, IMiddlewareActionHandler actionHandler, IEnumerable<IManagerCommand> commands, ITranslationLookup translationLookup, IConfigurationHandler<CommandConfiguration> commandConfiguration, IConfigurationHandler<ApplicationConfiguration> appConfigHandler, IGameServerInstanceFactory serverInstanceFactory, IEnumerable<IPlugin> plugins, IParserRegexFactory parserRegexFactory, IEnumerable<IRegisterEvent> customParserEvents, ICoreEventHandler coreEventHandler, IScriptCommandFactory scriptCommandFactory, IDatabaseContextFactory contextFactory, IMetaRegistration metaRegistration, IScriptPluginServiceResolver scriptPluginServiceResolver, ClientService clientService, IServiceProvider serviceProvider, ChangeHistoryService changeHistoryService, ApplicationConfiguration appConfig, PenaltyService penaltyService, IAlertManager alertManager, IInteractionRegistration interactionRegistration, IEnumerable<IPluginV2> v2PLugins)
Arguments
Type Name Description
ILogger<ApplicationManager> logger
IMiddlewareActionHandler actionHandler
IEnumerable<IManagerCommand> commands
ITranslationLookup translationLookup
IConfigurationHandler<CommandConfiguration> commandConfiguration
IConfigurationHandler<ApplicationConfiguration> appConfigHandler
IGameServerInstanceFactory serverInstanceFactory
IEnumerable<IPlugin> plugins
IParserRegexFactory parserRegexFactory
IEnumerable<IRegisterEvent> customParserEvents
ICoreEventHandler coreEventHandler
IScriptCommandFactory scriptCommandFactory
IDatabaseContextFactory contextFactory
IMetaRegistration metaRegistration
IScriptPluginServiceResolver scriptPluginServiceResolver
ClientService clientService
IServiceProvider serviceProvider
ChangeHistoryService changeHistoryService
ApplicationConfiguration appConfig
PenaltyService penaltyService
IAlertManager alertManager
IInteractionRegistration interactionRegistration
IEnumerable<IPluginV2> v2PLugins

Methods

ExecuteEvent

Source code

public virtual async Task ExecuteEvent(GameEvent newEvent)
Arguments
Type Name Description
GameEvent newEvent

GetServers

Source code

public virtual IList<Server> GetServers()

GetCommands

Source code

public virtual IList<IManagerCommand> GetCommands()

Init

Source code

public virtual async Task Init()

Start

Source code

public virtual async Task Start()

Stop

Source code

public virtual async Task Stop()

Restart

Source code

public virtual async Task Restart()

GetLogger

Source code

public virtual ILogger GetLogger(long serverId)
Arguments
Type Name Description
long serverId

GetMessageTokens

Source code

public virtual IList<MessageToken> GetMessageTokens()

GetActiveClients

Source code

public virtual IList<EFClient> GetActiveClients()

FindActiveClient

Source code

public virtual EFClient FindActiveClient(EFClient client)
Arguments
Type Name Description
EFClient client

GetClientService

Source code

public virtual ClientService GetClientService()

GetPenaltyService

Source code

public virtual PenaltyService GetPenaltyService()

GetApplicationSettings

Source code

public virtual IConfigurationHandler<ApplicationConfiguration> GetApplicationSettings()

AddEvent

Source code

public virtual void AddEvent(GameEvent gameEvent)
Arguments
Type Name Description
GameEvent gameEvent

QueueEvent

Source code

public virtual void QueueEvent(CoreEvent coreEvent)
Arguments
Type Name Description
CoreEvent coreEvent

GetPageList

Source code

public virtual IPageList GetPageList()

GenerateDynamicRConParser

Source code

public virtual IRConParser GenerateDynamicRConParser(string name)
Arguments
Type Name Description
string name

GenerateDynamicEventParser

Source code

public virtual IEventParser GenerateDynamicEventParser(string name)
Arguments
Type Name Description
string name

ExecuteSharedDatabaseOperation

Source code

public virtual async Task<IList<T>> ExecuteSharedDatabaseOperation<T>(string operationName)
where T : 
Arguments
Type Name Description
string operationName

RegisterSharedDatabaseOperation

Source code

public virtual void RegisterSharedDatabaseOperation(Task<IList> operation, string operationName)
Arguments
Type Name Description
Task<IList> operation
string operationName

AddAdditionalCommand

Source code

public virtual void AddAdditionalCommand(IManagerCommand command)
Arguments
Type Name Description
IManagerCommand command

RemoveCommandByName

Source code

public virtual void RemoveCommandByName(string commandName)
Arguments
Type Name Description
string commandName

Properties

Servers

public List<Server> Servers { get; }

Logger

public ILogger Logger { get; }

IsRunning

public virtual bool IsRunning { get; private set; }

IsInitialized

public bool IsInitialized { get; private set; }

StartTime

public DateTime StartTime { get; private set; }

Version

public virtual string Version { get; }

AdditionalRConParsers

public virtual IList<IRConParser> AdditionalRConParsers { get; }

AdditionalEventParsers

public virtual IList<IEventParser> AdditionalEventParsers { get; }

CommandInterceptors

public IList<Func<GameEvent, bool>> CommandInterceptors { get; set; }

TokenAuthenticator

public virtual ITokenAuthentication TokenAuthenticator { get; }

CancellationToken

public virtual CancellationToken CancellationToken { get; }

ExternalIPAddress

public virtual string ExternalIPAddress { get; private set; }

IsRestartRequested

public virtual bool IsRestartRequested { get; private set; }

MiddlewareActionHandler

public virtual IMiddlewareActionHandler MiddlewareActionHandler { get; }

ProcessingEvents

public virtual ConcurrentDictionary<long, GameEvent> ProcessingEvents { get; }

Plugins

public virtual IEnumerable<IPlugin> Plugins { get; }

InteractionRegistration

public virtual IInteractionRegistration InteractionRegistration { get; }

Commands

public virtual IReadOnlyList<IManagerCommand> Commands { get; }

AlertManager

public virtual IAlertManager AlertManager { get; }

Events

OnGameEventExecuted

public event EventHandler<GameEvent> OnGameEventExecuted

Generated with ModularDoc