Class BaseRequestHandler
Class that represents the base implementation for all request handlers in all protocols.
Implements
Inherited Members
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: Fibula.Mechanics.Handlers
Assembly: Fibula.Mechanics.dll
Syntax
public abstract class BaseRequestHandler : IHandler
Constructors
| Improve this Doc View SourceBaseRequestHandler(ILogger)
Initializes a new instance of the BaseRequestHandler class.
Declaration
protected BaseRequestHandler(ILogger logger)
Parameters
Type | Name | Description |
---|---|---|
Serilog.ILogger | logger | A reference to the logger in use. |
Properties
| Improve this Doc View SourceLogger
Gets the reference to the logger in use.
Declaration
protected ILogger Logger { get; }
Property Value
Type | Description |
---|---|
Serilog.ILogger |
Methods
| Improve this Doc View SourceHandleRequest(IIncomingPacket, IClient)
Handles the contents of a network message.
Declaration
public abstract IEnumerable<IOutboundPacket> HandleRequest(IIncomingPacket incomingPacket, IClient client)
Parameters
Type | Name | Description |
---|---|---|
IIncomingPacket | incomingPacket | The packet to handle. |
IClient | client | A reference to the client from where this request originated from, for context. |
Returns
Type | Description |
---|---|
System.Collections.Generic.IEnumerable<IOutboundPacket> | A collection of IOutboundPackets that compose that synchronous response, if any. |