mirror of
https://github.com/ICDSystems/ICD.Common.Utils.git
synced 2026-01-11 19:44:55 +00:00
fix: Fix preprocessors for netstandard vs simplsharp
This commit is contained in:
@@ -40,7 +40,7 @@ namespace ICD.Common.Utils
|
||||
{
|
||||
if (s_IsConsoleApp == null)
|
||||
{
|
||||
#if SIMPLSHARP
|
||||
#if !NETSTANDARD
|
||||
s_IsConsoleApp = true;
|
||||
#else
|
||||
try
|
||||
@@ -110,11 +110,10 @@ namespace ICD.Common.Utils
|
||||
{
|
||||
PrintLine(message);
|
||||
}
|
||||
return;
|
||||
}
|
||||
#endif
|
||||
|
||||
#else
|
||||
PrintLine(message);
|
||||
#endif
|
||||
}
|
||||
|
||||
public static void PrintLine(string message)
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
#if SIMPLSHARP
|
||||
#if !NETSTANDARD
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using Crestron.SimplSharp;
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
#if !SIMPLSHARP
|
||||
#if NETSTANDARD
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
@@ -9,9 +9,7 @@ using ICD.Common.Utils.EventArguments;
|
||||
using ICD.Common.Utils.Timers;
|
||||
using AddressFamily = System.Net.Sockets.AddressFamily;
|
||||
using Dns = System.Net.Dns;
|
||||
#if !NETSTANDARD
|
||||
using Crestron.SimplSharp;
|
||||
#endif
|
||||
|
||||
|
||||
namespace ICD.Common.Utils
|
||||
{
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
#if SIMPLSHARP
|
||||
#if !NETSTANDARD
|
||||
using System.Globalization;
|
||||
using Crestron.SimplSharp;
|
||||
using ICD.Common.Utils.Services;
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
#if !SIMPLSHARP
|
||||
#if NETSTANDARD
|
||||
using System;
|
||||
using System.Diagnostics;
|
||||
using System.Linq;
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
using ICD.Common.Utils.IO;
|
||||
using ICD.Common.Utils.Services;
|
||||
using ICD.Common.Utils.Services.Logging;
|
||||
#if SIMPLSHARP
|
||||
#if !NETSTANDARD
|
||||
using Crestron.SimplSharp;
|
||||
using ICD.Common.Properties;
|
||||
using ICD.Common.Utils.Extensions;
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
#if !SIMPLSHARP
|
||||
#if NETSTANDARD
|
||||
using ICD.Common.Utils.IO;
|
||||
using System;
|
||||
using System.Reflection;
|
||||
|
||||
@@ -13,7 +13,7 @@ namespace ICD.Common.Utils
|
||||
/// </summary>
|
||||
public sealed class TableBuilder
|
||||
{
|
||||
#if SIMPLSHARP
|
||||
#if !NETSTANDARD
|
||||
private const char HORIZONTAL = '-';
|
||||
private const char VERTICAL = '|';
|
||||
private const char INTERSECT = '+';
|
||||
@@ -230,7 +230,7 @@ namespace ICD.Common.Utils
|
||||
|
||||
private void AppendTopSeparator(StringBuilder builder, IList<int> columnWidths)
|
||||
{
|
||||
#if SIMPLSHARP
|
||||
#if !NETSTANDARD
|
||||
// Can't do fancy tables so don't bother drawing the top row
|
||||
#else
|
||||
builder.Append(DOWN_RIGHT).Append(HORIZONTAL);
|
||||
@@ -256,7 +256,7 @@ namespace ICD.Common.Utils
|
||||
|
||||
private void AppendBottomSeparator(StringBuilder builder, IList<int> columnWidths)
|
||||
{
|
||||
#if SIMPLSHARP
|
||||
#if !NETSTANDARD
|
||||
AppendSeparator(builder, columnWidths);
|
||||
#else
|
||||
builder.Append(UP_RIGHT).Append(HORIZONTAL);
|
||||
@@ -282,7 +282,7 @@ namespace ICD.Common.Utils
|
||||
|
||||
private static void AppendRow(StringBuilder builder, IList<string> row, IList<int> columnWidths)
|
||||
{
|
||||
#if !SIMPLSHARP
|
||||
#if NETSTANDARD
|
||||
builder.Append(VERTICAL).Append(' ');
|
||||
#endif
|
||||
|
||||
@@ -298,7 +298,7 @@ namespace ICD.Common.Utils
|
||||
builder.Append(VERTICAL);
|
||||
}
|
||||
|
||||
#if !SIMPLSHARP
|
||||
#if NETSTANDARD
|
||||
builder.Append(VERTICAL);
|
||||
#endif
|
||||
|
||||
@@ -307,7 +307,7 @@ namespace ICD.Common.Utils
|
||||
|
||||
private static void AppendSeparator(StringBuilder builder, IList<int> columnWidths)
|
||||
{
|
||||
#if !SIMPLSHARP
|
||||
#if NETSTANDARD
|
||||
builder.Append(VERTICAL_RIGHT).Append(HORIZONTAL);
|
||||
#endif
|
||||
|
||||
@@ -324,7 +324,7 @@ namespace ICD.Common.Utils
|
||||
builder.Append(INTERSECT);
|
||||
}
|
||||
|
||||
#if !SIMPLSHARP
|
||||
#if NETSTANDARD
|
||||
builder.Append(VERTICAL_LEFT);
|
||||
#endif
|
||||
|
||||
|
||||
Reference in New Issue
Block a user