mirror of
https://github.com/PepperDash/Essentials.git
synced 2026-02-15 20:54:55 +00:00
fix: use correct line endings for verbatim strings
This commit is contained in:
0
Crestron-Library-Usage-Analysis.md
Normal file
0
Crestron-Library-Usage-Analysis.md
Normal file
@@ -1,4 +1,8 @@
|
|||||||
using Crestron.SimplSharp;
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Reflection;
|
||||||
|
using System.Text.RegularExpressions;
|
||||||
|
using Crestron.SimplSharp;
|
||||||
using Crestron.SimplSharp.CrestronDataStore;
|
using Crestron.SimplSharp.CrestronDataStore;
|
||||||
using Crestron.SimplSharp.CrestronIO;
|
using Crestron.SimplSharp.CrestronIO;
|
||||||
using Crestron.SimplSharp.CrestronLogger;
|
using Crestron.SimplSharp.CrestronLogger;
|
||||||
@@ -11,10 +15,6 @@ using Serilog.Events;
|
|||||||
using Serilog.Formatting.Compact;
|
using Serilog.Formatting.Compact;
|
||||||
using Serilog.Formatting.Json;
|
using Serilog.Formatting.Json;
|
||||||
using Serilog.Templates;
|
using Serilog.Templates;
|
||||||
using System;
|
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Reflection;
|
|
||||||
using System.Text.RegularExpressions;
|
|
||||||
|
|
||||||
namespace PepperDash.Core;
|
namespace PepperDash.Core;
|
||||||
|
|
||||||
@@ -268,7 +268,8 @@ public static class Debug
|
|||||||
}
|
}
|
||||||
|
|
||||||
return (LogEventLevel)logLevel;
|
return (LogEventLevel)logLevel;
|
||||||
} catch (Exception ex)
|
}
|
||||||
|
catch (Exception ex)
|
||||||
{
|
{
|
||||||
CrestronConsole.PrintLine($"Exception retrieving log level for {levelStoreKey}: {ex.Message}");
|
CrestronConsole.PrintLine($"Exception retrieving log level for {levelStoreKey}: {ex.Message}");
|
||||||
return LogEventLevel.Information;
|
return LogEventLevel.Information;
|
||||||
@@ -328,13 +329,13 @@ public static class Debug
|
|||||||
if (levelString.Trim() == "?")
|
if (levelString.Trim() == "?")
|
||||||
{
|
{
|
||||||
CrestronConsole.ConsoleCommandResponse(
|
CrestronConsole.ConsoleCommandResponse(
|
||||||
$@"Used to set the minimum level of debug messages to be printed to the console:
|
"Used to set the minimum level of debug messages to be printed to the console:\r\n" +
|
||||||
{_logLevels[0]} = 0
|
$"{_logLevels[0]} = 0\r\n" +
|
||||||
{_logLevels[1]} = 1
|
$"{_logLevels[1]} = 1\r\n" +
|
||||||
{_logLevels[2]} = 2
|
$"{_logLevels[2]} = 2\r\n" +
|
||||||
{_logLevels[3]} = 3
|
$"{_logLevels[3]} = 3\r\n" +
|
||||||
{_logLevels[4]} = 4
|
$"{_logLevels[4]} = 4\r\n" +
|
||||||
{_logLevels[5]} = 5");
|
$"{_logLevels[5]} = 5");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -1,11 +1,11 @@
|
|||||||
using Crestron.SimplSharp;
|
using System;
|
||||||
using Crestron.SimplSharpPro;
|
|
||||||
using PepperDash.Core;
|
|
||||||
using Serilog.Events;
|
|
||||||
using System;
|
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using System.Linq;
|
using System.Linq;
|
||||||
using System.Text.RegularExpressions;
|
using System.Text.RegularExpressions;
|
||||||
|
using Crestron.SimplSharp;
|
||||||
|
using Crestron.SimplSharpPro;
|
||||||
|
using PepperDash.Core;
|
||||||
|
using Serilog.Events;
|
||||||
|
|
||||||
|
|
||||||
namespace PepperDash.Essentials.Core;
|
namespace PepperDash.Essentials.Core;
|
||||||
@@ -440,9 +440,9 @@ public static class DeviceManager
|
|||||||
if (String.IsNullOrEmpty(s) || s.Contains("?"))
|
if (String.IsNullOrEmpty(s) || s.Contains("?"))
|
||||||
{
|
{
|
||||||
CrestronConsole.ConsoleCommandResponse(
|
CrestronConsole.ConsoleCommandResponse(
|
||||||
@"SETDEVICESTREAMDEBUG [{deviceKey}] [OFF |TX | RX | BOTH] [timeOutInMinutes]
|
"SETDEVICESTREAMDEBUG [{deviceKey}] [OFF |TX | RX | BOTH] [timeOutInMinutes]\r\n" +
|
||||||
{deviceKey} [OFF | TX | RX | BOTH] - Device to set stream debugging on, and which setting to use
|
" {deviceKey} [OFF | TX | RX | BOTH] - Device to set stream debugging on, and which setting to use\r\n" +
|
||||||
timeOutInMinutes - Set timeout for stream debugging. Default is 30 minutes");
|
" timeOutInMinutes - Set timeout for stream debugging. Default is 30 minutes");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -1,16 +1,16 @@
|
|||||||
|
|
||||||
|
|
||||||
using Crestron.SimplSharp;
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.ComponentModel.DataAnnotations;
|
||||||
|
using System.IO;
|
||||||
|
using System.Linq;
|
||||||
using System.Reflection;
|
using System.Reflection;
|
||||||
|
using Crestron.SimplSharp;
|
||||||
using Newtonsoft.Json.Linq;
|
using Newtonsoft.Json.Linq;
|
||||||
using PepperDash.Core;
|
using PepperDash.Core;
|
||||||
using PepperDash.Essentials.Core.Config;
|
using PepperDash.Essentials.Core.Config;
|
||||||
using Serilog.Events;
|
using Serilog.Events;
|
||||||
using System;
|
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Linq;
|
|
||||||
using System.ComponentModel.DataAnnotations;
|
|
||||||
using System.IO;
|
|
||||||
|
|
||||||
namespace PepperDash.Essentials.Core;
|
namespace PepperDash.Essentials.Core;
|
||||||
|
|
||||||
@@ -286,9 +286,9 @@ public class DeviceFactory
|
|||||||
}
|
}
|
||||||
|
|
||||||
CrestronConsole.ConsoleCommandResponse(
|
CrestronConsole.ConsoleCommandResponse(
|
||||||
@"Type: '{0}'
|
"Type: '{0}'\r\n" +
|
||||||
Type: '{1}'
|
" Type: '{1}'\r\n" +
|
||||||
Description: {2}{3}", type.Key, Type, description, CrestronEnvironment.NewLine);
|
" Description: {2}{3}", type.Key, Type, description, CrestronEnvironment.NewLine);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -1,4 +1,10 @@
|
|||||||
using Crestron.SimplSharp;
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Reflection;
|
||||||
|
using System.Text.RegularExpressions;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
using Crestron.SimplSharp;
|
||||||
using Crestron.SimplSharp.CrestronIO;
|
using Crestron.SimplSharp.CrestronIO;
|
||||||
using Crestron.SimplSharp.Net.Http;
|
using Crestron.SimplSharp.Net.Http;
|
||||||
using Crestron.SimplSharp.WebScripting;
|
using Crestron.SimplSharp.WebScripting;
|
||||||
@@ -30,12 +36,6 @@ using PepperDash.Essentials.RoomBridges;
|
|||||||
using PepperDash.Essentials.Services;
|
using PepperDash.Essentials.Services;
|
||||||
using PepperDash.Essentials.WebApiHandlers;
|
using PepperDash.Essentials.WebApiHandlers;
|
||||||
using PepperDash.Essentials.WebSocketServer;
|
using PepperDash.Essentials.WebSocketServer;
|
||||||
using System;
|
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Linq;
|
|
||||||
using System.Reflection;
|
|
||||||
using System.Text.RegularExpressions;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
using WebSocketSharp;
|
using WebSocketSharp;
|
||||||
|
|
||||||
namespace PepperDash.Essentials;
|
namespace PepperDash.Essentials;
|
||||||
@@ -1569,15 +1569,14 @@ public class MobileControlSystemController : EssentialsDevice, IMobileControl
|
|||||||
if (Config.EnableApiServer)
|
if (Config.EnableApiServer)
|
||||||
{
|
{
|
||||||
CrestronConsole.ConsoleCommandResponse(
|
CrestronConsole.ConsoleCommandResponse(
|
||||||
@"Mobile Control Edge Server API Information:
|
"Mobile Control Edge Server API Information:\r\n\r\n" +
|
||||||
|
"\tServer address: {0}\r\n" +
|
||||||
Server address: {0}
|
"\tSystem Name: {1}\r\n" +
|
||||||
System Name: {1}
|
"\tSystem URL: {2}\r\n" +
|
||||||
System URL: {2}
|
"\tSystem UUID: {3}\r\n" +
|
||||||
System UUID: {3}
|
"\tSystem User code: {4}\r\n" +
|
||||||
System User code: {4}
|
"\tConnected?: {5}\r\n" +
|
||||||
Connected?: {5}
|
"\tSeconds Since Last Ack: {6}\r\n",
|
||||||
Seconds Since Last Ack: {6}",
|
|
||||||
url,
|
url,
|
||||||
name,
|
name,
|
||||||
ConfigReader.ConfigObject.SystemUrl,
|
ConfigReader.ConfigObject.SystemUrl,
|
||||||
@@ -1590,10 +1589,8 @@ public class MobileControlSystemController : EssentialsDevice, IMobileControl
|
|||||||
else
|
else
|
||||||
{
|
{
|
||||||
CrestronConsole.ConsoleCommandResponse(
|
CrestronConsole.ConsoleCommandResponse(
|
||||||
@"
|
"\r\nMobile Control Edge Server API Information:\r\n" +
|
||||||
Mobile Control Edge Server API Information:
|
" Not Enabled in Config.\r\n"
|
||||||
Not Enabled in Config.
|
|
||||||
"
|
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1604,21 +1601,17 @@ Mobile Control Edge Server API Information:
|
|||||||
)
|
)
|
||||||
{
|
{
|
||||||
CrestronConsole.ConsoleCommandResponse(
|
CrestronConsole.ConsoleCommandResponse(
|
||||||
@"
|
"\r\nMobile Control Direct Server Information:\r\n" +
|
||||||
Mobile Control Direct Server Information:
|
" User App URL: {0}\r\n" +
|
||||||
User App URL: {0}
|
" Server port: {1}\r\n",
|
||||||
Server port: {1}
|
|
||||||
",
|
|
||||||
string.Format("{0}[insert_client_token]", _directServer.UserAppUrlPrefix),
|
string.Format("{0}[insert_client_token]", _directServer.UserAppUrlPrefix),
|
||||||
_directServer.Port
|
_directServer.Port
|
||||||
);
|
);
|
||||||
|
|
||||||
CrestronConsole.ConsoleCommandResponse(
|
CrestronConsole.ConsoleCommandResponse(
|
||||||
@"
|
"\r\n UI Client Info:\r\n" +
|
||||||
UI Client Info:
|
" Tokens Defined: {0}\r\n" +
|
||||||
Tokens Defined: {0}
|
" Clients Connected: {1}\r\n",
|
||||||
Clients Connected: {1}
|
|
||||||
",
|
|
||||||
_directServer.UiClients.Count,
|
_directServer.UiClients.Count,
|
||||||
_directServer.ConnectedUiClientsCount
|
_directServer.ConnectedUiClientsCount
|
||||||
);
|
);
|
||||||
@@ -1636,15 +1629,13 @@ Mobile Control Direct Server Information:
|
|||||||
}
|
}
|
||||||
|
|
||||||
CrestronConsole.ConsoleCommandResponse(
|
CrestronConsole.ConsoleCommandResponse(
|
||||||
@"
|
"\r\nClient {0}:\r\n" +
|
||||||
Client {0}:
|
"Room Key: {1}\r\n" +
|
||||||
Room Key: {1}
|
"Touchpanel Key: {6}\r\n" +
|
||||||
Touchpanel Key: {6}
|
"Token: {2}\r\n" +
|
||||||
Token: {2}
|
"Client URL: {3}\r\n" +
|
||||||
Client URL: {3}
|
"Connected: {4}\r\n" +
|
||||||
Connected: {4}
|
"Duration: {5}\r\n",
|
||||||
Duration: {5}
|
|
||||||
",
|
|
||||||
clientNo,
|
clientNo,
|
||||||
clientContext.Value.Token.RoomKey,
|
clientContext.Value.Token.RoomKey,
|
||||||
clientContext.Key,
|
clientContext.Key,
|
||||||
@@ -1659,9 +1650,8 @@ Duration: {5}
|
|||||||
else
|
else
|
||||||
{
|
{
|
||||||
CrestronConsole.ConsoleCommandResponse(
|
CrestronConsole.ConsoleCommandResponse(
|
||||||
@"
|
"\r\nMobile Control Direct Server Information:\r\n" +
|
||||||
Mobile Control Direct Server Infromation:
|
" Not Enabled in Config.\r\n"
|
||||||
Not Enabled in Config."
|
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user