mirror of
https://github.com/PepperDash/Essentials.git
synced 2026-04-20 07:56:50 +00:00
feat: complete XML documentation in PD Core
This commit is contained in:
parent
4fa7a42330
commit
a7c4e2fd60
10 changed files with 5315 additions and 16 deletions
5243
buildFile.txt
Normal file
5243
buildFile.txt
Normal file
File diff suppressed because it is too large
Load diff
|
|
@ -24,14 +24,14 @@ namespace PepperDash.Core
|
|||
/// </summary>
|
||||
public bool Enabled { get; protected set; }
|
||||
|
||||
/// <summary>
|
||||
/// A place to store reference to the original config object, if any. These values should
|
||||
/// NOT be used as properties on the device as they are all publicly-settable values.
|
||||
/// </summary>
|
||||
// /// <summary>
|
||||
// /// A place to store reference to the original config object, if any. These values should
|
||||
// /// NOT be used as properties on the device as they are all publicly-settable values.
|
||||
// /// </summary>
|
||||
//public DeviceConfig Config { get; private set; }
|
||||
/// <summary>
|
||||
/// Helper method to check if Config exists
|
||||
/// </summary>
|
||||
// /// <summary>
|
||||
// /// Helper method to check if Config exists
|
||||
// /// </summary>
|
||||
//public bool HasConfig { get { return Config != null; } }
|
||||
|
||||
List<Action> _PreActivationActions;
|
||||
|
|
|
|||
|
|
@ -41,6 +41,9 @@ namespace PepperDash.Core
|
|||
CrestronConsole.PrintLine(message);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Constructor for DebugConsoleSink
|
||||
/// </summary>
|
||||
public DebugConsoleSink(ITextFormatter formatProvider )
|
||||
{
|
||||
_textFormatter = formatProvider ?? new JsonFormatter();
|
||||
|
|
@ -48,6 +51,9 @@ namespace PepperDash.Core
|
|||
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Provides extension methods for DebugConsoleSink
|
||||
/// </summary>
|
||||
public static class DebugConsoleSinkExtensions
|
||||
{
|
||||
/// <summary>
|
||||
|
|
|
|||
|
|
@ -27,6 +27,9 @@ namespace PepperDash.Core.Logging
|
|||
CrestronLogger.WriteToLog(message, (uint)logEvent.Level);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Constructor for DebugCrestronLoggerSink
|
||||
/// </summary>
|
||||
public DebugCrestronLoggerSink()
|
||||
{
|
||||
CrestronLogger.Initialize(1, LoggerModeEnum.RM);
|
||||
|
|
|
|||
|
|
@ -63,6 +63,9 @@ namespace PepperDash.Core.Logging
|
|||
handler(message);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Constructor for DebugErrorLogSink
|
||||
/// </summary>
|
||||
public DebugErrorLogSink(ITextFormatter formatter = null)
|
||||
{
|
||||
_formatter = formatter;
|
||||
|
|
|
|||
|
|
@ -4,6 +4,9 @@ using Log = PepperDash.Core.Debug;
|
|||
|
||||
namespace PepperDash.Core.Logging
|
||||
{
|
||||
/// <summary>
|
||||
/// Provides extension methods for logging on IKeyed objects
|
||||
/// </summary>
|
||||
public static class DebugExtensions
|
||||
{
|
||||
/// <summary>
|
||||
|
|
|
|||
|
|
@ -32,6 +32,9 @@ namespace PepperDash.Core
|
|||
private const string _certificateName = "selfCres";
|
||||
private const string _certificatePassword = "cres12345";
|
||||
|
||||
/// <summary>
|
||||
/// Gets the Port
|
||||
/// </summary>
|
||||
public int Port
|
||||
{ get
|
||||
{
|
||||
|
|
@ -41,6 +44,9 @@ namespace PepperDash.Core
|
|||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Gets the Url
|
||||
/// </summary>
|
||||
public string Url
|
||||
{
|
||||
get
|
||||
|
|
@ -58,6 +64,9 @@ namespace PepperDash.Core
|
|||
|
||||
private readonly ITextFormatter _textFormatter;
|
||||
|
||||
/// <summary>
|
||||
/// Constructor for DebugWebsocketSink
|
||||
/// </summary>
|
||||
public DebugWebsocketSink(ITextFormatter formatProvider)
|
||||
{
|
||||
|
||||
|
|
@ -217,6 +226,9 @@ namespace PepperDash.Core
|
|||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Provides extension methods for DebugWebsocketSink
|
||||
/// </summary>
|
||||
public static class DebugWebsocketSinkExtensions
|
||||
{
|
||||
/// <summary>
|
||||
|
|
@ -237,6 +249,9 @@ namespace PepperDash.Core
|
|||
{
|
||||
private DateTime _connectionTime;
|
||||
|
||||
/// <summary>
|
||||
/// Gets the ConnectedDuration
|
||||
/// </summary>
|
||||
public TimeSpan ConnectedDuration
|
||||
{
|
||||
get
|
||||
|
|
@ -252,11 +267,17 @@ namespace PepperDash.Core
|
|||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Constructor for DebugClient
|
||||
/// </summary>
|
||||
public DebugClient()
|
||||
{
|
||||
Debug.Console(0, "DebugClient Created");
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// OnOpen method
|
||||
/// </summary>
|
||||
protected override void OnOpen()
|
||||
{
|
||||
base.OnOpen();
|
||||
|
|
@ -267,6 +288,9 @@ namespace PepperDash.Core
|
|||
_connectionTime = DateTime.Now;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// OnMessage method
|
||||
/// </summary>
|
||||
protected override void OnMessage(MessageEventArgs e)
|
||||
{
|
||||
base.OnMessage(e);
|
||||
|
|
@ -274,6 +298,9 @@ namespace PepperDash.Core
|
|||
Debug.Console(0, "WebSocket UiClient Message: {0}", e.Data);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// OnClose method
|
||||
/// </summary>
|
||||
protected override void OnClose(CloseEventArgs e)
|
||||
{
|
||||
base.OnClose(e);
|
||||
|
|
@ -282,6 +309,9 @@ namespace PepperDash.Core
|
|||
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// OnError method
|
||||
/// </summary>
|
||||
protected override void OnError(WebSocketSharp.ErrorEventArgs e)
|
||||
{
|
||||
base.OnError(e);
|
||||
|
|
|
|||
|
|
@ -5,9 +5,16 @@ using System.Threading.Tasks;
|
|||
|
||||
namespace PepperDash.Core.Web.RequestHandlers
|
||||
{
|
||||
/// <summary>
|
||||
/// CWS Base Async Handler, implements IHttpCwsHandler
|
||||
/// </summary>
|
||||
public abstract class WebApiBaseRequestAsyncHandler:IHttpCwsHandler
|
||||
{
|
||||
private readonly Dictionary<string, Func<HttpCwsContext, Task>> _handlers;
|
||||
|
||||
/// <summary>
|
||||
/// Indicates whether CORS is enabled
|
||||
/// </summary>
|
||||
protected readonly bool EnableCors;
|
||||
|
||||
/// <summary>
|
||||
|
|
|
|||
|
|
@ -10,6 +10,10 @@ namespace PepperDash.Core.Web.RequestHandlers
|
|||
public abstract class WebApiBaseRequestHandler : IHttpCwsHandler
|
||||
{
|
||||
private readonly Dictionary<string, Action<HttpCwsContext>> _handlers;
|
||||
|
||||
/// <summary>
|
||||
/// Indicates whether CORS is enabled
|
||||
/// </summary>
|
||||
protected readonly bool EnableCors;
|
||||
|
||||
/// <summary>
|
||||
|
|
|
|||
|
|
@ -45,9 +45,9 @@ namespace PepperDash.Core.Web
|
|||
/// </summary>
|
||||
public bool IsRegistered { get; private set; }
|
||||
|
||||
/// <summary>
|
||||
/// Http request handler
|
||||
/// </summary>
|
||||
// /// <summary>
|
||||
// /// Http request handler
|
||||
// /// </summary>
|
||||
//public IHttpCwsHandler HttpRequestHandler
|
||||
//{
|
||||
// get { return _server.HttpRequestHandler; }
|
||||
|
|
@ -58,9 +58,9 @@ namespace PepperDash.Core.Web
|
|||
// }
|
||||
//}
|
||||
|
||||
/// <summary>
|
||||
/// Received request event handler
|
||||
/// </summary>
|
||||
// /// <summary>
|
||||
// /// Received request event handler
|
||||
// /// </summary>
|
||||
//public event EventHandler<HttpCwsRequestEventArgs> ReceivedRequestEvent
|
||||
//{
|
||||
// add { _server.ReceivedRequestEvent += new HttpCwsRequestEventHandler(value); }
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue