diff --git a/dotnet/src/webdriver/BiDi/BiDi.cs b/dotnet/src/webdriver/BiDi/BiDi.cs index 448e0ea85bf48..5ec8e36215768 100644 --- a/dotnet/src/webdriver/BiDi/BiDi.cs +++ b/dotnet/src/webdriver/BiDi/BiDi.cs @@ -17,14 +17,13 @@ // under the License. // +using OpenQA.Selenium.BiDi.Json; +using OpenQA.Selenium.BiDi.Json.Converters; using System; using System.Text.Json; using System.Text.Json.Serialization; using System.Threading; using System.Threading.Tasks; -using OpenQA.Selenium.BiDi.Communication; -using OpenQA.Selenium.BiDi.Communication.Json; -using OpenQA.Selenium.BiDi.Communication.Json.Converters; namespace OpenQA.Selenium.BiDi; diff --git a/dotnet/src/webdriver/BiDi/Communication/Broker.cs b/dotnet/src/webdriver/BiDi/Broker.cs similarity index 97% rename from dotnet/src/webdriver/BiDi/Communication/Broker.cs rename to dotnet/src/webdriver/BiDi/Broker.cs index 64f82aa59499f..81726b76631be 100644 --- a/dotnet/src/webdriver/BiDi/Communication/Broker.cs +++ b/dotnet/src/webdriver/BiDi/Broker.cs @@ -17,7 +17,6 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication.Transport; using OpenQA.Selenium.Internal.Logging; using System; using System.Collections.Concurrent; @@ -28,7 +27,7 @@ using System.Threading; using System.Threading.Tasks; -namespace OpenQA.Selenium.BiDi.Communication; +namespace OpenQA.Selenium.BiDi; public sealed class Broker : IAsyncDisposable { @@ -214,13 +213,13 @@ public async Task SubscribeAsync(string eventName, Fun } } - public async Task UnsubscribeAsync(Session.Subscription subscription, EventHandler eventHandler) + public async Task UnsubscribeAsync(Subscription subscription) { - var eventHandlers = _eventHandlers[eventHandler.EventName]; + var eventHandlers = _eventHandlers[subscription.EventHandler.EventName]; - eventHandlers.Remove(eventHandler); + eventHandlers.Remove(subscription.EventHandler); - await _bidi.SessionModule.UnsubscribeAsync([subscription]).ConfigureAwait(false); + await _bidi.SessionModule.UnsubscribeAsync([subscription.SubscriptionId]).ConfigureAwait(false); } public async ValueTask DisposeAsync() diff --git a/dotnet/src/webdriver/BiDi/Browser/BrowserModule.cs b/dotnet/src/webdriver/BiDi/Browser/BrowserModule.cs index 61c5ce4008f05..188846430a4fc 100644 --- a/dotnet/src/webdriver/BiDi/Browser/BrowserModule.cs +++ b/dotnet/src/webdriver/BiDi/Browser/BrowserModule.cs @@ -17,7 +17,6 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication; using System.Threading.Tasks; namespace OpenQA.Selenium.BiDi.Browser; diff --git a/dotnet/src/webdriver/BiDi/Browser/ClientWindow.cs b/dotnet/src/webdriver/BiDi/Browser/ClientWindow.cs index d8203dac5962b..08926c0dc1836 100644 --- a/dotnet/src/webdriver/BiDi/Browser/ClientWindow.cs +++ b/dotnet/src/webdriver/BiDi/Browser/ClientWindow.cs @@ -17,7 +17,7 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication.Json.Converters; +using OpenQA.Selenium.BiDi.Json.Converters; using System.Text.Json.Serialization; namespace OpenQA.Selenium.BiDi.Browser; diff --git a/dotnet/src/webdriver/BiDi/Browser/ClientWindowInfo.cs b/dotnet/src/webdriver/BiDi/Browser/ClientWindowInfo.cs index d457830bf167d..6d41ce909529f 100644 --- a/dotnet/src/webdriver/BiDi/Browser/ClientWindowInfo.cs +++ b/dotnet/src/webdriver/BiDi/Browser/ClientWindowInfo.cs @@ -17,7 +17,7 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication.Json.Converters; +using OpenQA.Selenium.BiDi.Json.Converters; using System.Text.Json.Serialization; namespace OpenQA.Selenium.BiDi.Browser; diff --git a/dotnet/src/webdriver/BiDi/Browser/CloseCommand.cs b/dotnet/src/webdriver/BiDi/Browser/CloseCommand.cs index 10b2943d375e8..3131edae1d36b 100644 --- a/dotnet/src/webdriver/BiDi/Browser/CloseCommand.cs +++ b/dotnet/src/webdriver/BiDi/Browser/CloseCommand.cs @@ -17,8 +17,6 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication; - namespace OpenQA.Selenium.BiDi.Browser; internal sealed class CloseCommand() diff --git a/dotnet/src/webdriver/BiDi/Browser/CreateUserContextCommand.cs b/dotnet/src/webdriver/BiDi/Browser/CreateUserContextCommand.cs index f8ecd399063a1..b3331f6125b25 100644 --- a/dotnet/src/webdriver/BiDi/Browser/CreateUserContextCommand.cs +++ b/dotnet/src/webdriver/BiDi/Browser/CreateUserContextCommand.cs @@ -17,8 +17,6 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication; - namespace OpenQA.Selenium.BiDi.Browser; internal sealed class CreateUserContextCommand(CreateUserContextParameters @params) diff --git a/dotnet/src/webdriver/BiDi/Browser/GetClientWindowsCommand.cs b/dotnet/src/webdriver/BiDi/Browser/GetClientWindowsCommand.cs index 08618af735406..f4b417cb6e911 100644 --- a/dotnet/src/webdriver/BiDi/Browser/GetClientWindowsCommand.cs +++ b/dotnet/src/webdriver/BiDi/Browser/GetClientWindowsCommand.cs @@ -17,7 +17,6 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication; using System.Collections.Generic; namespace OpenQA.Selenium.BiDi.Browser; diff --git a/dotnet/src/webdriver/BiDi/Browser/GetUserContextsCommand.cs b/dotnet/src/webdriver/BiDi/Browser/GetUserContextsCommand.cs index 01c7749909acd..1f0b9257d0e3e 100644 --- a/dotnet/src/webdriver/BiDi/Browser/GetUserContextsCommand.cs +++ b/dotnet/src/webdriver/BiDi/Browser/GetUserContextsCommand.cs @@ -17,7 +17,6 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication; using System.Collections.Generic; namespace OpenQA.Selenium.BiDi.Browser; diff --git a/dotnet/src/webdriver/BiDi/Browser/RemoveUserContextCommand.cs b/dotnet/src/webdriver/BiDi/Browser/RemoveUserContextCommand.cs index 4e628ef5b4060..271fb331b078f 100644 --- a/dotnet/src/webdriver/BiDi/Browser/RemoveUserContextCommand.cs +++ b/dotnet/src/webdriver/BiDi/Browser/RemoveUserContextCommand.cs @@ -17,8 +17,6 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication; - namespace OpenQA.Selenium.BiDi.Browser; internal sealed class RemoveUserContextCommand(RemoveUserContextParameters @params) diff --git a/dotnet/src/webdriver/BiDi/Browser/SetDownloadBehaviorCommand.cs b/dotnet/src/webdriver/BiDi/Browser/SetDownloadBehaviorCommand.cs index 8ba02441392db..95504c8111f42 100644 --- a/dotnet/src/webdriver/BiDi/Browser/SetDownloadBehaviorCommand.cs +++ b/dotnet/src/webdriver/BiDi/Browser/SetDownloadBehaviorCommand.cs @@ -17,7 +17,6 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication; using System.Collections.Generic; using System.Text.Json.Serialization; diff --git a/dotnet/src/webdriver/BiDi/Browser/UserContextInfo.cs b/dotnet/src/webdriver/BiDi/Browser/UserContextInfo.cs index 724021671572a..d5db8aa4cceda 100644 --- a/dotnet/src/webdriver/BiDi/Browser/UserContextInfo.cs +++ b/dotnet/src/webdriver/BiDi/Browser/UserContextInfo.cs @@ -17,8 +17,6 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication; - namespace OpenQA.Selenium.BiDi.Browser; public record UserContextInfo(UserContext UserContext) : EmptyResult; diff --git a/dotnet/src/webdriver/BiDi/BrowsingContext/ActivateCommand.cs b/dotnet/src/webdriver/BiDi/BrowsingContext/ActivateCommand.cs index 33d3e9f491f9c..fb154a34081b6 100644 --- a/dotnet/src/webdriver/BiDi/BrowsingContext/ActivateCommand.cs +++ b/dotnet/src/webdriver/BiDi/BrowsingContext/ActivateCommand.cs @@ -17,8 +17,6 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication; - namespace OpenQA.Selenium.BiDi.BrowsingContext; internal sealed class ActivateCommand(ActivateParameters @params) diff --git a/dotnet/src/webdriver/BiDi/BrowsingContext/BrowsingContext.cs b/dotnet/src/webdriver/BiDi/BrowsingContext/BrowsingContext.cs index 56191fc082e33..46a703f9533db 100644 --- a/dotnet/src/webdriver/BiDi/BrowsingContext/BrowsingContext.cs +++ b/dotnet/src/webdriver/BiDi/BrowsingContext/BrowsingContext.cs @@ -17,9 +17,8 @@ // under the License. // -using System.Threading.Tasks; using System; -using OpenQA.Selenium.BiDi.Communication; +using System.Threading.Tasks; namespace OpenQA.Selenium.BiDi.BrowsingContext; diff --git a/dotnet/src/webdriver/BiDi/BrowsingContext/BrowsingContextModule.cs b/dotnet/src/webdriver/BiDi/BrowsingContext/BrowsingContextModule.cs index f50d23085da40..72f2d5d995d0d 100644 --- a/dotnet/src/webdriver/BiDi/BrowsingContext/BrowsingContextModule.cs +++ b/dotnet/src/webdriver/BiDi/BrowsingContext/BrowsingContextModule.cs @@ -19,7 +19,6 @@ using System; using System.Threading.Tasks; -using OpenQA.Selenium.BiDi.Communication; namespace OpenQA.Selenium.BiDi.BrowsingContext; diff --git a/dotnet/src/webdriver/BiDi/BrowsingContext/CaptureScreenshotCommand.cs b/dotnet/src/webdriver/BiDi/BrowsingContext/CaptureScreenshotCommand.cs index 28a2441890b7d..f522b98699441 100644 --- a/dotnet/src/webdriver/BiDi/BrowsingContext/CaptureScreenshotCommand.cs +++ b/dotnet/src/webdriver/BiDi/BrowsingContext/CaptureScreenshotCommand.cs @@ -17,8 +17,7 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication; -using OpenQA.Selenium.BiDi.Communication.Json.Converters; +using OpenQA.Selenium.BiDi.Json.Converters; using System; using System.Text.Json.Serialization; diff --git a/dotnet/src/webdriver/BiDi/BrowsingContext/CloseCommand.cs b/dotnet/src/webdriver/BiDi/BrowsingContext/CloseCommand.cs index c13ac11feb399..5ba94f16aef4a 100644 --- a/dotnet/src/webdriver/BiDi/BrowsingContext/CloseCommand.cs +++ b/dotnet/src/webdriver/BiDi/BrowsingContext/CloseCommand.cs @@ -17,8 +17,6 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication; - namespace OpenQA.Selenium.BiDi.BrowsingContext; internal sealed class CloseCommand(CloseParameters @params) diff --git a/dotnet/src/webdriver/BiDi/BrowsingContext/CreateCommand.cs b/dotnet/src/webdriver/BiDi/BrowsingContext/CreateCommand.cs index 67bd979171ce2..892e3cc3a3674 100644 --- a/dotnet/src/webdriver/BiDi/BrowsingContext/CreateCommand.cs +++ b/dotnet/src/webdriver/BiDi/BrowsingContext/CreateCommand.cs @@ -17,8 +17,7 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication; -using OpenQA.Selenium.BiDi.Communication.Json.Converters; +using OpenQA.Selenium.BiDi.Json.Converters; using System.Text.Json.Serialization; namespace OpenQA.Selenium.BiDi.BrowsingContext; diff --git a/dotnet/src/webdriver/BiDi/BrowsingContext/DownloadEndEventArgs.cs b/dotnet/src/webdriver/BiDi/BrowsingContext/DownloadEndEventArgs.cs index 1e3dda74f7808..38d51c22e8b54 100644 --- a/dotnet/src/webdriver/BiDi/BrowsingContext/DownloadEndEventArgs.cs +++ b/dotnet/src/webdriver/BiDi/BrowsingContext/DownloadEndEventArgs.cs @@ -17,7 +17,7 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication.Json.Converters.Polymorphic; +using OpenQA.Selenium.BiDi.Json.Converters.Polymorphic; using System; using System.Text.Json.Serialization; diff --git a/dotnet/src/webdriver/BiDi/BrowsingContext/GetTreeCommand.cs b/dotnet/src/webdriver/BiDi/BrowsingContext/GetTreeCommand.cs index c7ff247308e51..425cea68e0d5e 100644 --- a/dotnet/src/webdriver/BiDi/BrowsingContext/GetTreeCommand.cs +++ b/dotnet/src/webdriver/BiDi/BrowsingContext/GetTreeCommand.cs @@ -17,7 +17,6 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication; using System.Collections.Generic; namespace OpenQA.Selenium.BiDi.BrowsingContext; diff --git a/dotnet/src/webdriver/BiDi/BrowsingContext/HandleUserPromptCommand.cs b/dotnet/src/webdriver/BiDi/BrowsingContext/HandleUserPromptCommand.cs index d15f1c601b79a..9490d16e2a094 100644 --- a/dotnet/src/webdriver/BiDi/BrowsingContext/HandleUserPromptCommand.cs +++ b/dotnet/src/webdriver/BiDi/BrowsingContext/HandleUserPromptCommand.cs @@ -17,8 +17,6 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication; - namespace OpenQA.Selenium.BiDi.BrowsingContext; internal sealed class HandleUserPromptCommand(HandleUserPromptParameters @params) diff --git a/dotnet/src/webdriver/BiDi/BrowsingContext/LocateNodesCommand.cs b/dotnet/src/webdriver/BiDi/BrowsingContext/LocateNodesCommand.cs index 3d18d994b84eb..3718dedc4f344 100644 --- a/dotnet/src/webdriver/BiDi/BrowsingContext/LocateNodesCommand.cs +++ b/dotnet/src/webdriver/BiDi/BrowsingContext/LocateNodesCommand.cs @@ -17,7 +17,6 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication; using System.Collections.Generic; namespace OpenQA.Selenium.BiDi.BrowsingContext; diff --git a/dotnet/src/webdriver/BiDi/BrowsingContext/Locator.cs b/dotnet/src/webdriver/BiDi/BrowsingContext/Locator.cs index 2db99cb07f3f6..a37009dff3691 100644 --- a/dotnet/src/webdriver/BiDi/BrowsingContext/Locator.cs +++ b/dotnet/src/webdriver/BiDi/BrowsingContext/Locator.cs @@ -17,7 +17,7 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication.Json.Converters; +using OpenQA.Selenium.BiDi.Json.Converters; using System.Text.Json.Serialization; namespace OpenQA.Selenium.BiDi.BrowsingContext; diff --git a/dotnet/src/webdriver/BiDi/BrowsingContext/NavigateCommand.cs b/dotnet/src/webdriver/BiDi/BrowsingContext/NavigateCommand.cs index c8b53d40dbc10..3ed6f319acacb 100644 --- a/dotnet/src/webdriver/BiDi/BrowsingContext/NavigateCommand.cs +++ b/dotnet/src/webdriver/BiDi/BrowsingContext/NavigateCommand.cs @@ -17,8 +17,7 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication; -using OpenQA.Selenium.BiDi.Communication.Json.Converters; +using OpenQA.Selenium.BiDi.Json.Converters; using System.Text.Json.Serialization; namespace OpenQA.Selenium.BiDi.BrowsingContext; diff --git a/dotnet/src/webdriver/BiDi/BrowsingContext/Navigation.cs b/dotnet/src/webdriver/BiDi/BrowsingContext/Navigation.cs index 9acb3047f7c52..785a9eb2da00b 100644 --- a/dotnet/src/webdriver/BiDi/BrowsingContext/Navigation.cs +++ b/dotnet/src/webdriver/BiDi/BrowsingContext/Navigation.cs @@ -17,7 +17,7 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication.Json.Converters; +using OpenQA.Selenium.BiDi.Json.Converters; using System.Text.Json.Serialization; namespace OpenQA.Selenium.BiDi.BrowsingContext; diff --git a/dotnet/src/webdriver/BiDi/BrowsingContext/PrintCommand.cs b/dotnet/src/webdriver/BiDi/BrowsingContext/PrintCommand.cs index 85cad725ca42a..dc821b30cb461 100644 --- a/dotnet/src/webdriver/BiDi/BrowsingContext/PrintCommand.cs +++ b/dotnet/src/webdriver/BiDi/BrowsingContext/PrintCommand.cs @@ -17,8 +17,7 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication; -using OpenQA.Selenium.BiDi.Communication.Json.Converters; +using OpenQA.Selenium.BiDi.Json.Converters; using System; using System.Collections.Generic; using System.Text.Json.Serialization; diff --git a/dotnet/src/webdriver/BiDi/BrowsingContext/ReloadCommand.cs b/dotnet/src/webdriver/BiDi/BrowsingContext/ReloadCommand.cs index ba1e8c7d30215..11ee0f502974c 100644 --- a/dotnet/src/webdriver/BiDi/BrowsingContext/ReloadCommand.cs +++ b/dotnet/src/webdriver/BiDi/BrowsingContext/ReloadCommand.cs @@ -17,8 +17,6 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication; - namespace OpenQA.Selenium.BiDi.BrowsingContext; internal sealed class ReloadCommand(ReloadParameters @params) diff --git a/dotnet/src/webdriver/BiDi/BrowsingContext/SetViewportCommand.cs b/dotnet/src/webdriver/BiDi/BrowsingContext/SetViewportCommand.cs index 781f68d3765cf..90c493a0de6d5 100644 --- a/dotnet/src/webdriver/BiDi/BrowsingContext/SetViewportCommand.cs +++ b/dotnet/src/webdriver/BiDi/BrowsingContext/SetViewportCommand.cs @@ -17,8 +17,6 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication; - namespace OpenQA.Selenium.BiDi.BrowsingContext; internal sealed class SetViewportCommand(SetViewportParameters @params) diff --git a/dotnet/src/webdriver/BiDi/BrowsingContext/TraverseHistoryCommand.cs b/dotnet/src/webdriver/BiDi/BrowsingContext/TraverseHistoryCommand.cs index 2e45c90489d7f..f881452387f75 100644 --- a/dotnet/src/webdriver/BiDi/BrowsingContext/TraverseHistoryCommand.cs +++ b/dotnet/src/webdriver/BiDi/BrowsingContext/TraverseHistoryCommand.cs @@ -17,8 +17,6 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication; - namespace OpenQA.Selenium.BiDi.BrowsingContext; internal sealed class TraverseHistoryCommand(TraverseHistoryParameters @params) diff --git a/dotnet/src/webdriver/BiDi/BrowsingContext/UserPromptOpenedEventArgs.cs b/dotnet/src/webdriver/BiDi/BrowsingContext/UserPromptOpenedEventArgs.cs index d2cd1020e54d0..2360cc26c9a8b 100644 --- a/dotnet/src/webdriver/BiDi/BrowsingContext/UserPromptOpenedEventArgs.cs +++ b/dotnet/src/webdriver/BiDi/BrowsingContext/UserPromptOpenedEventArgs.cs @@ -17,7 +17,7 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication.Json.Converters; +using OpenQA.Selenium.BiDi.Json.Converters; using System.Text.Json.Serialization; namespace OpenQA.Selenium.BiDi.BrowsingContext; diff --git a/dotnet/src/webdriver/BiDi/Communication/Command.cs b/dotnet/src/webdriver/BiDi/Command.cs similarity index 96% rename from dotnet/src/webdriver/BiDi/Communication/Command.cs rename to dotnet/src/webdriver/BiDi/Command.cs index 5c15c6e7a7400..43ffb9212a4d5 100644 --- a/dotnet/src/webdriver/BiDi/Communication/Command.cs +++ b/dotnet/src/webdriver/BiDi/Command.cs @@ -17,10 +17,9 @@ // under the License. // -using System; using System.Text.Json.Serialization; -namespace OpenQA.Selenium.BiDi.Communication; +namespace OpenQA.Selenium.BiDi; public abstract class Command { diff --git a/dotnet/src/webdriver/BiDi/Communication/CommandOptions.cs b/dotnet/src/webdriver/BiDi/CommandOptions.cs similarity index 95% rename from dotnet/src/webdriver/BiDi/Communication/CommandOptions.cs rename to dotnet/src/webdriver/BiDi/CommandOptions.cs index a68281a03800d..199f40cef0f5e 100644 --- a/dotnet/src/webdriver/BiDi/Communication/CommandOptions.cs +++ b/dotnet/src/webdriver/BiDi/CommandOptions.cs @@ -19,7 +19,7 @@ using System; -namespace OpenQA.Selenium.BiDi.Communication; +namespace OpenQA.Selenium.BiDi; public abstract class CommandOptions { diff --git a/dotnet/src/webdriver/BiDi/Emulation/EmulationModule.cs b/dotnet/src/webdriver/BiDi/Emulation/EmulationModule.cs index 6be60f7769c60..5212f3f7c4222 100644 --- a/dotnet/src/webdriver/BiDi/Emulation/EmulationModule.cs +++ b/dotnet/src/webdriver/BiDi/Emulation/EmulationModule.cs @@ -18,7 +18,6 @@ // using System.Threading.Tasks; -using OpenQA.Selenium.BiDi.Communication; namespace OpenQA.Selenium.BiDi.Emulation; diff --git a/dotnet/src/webdriver/BiDi/Emulation/SetForcedColorsModeThemeOverrideCommand.cs b/dotnet/src/webdriver/BiDi/Emulation/SetForcedColorsModeThemeOverrideCommand.cs index b1b359995b2be..7ce93624e017b 100644 --- a/dotnet/src/webdriver/BiDi/Emulation/SetForcedColorsModeThemeOverrideCommand.cs +++ b/dotnet/src/webdriver/BiDi/Emulation/SetForcedColorsModeThemeOverrideCommand.cs @@ -17,8 +17,7 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication; -using OpenQA.Selenium.BiDi.Communication.Json.Converters; +using OpenQA.Selenium.BiDi.Json.Converters; using System.Collections.Generic; using System.Text.Json.Serialization; diff --git a/dotnet/src/webdriver/BiDi/Emulation/SetGeolocationOverrideCommand.cs b/dotnet/src/webdriver/BiDi/Emulation/SetGeolocationOverrideCommand.cs index 2054bc1d95113..fefe3e1c2b416 100644 --- a/dotnet/src/webdriver/BiDi/Emulation/SetGeolocationOverrideCommand.cs +++ b/dotnet/src/webdriver/BiDi/Emulation/SetGeolocationOverrideCommand.cs @@ -19,7 +19,6 @@ using System.Collections.Generic; using System.Text.Json.Serialization; -using OpenQA.Selenium.BiDi.Communication; namespace OpenQA.Selenium.BiDi.Emulation; diff --git a/dotnet/src/webdriver/BiDi/Emulation/SetLocaleOverrideCommand.cs b/dotnet/src/webdriver/BiDi/Emulation/SetLocaleOverrideCommand.cs index 55373fb557594..ed70fedfab28c 100644 --- a/dotnet/src/webdriver/BiDi/Emulation/SetLocaleOverrideCommand.cs +++ b/dotnet/src/webdriver/BiDi/Emulation/SetLocaleOverrideCommand.cs @@ -19,7 +19,6 @@ using System.Collections.Generic; using System.Text.Json.Serialization; -using OpenQA.Selenium.BiDi.Communication; namespace OpenQA.Selenium.BiDi.Emulation; diff --git a/dotnet/src/webdriver/BiDi/Emulation/SetScreenOrientationOverrideCommand.cs b/dotnet/src/webdriver/BiDi/Emulation/SetScreenOrientationOverrideCommand.cs index cd30977fea772..d7dc42d0c87ab 100644 --- a/dotnet/src/webdriver/BiDi/Emulation/SetScreenOrientationOverrideCommand.cs +++ b/dotnet/src/webdriver/BiDi/Emulation/SetScreenOrientationOverrideCommand.cs @@ -17,8 +17,7 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication; -using OpenQA.Selenium.BiDi.Communication.Json.Converters; +using OpenQA.Selenium.BiDi.Json.Converters; using System.Collections.Generic; using System.Text.Json.Serialization; diff --git a/dotnet/src/webdriver/BiDi/Emulation/SetScriptingEnabledCommand.cs b/dotnet/src/webdriver/BiDi/Emulation/SetScriptingEnabledCommand.cs index d4155167a61ef..0c574aab59dda 100644 --- a/dotnet/src/webdriver/BiDi/Emulation/SetScriptingEnabledCommand.cs +++ b/dotnet/src/webdriver/BiDi/Emulation/SetScriptingEnabledCommand.cs @@ -19,7 +19,6 @@ using System.Collections.Generic; using System.Text.Json.Serialization; -using OpenQA.Selenium.BiDi.Communication; namespace OpenQA.Selenium.BiDi.Emulation; diff --git a/dotnet/src/webdriver/BiDi/Emulation/SetTimezoneOverrideCommand.cs b/dotnet/src/webdriver/BiDi/Emulation/SetTimezoneOverrideCommand.cs index aecb19b29774d..80b2dd4d882d0 100644 --- a/dotnet/src/webdriver/BiDi/Emulation/SetTimezoneOverrideCommand.cs +++ b/dotnet/src/webdriver/BiDi/Emulation/SetTimezoneOverrideCommand.cs @@ -17,7 +17,6 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication; using System.Collections.Generic; using System.Text.Json.Serialization; diff --git a/dotnet/src/webdriver/BiDi/Emulation/SetUserAgentOverrideCommand.cs b/dotnet/src/webdriver/BiDi/Emulation/SetUserAgentOverrideCommand.cs index c9f12e7ef28df..6181a3e1cb426 100644 --- a/dotnet/src/webdriver/BiDi/Emulation/SetUserAgentOverrideCommand.cs +++ b/dotnet/src/webdriver/BiDi/Emulation/SetUserAgentOverrideCommand.cs @@ -17,7 +17,6 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication; using System.Collections.Generic; using System.Text.Json.Serialization; diff --git a/dotnet/src/webdriver/BiDi/Communication/EventHandler.cs b/dotnet/src/webdriver/BiDi/EventHandler.cs similarity index 92% rename from dotnet/src/webdriver/BiDi/Communication/EventHandler.cs rename to dotnet/src/webdriver/BiDi/EventHandler.cs index 16e95beec1265..e3fae4ae9d927 100644 --- a/dotnet/src/webdriver/BiDi/Communication/EventHandler.cs +++ b/dotnet/src/webdriver/BiDi/EventHandler.cs @@ -21,9 +21,9 @@ using System.Collections.Generic; using System.Threading.Tasks; -namespace OpenQA.Selenium.BiDi.Communication; +namespace OpenQA.Selenium.BiDi; -public abstract class EventHandler(string eventName, IEnumerable? contexts = null) +internal abstract class EventHandler(string eventName, IEnumerable? contexts = null) { public string EventName { get; } = eventName; diff --git a/dotnet/src/webdriver/BiDi/Communication/Transport/ITransport.cs b/dotnet/src/webdriver/BiDi/ITransport.cs similarity index 95% rename from dotnet/src/webdriver/BiDi/Communication/Transport/ITransport.cs rename to dotnet/src/webdriver/BiDi/ITransport.cs index c47a3aaad38eb..471bb3cc56a60 100644 --- a/dotnet/src/webdriver/BiDi/Communication/Transport/ITransport.cs +++ b/dotnet/src/webdriver/BiDi/ITransport.cs @@ -21,7 +21,7 @@ using System.Threading; using System; -namespace OpenQA.Selenium.BiDi.Communication.Transport; +namespace OpenQA.Selenium.BiDi; interface ITransport : IDisposable { diff --git a/dotnet/src/webdriver/BiDi/Input/InputModule.cs b/dotnet/src/webdriver/BiDi/Input/InputModule.cs index 8d2662caa035a..ccc99be5d5e4a 100644 --- a/dotnet/src/webdriver/BiDi/Input/InputModule.cs +++ b/dotnet/src/webdriver/BiDi/Input/InputModule.cs @@ -17,7 +17,6 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication; using System.Collections.Generic; using System.Threading.Tasks; diff --git a/dotnet/src/webdriver/BiDi/Input/Origin.cs b/dotnet/src/webdriver/BiDi/Input/Origin.cs index fc1d4dcc61377..00dd030b9873b 100644 --- a/dotnet/src/webdriver/BiDi/Input/Origin.cs +++ b/dotnet/src/webdriver/BiDi/Input/Origin.cs @@ -17,7 +17,7 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication.Json.Converters; +using OpenQA.Selenium.BiDi.Json.Converters; using System.Text.Json.Serialization; namespace OpenQA.Selenium.BiDi.Input; diff --git a/dotnet/src/webdriver/BiDi/Input/PerformActionsCommand.cs b/dotnet/src/webdriver/BiDi/Input/PerformActionsCommand.cs index 92b751be69213..bb3004236967c 100644 --- a/dotnet/src/webdriver/BiDi/Input/PerformActionsCommand.cs +++ b/dotnet/src/webdriver/BiDi/Input/PerformActionsCommand.cs @@ -17,7 +17,6 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication; using System.Collections.Generic; namespace OpenQA.Selenium.BiDi.Input; diff --git a/dotnet/src/webdriver/BiDi/Input/ReleaseActionsCommand.cs b/dotnet/src/webdriver/BiDi/Input/ReleaseActionsCommand.cs index b55cdef462ddd..e9f76178c8a86 100644 --- a/dotnet/src/webdriver/BiDi/Input/ReleaseActionsCommand.cs +++ b/dotnet/src/webdriver/BiDi/Input/ReleaseActionsCommand.cs @@ -17,8 +17,6 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication; - namespace OpenQA.Selenium.BiDi.Input; internal sealed class ReleaseActionsCommand(ReleaseActionsParameters @params) diff --git a/dotnet/src/webdriver/BiDi/Input/SetFilesCommand.cs b/dotnet/src/webdriver/BiDi/Input/SetFilesCommand.cs index 3b0736522281d..bb57852945d12 100644 --- a/dotnet/src/webdriver/BiDi/Input/SetFilesCommand.cs +++ b/dotnet/src/webdriver/BiDi/Input/SetFilesCommand.cs @@ -17,7 +17,6 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication; using System.Collections.Generic; namespace OpenQA.Selenium.BiDi.Input; diff --git a/dotnet/src/webdriver/BiDi/Input/SourceActions.cs b/dotnet/src/webdriver/BiDi/Input/SourceActions.cs index cfc5983e2b066..0e75ede2b1f50 100644 --- a/dotnet/src/webdriver/BiDi/Input/SourceActions.cs +++ b/dotnet/src/webdriver/BiDi/Input/SourceActions.cs @@ -17,8 +17,8 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication.Json.Converters; -using OpenQA.Selenium.BiDi.Communication.Json.Converters.Enumerable; +using OpenQA.Selenium.BiDi.Json.Converters; +using OpenQA.Selenium.BiDi.Json.Converters.Enumerable; using System; using System.Collections; using System.Collections.Generic; diff --git a/dotnet/src/webdriver/BiDi/Communication/Json/BiDiJsonSerializerContext.cs b/dotnet/src/webdriver/BiDi/Json/BiDiJsonSerializerContext.cs similarity index 99% rename from dotnet/src/webdriver/BiDi/Communication/Json/BiDiJsonSerializerContext.cs rename to dotnet/src/webdriver/BiDi/Json/BiDiJsonSerializerContext.cs index 0f35020aba048..046e3a4938b96 100644 --- a/dotnet/src/webdriver/BiDi/Communication/Json/BiDiJsonSerializerContext.cs +++ b/dotnet/src/webdriver/BiDi/Json/BiDiJsonSerializerContext.cs @@ -20,7 +20,7 @@ using System.Collections.Generic; using System.Text.Json.Serialization; -namespace OpenQA.Selenium.BiDi.Communication.Json; +namespace OpenQA.Selenium.BiDi.Json; #region https://github.com/dotnet/runtime/issues/72604 [JsonSerializable(typeof(Script.EvaluateResultSuccess))] diff --git a/dotnet/src/webdriver/BiDi/Communication/Json/Converters/BrowserClientWindowConverter.cs b/dotnet/src/webdriver/BiDi/Json/Converters/BrowserClientWindowConverter.cs similarity index 95% rename from dotnet/src/webdriver/BiDi/Communication/Json/Converters/BrowserClientWindowConverter.cs rename to dotnet/src/webdriver/BiDi/Json/Converters/BrowserClientWindowConverter.cs index 5849c3bfe6cf4..9250e60980348 100644 --- a/dotnet/src/webdriver/BiDi/Communication/Json/Converters/BrowserClientWindowConverter.cs +++ b/dotnet/src/webdriver/BiDi/Json/Converters/BrowserClientWindowConverter.cs @@ -22,7 +22,7 @@ using System.Text.Json; using System.Text.Json.Serialization; -namespace OpenQA.Selenium.BiDi.Communication.Json.Converters; +namespace OpenQA.Selenium.BiDi.Json.Converters; internal class BrowserClientWindowConverter : JsonConverter { diff --git a/dotnet/src/webdriver/BiDi/Communication/Json/Converters/BrowserUserContextConverter.cs b/dotnet/src/webdriver/BiDi/Json/Converters/BrowserUserContextConverter.cs similarity index 96% rename from dotnet/src/webdriver/BiDi/Communication/Json/Converters/BrowserUserContextConverter.cs rename to dotnet/src/webdriver/BiDi/Json/Converters/BrowserUserContextConverter.cs index 3d68e7f5cd150..e660c9843f086 100644 --- a/dotnet/src/webdriver/BiDi/Communication/Json/Converters/BrowserUserContextConverter.cs +++ b/dotnet/src/webdriver/BiDi/Json/Converters/BrowserUserContextConverter.cs @@ -22,7 +22,7 @@ using System.Text.Json; using System.Text.Json.Serialization; -namespace OpenQA.Selenium.BiDi.Communication.Json.Converters; +namespace OpenQA.Selenium.BiDi.Json.Converters; internal class BrowserUserContextConverter : JsonConverter { diff --git a/dotnet/src/webdriver/BiDi/Communication/Json/Converters/BrowsingContextConverter.cs b/dotnet/src/webdriver/BiDi/Json/Converters/BrowsingContextConverter.cs similarity index 96% rename from dotnet/src/webdriver/BiDi/Communication/Json/Converters/BrowsingContextConverter.cs rename to dotnet/src/webdriver/BiDi/Json/Converters/BrowsingContextConverter.cs index fc3b3aefd9b7d..208b2698ad01f 100644 --- a/dotnet/src/webdriver/BiDi/Communication/Json/Converters/BrowsingContextConverter.cs +++ b/dotnet/src/webdriver/BiDi/Json/Converters/BrowsingContextConverter.cs @@ -21,7 +21,7 @@ using System.Text.Json; using System.Text.Json.Serialization; -namespace OpenQA.Selenium.BiDi.Communication.Json.Converters; +namespace OpenQA.Selenium.BiDi.Json.Converters; internal class BrowsingContextConverter : JsonConverter { diff --git a/dotnet/src/webdriver/BiDi/Communication/Json/Converters/CamelCaseEnumConverter.cs b/dotnet/src/webdriver/BiDi/Json/Converters/CamelCaseEnumConverter.cs similarity index 94% rename from dotnet/src/webdriver/BiDi/Communication/Json/Converters/CamelCaseEnumConverter.cs rename to dotnet/src/webdriver/BiDi/Json/Converters/CamelCaseEnumConverter.cs index 1a40f7821b3a3..1f67ccb53afbb 100644 --- a/dotnet/src/webdriver/BiDi/Communication/Json/Converters/CamelCaseEnumConverter.cs +++ b/dotnet/src/webdriver/BiDi/Json/Converters/CamelCaseEnumConverter.cs @@ -21,7 +21,7 @@ using System.Text.Json; using System.Text.Json.Serialization; -namespace OpenQA.Selenium.BiDi.Communication.Json.Converters; +namespace OpenQA.Selenium.BiDi.Json.Converters; public class CamelCaseEnumConverter() : JsonStringEnumConverter(JsonNamingPolicy.CamelCase) where TEnum : struct, Enum; diff --git a/dotnet/src/webdriver/BiDi/Communication/Json/Converters/ChannelConverter.cs b/dotnet/src/webdriver/BiDi/Json/Converters/ChannelConverter.cs similarity index 95% rename from dotnet/src/webdriver/BiDi/Communication/Json/Converters/ChannelConverter.cs rename to dotnet/src/webdriver/BiDi/Json/Converters/ChannelConverter.cs index 43110782e8f40..6e15b181c3ca3 100644 --- a/dotnet/src/webdriver/BiDi/Communication/Json/Converters/ChannelConverter.cs +++ b/dotnet/src/webdriver/BiDi/Json/Converters/ChannelConverter.cs @@ -22,7 +22,7 @@ using System.Text.Json; using System.Text.Json.Serialization; -namespace OpenQA.Selenium.BiDi.Communication.Json.Converters; +namespace OpenQA.Selenium.BiDi.Json.Converters; internal class ChannelConverter : JsonConverter { diff --git a/dotnet/src/webdriver/BiDi/Communication/Json/Converters/CollectorConverter.cs b/dotnet/src/webdriver/BiDi/Json/Converters/CollectorConverter.cs similarity index 96% rename from dotnet/src/webdriver/BiDi/Communication/Json/Converters/CollectorConverter.cs rename to dotnet/src/webdriver/BiDi/Json/Converters/CollectorConverter.cs index 836f252435a4d..9f77d0f03fcbc 100644 --- a/dotnet/src/webdriver/BiDi/Communication/Json/Converters/CollectorConverter.cs +++ b/dotnet/src/webdriver/BiDi/Json/Converters/CollectorConverter.cs @@ -22,7 +22,7 @@ using System.Text.Json; using System.Text.Json.Serialization; -namespace OpenQA.Selenium.BiDi.Communication.Json.Converters; +namespace OpenQA.Selenium.BiDi.Json.Converters; internal class CollectorConverter : JsonConverter { diff --git a/dotnet/src/webdriver/BiDi/Communication/Json/Converters/DateTimeOffsetConverter.cs b/dotnet/src/webdriver/BiDi/Json/Converters/DateTimeOffsetConverter.cs similarity index 96% rename from dotnet/src/webdriver/BiDi/Communication/Json/Converters/DateTimeOffsetConverter.cs rename to dotnet/src/webdriver/BiDi/Json/Converters/DateTimeOffsetConverter.cs index 6d51f829dc7ad..5c2855e1fd99b 100644 --- a/dotnet/src/webdriver/BiDi/Communication/Json/Converters/DateTimeOffsetConverter.cs +++ b/dotnet/src/webdriver/BiDi/Json/Converters/DateTimeOffsetConverter.cs @@ -21,7 +21,7 @@ using System.Text.Json; using System.Text.Json.Serialization; -namespace OpenQA.Selenium.BiDi.Communication.Json.Converters; +namespace OpenQA.Selenium.BiDi.Json.Converters; internal class DateTimeOffsetConverter : JsonConverter { diff --git a/dotnet/src/webdriver/BiDi/Communication/Json/Converters/Enumerable/InputSourceActionsConverter.cs b/dotnet/src/webdriver/BiDi/Json/Converters/Enumerable/InputSourceActionsConverter.cs similarity index 96% rename from dotnet/src/webdriver/BiDi/Communication/Json/Converters/Enumerable/InputSourceActionsConverter.cs rename to dotnet/src/webdriver/BiDi/Json/Converters/Enumerable/InputSourceActionsConverter.cs index a73f141e086ee..4f93808e9584b 100644 --- a/dotnet/src/webdriver/BiDi/Communication/Json/Converters/Enumerable/InputSourceActionsConverter.cs +++ b/dotnet/src/webdriver/BiDi/Json/Converters/Enumerable/InputSourceActionsConverter.cs @@ -17,7 +17,6 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication.Json.Internal; using OpenQA.Selenium.BiDi.Input; using System; using System.Collections.Generic; @@ -25,7 +24,7 @@ using System.Text.Json; using System.Text.Json.Serialization; -namespace OpenQA.Selenium.BiDi.Communication.Json.Converters.Enumerable; +namespace OpenQA.Selenium.BiDi.Json.Converters.Enumerable; internal class InputSourceActionsConverter : JsonConverter { diff --git a/dotnet/src/webdriver/BiDi/Communication/Json/Converters/HandleConverter.cs b/dotnet/src/webdriver/BiDi/Json/Converters/HandleConverter.cs similarity index 96% rename from dotnet/src/webdriver/BiDi/Communication/Json/Converters/HandleConverter.cs rename to dotnet/src/webdriver/BiDi/Json/Converters/HandleConverter.cs index f2e9af7139840..852a3d925cc00 100644 --- a/dotnet/src/webdriver/BiDi/Communication/Json/Converters/HandleConverter.cs +++ b/dotnet/src/webdriver/BiDi/Json/Converters/HandleConverter.cs @@ -22,7 +22,7 @@ using System.Text.Json; using System.Text.Json.Serialization; -namespace OpenQA.Selenium.BiDi.Communication.Json.Converters; +namespace OpenQA.Selenium.BiDi.Json.Converters; internal class HandleConverter : JsonConverter { diff --git a/dotnet/src/webdriver/BiDi/Communication/Json/Converters/InputOriginConverter.cs b/dotnet/src/webdriver/BiDi/Json/Converters/InputOriginConverter.cs similarity index 97% rename from dotnet/src/webdriver/BiDi/Communication/Json/Converters/InputOriginConverter.cs rename to dotnet/src/webdriver/BiDi/Json/Converters/InputOriginConverter.cs index f47b25bb7ee37..b11a63643f353 100644 --- a/dotnet/src/webdriver/BiDi/Communication/Json/Converters/InputOriginConverter.cs +++ b/dotnet/src/webdriver/BiDi/Json/Converters/InputOriginConverter.cs @@ -23,7 +23,7 @@ using System.Text.Json; using System.Text.Json.Serialization; -namespace OpenQA.Selenium.BiDi.Communication.Json.Converters; +namespace OpenQA.Selenium.BiDi.Json.Converters; [UnconditionalSuppressMessage("Trimming", "IL2026", Justification = "Json serializer options should have AOT-safe type resolution")] [UnconditionalSuppressMessage("AOT", "IL3050", Justification = "Json serializer options should have AOT-safe type resolution")] diff --git a/dotnet/src/webdriver/BiDi/Communication/Json/Converters/InterceptConverter.cs b/dotnet/src/webdriver/BiDi/Json/Converters/InterceptConverter.cs similarity index 96% rename from dotnet/src/webdriver/BiDi/Communication/Json/Converters/InterceptConverter.cs rename to dotnet/src/webdriver/BiDi/Json/Converters/InterceptConverter.cs index d789065e8d458..a72e6cfa96921 100644 --- a/dotnet/src/webdriver/BiDi/Communication/Json/Converters/InterceptConverter.cs +++ b/dotnet/src/webdriver/BiDi/Json/Converters/InterceptConverter.cs @@ -22,7 +22,7 @@ using System.Text.Json; using System.Text.Json.Serialization; -namespace OpenQA.Selenium.BiDi.Communication.Json.Converters; +namespace OpenQA.Selenium.BiDi.Json.Converters; internal class InterceptConverter : JsonConverter { diff --git a/dotnet/src/webdriver/BiDi/Communication/Json/Converters/InternalIdConverter.cs b/dotnet/src/webdriver/BiDi/Json/Converters/InternalIdConverter.cs similarity index 96% rename from dotnet/src/webdriver/BiDi/Communication/Json/Converters/InternalIdConverter.cs rename to dotnet/src/webdriver/BiDi/Json/Converters/InternalIdConverter.cs index ec65181f7c9bb..6f14fa6571d64 100644 --- a/dotnet/src/webdriver/BiDi/Communication/Json/Converters/InternalIdConverter.cs +++ b/dotnet/src/webdriver/BiDi/Json/Converters/InternalIdConverter.cs @@ -22,7 +22,7 @@ using System.Text.Json; using System.Text.Json.Serialization; -namespace OpenQA.Selenium.BiDi.Communication.Json.Converters; +namespace OpenQA.Selenium.BiDi.Json.Converters; internal class InternalIdConverter : JsonConverter { diff --git a/dotnet/src/webdriver/BiDi/Communication/Json/Converters/KebabCaseEnumConverter.cs b/dotnet/src/webdriver/BiDi/Json/Converters/KebabCaseEnumConverter.cs similarity index 94% rename from dotnet/src/webdriver/BiDi/Communication/Json/Converters/KebabCaseEnumConverter.cs rename to dotnet/src/webdriver/BiDi/Json/Converters/KebabCaseEnumConverter.cs index 3c5536a3a4b96..92fa84a14c219 100644 --- a/dotnet/src/webdriver/BiDi/Communication/Json/Converters/KebabCaseEnumConverter.cs +++ b/dotnet/src/webdriver/BiDi/Json/Converters/KebabCaseEnumConverter.cs @@ -21,7 +21,7 @@ using System.Text.Json; using System.Text.Json.Serialization; -namespace OpenQA.Selenium.BiDi.Communication.Json.Converters; +namespace OpenQA.Selenium.BiDi.Json.Converters; public class KebabCaseEnumConverter() : JsonStringEnumConverter(JsonNamingPolicy.KebabCaseLower) where TEnum : struct, Enum; diff --git a/dotnet/src/webdriver/BiDi/Communication/Json/Converters/NavigationConverter.cs b/dotnet/src/webdriver/BiDi/Json/Converters/NavigationConverter.cs similarity index 95% rename from dotnet/src/webdriver/BiDi/Communication/Json/Converters/NavigationConverter.cs rename to dotnet/src/webdriver/BiDi/Json/Converters/NavigationConverter.cs index ce9d27b9a2b63..7303f78328c63 100644 --- a/dotnet/src/webdriver/BiDi/Communication/Json/Converters/NavigationConverter.cs +++ b/dotnet/src/webdriver/BiDi/Json/Converters/NavigationConverter.cs @@ -22,7 +22,7 @@ using System.Text.Json; using System.Text.Json.Serialization; -namespace OpenQA.Selenium.BiDi.Communication.Json.Converters; +namespace OpenQA.Selenium.BiDi.Json.Converters; internal class NavigationConverter : JsonConverter { diff --git a/dotnet/src/webdriver/BiDi/Communication/Json/Converters/Polymorphic/DownloadEndEventArgsConverter.cs b/dotnet/src/webdriver/BiDi/Json/Converters/Polymorphic/DownloadEndEventArgsConverter.cs similarity index 93% rename from dotnet/src/webdriver/BiDi/Communication/Json/Converters/Polymorphic/DownloadEndEventArgsConverter.cs rename to dotnet/src/webdriver/BiDi/Json/Converters/Polymorphic/DownloadEndEventArgsConverter.cs index b065d172b41f4..e3331b59efe12 100644 --- a/dotnet/src/webdriver/BiDi/Communication/Json/Converters/Polymorphic/DownloadEndEventArgsConverter.cs +++ b/dotnet/src/webdriver/BiDi/Json/Converters/Polymorphic/DownloadEndEventArgsConverter.cs @@ -18,12 +18,11 @@ // using OpenQA.Selenium.BiDi.BrowsingContext; -using OpenQA.Selenium.BiDi.Communication.Json.Internal; using System; using System.Text.Json; using System.Text.Json.Serialization; -namespace OpenQA.Selenium.BiDi.Communication.Json.Converters.Polymorphic; +namespace OpenQA.Selenium.BiDi.Json.Converters.Polymorphic; // https://github.com/dotnet/runtime/issues/72604 internal class DownloadEndEventArgsConverter : JsonConverter diff --git a/dotnet/src/webdriver/BiDi/Communication/Json/Converters/Polymorphic/EvaluateResultConverter.cs b/dotnet/src/webdriver/BiDi/Json/Converters/Polymorphic/EvaluateResultConverter.cs similarity index 93% rename from dotnet/src/webdriver/BiDi/Communication/Json/Converters/Polymorphic/EvaluateResultConverter.cs rename to dotnet/src/webdriver/BiDi/Json/Converters/Polymorphic/EvaluateResultConverter.cs index 25f94b42b4dc7..2f1d643cf4a5a 100644 --- a/dotnet/src/webdriver/BiDi/Communication/Json/Converters/Polymorphic/EvaluateResultConverter.cs +++ b/dotnet/src/webdriver/BiDi/Json/Converters/Polymorphic/EvaluateResultConverter.cs @@ -17,13 +17,12 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication.Json.Internal; using OpenQA.Selenium.BiDi.Script; using System; using System.Text.Json; using System.Text.Json.Serialization; -namespace OpenQA.Selenium.BiDi.Communication.Json.Converters.Polymorphic; +namespace OpenQA.Selenium.BiDi.Json.Converters.Polymorphic; // https://github.com/dotnet/runtime/issues/72604 internal class EvaluateResultConverter : JsonConverter diff --git a/dotnet/src/webdriver/BiDi/Communication/Json/Converters/Polymorphic/LogEntryConverter.cs b/dotnet/src/webdriver/BiDi/Json/Converters/Polymorphic/LogEntryConverter.cs similarity index 93% rename from dotnet/src/webdriver/BiDi/Communication/Json/Converters/Polymorphic/LogEntryConverter.cs rename to dotnet/src/webdriver/BiDi/Json/Converters/Polymorphic/LogEntryConverter.cs index 53f90772a3b0e..a591c6b0caed3 100644 --- a/dotnet/src/webdriver/BiDi/Communication/Json/Converters/Polymorphic/LogEntryConverter.cs +++ b/dotnet/src/webdriver/BiDi/Json/Converters/Polymorphic/LogEntryConverter.cs @@ -17,13 +17,12 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication.Json.Internal; using OpenQA.Selenium.BiDi.Log; using System; using System.Text.Json; using System.Text.Json.Serialization; -namespace OpenQA.Selenium.BiDi.Communication.Json.Converters.Polymorphic; +namespace OpenQA.Selenium.BiDi.Json.Converters.Polymorphic; // https://github.com/dotnet/runtime/issues/72604 internal class LogEntryConverter : JsonConverter diff --git a/dotnet/src/webdriver/BiDi/Communication/Json/Converters/Polymorphic/RealmInfoConverter.cs b/dotnet/src/webdriver/BiDi/Json/Converters/Polymorphic/RealmInfoConverter.cs similarity index 94% rename from dotnet/src/webdriver/BiDi/Communication/Json/Converters/Polymorphic/RealmInfoConverter.cs rename to dotnet/src/webdriver/BiDi/Json/Converters/Polymorphic/RealmInfoConverter.cs index 288ffb496a3f8..e12c40d8bbd80 100644 --- a/dotnet/src/webdriver/BiDi/Communication/Json/Converters/Polymorphic/RealmInfoConverter.cs +++ b/dotnet/src/webdriver/BiDi/Json/Converters/Polymorphic/RealmInfoConverter.cs @@ -17,13 +17,12 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication.Json.Internal; using OpenQA.Selenium.BiDi.Script; using System; using System.Text.Json; using System.Text.Json.Serialization; -namespace OpenQA.Selenium.BiDi.Communication.Json.Converters.Polymorphic; +namespace OpenQA.Selenium.BiDi.Json.Converters.Polymorphic; // https://github.com/dotnet/runtime/issues/72604 internal class RealmInfoConverter : JsonConverter diff --git a/dotnet/src/webdriver/BiDi/Communication/Json/Converters/Polymorphic/RemoteValueConverter.cs b/dotnet/src/webdriver/BiDi/Json/Converters/Polymorphic/RemoteValueConverter.cs similarity index 97% rename from dotnet/src/webdriver/BiDi/Communication/Json/Converters/Polymorphic/RemoteValueConverter.cs rename to dotnet/src/webdriver/BiDi/Json/Converters/Polymorphic/RemoteValueConverter.cs index 6879403266419..441a183cc403a 100644 --- a/dotnet/src/webdriver/BiDi/Communication/Json/Converters/Polymorphic/RemoteValueConverter.cs +++ b/dotnet/src/webdriver/BiDi/Json/Converters/Polymorphic/RemoteValueConverter.cs @@ -17,13 +17,12 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication.Json.Internal; using OpenQA.Selenium.BiDi.Script; using System; using System.Text.Json; using System.Text.Json.Serialization; -namespace OpenQA.Selenium.BiDi.Communication.Json.Converters.Polymorphic; +namespace OpenQA.Selenium.BiDi.Json.Converters.Polymorphic; // https://github.com/dotnet/runtime/issues/72604 internal class RemoteValueConverter : JsonConverter diff --git a/dotnet/src/webdriver/BiDi/Communication/Json/Converters/PreloadScriptConverter.cs b/dotnet/src/webdriver/BiDi/Json/Converters/PreloadScriptConverter.cs similarity index 96% rename from dotnet/src/webdriver/BiDi/Communication/Json/Converters/PreloadScriptConverter.cs rename to dotnet/src/webdriver/BiDi/Json/Converters/PreloadScriptConverter.cs index e7fc7bc4be8ff..9a531f60f79ed 100644 --- a/dotnet/src/webdriver/BiDi/Communication/Json/Converters/PreloadScriptConverter.cs +++ b/dotnet/src/webdriver/BiDi/Json/Converters/PreloadScriptConverter.cs @@ -22,7 +22,7 @@ using System.Text.Json; using System.Text.Json.Serialization; -namespace OpenQA.Selenium.BiDi.Communication.Json.Converters; +namespace OpenQA.Selenium.BiDi.Json.Converters; internal class PreloadScriptConverter : JsonConverter { diff --git a/dotnet/src/webdriver/BiDi/Communication/Json/Converters/PrintPageRangeConverter.cs b/dotnet/src/webdriver/BiDi/Json/Converters/PrintPageRangeConverter.cs similarity index 96% rename from dotnet/src/webdriver/BiDi/Communication/Json/Converters/PrintPageRangeConverter.cs rename to dotnet/src/webdriver/BiDi/Json/Converters/PrintPageRangeConverter.cs index 74b7312125742..1d0018b529a38 100644 --- a/dotnet/src/webdriver/BiDi/Communication/Json/Converters/PrintPageRangeConverter.cs +++ b/dotnet/src/webdriver/BiDi/Json/Converters/PrintPageRangeConverter.cs @@ -22,7 +22,7 @@ using System.Text.Json; using System.Text.Json.Serialization; -namespace OpenQA.Selenium.BiDi.Communication.Json.Converters; +namespace OpenQA.Selenium.BiDi.Json.Converters; internal class PrintPageRangeConverter : JsonConverter { diff --git a/dotnet/src/webdriver/BiDi/Communication/Json/Converters/RealmConverter.cs b/dotnet/src/webdriver/BiDi/Json/Converters/RealmConverter.cs similarity index 96% rename from dotnet/src/webdriver/BiDi/Communication/Json/Converters/RealmConverter.cs rename to dotnet/src/webdriver/BiDi/Json/Converters/RealmConverter.cs index c99f371a3ea5c..235c40b0363f4 100644 --- a/dotnet/src/webdriver/BiDi/Communication/Json/Converters/RealmConverter.cs +++ b/dotnet/src/webdriver/BiDi/Json/Converters/RealmConverter.cs @@ -22,7 +22,7 @@ using System.Text.Json; using System.Text.Json.Serialization; -namespace OpenQA.Selenium.BiDi.Communication.Json.Converters; +namespace OpenQA.Selenium.BiDi.Json.Converters; internal class RealmConverter : JsonConverter { diff --git a/dotnet/src/webdriver/BiDi/Communication/Json/Converters/RequestConverter.cs b/dotnet/src/webdriver/BiDi/Json/Converters/RequestConverter.cs similarity index 95% rename from dotnet/src/webdriver/BiDi/Communication/Json/Converters/RequestConverter.cs rename to dotnet/src/webdriver/BiDi/Json/Converters/RequestConverter.cs index 3b2265a988a72..18b0eb0fa2256 100644 --- a/dotnet/src/webdriver/BiDi/Communication/Json/Converters/RequestConverter.cs +++ b/dotnet/src/webdriver/BiDi/Json/Converters/RequestConverter.cs @@ -22,7 +22,7 @@ using System.Text.Json; using System.Text.Json.Serialization; -namespace OpenQA.Selenium.BiDi.Communication.Json.Converters; +namespace OpenQA.Selenium.BiDi.Json.Converters; internal class RequestConverter : JsonConverter { diff --git a/dotnet/src/webdriver/BiDi/Communication/Json/Converters/SpecialNumberConverter.cs b/dotnet/src/webdriver/BiDi/Json/Converters/SpecialNumberConverter.cs similarity index 98% rename from dotnet/src/webdriver/BiDi/Communication/Json/Converters/SpecialNumberConverter.cs rename to dotnet/src/webdriver/BiDi/Json/Converters/SpecialNumberConverter.cs index 5300c99028ea9..9eb5bba450313 100644 --- a/dotnet/src/webdriver/BiDi/Communication/Json/Converters/SpecialNumberConverter.cs +++ b/dotnet/src/webdriver/BiDi/Json/Converters/SpecialNumberConverter.cs @@ -21,7 +21,7 @@ using System.Text.Json; using System.Text.Json.Serialization; -namespace OpenQA.Selenium.BiDi.Communication.Json.Converters; +namespace OpenQA.Selenium.BiDi.Json.Converters; // Serializes and deserializes double into a BiDi spec-compliant number value. // See https://w3c.github.io/webdriver-bidi/#type-script-PrimitiveProtocolValue diff --git a/dotnet/src/webdriver/BiDi/Communication/Json/Converters/SubscriptionConverter.cs b/dotnet/src/webdriver/BiDi/Json/Converters/SubscriptionConverter.cs similarity index 95% rename from dotnet/src/webdriver/BiDi/Communication/Json/Converters/SubscriptionConverter.cs rename to dotnet/src/webdriver/BiDi/Json/Converters/SubscriptionConverter.cs index 1b9cbfdcfad65..bfa1c36afdf74 100644 --- a/dotnet/src/webdriver/BiDi/Communication/Json/Converters/SubscriptionConverter.cs +++ b/dotnet/src/webdriver/BiDi/Json/Converters/SubscriptionConverter.cs @@ -21,7 +21,7 @@ using System.Text.Json; using System.Text.Json.Serialization; -namespace OpenQA.Selenium.BiDi.Communication.Json.Converters; +namespace OpenQA.Selenium.BiDi.Json.Converters; internal class SubscriptionConverter : JsonConverter { diff --git a/dotnet/src/webdriver/BiDi/Communication/Json/Converters/WebExtensionConverter.cs b/dotnet/src/webdriver/BiDi/Json/Converters/WebExtensionConverter.cs similarity index 96% rename from dotnet/src/webdriver/BiDi/Communication/Json/Converters/WebExtensionConverter.cs rename to dotnet/src/webdriver/BiDi/Json/Converters/WebExtensionConverter.cs index f29dc90567fad..ec3bc5e9cb7dd 100644 --- a/dotnet/src/webdriver/BiDi/Communication/Json/Converters/WebExtensionConverter.cs +++ b/dotnet/src/webdriver/BiDi/Json/Converters/WebExtensionConverter.cs @@ -22,7 +22,7 @@ using System.Text.Json; using System.Text.Json.Serialization; -namespace OpenQA.Selenium.BiDi.Communication.Json.Converters; +namespace OpenQA.Selenium.BiDi.Json.Converters; internal class WebExtensionConverter : JsonConverter { diff --git a/dotnet/src/webdriver/BiDi/Communication/Json/Internal/JsonExtensions.cs b/dotnet/src/webdriver/BiDi/Json/JsonExtensions.cs similarity index 97% rename from dotnet/src/webdriver/BiDi/Communication/Json/Internal/JsonExtensions.cs rename to dotnet/src/webdriver/BiDi/Json/JsonExtensions.cs index 95bc5ad4915e3..11860c023aec8 100644 --- a/dotnet/src/webdriver/BiDi/Communication/Json/Internal/JsonExtensions.cs +++ b/dotnet/src/webdriver/BiDi/Json/JsonExtensions.cs @@ -20,7 +20,7 @@ using System.Text.Json; using System.Text.Json.Serialization.Metadata; -namespace OpenQA.Selenium.BiDi.Communication.Json.Internal; +namespace OpenQA.Selenium.BiDi.Json; internal static class JsonExtensions { diff --git a/dotnet/src/webdriver/BiDi/Log/LogEntry.cs b/dotnet/src/webdriver/BiDi/Log/LogEntry.cs index 783495c3fef26..ed68fb3830193 100644 --- a/dotnet/src/webdriver/BiDi/Log/LogEntry.cs +++ b/dotnet/src/webdriver/BiDi/Log/LogEntry.cs @@ -17,8 +17,8 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication.Json.Converters; -using OpenQA.Selenium.BiDi.Communication.Json.Converters.Polymorphic; +using OpenQA.Selenium.BiDi.Json.Converters; +using OpenQA.Selenium.BiDi.Json.Converters.Polymorphic; using System; using System.Collections.Generic; using System.Text.Json.Serialization; diff --git a/dotnet/src/webdriver/BiDi/Log/LogModule.cs b/dotnet/src/webdriver/BiDi/Log/LogModule.cs index a3887d7f052cf..28f5fbe5ed20b 100644 --- a/dotnet/src/webdriver/BiDi/Log/LogModule.cs +++ b/dotnet/src/webdriver/BiDi/Log/LogModule.cs @@ -17,9 +17,8 @@ // under the License. // -using System.Threading.Tasks; using System; -using OpenQA.Selenium.BiDi.Communication; +using System.Threading.Tasks; namespace OpenQA.Selenium.BiDi.Log; diff --git a/dotnet/src/webdriver/BiDi/Module.cs b/dotnet/src/webdriver/BiDi/Module.cs index 202bc30bbcd75..5c36189461f97 100644 --- a/dotnet/src/webdriver/BiDi/Module.cs +++ b/dotnet/src/webdriver/BiDi/Module.cs @@ -17,8 +17,7 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication; -using OpenQA.Selenium.BiDi.Communication.Json; +using OpenQA.Selenium.BiDi.Json; using System.Text.Json; namespace OpenQA.Selenium.BiDi; diff --git a/dotnet/src/webdriver/BiDi/Network/AddDataCollectorCommand.cs b/dotnet/src/webdriver/BiDi/Network/AddDataCollectorCommand.cs index f5bb6f08f76dd..ea831d1cec4c6 100644 --- a/dotnet/src/webdriver/BiDi/Network/AddDataCollectorCommand.cs +++ b/dotnet/src/webdriver/BiDi/Network/AddDataCollectorCommand.cs @@ -17,8 +17,7 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication; -using OpenQA.Selenium.BiDi.Communication.Json.Converters; +using OpenQA.Selenium.BiDi.Json.Converters; using System.Collections.Generic; using System.Text.Json.Serialization; diff --git a/dotnet/src/webdriver/BiDi/Network/AddInterceptCommand.cs b/dotnet/src/webdriver/BiDi/Network/AddInterceptCommand.cs index f48115877588a..23055edfa82fe 100644 --- a/dotnet/src/webdriver/BiDi/Network/AddInterceptCommand.cs +++ b/dotnet/src/webdriver/BiDi/Network/AddInterceptCommand.cs @@ -17,8 +17,7 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication; -using OpenQA.Selenium.BiDi.Communication.Json.Converters; +using OpenQA.Selenium.BiDi.Json.Converters; using System.Collections.Generic; using System.Text.Json.Serialization; diff --git a/dotnet/src/webdriver/BiDi/Network/ContinueRequestCommand.cs b/dotnet/src/webdriver/BiDi/Network/ContinueRequestCommand.cs index 812256f6e6977..57644769f6f97 100644 --- a/dotnet/src/webdriver/BiDi/Network/ContinueRequestCommand.cs +++ b/dotnet/src/webdriver/BiDi/Network/ContinueRequestCommand.cs @@ -17,7 +17,6 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication; using System.Collections.Generic; namespace OpenQA.Selenium.BiDi.Network; diff --git a/dotnet/src/webdriver/BiDi/Network/ContinueResponseCommand.cs b/dotnet/src/webdriver/BiDi/Network/ContinueResponseCommand.cs index 082ccd3e8ceef..045e34a0040fa 100644 --- a/dotnet/src/webdriver/BiDi/Network/ContinueResponseCommand.cs +++ b/dotnet/src/webdriver/BiDi/Network/ContinueResponseCommand.cs @@ -17,7 +17,6 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication; using System.Collections.Generic; namespace OpenQA.Selenium.BiDi.Network; diff --git a/dotnet/src/webdriver/BiDi/Network/ContinueWithAuthCommand.cs b/dotnet/src/webdriver/BiDi/Network/ContinueWithAuthCommand.cs index cd919cd0d705a..dcf9f0c159b83 100644 --- a/dotnet/src/webdriver/BiDi/Network/ContinueWithAuthCommand.cs +++ b/dotnet/src/webdriver/BiDi/Network/ContinueWithAuthCommand.cs @@ -17,7 +17,6 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication; using System.Text.Json.Serialization; namespace OpenQA.Selenium.BiDi.Network; diff --git a/dotnet/src/webdriver/BiDi/Network/Cookie.cs b/dotnet/src/webdriver/BiDi/Network/Cookie.cs index c3914d1bc8761..148230bc376d3 100644 --- a/dotnet/src/webdriver/BiDi/Network/Cookie.cs +++ b/dotnet/src/webdriver/BiDi/Network/Cookie.cs @@ -17,7 +17,7 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication.Json.Converters; +using OpenQA.Selenium.BiDi.Json.Converters; using System; using System.Text.Json.Serialization; diff --git a/dotnet/src/webdriver/BiDi/Network/FailRequestCommand.cs b/dotnet/src/webdriver/BiDi/Network/FailRequestCommand.cs index 51a5ab5bd62f8..b11265e121ab0 100644 --- a/dotnet/src/webdriver/BiDi/Network/FailRequestCommand.cs +++ b/dotnet/src/webdriver/BiDi/Network/FailRequestCommand.cs @@ -17,8 +17,6 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication; - namespace OpenQA.Selenium.BiDi.Network; internal sealed class FailRequestCommand(FailRequestParameters @params) diff --git a/dotnet/src/webdriver/BiDi/Network/GetDataCommand.cs b/dotnet/src/webdriver/BiDi/Network/GetDataCommand.cs index fe1e3f6cfe074..3a0151479e659 100644 --- a/dotnet/src/webdriver/BiDi/Network/GetDataCommand.cs +++ b/dotnet/src/webdriver/BiDi/Network/GetDataCommand.cs @@ -17,8 +17,6 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication; - namespace OpenQA.Selenium.BiDi.Network; internal sealed class GetDataCommand(GetDataParameters @params) diff --git a/dotnet/src/webdriver/BiDi/Network/Initiator.cs b/dotnet/src/webdriver/BiDi/Network/Initiator.cs index 522ae62daf1fa..dc7a26ed4920a 100644 --- a/dotnet/src/webdriver/BiDi/Network/Initiator.cs +++ b/dotnet/src/webdriver/BiDi/Network/Initiator.cs @@ -17,7 +17,7 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication.Json.Converters; +using OpenQA.Selenium.BiDi.Json.Converters; using System.Text.Json.Serialization; namespace OpenQA.Selenium.BiDi.Network; diff --git a/dotnet/src/webdriver/BiDi/Network/NetworkModule.cs b/dotnet/src/webdriver/BiDi/Network/NetworkModule.cs index 4242f8515bab9..12bc9c98d1613 100644 --- a/dotnet/src/webdriver/BiDi/Network/NetworkModule.cs +++ b/dotnet/src/webdriver/BiDi/Network/NetworkModule.cs @@ -20,7 +20,6 @@ using System; using System.Collections.Generic; using System.Threading.Tasks; -using OpenQA.Selenium.BiDi.Communication; namespace OpenQA.Selenium.BiDi.Network; diff --git a/dotnet/src/webdriver/BiDi/Network/ProvideResponseCommand.cs b/dotnet/src/webdriver/BiDi/Network/ProvideResponseCommand.cs index 8c49f8ab4d1da..96749f3877753 100644 --- a/dotnet/src/webdriver/BiDi/Network/ProvideResponseCommand.cs +++ b/dotnet/src/webdriver/BiDi/Network/ProvideResponseCommand.cs @@ -17,7 +17,6 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication; using System.Collections.Generic; namespace OpenQA.Selenium.BiDi.Network; diff --git a/dotnet/src/webdriver/BiDi/Network/RemoveDataCollectorCommand.cs b/dotnet/src/webdriver/BiDi/Network/RemoveDataCollectorCommand.cs index 4029d632eaf3a..e69fc47625acc 100644 --- a/dotnet/src/webdriver/BiDi/Network/RemoveDataCollectorCommand.cs +++ b/dotnet/src/webdriver/BiDi/Network/RemoveDataCollectorCommand.cs @@ -17,8 +17,6 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication; - namespace OpenQA.Selenium.BiDi.Network; internal sealed class RemoveDataCollectorCommand(RemoveDataCollectorParameters @params) diff --git a/dotnet/src/webdriver/BiDi/Network/RemoveInterceptCommand.cs b/dotnet/src/webdriver/BiDi/Network/RemoveInterceptCommand.cs index 1ff416186f44a..5651ab6b2f0e7 100644 --- a/dotnet/src/webdriver/BiDi/Network/RemoveInterceptCommand.cs +++ b/dotnet/src/webdriver/BiDi/Network/RemoveInterceptCommand.cs @@ -17,8 +17,6 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication; - namespace OpenQA.Selenium.BiDi.Network; internal sealed class RemoveInterceptCommand(RemoveInterceptParameters @params) diff --git a/dotnet/src/webdriver/BiDi/Network/Request.cs b/dotnet/src/webdriver/BiDi/Network/Request.cs index c3d97ace206ad..859d131254b14 100644 --- a/dotnet/src/webdriver/BiDi/Network/Request.cs +++ b/dotnet/src/webdriver/BiDi/Network/Request.cs @@ -17,7 +17,7 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication.Json.Converters; +using OpenQA.Selenium.BiDi.Json.Converters; using System.Text.Json.Serialization; namespace OpenQA.Selenium.BiDi.Network; diff --git a/dotnet/src/webdriver/BiDi/Network/SetCacheBehaviorCommand.cs b/dotnet/src/webdriver/BiDi/Network/SetCacheBehaviorCommand.cs index 0a8b8b44a53e3..9e019cc67a4ee 100644 --- a/dotnet/src/webdriver/BiDi/Network/SetCacheBehaviorCommand.cs +++ b/dotnet/src/webdriver/BiDi/Network/SetCacheBehaviorCommand.cs @@ -17,8 +17,7 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication; -using OpenQA.Selenium.BiDi.Communication.Json.Converters; +using OpenQA.Selenium.BiDi.Json.Converters; using System.Collections.Generic; using System.Text.Json.Serialization; diff --git a/dotnet/src/webdriver/BiDi/Network/SetExtraHeadersCommand.cs b/dotnet/src/webdriver/BiDi/Network/SetExtraHeadersCommand.cs index e14d13ce7cb69..6c4477d2c9589 100644 --- a/dotnet/src/webdriver/BiDi/Network/SetExtraHeadersCommand.cs +++ b/dotnet/src/webdriver/BiDi/Network/SetExtraHeadersCommand.cs @@ -18,7 +18,6 @@ // using System.Collections.Generic; -using OpenQA.Selenium.BiDi.Communication; namespace OpenQA.Selenium.BiDi.Network; diff --git a/dotnet/src/webdriver/BiDi/Script/AddPreloadScriptCommand.cs b/dotnet/src/webdriver/BiDi/Script/AddPreloadScriptCommand.cs index b741c2518cee9..c676ea7b5600a 100644 --- a/dotnet/src/webdriver/BiDi/Script/AddPreloadScriptCommand.cs +++ b/dotnet/src/webdriver/BiDi/Script/AddPreloadScriptCommand.cs @@ -17,7 +17,6 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication; using System.Collections.Generic; namespace OpenQA.Selenium.BiDi.Script; diff --git a/dotnet/src/webdriver/BiDi/Script/CallFunctionCommand.cs b/dotnet/src/webdriver/BiDi/Script/CallFunctionCommand.cs index 1203ed39a6578..2b2ea525466fa 100644 --- a/dotnet/src/webdriver/BiDi/Script/CallFunctionCommand.cs +++ b/dotnet/src/webdriver/BiDi/Script/CallFunctionCommand.cs @@ -17,7 +17,6 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication; using System.Collections.Generic; namespace OpenQA.Selenium.BiDi.Script; diff --git a/dotnet/src/webdriver/BiDi/Script/Channel.cs b/dotnet/src/webdriver/BiDi/Script/Channel.cs index 9d1ca1f61b5cf..cfdc06bed8139 100644 --- a/dotnet/src/webdriver/BiDi/Script/Channel.cs +++ b/dotnet/src/webdriver/BiDi/Script/Channel.cs @@ -17,7 +17,7 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication.Json.Converters; +using OpenQA.Selenium.BiDi.Json.Converters; using System.Text.Json.Serialization; namespace OpenQA.Selenium.BiDi.Script; diff --git a/dotnet/src/webdriver/BiDi/Script/DisownCommand.cs b/dotnet/src/webdriver/BiDi/Script/DisownCommand.cs index f005c467bcb56..e6c3fafc511a0 100644 --- a/dotnet/src/webdriver/BiDi/Script/DisownCommand.cs +++ b/dotnet/src/webdriver/BiDi/Script/DisownCommand.cs @@ -17,7 +17,6 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication; using System.Collections.Generic; namespace OpenQA.Selenium.BiDi.Script; diff --git a/dotnet/src/webdriver/BiDi/Script/EvaluateCommand.cs b/dotnet/src/webdriver/BiDi/Script/EvaluateCommand.cs index 3396c240e5148..65d5ed6d8ca24 100644 --- a/dotnet/src/webdriver/BiDi/Script/EvaluateCommand.cs +++ b/dotnet/src/webdriver/BiDi/Script/EvaluateCommand.cs @@ -17,8 +17,7 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication; -using OpenQA.Selenium.BiDi.Communication.Json.Converters.Polymorphic; +using OpenQA.Selenium.BiDi.Json.Converters.Polymorphic; using System; using System.Text.Json.Serialization; diff --git a/dotnet/src/webdriver/BiDi/Script/GetRealmsCommand.cs b/dotnet/src/webdriver/BiDi/Script/GetRealmsCommand.cs index d399b97527a9f..0640bc324c8e9 100644 --- a/dotnet/src/webdriver/BiDi/Script/GetRealmsCommand.cs +++ b/dotnet/src/webdriver/BiDi/Script/GetRealmsCommand.cs @@ -17,7 +17,6 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication; using System.Collections.Generic; namespace OpenQA.Selenium.BiDi.Script; diff --git a/dotnet/src/webdriver/BiDi/Script/LocalValue.cs b/dotnet/src/webdriver/BiDi/Script/LocalValue.cs index e3af6cace2fb4..809d54d5410e5 100644 --- a/dotnet/src/webdriver/BiDi/Script/LocalValue.cs +++ b/dotnet/src/webdriver/BiDi/Script/LocalValue.cs @@ -24,7 +24,7 @@ using System.Numerics; using System.Text.Json.Serialization; using System.Text.RegularExpressions; -using OpenQA.Selenium.BiDi.Communication.Json.Converters; +using OpenQA.Selenium.BiDi.Json.Converters; namespace OpenQA.Selenium.BiDi.Script; diff --git a/dotnet/src/webdriver/BiDi/Script/RealmInfo.cs b/dotnet/src/webdriver/BiDi/Script/RealmInfo.cs index c22c7cb52be8f..956b99db23f01 100644 --- a/dotnet/src/webdriver/BiDi/Script/RealmInfo.cs +++ b/dotnet/src/webdriver/BiDi/Script/RealmInfo.cs @@ -17,7 +17,7 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication.Json.Converters.Polymorphic; +using OpenQA.Selenium.BiDi.Json.Converters.Polymorphic; using System.Collections.Generic; using System.Text.Json.Serialization; diff --git a/dotnet/src/webdriver/BiDi/Script/RealmType.cs b/dotnet/src/webdriver/BiDi/Script/RealmType.cs index f415c00b5e560..8eae602c00490 100644 --- a/dotnet/src/webdriver/BiDi/Script/RealmType.cs +++ b/dotnet/src/webdriver/BiDi/Script/RealmType.cs @@ -17,7 +17,7 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication.Json.Converters; +using OpenQA.Selenium.BiDi.Json.Converters; using System.Text.Json.Serialization; namespace OpenQA.Selenium.BiDi.Script; diff --git a/dotnet/src/webdriver/BiDi/Script/RemoteValue.cs b/dotnet/src/webdriver/BiDi/Script/RemoteValue.cs index ec45b047c6ba6..af66335413c3c 100644 --- a/dotnet/src/webdriver/BiDi/Script/RemoteValue.cs +++ b/dotnet/src/webdriver/BiDi/Script/RemoteValue.cs @@ -17,8 +17,8 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication.Json.Converters; -using OpenQA.Selenium.BiDi.Communication.Json.Converters.Polymorphic; +using OpenQA.Selenium.BiDi.Json.Converters; +using OpenQA.Selenium.BiDi.Json.Converters.Polymorphic; using System; using System.Collections.Generic; using System.Numerics; diff --git a/dotnet/src/webdriver/BiDi/Script/RemovePreloadScriptCommand.cs b/dotnet/src/webdriver/BiDi/Script/RemovePreloadScriptCommand.cs index 14fa1068ac8a9..353c1c9c9dc83 100644 --- a/dotnet/src/webdriver/BiDi/Script/RemovePreloadScriptCommand.cs +++ b/dotnet/src/webdriver/BiDi/Script/RemovePreloadScriptCommand.cs @@ -17,8 +17,6 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication; - namespace OpenQA.Selenium.BiDi.Script; internal sealed class RemovePreloadScriptCommand(RemovePreloadScriptParameters @params) diff --git a/dotnet/src/webdriver/BiDi/Script/ResultOwnership.cs b/dotnet/src/webdriver/BiDi/Script/ResultOwnership.cs index 39bf31735f03d..56b5ac79e855b 100644 --- a/dotnet/src/webdriver/BiDi/Script/ResultOwnership.cs +++ b/dotnet/src/webdriver/BiDi/Script/ResultOwnership.cs @@ -17,7 +17,7 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication.Json.Converters; +using OpenQA.Selenium.BiDi.Json.Converters; using System.Text.Json.Serialization; namespace OpenQA.Selenium.BiDi.Script; diff --git a/dotnet/src/webdriver/BiDi/Script/ScriptModule.cs b/dotnet/src/webdriver/BiDi/Script/ScriptModule.cs index 6867941312362..84be58f672529 100644 --- a/dotnet/src/webdriver/BiDi/Script/ScriptModule.cs +++ b/dotnet/src/webdriver/BiDi/Script/ScriptModule.cs @@ -17,7 +17,6 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication; using System; using System.Collections.Generic; using System.Threading.Tasks; diff --git a/dotnet/src/webdriver/BiDi/Script/SerializationOptions.cs b/dotnet/src/webdriver/BiDi/Script/SerializationOptions.cs index f34c602f799d8..c3cf19eaf379a 100644 --- a/dotnet/src/webdriver/BiDi/Script/SerializationOptions.cs +++ b/dotnet/src/webdriver/BiDi/Script/SerializationOptions.cs @@ -17,7 +17,7 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication.Json.Converters; +using OpenQA.Selenium.BiDi.Json.Converters; using System.Text.Json.Serialization; namespace OpenQA.Selenium.BiDi.Script; diff --git a/dotnet/src/webdriver/BiDi/Session/EndCommand.cs b/dotnet/src/webdriver/BiDi/Session/EndCommand.cs index 02001e2fb23f8..5576c6257c18b 100644 --- a/dotnet/src/webdriver/BiDi/Session/EndCommand.cs +++ b/dotnet/src/webdriver/BiDi/Session/EndCommand.cs @@ -17,8 +17,6 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication; - namespace OpenQA.Selenium.BiDi.Session; internal sealed class EndCommand() diff --git a/dotnet/src/webdriver/BiDi/Session/NewCommand.cs b/dotnet/src/webdriver/BiDi/Session/NewCommand.cs index 06d509539a04b..dab6bcc39da90 100644 --- a/dotnet/src/webdriver/BiDi/Session/NewCommand.cs +++ b/dotnet/src/webdriver/BiDi/Session/NewCommand.cs @@ -17,8 +17,6 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication; - namespace OpenQA.Selenium.BiDi.Session; internal sealed class NewCommand(NewParameters @params) diff --git a/dotnet/src/webdriver/BiDi/Session/SessionModule.cs b/dotnet/src/webdriver/BiDi/Session/SessionModule.cs index b545d51f6d441..aa61ee6cfd23b 100644 --- a/dotnet/src/webdriver/BiDi/Session/SessionModule.cs +++ b/dotnet/src/webdriver/BiDi/Session/SessionModule.cs @@ -17,7 +17,6 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication; using System.Collections.Generic; using System.Threading.Tasks; diff --git a/dotnet/src/webdriver/BiDi/Session/StatusCommand.cs b/dotnet/src/webdriver/BiDi/Session/StatusCommand.cs index 54f1865554007..6ba3045b04976 100644 --- a/dotnet/src/webdriver/BiDi/Session/StatusCommand.cs +++ b/dotnet/src/webdriver/BiDi/Session/StatusCommand.cs @@ -17,8 +17,6 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication; - namespace OpenQA.Selenium.BiDi.Session; internal sealed class StatusCommand() diff --git a/dotnet/src/webdriver/BiDi/Session/SubscribeCommand.cs b/dotnet/src/webdriver/BiDi/Session/SubscribeCommand.cs index a4982b7427306..8336fab962053 100644 --- a/dotnet/src/webdriver/BiDi/Session/SubscribeCommand.cs +++ b/dotnet/src/webdriver/BiDi/Session/SubscribeCommand.cs @@ -17,7 +17,6 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication; using System.Collections.Generic; namespace OpenQA.Selenium.BiDi.Session; diff --git a/dotnet/src/webdriver/BiDi/Session/Subscription.cs b/dotnet/src/webdriver/BiDi/Session/Subscription.cs index 7f9899581f556..ccf7b30215a3b 100644 --- a/dotnet/src/webdriver/BiDi/Session/Subscription.cs +++ b/dotnet/src/webdriver/BiDi/Session/Subscription.cs @@ -17,7 +17,7 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication.Json.Converters; +using OpenQA.Selenium.BiDi.Json.Converters; using System.Text.Json.Serialization; namespace OpenQA.Selenium.BiDi.Session; diff --git a/dotnet/src/webdriver/BiDi/Session/UnsubscribeCommand.cs b/dotnet/src/webdriver/BiDi/Session/UnsubscribeCommand.cs index 2978260b266f8..24b48fbe7e04c 100644 --- a/dotnet/src/webdriver/BiDi/Session/UnsubscribeCommand.cs +++ b/dotnet/src/webdriver/BiDi/Session/UnsubscribeCommand.cs @@ -17,7 +17,6 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication; using System.Collections.Generic; namespace OpenQA.Selenium.BiDi.Session; diff --git a/dotnet/src/webdriver/BiDi/Session/UserPromptHandler.cs b/dotnet/src/webdriver/BiDi/Session/UserPromptHandler.cs index c4b051e4c30f4..7ec257c8966ce 100644 --- a/dotnet/src/webdriver/BiDi/Session/UserPromptHandler.cs +++ b/dotnet/src/webdriver/BiDi/Session/UserPromptHandler.cs @@ -17,7 +17,7 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication.Json.Converters; +using OpenQA.Selenium.BiDi.Json.Converters; using System.Text.Json.Serialization; namespace OpenQA.Selenium.BiDi.Session; diff --git a/dotnet/src/webdriver/BiDi/Storage/DeleteCookiesCommand.cs b/dotnet/src/webdriver/BiDi/Storage/DeleteCookiesCommand.cs index 31adb809f6e72..a7ed29c57bfb3 100644 --- a/dotnet/src/webdriver/BiDi/Storage/DeleteCookiesCommand.cs +++ b/dotnet/src/webdriver/BiDi/Storage/DeleteCookiesCommand.cs @@ -17,8 +17,6 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication; - namespace OpenQA.Selenium.BiDi.Storage; internal sealed class DeleteCookiesCommand(DeleteCookiesParameters @params) diff --git a/dotnet/src/webdriver/BiDi/Storage/GetCookiesCommand.cs b/dotnet/src/webdriver/BiDi/Storage/GetCookiesCommand.cs index e8337e784de86..6cf8eb112359b 100644 --- a/dotnet/src/webdriver/BiDi/Storage/GetCookiesCommand.cs +++ b/dotnet/src/webdriver/BiDi/Storage/GetCookiesCommand.cs @@ -17,7 +17,6 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication; using System; using System.Collections.Generic; using System.Text.Json.Serialization; diff --git a/dotnet/src/webdriver/BiDi/Storage/SetCookieCommand.cs b/dotnet/src/webdriver/BiDi/Storage/SetCookieCommand.cs index 635faa93e381a..74b3f9d7dfdd7 100644 --- a/dotnet/src/webdriver/BiDi/Storage/SetCookieCommand.cs +++ b/dotnet/src/webdriver/BiDi/Storage/SetCookieCommand.cs @@ -17,8 +17,7 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication; -using OpenQA.Selenium.BiDi.Communication.Json.Converters; +using OpenQA.Selenium.BiDi.Json.Converters; using System; using System.Text.Json.Serialization; diff --git a/dotnet/src/webdriver/BiDi/Storage/StorageModule.cs b/dotnet/src/webdriver/BiDi/Storage/StorageModule.cs index 3e71db576c760..cf17d11332bc0 100644 --- a/dotnet/src/webdriver/BiDi/Storage/StorageModule.cs +++ b/dotnet/src/webdriver/BiDi/Storage/StorageModule.cs @@ -17,7 +17,6 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication; using System.Threading.Tasks; namespace OpenQA.Selenium.BiDi.Storage; diff --git a/dotnet/src/webdriver/BiDi/Subscription.cs b/dotnet/src/webdriver/BiDi/Subscription.cs index 2e9583833a8eb..80fa4b8e03050 100644 --- a/dotnet/src/webdriver/BiDi/Subscription.cs +++ b/dotnet/src/webdriver/BiDi/Subscription.cs @@ -17,7 +17,6 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication; using System; using System.Collections.Generic; using System.Threading.Tasks; @@ -26,20 +25,22 @@ namespace OpenQA.Selenium.BiDi; public class Subscription : IAsyncDisposable { - private readonly Session.Subscription _subscription; private readonly Broker _broker; - private readonly Communication.EventHandler _eventHandler; - internal Subscription(Session.Subscription subscription, Broker broker, Communication.EventHandler eventHandler) + internal Subscription(Session.Subscription subscription, Broker broker, EventHandler eventHandler) { - _subscription = subscription; + SubscriptionId = subscription; _broker = broker; - _eventHandler = eventHandler; + EventHandler = eventHandler; } + internal Session.Subscription SubscriptionId { get; } + + internal EventHandler EventHandler { get; } + public async Task UnsubscribeAsync() { - await _broker.UnsubscribeAsync(_subscription, _eventHandler).ConfigureAwait(false); + await _broker.UnsubscribeAsync(this).ConfigureAwait(false); } public async ValueTask DisposeAsync() diff --git a/dotnet/src/webdriver/BiDi/WebExtension/InstallCommand.cs b/dotnet/src/webdriver/BiDi/WebExtension/InstallCommand.cs index 8027787d72eec..d7c4e29d3d756 100644 --- a/dotnet/src/webdriver/BiDi/WebExtension/InstallCommand.cs +++ b/dotnet/src/webdriver/BiDi/WebExtension/InstallCommand.cs @@ -17,7 +17,6 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication; using System; using System.Text.Json.Serialization; diff --git a/dotnet/src/webdriver/BiDi/WebExtension/UninstallCommand.cs b/dotnet/src/webdriver/BiDi/WebExtension/UninstallCommand.cs index e28dd8a767c24..824bc09ec84c6 100644 --- a/dotnet/src/webdriver/BiDi/WebExtension/UninstallCommand.cs +++ b/dotnet/src/webdriver/BiDi/WebExtension/UninstallCommand.cs @@ -17,8 +17,6 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication; - namespace OpenQA.Selenium.BiDi.WebExtension; internal sealed class UninstallCommand(UninstallParameters @params) diff --git a/dotnet/src/webdriver/BiDi/WebExtension/WebExtensionModule.cs b/dotnet/src/webdriver/BiDi/WebExtension/WebExtensionModule.cs index 8432ccc36bd01..365d6e18eb860 100644 --- a/dotnet/src/webdriver/BiDi/WebExtension/WebExtensionModule.cs +++ b/dotnet/src/webdriver/BiDi/WebExtension/WebExtensionModule.cs @@ -17,7 +17,6 @@ // under the License. // -using OpenQA.Selenium.BiDi.Communication; using System.Threading.Tasks; namespace OpenQA.Selenium.BiDi.WebExtension; diff --git a/dotnet/src/webdriver/BiDi/Communication/Transport/WebSocketTransport.cs b/dotnet/src/webdriver/BiDi/WebSocketTransport.cs similarity index 98% rename from dotnet/src/webdriver/BiDi/Communication/Transport/WebSocketTransport.cs rename to dotnet/src/webdriver/BiDi/WebSocketTransport.cs index f18e630ca8b16..c64d4a0f79a15 100644 --- a/dotnet/src/webdriver/BiDi/Communication/Transport/WebSocketTransport.cs +++ b/dotnet/src/webdriver/BiDi/WebSocketTransport.cs @@ -17,15 +17,15 @@ // under the License. // +using OpenQA.Selenium.Internal.Logging; using System; using System.IO; using System.Net.WebSockets; -using System.Threading.Tasks; -using System.Threading; using System.Text; -using OpenQA.Selenium.Internal.Logging; +using System.Threading; +using System.Threading.Tasks; -namespace OpenQA.Selenium.BiDi.Communication.Transport; +namespace OpenQA.Selenium.BiDi; class WebSocketTransport(Uri _uri) : ITransport, IDisposable {