From 124bd4c2c03874f5b4de241e3d89ac95f6048b9a Mon Sep 17 00:00:00 2001 From: BaronGreenback Date: Sat, 21 Nov 2020 12:59:14 +0000 Subject: Networking: 1 - Network Manager (#4124) * NetworkManager * Config file with additional options. * Update Jellyfin.Networking/Manager/INetworkManager.cs Co-authored-by: Cody Robibero * Update Jellyfin.Networking/Manager/INetworkManager.cs Co-authored-by: Cody Robibero * Update MediaBrowser.Model/Configuration/ServerConfiguration.cs Co-authored-by: Cody Robibero * Update MediaBrowser.Model/Configuration/ServerConfiguration.cs Co-authored-by: Cody Robibero * Update MediaBrowser.Model/Configuration/ServerConfiguration.cs Co-authored-by: Cody Robibero * Update Jellyfin.Networking/Manager/NetworkManager.cs Co-authored-by: Cody Robibero * Split function. * Update Jellyfin.Networking/Manager/INetworkManager.cs Co-authored-by: Cody Robibero * fixed iterations * Update Jellyfin.Networking.csproj * Update NetworkManager.cs * Updated to NetCollection 1.03. * Update ServerConfiguration.cs * Update StartupController.cs * Update INetworkManager.cs Removed public * Update INetworkManager.cs * Update Jellyfin.Networking/Manager/NetworkManager.cs Co-authored-by: Claus Vium * Updated comment * Update Jellyfin.Networking/Manager/NetworkManager.cs Co-authored-by: Claus Vium * Update Jellyfin.Networking/Manager/NetworkManager.cs Co-authored-by: Claus Vium * Update Jellyfin.Networking/Manager/NetworkManager.cs Co-authored-by: Claus Vium * Update Jellyfin.Networking/Manager/NetworkManager.cs Co-authored-by: Claus Vium * Update Jellyfin.Networking/Manager/INetworkManager.cs Co-authored-by: Claus Vium * Remove mono code. Removed forced chromecast option * Inverted if * Update Jellyfin.Networking/Manager/NetworkManager.cs Co-authored-by: Cody Robibero * Update Jellyfin.Networking/Manager/NetworkManager.cs Co-authored-by: Cody Robibero * Update Jellyfin.Networking/Manager/NetworkManager.cs Co-authored-by: Cody Robibero * Update Jellyfin.Networking/Manager/NetworkManager.cs Co-authored-by: Cody Robibero * Update Jellyfin.Networking/Manager/NetworkManager.cs Co-authored-by: Cody Robibero * Update Jellyfin.Networking/Manager/NetworkManager.cs Co-authored-by: Cody Robibero * Moved config into a separate container * Update Jellyfin.Networking/Manager/NetworkManager.cs Co-authored-by: Cody Robibero * Changed sortedList to dictionary. * Update INetworkManager.cs Changed UpdateSettings param type * Update NetworkManager.cs * Update NetworkManager.cs * Update NetworkManager.cs * Update NetworkConfiguration.cs * Update INetworkManager.cs * Update Jellyfin.Networking/Manager/NetworkManager.cs Co-authored-by: Claus Vium * Update Jellyfin.Networking/Manager/NetworkManager.cs Co-authored-by: Claus Vium * Update MediaBrowser.Model/Configuration/ServerConfiguration.cs Co-authored-by: Cody Robibero * Update MediaBrowser.Model/Configuration/ServerConfiguration.cs Co-authored-by: Cody Robibero * Updated changes github didn't update. * Fixed compilation. * Update Jellyfin.Networking/Manager/NetworkManager.cs Co-authored-by: Cody Robibero * Update Jellyfin.Networking/Manager/NetworkManager.cs Co-authored-by: Cody Robibero * Update Jellyfin.Networking/Manager/NetworkManager.cs Co-authored-by: Cody Robibero * Removed read locking. * Update NetworkManager.cs Changed configuration event to NamedConfigurationUpdated * updated comment * removed whitespace * Updated NetCollection to 1.0.6 Updated DXCopAnalyser to 3.3.1 * removed NetCollection * Update NetworkManager.cs * Update NetworkExtensions.cs * Update NetworkExtensions.cs Removed function. * Update NetworkExtensions.cs * Update NetworkManager.cs Changed ToString() to AsString() as native collection formats incorrectly. * Update Jellyfin.Networking/Manager/NetworkManager.cs Co-authored-by: Cody Robibero * Update NetworkExtensions.cs * Update Jellyfin.Networking/Configuration/NetworkConfiguration.cs Co-authored-by: h1dden-da3m0n <33120068+h1dden-da3m0n@users.noreply.github.com> * Update Jellyfin.Networking/Manager/NetworkManager.cs Co-authored-by: h1dden-da3m0n <33120068+h1dden-da3m0n@users.noreply.github.com> * Update Jellyfin.Networking/Configuration/NetworkConfiguration.cs Co-authored-by: h1dden-da3m0n <33120068+h1dden-da3m0n@users.noreply.github.com> * Update Jellyfin.Networking/Configuration/NetworkConfiguration.cs Co-authored-by: h1dden-da3m0n <33120068+h1dden-da3m0n@users.noreply.github.com> * Update MediaBrowser.Common/Net/IPObject.cs Co-authored-by: h1dden-da3m0n <33120068+h1dden-da3m0n@users.noreply.github.com> * updated * Replaced NetCollection with Collection * Update MediaBrowser.Common/Net/NetworkExtensions.cs Co-authored-by: Cody Robibero * Update MediaBrowser.Model/Configuration/PathSubstitution.cs Co-authored-by: Cody Robibero * Update MediaBrowser.Common/Net/NetworkExtensions.cs Co-authored-by: Cody Robibero * Update Jellyfin.Networking/Manager/NetworkManager.cs Co-authored-by: Cody Robibero * Update Jellyfin.Networking/Manager/NetworkManager.cs Co-authored-by: Cody Robibero * Update Jellyfin.Networking/Manager/NetworkManager.cs Co-authored-by: Cody Robibero * Update Jellyfin.Networking/Manager/NetworkManager.cs Co-authored-by: Cody Robibero * Update Jellyfin.Networking/Manager/NetworkManager.cs Co-authored-by: Cody Robibero * Update MediaBrowser.Common/Net/IPObject.cs Co-authored-by: Cody Robibero * Update MediaBrowser.Common/Net/IPObject.cs Co-authored-by: Cody Robibero * Update MediaBrowser.Common/Net/IPObject.cs Co-authored-by: Cody Robibero * Update MediaBrowser.Common/Net/IPHost.cs Co-authored-by: Cody Robibero * Update MediaBrowser.Common/Net/IPHost.cs Co-authored-by: Cody Robibero * Update MediaBrowser.Common/Net/IPHost.cs Co-authored-by: Cody Robibero * Update MediaBrowser.Common/Net/IPHost.cs Co-authored-by: Cody Robibero * Update MediaBrowser.Common/Net/IPHost.cs Co-authored-by: Cody Robibero * Update MediaBrowser.Common/Net/IPHost.cs Co-authored-by: Cody Robibero * Update Jellyfin.Networking/Manager/NetworkManager.cs Co-authored-by: Cody Robibero * Update Jellyfin.Networking/Manager/NetworkManager.cs Co-authored-by: Cody Robibero * Update MediaBrowser.Common/Net/IPHost.cs Co-authored-by: Cody Robibero * Update MediaBrowser.Common/Net/IPObject.cs Co-authored-by: Cody Robibero * Update MediaBrowser.Common/Net/IPObject.cs Co-authored-by: Cody Robibero * updated comments. * Updated comments / changes as suggested by @crobibero. * Split function as suggested * Fixed null ref. * Updated comment. * Updated cs to .net5 * Fixed issue with PublishedServerUrl * Fixes * Update Jellyfin.Networking/Manager/NetworkManager.cs Co-authored-by: Claus Vium * Restored locking * optimisation * Added comment * updates. * updated. * updates * updated. * Update IPHost.cs * Update Jellyfin.Networking/Manager/NetworkManager.cs Co-authored-by: Claus Vium * Update NetworkManager.cs * Removed whitespace. * Added debug logging * Added debug. * Update Jellyfin.Networking/Manager/NetworkManager.cs Co-authored-by: Bond-009 * Replaced GetAddressBytes Co-authored-by: Cody Robibero Co-authored-by: Claus Vium Co-authored-by: h1dden-da3m0n <33120068+h1dden-da3m0n@users.noreply.github.com> Co-authored-by: Bond-009 --- .../Configuration/NetworkConfigurationExtensions.cs | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) create mode 100644 Jellyfin.Networking/Configuration/NetworkConfigurationExtensions.cs (limited to 'Jellyfin.Networking/Configuration/NetworkConfigurationExtensions.cs') diff --git a/Jellyfin.Networking/Configuration/NetworkConfigurationExtensions.cs b/Jellyfin.Networking/Configuration/NetworkConfigurationExtensions.cs new file mode 100644 index 000000000..e77b17ba9 --- /dev/null +++ b/Jellyfin.Networking/Configuration/NetworkConfigurationExtensions.cs @@ -0,0 +1,21 @@ +using Jellyfin.Networking.Configuration; +using MediaBrowser.Common.Configuration; + +namespace Jellyfin.Networking.Configuration +{ + /// + /// Defines the . + /// + public static class NetworkConfigurationExtensions + { + /// + /// Retrieves the network configuration. + /// + /// The . + /// The . + public static NetworkConfiguration GetNetworkConfiguration(this IConfigurationManager config) + { + return config.GetConfiguration("network"); + } + } +} -- cgit v1.2.3