Rename shared namespace and preserve pipe handling
Rename `Shared` to `ClientServerShared` across client, server, calculator, interface, and serializer code. Update pipe-name parsing to use ordinal comparison while retaining the `PipeDemo` default. Preserve custom JSON serialization with public field support for `Vector3`.
This commit is contained in:
+1
-1
@@ -1,6 +1,6 @@
|
||||
using System.Diagnostics;
|
||||
using PipeMethodCalls;
|
||||
using Shared;
|
||||
using ClientServerShared;
|
||||
|
||||
Console.WriteLine("Client started.");
|
||||
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
using System.Numerics;
|
||||
using Shared;
|
||||
using ClientServerShared;
|
||||
|
||||
namespace Server;
|
||||
|
||||
|
||||
+2
-2
@@ -1,8 +1,8 @@
|
||||
using ClientServerShared;
|
||||
using PipeMethodCalls;
|
||||
using Server;
|
||||
using Shared;
|
||||
|
||||
string pipeName = args.FirstOrDefault(a => a.StartsWith(PipeConstants.PipeNameArgPrefix))?
|
||||
string pipeName = args.FirstOrDefault(static a => a.StartsWith(PipeConstants.PipeNameArgPrefix, StringComparison.Ordinal))?
|
||||
[PipeConstants.PipeNameArgPrefix.Length..] ?? "PipeDemo";
|
||||
|
||||
Console.WriteLine($"Server started. Pipe: {pipeName}");
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
using System.Numerics;
|
||||
|
||||
namespace Shared;
|
||||
namespace ClientServerShared;
|
||||
|
||||
public interface ICalculator
|
||||
{
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
using System.Text.Json;
|
||||
using PipeMethodCalls;
|
||||
using System.Text.Json;
|
||||
|
||||
namespace Shared;
|
||||
namespace ClientServerShared;
|
||||
|
||||
/// <summary>
|
||||
/// JSON serializer that also includes public fields (required for System.Numerics.Vector3).
|
||||
|
||||
Reference in New Issue
Block a user