From 39e15460fb17ae41e72843a5bf8b66c446be7ded Mon Sep 17 00:00:00 2001 From: Benedikt Schenkel Date: Wed, 29 Nov 2023 10:11:12 +0100 Subject: [PATCH] resolve comment --- src/FieldElementSubsystems.Test/Point/PointTest.cs | 2 +- .../Baseline4R1/PointToInterlockingConnection.cs | 6 ++++-- src/Point/Connections/PointStateBaseline4R1.cs | 6 ++++-- .../Interfaces}/IPointToInterlockingConnection.cs | 7 ++----- src/Point/Point.cs | 11 +++++------ .../ReportedPointPositionProtoConversion.cs | 4 +--- src/Point/Startup.cs | 2 +- 7 files changed, 18 insertions(+), 20 deletions(-) rename src/{Messages/IPointToInterlockingConnection => Point/Interfaces}/IPointToInterlockingConnection.cs (79%) diff --git a/src/FieldElementSubsystems.Test/Point/PointTest.cs b/src/FieldElementSubsystems.Test/Point/PointTest.cs index 9d6565e..bd75540 100644 --- a/src/FieldElementSubsystems.Test/Point/PointTest.cs +++ b/src/FieldElementSubsystems.Test/Point/PointTest.cs @@ -1,4 +1,4 @@ -using EulynxLive.Messages.IPointToInterlockingConnection; +using IPointToInterlockingConnection = EulynxLive.Point.Interfaces.IPointToInterlockingConnection; using Microsoft.Extensions.Configuration; using Microsoft.Extensions.Logging; using Moq; diff --git a/src/Point/Connections/Baseline4R1/PointToInterlockingConnection.cs b/src/Point/Connections/Baseline4R1/PointToInterlockingConnection.cs index 074ae59..5d11b0e 100644 --- a/src/Point/Connections/Baseline4R1/PointToInterlockingConnection.cs +++ b/src/Point/Connections/Baseline4R1/PointToInterlockingConnection.cs @@ -1,8 +1,10 @@ using EulynxLive.Messages.Baseline4R1; using Grpc.Core; -using static EulynxLive.Messages.IPointToInterlockingConnection.IPointToInterlockingConnection; +using IPointToInterlockingConnection = EulynxLive.Point.Interfaces.IPointToInterlockingConnection; +using PointState = EulynxLive.Point.Interfaces.IPointToInterlockingConnection.PointState; +using PointPosition = EulynxLive.Point.Interfaces.IPointToInterlockingConnection.PointPosition; using EulynxLive.Point.Interfaces; -using EulynxLive.Messages.IPointToInterlockingConnection; + namespace EulynxLive.Point.EulynxBaseline4R1; diff --git a/src/Point/Connections/PointStateBaseline4R1.cs b/src/Point/Connections/PointStateBaseline4R1.cs index 3599b9a..3a69877 100644 --- a/src/Point/Connections/PointStateBaseline4R1.cs +++ b/src/Point/Connections/PointStateBaseline4R1.cs @@ -1,7 +1,9 @@ using EulynxLive.Messages.Baseline4R1; -using EulynxLive.Messages.IPointToInterlockingConnection; -using static EulynxLive.Messages.IPointToInterlockingConnection.IPointToInterlockingConnection; +using IPointToInterlockingConnection = EulynxLive.Point.Interfaces.IPointToInterlockingConnection; +using PointState = EulynxLive.Point.Interfaces.IPointToInterlockingConnection.PointState; +using PointPosition = EulynxLive.Point.Interfaces.IPointToInterlockingConnection.PointPosition; +using DegradedPointPosition = EulynxLive.Point.Interfaces.IPointToInterlockingConnection.DegradedPointPosition; public record PointStateBaseline4R1 { diff --git a/src/Messages/IPointToInterlockingConnection/IPointToInterlockingConnection.cs b/src/Point/Interfaces/IPointToInterlockingConnection.cs similarity index 79% rename from src/Messages/IPointToInterlockingConnection/IPointToInterlockingConnection.cs rename to src/Point/Interfaces/IPointToInterlockingConnection.cs index 9822cbf..3329e74 100644 --- a/src/Messages/IPointToInterlockingConnection/IPointToInterlockingConnection.cs +++ b/src/Point/Interfaces/IPointToInterlockingConnection.cs @@ -1,9 +1,6 @@ -using System.Threading; -using System.Threading.Tasks; +namespace EulynxLive.Point.Interfaces; -namespace EulynxLive.Messages.IPointToInterlockingConnection; - -public interface IPointToInterlockingConnection: System.IDisposable { +public interface IPointToInterlockingConnection: IDisposable { Task SendPointPosition(PointState state); Task SendTimeoutMessage(); void Connect(); diff --git a/src/Point/Point.cs b/src/Point/Point.cs index c10b993..acd229b 100644 --- a/src/Point/Point.cs +++ b/src/Point/Point.cs @@ -1,10 +1,9 @@ -using DegradedPointPosition = EulynxLive.Messages.IPointToInterlockingConnection.IPointToInterlockingConnection.DegradedPointPosition; -using EulynxLive.Messages.IPointToInterlockingConnection; -using EulynxLive.Point.Proto; +using EulynxLive.Point.Proto; using Grpc.Core; -using PointPosition = EulynxLive.Messages.IPointToInterlockingConnection.IPointToInterlockingConnection.PointPosition; -using PointState = EulynxLive.Messages.IPointToInterlockingConnection.IPointToInterlockingConnection.PointState; -using Sci; +using IPointToInterlockingConnection = EulynxLive.Point.Interfaces.IPointToInterlockingConnection; +using PointPosition = EulynxLive.Point.Interfaces.IPointToInterlockingConnection.PointPosition; +using PointState = EulynxLive.Point.Interfaces.IPointToInterlockingConnection.PointState; +using DegradedPointPosition = EulynxLive.Point.Interfaces.IPointToInterlockingConnection.DegradedPointPosition; using System.Net.WebSockets; using System.Text; using System.Text.Json; diff --git a/src/Point/Services/Extensions/ReportedPointPositionProtoConversion.cs b/src/Point/Services/Extensions/ReportedPointPositionProtoConversion.cs index fef9b23..2ae254d 100644 --- a/src/Point/Services/Extensions/ReportedPointPositionProtoConversion.cs +++ b/src/Point/Services/Extensions/ReportedPointPositionProtoConversion.cs @@ -1,8 +1,6 @@ -using System; using EulynxLive.Point.Proto; -using ReportedPointPosition = EulynxLive.Messages.IPointToInterlockingConnection.IPointToInterlockingConnection.PointPosition ; -using DegradedPointPosition = EulynxLive.Messages.IPointToInterlockingConnection.IPointToInterlockingConnection.DegradedPointPosition; +using ReportedPointPosition = EulynxLive.Point.Interfaces.IPointToInterlockingConnection.PointPosition ; namespace Point.Services.Extensions { diff --git a/src/Point/Startup.cs b/src/Point/Startup.cs index 4e67cf7..d37e9dc 100644 --- a/src/Point/Startup.cs +++ b/src/Point/Startup.cs @@ -1,6 +1,6 @@ using Microsoft.AspNetCore.SpaServices.ReactDevelopmentServer; using EulynxLive.Point.Services; -using EulynxLive.Messages.IPointToInterlockingConnection; +using IPointToInterlockingConnection =EulynxLive.Point.Interfaces.IPointToInterlockingConnection; using EulynxLive.Point.EulynxBaseline4R1; namespace EulynxLive.Point