195 references to SR
System.Net.Requests (195)
src\libraries\Common\src\System\Net\ContextAwareResult.cs (2)
134
throw new InvalidOperationException(
SR
.net_completed_result);
157
throw new InvalidOperationException(
SR
.net_completed_result);
src\libraries\Common\src\System\Net\HttpValidationHelpers.cs (8)
13
throw new ArgumentException(
SR
.Format(
SR
.net_WebHeaderInvalidHeaderChars, name), nameof(name));
19
throw new ArgumentException(
SR
.Format(
SR
.net_WebHeaderInvalidHeaderChars, name), nameof(name));
71
throw new ArgumentException(
SR
.net_WebHeaderInvalidControlChars, nameof(value));
81
throw new ArgumentException(
SR
.net_WebHeaderInvalidCRLFChars, nameof(value));
89
throw new ArgumentException(
SR
.net_WebHeaderInvalidControlChars, nameof(value));
95
throw new ArgumentException(
SR
.net_WebHeaderInvalidCRLFChars, nameof(value));
System\Net\Cache\HttpRequestCachePolicy.cs (4)
38
throw new ArgumentException(
SR
.Format(
SR
.net_invalid_enum, nameof(HttpCacheAgeControl)), nameof(cacheAgeControl));
64
throw new ArgumentException(
SR
.Format(
SR
.net_invalid_enum, nameof(HttpCacheAgeControl)), nameof(cacheAgeControl));
System\Net\CommandStream.cs (7)
144
return new WebException(
SR
.Format(
SR
.net_ftp_servererror, NetRes.GetWebStatusCodeString(code, statusDescription)),
319
exception = GenerateException(
SR
.net_ftp_protocolerror, WebExceptionStatus.ServerProtocolViolation, null);
546
throw GenerateException(
SR
.net_ftp_receivefailure, WebExceptionStatus.ReceiveFailure, e);
582
throw GenerateException(
SR
.net_ftp_protocolerror, WebExceptionStatus.ServerProtocolViolation, null);
591
throw GenerateException(
SR
.net_ftp_protocolerror, WebExceptionStatus.ServerProtocolViolation, null);
605
throw GenerateException(
SR
.net_ftp_protocolerror, WebExceptionStatus.ServerProtocolViolation, null);
System\Net\ExceptionHelper.cs (3)
8
internal static NotSupportedException PropertyNotSupportedException => new NotSupportedException(
SR
.net_PropertyNotSupportedException);
10
internal static WebException RequestAbortedException => new WebException(
SR
.net_reqaborted);
12
internal static WebException TimeoutException => new WebException(
SR
.net_timeout);
System\Net\FileWebRequest.cs (13)
103
throw new ArgumentOutOfRangeException(nameof(value),
SR
.net_io_timeout_use_ge_zero);
112
new WebException(
SR
.Format(
SR
.net_requestaborted, WebExceptionStatus.RequestCanceled), WebExceptionStatus.RequestCanceled);
124
throw new ProtocolViolationException(
SR
.net_nouploadonget);
129
throw new InvalidOperationException(
SR
.net_reqsubmitted);
136
throw new InvalidOperationException(
SR
.net_repcall);
188
throw new InvalidOperationException(
SR
.net_repcall);
261
throw new WebException(
SR
.net_webstatus_Timeout, WebExceptionStatus.Timeout);
277
throw new WebException(
SR
.net_webstatus_Timeout, WebExceptionStatus.Timeout);
291
get { throw new NotSupportedException(
SR
.net_PropertyNotSupportedException); }
292
set { throw new NotSupportedException(
SR
.net_PropertyNotSupportedException); }
468
throw new WebException(
SR
.Format(
SR
.net_requestaborted, WebExceptionStatus.RequestCanceled), WebExceptionStatus.RequestCanceled);
System\Net\FtpControlStream.cs (22)
115
throw new WebException(
SR
.net_ftp_active_address_different, WebExceptionStatus.ProtocolError);
261
throw new WebException(
SR
.net_InvalidStatusCode, WebExceptionStatus.ProtocolError);
353
_abortReason =
SR
.Format(
SR
.net_ftp_invalid_status_response, status, entry.Command);
568
throw new WebException(
SR
.net_ftp_invalid_uri);
678
_abortReason =
SR
.Format(
SR
.net_ftp_server_failed_passive, response.Status);
748
throw new WebException(
SR
.net_ftp_active_address_different, WebExceptionStatus.ProtocolError);
910
throw new FormatException(
SR
.Format(
SR
.net_ftp_response_invalid_format, responseString));
996
throw new FormatException(
SR
.Format(
SR
.net_ftp_invalid_response_filename, filename));
1003
throw new FormatException(
SR
.Format(
SR
.net_ftp_invalid_response_filename, filename));
1062
throw new FormatException(
SR
.Format(
SR
.net_ftp_response_invalid_format, responseString));
1084
throw new FormatException(
SR
.Format(
SR
.net_ftp_response_invalid_format, responseString));
1091
throw new FormatException(
SR
.Format(
SR
.net_ftp_response_invalid_format, responseString));
1141
throw GenerateException(
SR
.net_ftp_protocolerror, WebExceptionStatus.ProtocolError, e); // could not open data connection
1152
throw new FormatException(
SR
.net_ftp_no_newlines);
System\Net\FtpWebRequest.cs (36)
104
throw new ArgumentException(
SR
.net_ftp_unsupported_method, nameof(method));
271
throw new InvalidOperationException(
SR
.net_reqsubmitted);
279
throw new ArgumentException(
SR
.net_ftp_unsupported_method, nameof(value));
301
throw new InvalidOperationException(
SR
.net_reqsubmitted);
324
throw new InvalidOperationException(
SR
.net_reqsubmitted);
329
throw new ArgumentException(
SR
.net_ftp_no_defaultcreds, nameof(value));
359
throw new InvalidOperationException(
SR
.net_reqsubmitted);
363
throw new ArgumentOutOfRangeException(nameof(value),
SR
.net_io_timeout_use_ge_zero);
397
throw new InvalidOperationException(
SR
.net_reqsubmitted);
401
throw new ArgumentOutOfRangeException(nameof(value),
SR
.net_io_timeout_use_gt_zero);
420
throw new InvalidOperationException(
SR
.net_reqsubmitted);
452
throw new InvalidOperationException(
SR
.net_reqsubmitted);
469
throw new InvalidOperationException(
SR
.net_reqsubmitted);
493
throw new FormatException(
SR
.net_ftp_no_newlines);
537
throw new InvalidOperationException(
SR
.net_repcall);
622
throw new InvalidOperationException(
SR
.net_repcall);
689
throw new ArgumentException(
SR
.net_io_invalidasyncresult, nameof(asyncResult));
693
throw new InvalidOperationException(
SR
.Format(
SR
.net_io_invalidendcall, "EndGetResponse"));
720
throw new InvalidOperationException(
SR
.net_repcall);
725
throw new ProtocolViolationException(
SR
.net_nouploadonget);
773
throw new InvalidOperationException(
SR
.net_repcall);
778
throw new ProtocolViolationException(
SR
.net_nouploadonget);
812
throw new ArgumentException(
SR
.net_io_invalidasyncresult, nameof(asyncResult));
817
throw new InvalidOperationException(
SR
.Format(
SR
.net_io_invalidendcall, "EndGetResponse"));
922
SetException(ExceptionDispatchInfo.SetCurrentStackTrace(new WebException(
SR
.net_timeout, WebExceptionStatus.Timeout)));
941
return new WebException(
SR
.net_webstatus_NameResolutionFailure, WebExceptionStatus.NameResolutionFailure);
945
return new WebException(
SR
.net_webstatus_ConnectFailure, WebExceptionStatus.ConnectFailure);
1116
_exception = new WebException(
SR
.Format(
SR
.net_ftp_servererror, connection.StatusLine), exception, WebExceptionStatus.ProtocolError, _ftpWebResponse);
1470
throw new InvalidOperationException(
SR
.net_reqsubmitted);
1487
throw new InvalidOperationException(
SR
.net_reqsubmitted);
1507
throw new InvalidOperationException(
SR
.net_reqsubmitted);
1523
throw new InvalidOperationException(
SR
.net_reqsubmitted);
1555
throw new InvalidOperationException(
SR
.net_reqsubmitted);
System\Net\HttpWebRequest.cs (44)
255
throw new InvalidOperationException(
SR
.net_reqsubmitted);
297
throw new InvalidOperationException(
SR
.net_reqsubmitted);
301
throw new ArgumentOutOfRangeException(nameof(value),
SR
.net_io_timeout_use_ge_zero);
317
throw new ArgumentOutOfRangeException(nameof(value),
SR
.net_io_timeout_use_ge_zero);
336
throw new InvalidOperationException(
SR
.net_writestarted);
376
throw new InvalidOperationException(
SR
.net_writestarted);
383
throw new ArgumentException(
SR
.net_invalid_host, nameof(value));
477
throw new ArgumentException(
SR
.net_nochunked, nameof(value));
481
throw new InvalidOperationException(
SR
.net_needchunked);
522
throw new InvalidOperationException(
SR
.net_writestarted);
615
throw new ArgumentException(
SR
.net_connarg, nameof(value));
664
throw new ArgumentException(
SR
.net_no100, nameof(value));
763
throw new InvalidOperationException(
SR
.net_writestarted);
836
throw new ArgumentException(
SR
.net_wrongversion, nameof(value));
851
throw new InvalidOperationException(
SR
.net_reqsubmitted);
856
throw new ArgumentOutOfRangeException(nameof(value),
SR
.net_io_timeout_use_gt_zero);
906
throw new InvalidOperationException(
SR
.net_reqsubmitted);
937
throw new ArgumentException(
SR
.net_badmethod, nameof(value));
969
throw new InvalidOperationException(
SR
.net_writestarted);
989
throw new InvalidOperationException(
SR
.net_reqsubmitted);
1081
throw new ProtocolViolationException(
SR
.net_nouploadonget);
1086
throw new InvalidOperationException(
SR
.net_reqsubmitted);
1146
throw new InvalidOperationException(
SR
.net_repcall);
1163
throw new ArgumentException(
SR
.net_io_invalidasyncresult, nameof(asyncResult));
1168
throw new InvalidOperationException(
SR
.Format(
SR
.net_io_invalidendcall, "EndGetRequestStream"));
1188
throw new InvalidOperationException(
SR
.net_reqsubmitted);
1278
SR
.Format(
SR
.net_servererror, (int)response.StatusCode, response.StatusDescription),
1330
throw new WebException(
SR
.CacheEntryNotFound, WebExceptionStatus.CacheEntryNotFound);
1386
throw new WebException(
SR
.CacheEntryNotFound, WebExceptionStatus.CacheEntryNotFound);
1419
throw new InvalidOperationException(
SR
.net_repcall);
1434
throw new ArgumentException(
SR
.net_io_invalidasyncresult, nameof(asyncResult));
1439
throw new InvalidOperationException(
SR
.Format(
SR
.net_io_invalidendcall, "EndGetResponse"));
1514
throw new ArgumentOutOfRangeException(from < 0 ? nameof(from) : nameof(to),
SR
.net_rangetoosmall);
1518
throw new ArgumentOutOfRangeException(nameof(from),
SR
.net_fromto);
1522
throw new ArgumentException(
SR
.net_nottoken, nameof(rangeSpecifier));
1526
throw new InvalidOperationException(
SR
.net_rangetype);
1541
throw new ArgumentException(
SR
.net_nottoken, nameof(rangeSpecifier));
1545
throw new InvalidOperationException(
SR
.net_rangetype);
1586
throw new WebException(
SR
.net_reqaborted, WebExceptionStatus.RequestCanceled);
1630
throw new ProtocolViolationException(
SR
.net_baddate);
1832
throw new OverflowException(
SR
.net_maximumbindretries);
System\Net\HttpWebResponse.cs (1)
158
throw new ProtocolViolationException(
SR
.net_baddate);
System\Net\NetRes.cs (16)
18
statusMessage =
SR
.net_ftpstatuscode_ServiceNotAvailable;
21
statusMessage =
SR
.net_ftpstatuscode_CantOpenData;
24
statusMessage =
SR
.net_ftpstatuscode_ConnectionClosed;
27
statusMessage =
SR
.net_ftpstatuscode_ActionNotTakenFileUnavailableOrBusy;
30
statusMessage =
SR
.net_ftpstatuscode_ActionAbortedLocalProcessingError;
33
statusMessage =
SR
.net_ftpstatuscode_ActionNotTakenInsufficientSpace;
36
statusMessage =
SR
.net_ftpstatuscode_CommandSyntaxError;
39
statusMessage =
SR
.net_ftpstatuscode_ArgumentSyntaxError;
42
statusMessage =
SR
.net_ftpstatuscode_CommandNotImplemented;
45
statusMessage =
SR
.net_ftpstatuscode_BadCommandSequence;
48
statusMessage =
SR
.net_ftpstatuscode_NotLoggedIn;
51
statusMessage =
SR
.net_ftpstatuscode_AccountNeeded;
54
statusMessage =
SR
.net_ftpstatuscode_ActionNotTakenFileUnavailable;
57
statusMessage =
SR
.net_ftpstatuscode_ActionAbortedUnknownPageType;
60
statusMessage =
SR
.net_ftpstatuscode_FileActionAborted;
63
statusMessage =
SR
.net_ftpstatuscode_ActionNotTakenFilenameNotAllowed;
System\Net\ServicePoint\ServicePointManager.cs (1)
46
throw new NotSupportedException(
SR
.net_securityprotocolnotsupported);
System\Net\WebException.cs (1)
94
SR
.net_webstatus_Timeout,
System\Net\WebRequest.cs (30)
138
throw new NotSupportedException(
SR
.net_unknown_prefix);
211
throw new NotSupportedException(
SR
.net_unknown_prefix);
387
throw NotImplemented.ByDesignWithMessage(
SR
.net_PropertyNotImplementedException);
391
throw NotImplemented.ByDesignWithMessage(
SR
.net_PropertyNotImplementedException);
399
throw NotImplemented.ByDesignWithMessage(
SR
.net_PropertyNotImplementedException);
403
throw NotImplemented.ByDesignWithMessage(
SR
.net_PropertyNotImplementedException);
411
throw NotImplemented.ByDesignWithMessage(
SR
.net_PropertyNotImplementedException);
419
throw NotImplemented.ByDesignWithMessage(
SR
.net_PropertyNotImplementedException);
423
throw NotImplemented.ByDesignWithMessage(
SR
.net_PropertyNotImplementedException);
431
throw NotImplemented.ByDesignWithMessage(
SR
.net_PropertyNotImplementedException);
435
throw NotImplemented.ByDesignWithMessage(
SR
.net_PropertyNotImplementedException);
443
throw NotImplemented.ByDesignWithMessage(
SR
.net_PropertyNotImplementedException);
447
throw NotImplemented.ByDesignWithMessage(
SR
.net_PropertyNotImplementedException);
456
throw NotImplemented.ByDesignWithMessage(
SR
.net_PropertyNotImplementedException);
460
throw NotImplemented.ByDesignWithMessage(
SR
.net_PropertyNotImplementedException);
468
throw NotImplemented.ByDesignWithMessage(
SR
.net_PropertyNotImplementedException);
472
throw NotImplemented.ByDesignWithMessage(
SR
.net_PropertyNotImplementedException);
480
throw NotImplemented.ByDesignWithMessage(
SR
.net_PropertyNotImplementedException);
484
throw NotImplemented.ByDesignWithMessage(
SR
.net_PropertyNotImplementedException);
490
throw NotImplemented.ByDesignWithMessage(
SR
.net_MethodNotImplementedException);
495
throw NotImplemented.ByDesignWithMessage(
SR
.net_MethodNotImplementedException);
500
throw NotImplemented.ByDesignWithMessage(
SR
.net_MethodNotImplementedException);
505
throw NotImplemented.ByDesignWithMessage(
SR
.net_MethodNotImplementedException);
510
throw NotImplemented.ByDesignWithMessage(
SR
.net_MethodNotImplementedException);
515
throw NotImplemented.ByDesignWithMessage(
SR
.net_MethodNotImplementedException);
542
throw NotImplemented.ByDesignWithMessage(
SR
.net_MethodNotImplementedException);
567
throw NotImplemented.ByDesignWithMessage(
SR
.net_PropertyNotImplementedException);
571
throw NotImplemented.ByDesignWithMessage(
SR
.net_PropertyNotImplementedException);
579
throw NotImplemented.ByDesignWithMessage(
SR
.net_PropertyNotImplementedException);
583
throw NotImplemented.ByDesignWithMessage(
SR
.net_PropertyNotImplementedException);
System\Net\WebResponse.cs (7)
77
throw NotImplemented.ByDesignWithMessage(
SR
.net_PropertyNotImplementedException);
81
throw NotImplemented.ByDesignWithMessage(
SR
.net_PropertyNotImplementedException);
95
throw NotImplemented.ByDesignWithMessage(
SR
.net_PropertyNotImplementedException);
99
throw NotImplemented.ByDesignWithMessage(
SR
.net_PropertyNotImplementedException);
114
throw NotImplemented.ByDesignWithMessage(
SR
.net_MethodNotImplementedException);
125
throw NotImplemented.ByDesignWithMessage(
SR
.net_PropertyNotImplementedException);
139
throw NotImplemented.ByDesignWithMessage(
SR
.net_PropertyNotImplementedException);