#endif
#endif
-#if MOBILE && !MOBILE
- [assembly: InternalsVisibleTo ("System.Net, PublicKey=00240000048000009400000006020000002400005253413100040000010001008D56C76F9E8649383049F383C44BE0EC204181822A6C31CF5EB7EF486944D032188EA1D3920763712CCB12D75FB77E9811149E6148E5D32FBAAB37611C1878DDC19E20EF135D0CB2CFF2BFEC3D115810C3D9069638FE4BE215DBF795861920E5AB6F7DB2E2CEEF136AC23D5DD2BF031700AEC232F6C6B1C785B4305C123B37AB")]
-#else
[assembly: InternalsVisibleTo ("System.ComponentModel.DataAnnotations, PublicKey=0024000004800000940000000602000000240000525341310004000001000100b5fc90e7027f67871e773a8fde8938c81dd402ba65b9201d60593e96c492651e889cc13f1415ebb53fac1131ae0bd333c5ee6021672d9718ea31a8aebd0da0072f25d87dba6fc90ffd598ed4da35e44c398c454307e8e33b8426143daec9f596836f97c8f74750e5975c64e2189f45def46b2a2b1247adc3652bf5c308055da9")]
[assembly: InternalsVisibleTo ("System.Net.Http, PublicKey=002400000480000094000000060200000024000052534131000400000100010007d1fa57c4aed9f0a32e84aa0faefd0de9e8fd6aec8f87fb03766c834c99921eb23be79ad9d5dcc1dd9ad236132102900b723cf980957fc4e177108fc607774f29e8320e92ea05ece4e821c0a5efe8f1645c4c0c93c1ab99285d622caa652c1dfad63d745d6f2de5f17e5eaf0fc4963d261c8a12436518206dc093344d5ad293")]
[assembly: StringFreezing]
[assembly: DefaultDependency (LoadHint.Always)]
-#endif
[assembly: InternalsVisibleTo ("Mono.Security.Providers.NewSystemSource, PublicKey=002400000480000094000000060200000024000052534131000400000100010079159977d2d03a8e6bea7a2e74e8d1afcc93e8851974952bb480a12c9134474d04062447c37e0e68c080536fcf3c3fbe2ff9c979ce998475e506e8ce82dd5b0f350dc10e93bf2eeecf874b24770c5081dbea7447fddafa277b22de47d6ffea449674a4f9fccf84d15069089380284dbdd35f46cdff12a1bd78e4ef0065d016df")]
[assembly: InternalsVisibleTo ("Mono.Security.Providers.OldTls, PublicKey=002400000480000094000000060200000024000052534131000400000100010079159977d2d03a8e6bea7a2e74e8d1afcc93e8851974952bb480a12c9134474d04062447c37e0e68c080536fcf3c3fbe2ff9c979ce998475e506e8ce82dd5b0f350dc10e93bf2eeecf874b24770c5081dbea7447fddafa277b22de47d6ffea449674a4f9fccf84d15069089380284dbdd35f46cdff12a1bd78e4ef0065d016df")]
public Socket(AddressFamily addressFamily, SocketType socketType, ProtocolType protocolType)
{
-#if MOBILE && !MOBILE
- switch (addressFamily) {
- case AddressFamily.InterNetwork: // ok
- case AddressFamily.InterNetworkV6: // ok
- case AddressFamily.Unknown: // SocketException will be thrown later (with right error #)
- break;
- // case AddressFamily.Unspecified:
- default:
- throw new ArgumentException ("addressFamily");
- }
-
- switch (socketType) {
- case SocketType.Stream: // ok
- case SocketType.Unknown: // SocketException will be thrown later (with right error #)
- break;
- default:
- throw new ArgumentException ("socketType");
- }
-
- switch (protocolType) {
- case ProtocolType.Tcp: // ok
- case ProtocolType.Unspecified: // ok
- case ProtocolType.Unknown: // SocketException will be thrown later (with right error #)
- break;
- default:
- throw new ArgumentException ("protocolType");
- }
-#endif
this.address_family = addressFamily;
this.socket_type = socketType;
this.protocol_type = protocolType;
if (error != 0)
throw new SocketException (error);
-#if !MOBILE || MOBILE
SocketDefaults ();
-#endif
}
#if !MOBILE
void ThrowIfUdp ()
{
-#if !MOBILE || MOBILE
if (protocol_type == ProtocolType.Udp)
throw new SocketException ((int)SocketError.ProtocolOption);
-#endif
}
SocketAsyncResult ValidateEndIAsyncResult (IAsyncResult ares, string methodName, string argName)