public abstract System.Net.IPEndPoint[] GetActiveUdpListeners();
public abstract System.Net.NetworkInformation.IcmpV4Statistics GetIcmpV4Statistics();
public abstract System.Net.NetworkInformation.IcmpV6Statistics GetIcmpV6Statistics();
+ [System.Runtime.Versioning.UnsupportedOSPlatform("illumos")]
+ [System.Runtime.Versioning.UnsupportedOSPlatform("solaris")]
public static System.Net.NetworkInformation.IPGlobalProperties GetIPGlobalProperties() { throw null; }
public abstract System.Net.NetworkInformation.IPGlobalStatistics GetIPv4GlobalStatistics();
public abstract System.Net.NetworkInformation.IPGlobalStatistics GetIPv6GlobalStatistics();
public virtual System.Net.NetworkInformation.OperationalStatus OperationalStatus { get { throw null; } }
public virtual long Speed { get { throw null; } }
public virtual bool SupportsMulticast { get { throw null; } }
+ [System.Runtime.Versioning.UnsupportedOSPlatform("illumos")]
+ [System.Runtime.Versioning.UnsupportedOSPlatform("solaris")]
public static System.Net.NetworkInformation.NetworkInterface[] GetAllNetworkInterfaces() { throw null; }
public virtual System.Net.NetworkInformation.IPInterfaceProperties GetIPProperties() { throw null; }
public virtual System.Net.NetworkInformation.IPInterfaceStatistics GetIPStatistics() { throw null; }
public virtual System.Net.NetworkInformation.IPv4InterfaceStatistics GetIPv4Statistics() { throw null; }
+ [System.Runtime.Versioning.UnsupportedOSPlatform("illumos")]
+ [System.Runtime.Versioning.UnsupportedOSPlatform("solaris")]
public static bool GetIsNetworkAvailable() { throw null; }
public virtual System.Net.NetworkInformation.PhysicalAddress GetPhysicalAddress() { throw null; }
public virtual bool Supports(System.Net.NetworkInformation.NetworkInterfaceComponent networkInterfaceComponent) { throw null; }
<Compile Include="System\Net\NetworkInformation\NetworkAddressChange.UnknownUnix.cs" />
</ItemGroup>
<ItemGroup>
+ <SupportedPlatform Include="illumos"/>
+ <SupportedPlatform Include="Solaris "/>
+ </ItemGroup>
+ <ItemGroup>
<Reference Include="Microsoft.Win32.Primitives" />
<Reference Include="System.Collections" />
<Reference Include="System.Diagnostics.Tracing" />
// Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
+using System.Runtime.Versioning;
+
namespace System.Net.NetworkInformation
{
internal sealed class BsdIPGlobalProperties : UnixIPGlobalProperties
return new BsdIPv4GlobalStatistics();
}
+ [UnsupportedOSPlatform("osx")]
+ [UnsupportedOSPlatform("ios")]
+ [UnsupportedOSPlatform("tvos")]
+ [UnsupportedOSPlatform("freebsd")]
public override IPGlobalStatistics GetIPv6GlobalStatistics()
{
// Although there is a 'net.inet6.ip6.stats' sysctl variable, there
using System.Collections.Generic;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
+using System.Runtime.Versioning;
namespace System.Net.NetworkInformation
{
public override long OutputPacketRequests { get { return _outboundPackets; } }
+ [UnsupportedOSPlatform("osx")]
+ [UnsupportedOSPlatform("ios")]
+ [UnsupportedOSPlatform("tvos")]
+ [UnsupportedOSPlatform("freebsd")]
public override long OutputPacketRoutingDiscards { get { throw new PlatformNotSupportedException(SR.net_InformationUnavailableOnPlatform); } }
+ [UnsupportedOSPlatform("osx")]
+ [UnsupportedOSPlatform("ios")]
+ [UnsupportedOSPlatform("tvos")]
+ [UnsupportedOSPlatform("freebsd")]
public override long OutputPacketsDiscarded { get { throw new PlatformNotSupportedException(SR.net_InformationUnavailableOnPlatform); } }
public override long OutputPacketsWithNoRoute { get { return _outputPacketsNoRoute; } }
+ [UnsupportedOSPlatform("osx")]
+ [UnsupportedOSPlatform("ios")]
+ [UnsupportedOSPlatform("tvos")]
+ [UnsupportedOSPlatform("freebsd")]
public override long PacketFragmentFailures { get { throw new PlatformNotSupportedException(SR.net_InformationUnavailableOnPlatform); } }
+ [UnsupportedOSPlatform("osx")]
+ [UnsupportedOSPlatform("ios")]
+ [UnsupportedOSPlatform("tvos")]
+ [UnsupportedOSPlatform("freebsd")]
public override long PacketReassembliesRequired { get { throw new PlatformNotSupportedException(SR.net_InformationUnavailableOnPlatform); } }
public override long PacketReassemblyFailures { get { return _cantFrags; } }
+ [UnsupportedOSPlatform("osx")]
+ [UnsupportedOSPlatform("ios")]
+ [UnsupportedOSPlatform("tvos")]
+ [UnsupportedOSPlatform("freebsd")]
public override long PacketReassemblyTimeout { get { throw new PlatformNotSupportedException(SR.net_InformationUnavailableOnPlatform); } }
public override long PacketsFragmented { get { return _datagramsFragmented; } }
// Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
+using System.Runtime.Versioning;
+
namespace System.Net.NetworkInformation
{
internal sealed class BsdIPv4InterfaceProperties : UnixIPv4InterfaceProperties
_mtu = mtu;
}
+ [UnsupportedOSPlatform("osx")]
+ [UnsupportedOSPlatform("ios")]
+ [UnsupportedOSPlatform("tvos")]
+ [UnsupportedOSPlatform("freebsd")]
public override bool IsAutomaticPrivateAddressingActive { get { throw new PlatformNotSupportedException(SR.net_InformationUnavailableOnPlatform); } }
+ [UnsupportedOSPlatform("osx")]
+ [UnsupportedOSPlatform("ios")]
+ [UnsupportedOSPlatform("tvos")]
+ [UnsupportedOSPlatform("freebsd")]
public override bool IsAutomaticPrivateAddressingEnabled { get { throw new PlatformNotSupportedException(SR.net_InformationUnavailableOnPlatform); } }
+ [UnsupportedOSPlatform("osx")]
+ [UnsupportedOSPlatform("ios")]
+ [UnsupportedOSPlatform("tvos")]
+ [UnsupportedOSPlatform("freebsd")]
public override bool IsDhcpEnabled { get { throw new PlatformNotSupportedException(SR.net_InformationUnavailableOnPlatform); } }
// Doesn't seem to be exposed on a per-interface basis.
+ [UnsupportedOSPlatform("osx")]
+ [UnsupportedOSPlatform("ios")]
+ [UnsupportedOSPlatform("tvos")]
+ [UnsupportedOSPlatform("freebsd")]
public override bool IsForwardingEnabled { get { throw new PlatformNotSupportedException(SR.net_InformationUnavailableOnPlatform); } }
public override int Mtu { get { return _mtu; } }
+ [UnsupportedOSPlatform("osx")]
+ [UnsupportedOSPlatform("ios")]
+ [UnsupportedOSPlatform("tvos")]
+ [UnsupportedOSPlatform("freebsd")]
public override bool UsesWins { get { throw new PlatformNotSupportedException(SR.net_InformationUnavailableOnPlatform); } }
}
}
// Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
+using System.Runtime.Versioning;
+
namespace System.Net.NetworkInformation
{
internal sealed class BsdIPv4InterfaceStatistics : IPv4InterfaceStatistics
public override long NonUnicastPacketsSent => _statistics.NonUnicastPacketsSent;
+ [UnsupportedOSPlatform("osx")]
+ [UnsupportedOSPlatform("ios")]
+ [UnsupportedOSPlatform("tvos")]
+ [UnsupportedOSPlatform("freebsd")]
public override long OutgoingPacketsDiscarded => _statistics.OutgoingPacketsDiscarded;
public override long OutgoingPacketsWithErrors => _statistics.OutgoingPacketsWithErrors;
// Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
+using System.Runtime.Versioning;
+
namespace System.Net.NetworkInformation
{
internal sealed class BsdIPv6InterfaceProperties : UnixIPv6InterfaceProperties
public override int Mtu { get { return _mtu; } }
+ [UnsupportedOSPlatform("osx")]
+ [UnsupportedOSPlatform("ios")]
+ [UnsupportedOSPlatform("tvos")]
+ [UnsupportedOSPlatform("freebsd")]
public override long GetScopeId(ScopeLevel scopeLevel)
{
throw new PlatformNotSupportedException(SR.net_InformationUnavailableOnPlatform);
// Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
+using System.Runtime.Versioning;
+
namespace System.Net.NetworkInformation
{
internal sealed class BsdIcmpV4Statistics : IcmpV4Statistics
public override long EchoRequestsSent { get { return _echoRequestsSent; } }
+ [UnsupportedOSPlatform("osx")]
+ [UnsupportedOSPlatform("ios")]
+ [UnsupportedOSPlatform("tvos")]
+ [UnsupportedOSPlatform("freebsd")]
public override long ErrorsReceived { get { throw new PlatformNotSupportedException(); } }
+ [UnsupportedOSPlatform("osx")]
+ [UnsupportedOSPlatform("ios")]
+ [UnsupportedOSPlatform("tvos")]
+ [UnsupportedOSPlatform("freebsd")]
public override long ErrorsSent { get { throw new PlatformNotSupportedException(); } }
+ [UnsupportedOSPlatform("osx")]
+ [UnsupportedOSPlatform("ios")]
+ [UnsupportedOSPlatform("tvos")]
+ [UnsupportedOSPlatform("freebsd")]
public override long MessagesReceived { get { throw new PlatformNotSupportedException(); } }
+ [UnsupportedOSPlatform("osx")]
+ [UnsupportedOSPlatform("ios")]
+ [UnsupportedOSPlatform("tvos")]
+ [UnsupportedOSPlatform("freebsd")]
public override long MessagesSent { get { throw new PlatformNotSupportedException(); } }
public override long ParameterProblemsReceived { get { return _parameterProblemsReceived; } }
// Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
+using System.Runtime.Versioning;
+
namespace System.Net.NetworkInformation
{
internal sealed class BsdIcmpV6Statistics : IcmpV6Statistics
public override long EchoRequestsSent { get { return _echoRequestsSent; } }
+ [UnsupportedOSPlatform("osx")]
+ [UnsupportedOSPlatform("ios")]
+ [UnsupportedOSPlatform("tvos")]
+ [UnsupportedOSPlatform("freebsd")]
public override long ErrorsReceived { get { throw new PlatformNotSupportedException(); } }
+ [UnsupportedOSPlatform("osx")]
+ [UnsupportedOSPlatform("ios")]
+ [UnsupportedOSPlatform("tvos")]
+ [UnsupportedOSPlatform("freebsd")]
public override long ErrorsSent { get { throw new PlatformNotSupportedException(); } }
+ [UnsupportedOSPlatform("osx")]
+ [UnsupportedOSPlatform("ios")]
+ [UnsupportedOSPlatform("tvos")]
+ [UnsupportedOSPlatform("freebsd")]
public override long MessagesReceived { get { throw new PlatformNotSupportedException(); } }
+ [UnsupportedOSPlatform("osx")]
+ [UnsupportedOSPlatform("ios")]
+ [UnsupportedOSPlatform("tvos")]
+ [UnsupportedOSPlatform("freebsd")]
public override long MessagesSent { get { throw new PlatformNotSupportedException(); } }
public override long ParameterProblemsReceived { get { return _parameterProblemsReceived; } }
using System.Collections.Generic;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
+using System.Runtime.Versioning;
namespace System.Net.NetworkInformation
{
_gatewayAddresses = GetGatewayAddresses(oni.Index);
}
+ [UnsupportedOSPlatform("osx")]
+ [UnsupportedOSPlatform("ios")]
+ [UnsupportedOSPlatform("tvos")]
+ [UnsupportedOSPlatform("freebsd")]
public override IPAddressInformationCollection AnycastAddresses { get { throw new PlatformNotSupportedException(SR.net_InformationUnavailableOnPlatform); } }
+ [UnsupportedOSPlatform("osx")]
+ [UnsupportedOSPlatform("ios")]
+ [UnsupportedOSPlatform("tvos")]
+ [UnsupportedOSPlatform("freebsd")]
public override IPAddressCollection DhcpServerAddresses { get { throw new PlatformNotSupportedException(SR.net_InformationUnavailableOnPlatform); } }
public override GatewayIPAddressInformationCollection GatewayAddresses { get { return _gatewayAddresses; } }
+ [UnsupportedOSPlatform("osx")]
+ [UnsupportedOSPlatform("ios")]
+ [UnsupportedOSPlatform("tvos")]
+ [UnsupportedOSPlatform("freebsd")]
public override bool IsDnsEnabled { get { throw new PlatformNotSupportedException(SR.net_InformationUnavailableOnPlatform); } }
+ [UnsupportedOSPlatform("osx")]
+ [UnsupportedOSPlatform("ios")]
+ [UnsupportedOSPlatform("tvos")]
+ [UnsupportedOSPlatform("freebsd")]
public override bool IsDynamicDnsEnabled { get { throw new PlatformNotSupportedException(SR.net_InformationUnavailableOnPlatform); } }
+ [UnsupportedOSPlatform("osx")]
+ [UnsupportedOSPlatform("ios")]
+ [UnsupportedOSPlatform("tvos")]
+ [UnsupportedOSPlatform("freebsd")]
public override IPAddressCollection WinsServersAddresses { get { throw new PlatformNotSupportedException(SR.net_InformationUnavailableOnPlatform); } }
public override IPv4InterfaceProperties GetIPv4Properties()
// Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
+using System.Runtime.Versioning;
+
namespace System.Net.NetworkInformation
{
internal sealed class BsdIpInterfaceStatistics : IPInterfaceStatistics
public override long NonUnicastPacketsSent { get { return _outNonUnicastPackets; } }
+ [UnsupportedOSPlatform("osx")]
+ [UnsupportedOSPlatform("ios")]
+ [UnsupportedOSPlatform("tvos")]
+ [UnsupportedOSPlatform("freebsd")]
public override long OutgoingPacketsDiscarded { get { throw new PlatformNotSupportedException(SR.net_InformationUnavailableOnPlatform); } }
public override long OutgoingPacketsWithErrors { get { return _outErrors; } }
// Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
+using System.Runtime.Versioning;
+
namespace System.Net.NetworkInformation
{
internal sealed class BsdTcpStatistics : TcpStatistics
public override long FailedConnectionAttempts { get { return _failedConnectionAttempts; } }
+ [UnsupportedOSPlatform("osx")]
+ [UnsupportedOSPlatform("ios")]
+ [UnsupportedOSPlatform("tvos")]
+ [UnsupportedOSPlatform("freebsd")]
public override long MaximumConnections { get { throw new PlatformNotSupportedException(SR.net_InformationUnavailableOnPlatform); } }
+ [UnsupportedOSPlatform("osx")]
+ [UnsupportedOSPlatform("ios")]
+ [UnsupportedOSPlatform("tvos")]
+ [UnsupportedOSPlatform("freebsd")]
public override long MaximumTransmissionTimeout { get { throw new PlatformNotSupportedException(SR.net_InformationUnavailableOnPlatform); } }
+ [UnsupportedOSPlatform("osx")]
+ [UnsupportedOSPlatform("ios")]
+ [UnsupportedOSPlatform("tvos")]
+ [UnsupportedOSPlatform("freebsd")]
public override long MinimumTransmissionTimeout { get { throw new PlatformNotSupportedException(SR.net_InformationUnavailableOnPlatform); } }
+ [UnsupportedOSPlatform("osx")]
+ [UnsupportedOSPlatform("ios")]
+ [UnsupportedOSPlatform("tvos")]
+ [UnsupportedOSPlatform("freebsd")]
public override long ResetConnections { get { throw new PlatformNotSupportedException(SR.net_InformationUnavailableOnPlatform); } }
+ [UnsupportedOSPlatform("osx")]
+ [UnsupportedOSPlatform("ios")]
+ [UnsupportedOSPlatform("tvos")]
+ [UnsupportedOSPlatform("freebsd")]
public override long ResetsSent { get { throw new PlatformNotSupportedException(SR.net_InformationUnavailableOnPlatform); } }
public override long SegmentsReceived { get { return _segmentsReceived; } }
/// </summary>
public abstract class IPGlobalProperties
{
+ [UnsupportedOSPlatform("illumos")]
+ [UnsupportedOSPlatform("solaris")]
public static IPGlobalProperties GetIPGlobalProperties()
{
return IPGlobalPropertiesPal.GetIPGlobalProperties();
// Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
+using System.Runtime.Versioning;
+
namespace System.Net.NetworkInformation
{
internal static class IPGlobalPropertiesPal
{
+ [UnsupportedOSPlatform("illumos")]
+ [UnsupportedOSPlatform("solaris")]
public static IPGlobalProperties GetIPGlobalProperties()
{
throw new PlatformNotSupportedException();
// Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
+using System.Runtime.Versioning;
+
namespace System.Net.NetworkInformation
{
/// <summary>
/// <summary>
/// Gets the number of outgoing packets that were discarded.
/// </summary>
+ [UnsupportedOSPlatform("osx")]
+ [UnsupportedOSPlatform("ios")]
+ [UnsupportedOSPlatform("tvos")]
+ [UnsupportedOSPlatform("freebsd")]
public abstract long OutgoingPacketsDiscarded { get; }
/// <summary>
// Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
+using System.Runtime.Versioning;
+
namespace System.Net.NetworkInformation
{
/// <summary>
public abstract long IncomingUnknownProtocolPackets { get; }
public abstract long NonUnicastPacketsReceived { get; }
public abstract long NonUnicastPacketsSent { get; }
+ [UnsupportedOSPlatform("osx")]
+ [UnsupportedOSPlatform("ios")]
+ [UnsupportedOSPlatform("tvos")]
+ [UnsupportedOSPlatform("freebsd")]
public abstract long OutgoingPacketsDiscarded { get; }
public abstract long OutgoingPacketsWithErrors { get; }
public abstract long OutputQueueLength { get; }
// Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
+using System.Runtime.Versioning;
+
namespace System.Net.NetworkInformation
{
internal sealed class LinuxIPAddressInformation : IPAddressInformation
public override IPAddress Address { get { return _address; } }
+ [UnsupportedOSPlatform("linux")]
public override bool IsDnsEligible { get { throw new PlatformNotSupportedException(SR.net_InformationUnavailableOnPlatform); } }
+ [UnsupportedOSPlatform("linux")]
public override bool IsTransient { get { throw new PlatformNotSupportedException(SR.net_InformationUnavailableOnPlatform); } }
}
}
using System.Diagnostics;
using System.IO;
using System.Runtime.InteropServices;
+using System.Runtime.Versioning;
namespace System.Net.NetworkInformation
{
public override long OutputPacketRequests { get { return _table.OutRequests; } }
+ [UnsupportedOSPlatform("linux")]
public override long OutputPacketRoutingDiscards { get { throw new PlatformNotSupportedException(SR.net_InformationUnavailableOnPlatform); } }
public override long OutputPacketsDiscarded { get { return _table.OutDiscards; } }
using System.Collections.Generic;
using System.IO;
+using System.Runtime.Versioning;
namespace System.Net.NetworkInformation
{
_ipv6Properties = new LinuxIPv6InterfaceProperties(lni);
}
+ [UnsupportedOSPlatform("linux")]
public override bool IsDynamicDnsEnabled { get { throw new PlatformNotSupportedException(SR.net_InformationUnavailableOnPlatform); } }
+ [UnsupportedOSPlatform("linux")]
public override IPAddressInformationCollection AnycastAddresses { get { throw new PlatformNotSupportedException(SR.net_InformationUnavailableOnPlatform); } }
public override GatewayIPAddressInformationCollection GatewayAddresses { get { return _gatewayAddresses; } }
// The .NET Foundation licenses this file to you under the MIT license.
using System.IO;
+using System.Runtime.Versioning;
namespace System.Net.NetworkInformation
{
public override long IncomingPacketsWithErrors { get { return _table.ErrorsReceived; } }
+ [UnsupportedOSPlatform("linux")]
public override long IncomingUnknownProtocolPackets { get { throw new PlatformNotSupportedException(SR.net_InformationUnavailableOnPlatform); } }
public override long NonUnicastPacketsReceived { get { return _table.MulticastFramesReceived; } }
+ [UnsupportedOSPlatform("linux")]
public override long NonUnicastPacketsSent { get { throw new PlatformNotSupportedException(SR.net_InformationUnavailableOnPlatform); } }
public override long OutgoingPacketsDiscarded { get { return _table.OutgoingPacketsDropped; } }
// The .NET Foundation licenses this file to you under the MIT license.
using System.IO;
+using System.Runtime.Versioning;
namespace System.Net.NetworkInformation
{
_isForwardingEnabled = GetIsForwardingEnabled();
}
+ [UnsupportedOSPlatform("linux")]
public override bool IsAutomaticPrivateAddressingActive { get { throw new PlatformNotSupportedException(SR.net_InformationUnavailableOnPlatform); } }
+ [UnsupportedOSPlatform("linux")]
public override bool IsAutomaticPrivateAddressingEnabled { get { throw new PlatformNotSupportedException(SR.net_InformationUnavailableOnPlatform); } }
+ [UnsupportedOSPlatform("linux")]
public override bool IsDhcpEnabled { get { throw new PlatformNotSupportedException(SR.net_InformationUnavailableOnPlatform); } }
public override bool IsForwardingEnabled { get { return _isForwardingEnabled; } }
// Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
+using System.Runtime.Versioning;
+
namespace System.Net.NetworkInformation
{
internal sealed class LinuxIPv4InterfaceStatistics : IPv4InterfaceStatistics
public override long IncomingPacketsWithErrors => _statistics.IncomingPacketsWithErrors;
+ [UnsupportedOSPlatform("linux")]
public override long IncomingUnknownProtocolPackets => _statistics.IncomingUnknownProtocolPackets;
public override long NonUnicastPacketsReceived => _statistics.NonUnicastPacketsReceived;
+ [UnsupportedOSPlatform("linux")]
public override long NonUnicastPacketsSent => _statistics.NonUnicastPacketsSent;
public override long OutgoingPacketsDiscarded => _statistics.OutgoingPacketsDiscarded;
// Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
+using System.Runtime.Versioning;
namespace System.Net.NetworkInformation
{
_currentConnections = StringParsingHelpers.ParseNumSocketConnections(sockstatFile, protoName);
}
+ [UnsupportedOSPlatform("linux")]
public override long ConnectionsAccepted { get { throw new PlatformNotSupportedException(SR.net_InformationUnavailableOnPlatform); } }
+ [UnsupportedOSPlatform("linux")]
public override long ConnectionsInitiated { get { throw new PlatformNotSupportedException(SR.net_InformationUnavailableOnPlatform); } }
+ [UnsupportedOSPlatform("linux")]
public override long CumulativeConnections { get { throw new PlatformNotSupportedException(SR.net_InformationUnavailableOnPlatform); } }
public override long CurrentConnections { get { return _currentConnections; } }
public override long MaximumConnections { get { return _table.MaxConn; } }
+ [UnsupportedOSPlatform("linux")]
public override long MaximumTransmissionTimeout { get { throw new PlatformNotSupportedException(SR.net_InformationUnavailableOnPlatform); } }
+ [UnsupportedOSPlatform("linux")]
public override long MinimumTransmissionTimeout { get { throw new PlatformNotSupportedException(SR.net_InformationUnavailableOnPlatform); } }
public override long ResetConnections { get { return _table.EstabResets; } }
+ [UnsupportedOSPlatform("linux")]
public override long ResetsSent { get { throw new PlatformNotSupportedException(SR.net_InformationUnavailableOnPlatform); } }
public override long SegmentsReceived { get { return _table.InSegs; } }
// The .NET Foundation licenses this file to you under the MIT license.
using System.IO;
+using System.Runtime.Versioning;
namespace System.Net.NetworkInformation
{
public override long DatagramsSent { get { return _table.OutDatagrams; } }
+ [UnsupportedOSPlatform("linux")]
public override long IncomingDatagramsDiscarded { get { throw new PlatformNotSupportedException(SR.net_InformationUnavailableOnPlatform); } }
public override long IncomingDatagramsWithErrors { get { return _table.InErrors; } }
using System.Collections.Generic;
using System.Threading;
+using System.Runtime.Versioning;
namespace System.Net.NetworkInformation
{
ContextCallback callbackContext = s_runAddressChangedHandler != null ? s_runHandlerAvailable : s_runHandlerNotAvailable;
}
+ [UnsupportedOSPlatform("illumos")]
+ [UnsupportedOSPlatform("solaris")]
public static event NetworkAddressChangedEventHandler? NetworkAddressChanged
{
add { throw new PlatformNotSupportedException(); }
remove { throw new PlatformNotSupportedException(); }
}
+ [UnsupportedOSPlatform("illumos")]
+ [UnsupportedOSPlatform("solaris")]
public static event NetworkAvailabilityChangedEventHandler? NetworkAvailabilityChanged
{
add { throw new PlatformNotSupportedException(); }
// Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
+using System.Runtime.Versioning;
+
namespace System.Net.NetworkInformation
{
public abstract class NetworkInterface
/// Returns objects that describe the network interfaces on the local computer.
/// </summary>
/// <returns>An array of all network interfaces on the local computer.</returns>
+ [UnsupportedOSPlatform("illumos")]
+ [UnsupportedOSPlatform("solaris")]
public static NetworkInterface[] GetAllNetworkInterfaces()
{
return NetworkInterfacePal.GetAllNetworkInterfaces();
}
+ [UnsupportedOSPlatform("illumos")]
+ [UnsupportedOSPlatform("solaris")]
public static bool GetIsNetworkAvailable()
{
return NetworkInterfacePal.GetIsNetworkAvailable();
}
+ [UnsupportedOSPlatform("illumos")]
+ [UnsupportedOSPlatform("solaris")]
public static int IPv6LoopbackInterfaceIndex
{
get
}
}
+ [UnsupportedOSPlatform("illumos")]
+ [UnsupportedOSPlatform("solaris")]
public static int LoopbackInterfaceIndex
{
get
// Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
+using System.Runtime.Versioning;
+
namespace System.Net.NetworkInformation
{
internal static class NetworkInterfacePal
{
/// Returns objects that describe the network interfaces on the local computer.
+ [UnsupportedOSPlatform("illumos")]
+ [UnsupportedOSPlatform("solaris")]
public static NetworkInterface[] GetAllNetworkInterfaces()
{
throw new PlatformNotSupportedException();
}
+ [UnsupportedOSPlatform("illumos")]
+ [UnsupportedOSPlatform("solaris")]
public static bool GetIsNetworkAvailable()
{
throw new PlatformNotSupportedException();
}
+ [UnsupportedOSPlatform("illumos")]
+ [UnsupportedOSPlatform("solaris")]
public static int IPv6LoopbackInterfaceIndex
{
get { throw new PlatformNotSupportedException(); }
}
+ [UnsupportedOSPlatform("illumos")]
+ [UnsupportedOSPlatform("solaris")]
public static int LoopbackInterfaceIndex
{
get { throw new PlatformNotSupportedException(); }
using System.Collections.Generic;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
+using System.Runtime.Versioning;
using System.Threading;
using System.Threading.Tasks;
{
internal abstract class UnixIPGlobalProperties : IPGlobalProperties
{
+ [UnsupportedOSPlatform("linux")]
+ [UnsupportedOSPlatform("osx")]
+ [UnsupportedOSPlatform("ios")]
+ [UnsupportedOSPlatform("tvos")]
+ [UnsupportedOSPlatform("freebsd")]
+ [UnsupportedOSPlatform("illumos")]
+ [UnsupportedOSPlatform("solaris")]
public override string DhcpScopeName { get { throw new PlatformNotSupportedException(SR.net_InformationUnavailableOnPlatform); } }
public override string DomainName { get { return HostInformation.DomainName; } }
public override string HostName { get { return HostInformation.HostName; } }
+ [UnsupportedOSPlatform("linux")]
+ [UnsupportedOSPlatform("osx")]
+ [UnsupportedOSPlatform("ios")]
+ [UnsupportedOSPlatform("tvos")]
+ [UnsupportedOSPlatform("freebsd")]
+ [UnsupportedOSPlatform("illumos")]
+ [UnsupportedOSPlatform("solaris")]
public override bool IsWinsProxy { get { throw new PlatformNotSupportedException(SR.net_InformationUnavailableOnPlatform); } }
public override NetBiosNodeType NodeType { get { return NetBiosNodeType.Unknown; } }
// Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
+using System.Runtime.Versioning;
+
namespace System.Net.NetworkInformation
{
internal sealed class UnixMulticastIPAddressInformation : MulticastIPAddressInformation
public override IPAddress Address { get { return _address; } }
+ [UnsupportedOSPlatform("linux")]
+ [UnsupportedOSPlatform("osx")]
+ [UnsupportedOSPlatform("ios")]
+ [UnsupportedOSPlatform("tvos")]
+ [UnsupportedOSPlatform("freebsd")]
+ [UnsupportedOSPlatform("illumos")]
+ [UnsupportedOSPlatform("solaris")]
public override bool IsDnsEligible { get { throw new PlatformNotSupportedException(SR.net_InformationUnavailableOnPlatform); } }
+ [UnsupportedOSPlatform("linux")]
+ [UnsupportedOSPlatform("osx")]
+ [UnsupportedOSPlatform("ios")]
+ [UnsupportedOSPlatform("tvos")]
+ [UnsupportedOSPlatform("freebsd")]
+ [UnsupportedOSPlatform("illumos")]
+ [UnsupportedOSPlatform("solaris")]
public override bool IsTransient { get { throw new PlatformNotSupportedException(SR.net_InformationUnavailableOnPlatform); } }
+ [UnsupportedOSPlatform("linux")]
+ [UnsupportedOSPlatform("osx")]
+ [UnsupportedOSPlatform("ios")]
+ [UnsupportedOSPlatform("tvos")]
+ [UnsupportedOSPlatform("freebsd")]
+ [UnsupportedOSPlatform("illumos")]
+ [UnsupportedOSPlatform("solaris")]
public override long AddressPreferredLifetime { get { throw new PlatformNotSupportedException(SR.net_InformationUnavailableOnPlatform); } }
+ [UnsupportedOSPlatform("linux")]
+ [UnsupportedOSPlatform("osx")]
+ [UnsupportedOSPlatform("ios")]
+ [UnsupportedOSPlatform("tvos")]
+ [UnsupportedOSPlatform("freebsd")]
+ [UnsupportedOSPlatform("illumos")]
+ [UnsupportedOSPlatform("solaris")]
public override long AddressValidLifetime { get { throw new PlatformNotSupportedException(SR.net_InformationUnavailableOnPlatform); } }
+ [UnsupportedOSPlatform("linux")]
+ [UnsupportedOSPlatform("osx")]
+ [UnsupportedOSPlatform("ios")]
+ [UnsupportedOSPlatform("tvos")]
+ [UnsupportedOSPlatform("freebsd")]
+ [UnsupportedOSPlatform("illumos")]
+ [UnsupportedOSPlatform("solaris")]
public override long DhcpLeaseLifetime { get { throw new PlatformNotSupportedException(SR.net_InformationUnavailableOnPlatform); } }
+ [UnsupportedOSPlatform("linux")]
+ [UnsupportedOSPlatform("osx")]
+ [UnsupportedOSPlatform("ios")]
+ [UnsupportedOSPlatform("tvos")]
+ [UnsupportedOSPlatform("freebsd")]
+ [UnsupportedOSPlatform("illumos")]
+ [UnsupportedOSPlatform("solaris")]
public override DuplicateAddressDetectionState DuplicateAddressDetectionState { get { throw new PlatformNotSupportedException(SR.net_InformationUnavailableOnPlatform); } }
+ [UnsupportedOSPlatform("linux")]
+ [UnsupportedOSPlatform("osx")]
+ [UnsupportedOSPlatform("ios")]
+ [UnsupportedOSPlatform("tvos")]
+ [UnsupportedOSPlatform("freebsd")]
+ [UnsupportedOSPlatform("illumos")]
+ [UnsupportedOSPlatform("solaris")]
public override PrefixOrigin PrefixOrigin { get { throw new PlatformNotSupportedException(SR.net_InformationUnavailableOnPlatform); } }
+ [UnsupportedOSPlatform("linux")]
+ [UnsupportedOSPlatform("osx")]
+ [UnsupportedOSPlatform("ios")]
+ [UnsupportedOSPlatform("tvos")]
+ [UnsupportedOSPlatform("freebsd")]
+ [UnsupportedOSPlatform("illumos")]
+ [UnsupportedOSPlatform("solaris")]
public override SuffixOrigin SuffixOrigin { get { throw new PlatformNotSupportedException(SR.net_InformationUnavailableOnPlatform); } }
}
}
// Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
+
using System.Net.Sockets;
+using System.Runtime.Versioning;
namespace System.Net.NetworkInformation
{
public override IPAddress Address { get { return _address; } }
/// Gets a bool value that indicates whether the Internet Protocol (IP) address is legal to appear in a Domain Name System (DNS) server database.
+ [UnsupportedOSPlatform("linux")]
+ [UnsupportedOSPlatform("osx")]
+ [UnsupportedOSPlatform("ios")]
+ [UnsupportedOSPlatform("tvos")]
+ [UnsupportedOSPlatform("freebsd")]
+ [UnsupportedOSPlatform("illumos")]
+ [UnsupportedOSPlatform("solaris")]
public override bool IsDnsEligible { get { throw new PlatformNotSupportedException(SR.net_InformationUnavailableOnPlatform); } }
/// Gets a bool value that indicates whether the Internet Protocol (IP) address is transient.
+ [UnsupportedOSPlatform("linux")]
+ [UnsupportedOSPlatform("osx")]
+ [UnsupportedOSPlatform("ios")]
+ [UnsupportedOSPlatform("tvos")]
+ [UnsupportedOSPlatform("freebsd")]
+ [UnsupportedOSPlatform("illumos")]
+ [UnsupportedOSPlatform("solaris")]
public override bool IsTransient { get { throw new PlatformNotSupportedException(SR.net_InformationUnavailableOnPlatform); } }
/// [To be supplied.]
+ [UnsupportedOSPlatform("linux")]
+ [UnsupportedOSPlatform("osx")]
+ [UnsupportedOSPlatform("ios")]
+ [UnsupportedOSPlatform("tvos")]
+ [UnsupportedOSPlatform("freebsd")]
+ [UnsupportedOSPlatform("illumos")]
+ [UnsupportedOSPlatform("solaris")]
public override long AddressPreferredLifetime { get { throw new PlatformNotSupportedException(SR.net_InformationUnavailableOnPlatform); } }
/// [To be supplied.]
+ [UnsupportedOSPlatform("linux")]
+ [UnsupportedOSPlatform("osx")]
+ [UnsupportedOSPlatform("ios")]
+ [UnsupportedOSPlatform("tvos")]
+ [UnsupportedOSPlatform("freebsd")]
+ [UnsupportedOSPlatform("illumos")]
+ [UnsupportedOSPlatform("solaris")]
public override long AddressValidLifetime { get { throw new PlatformNotSupportedException(SR.net_InformationUnavailableOnPlatform); } }
/// Specifies the amount of time remaining on the Dynamic Host Configuration Protocol (DHCP) lease for this IP address.
+ [UnsupportedOSPlatform("linux")]
+ [UnsupportedOSPlatform("osx")]
+ [UnsupportedOSPlatform("ios")]
+ [UnsupportedOSPlatform("tvos")]
+ [UnsupportedOSPlatform("freebsd")]
+ [UnsupportedOSPlatform("illumos")]
+ [UnsupportedOSPlatform("solaris")]
public override long DhcpLeaseLifetime { get { throw new PlatformNotSupportedException(SR.net_InformationUnavailableOnPlatform); } }
/// Gets a value that indicates the state of the duplicate address detection algorithm.
+ [UnsupportedOSPlatform("linux")]
+ [UnsupportedOSPlatform("osx")]
+ [UnsupportedOSPlatform("ios")]
+ [UnsupportedOSPlatform("tvos")]
+ [UnsupportedOSPlatform("freebsd")]
+ [UnsupportedOSPlatform("illumos")]
+ [UnsupportedOSPlatform("solaris")]
public override DuplicateAddressDetectionState DuplicateAddressDetectionState { get { throw new PlatformNotSupportedException(SR.net_InformationUnavailableOnPlatform); } }
+
/// Gets a value that identifies the source of a unicast IP address prefix.
+ [UnsupportedOSPlatform("linux")]
+ [UnsupportedOSPlatform("osx")]
+ [UnsupportedOSPlatform("ios")]
+ [UnsupportedOSPlatform("tvos")]
+ [UnsupportedOSPlatform("freebsd")]
+ [UnsupportedOSPlatform("illumos")]
+ [UnsupportedOSPlatform("solaris")]
public override PrefixOrigin PrefixOrigin { get { throw new PlatformNotSupportedException(SR.net_InformationUnavailableOnPlatform); } }
/// Gets a value that identifies the source of a unicast IP address suffix.
+ [UnsupportedOSPlatform("linux")]
+ [UnsupportedOSPlatform("osx")]
+ [UnsupportedOSPlatform("ios")]
+ [UnsupportedOSPlatform("tvos")]
+ [UnsupportedOSPlatform("freebsd")]
+ [UnsupportedOSPlatform("illumos")]
+ [UnsupportedOSPlatform("solaris")]
public override SuffixOrigin SuffixOrigin { get { throw new PlatformNotSupportedException(SR.net_InformationUnavailableOnPlatform); } }
public override IPAddress IPv4Mask