Class CommandHandlerDescriptorExtensions
Extensions for command handler descriptors.
Namespace: TehGM.Wolfringo.Commands.Initialization
Assembly: Wolfringo.Commands.dll
Syntax
public static class CommandHandlerDescriptorExtensions
Methods
| Improve this Doc View SourceIsPersistent(ICommandHandlerDescriptor)
Checks if the command handler is persistent.
Declaration
public static bool IsPersistent(this ICommandHandlerDescriptor descriptor)
Parameters
Type | Name | Description |
---|---|---|
ICommandHandlerDescriptor | descriptor | Command handler descriptor. |
Returns
Type | Description |
---|---|
Boolean | True if handler is persistent; otherwise false. |
Remarks
This value will only return true if handler's type has CommandsHandlerAttribute. If the attribute is not present (for example, when handler was force-initialized without command discovery), it'll always return false.
It's up to ICommandsHandlerProvider to respect this value. CommandsHandlerProvider included with Wolfringo will always respect it and cache handlers if this value is true.