18 references to FromException
Microsoft.AspNetCore.Server.HttpSys (1)
AsyncAcceptContext.cs (1)
54
return ValueTask.
FromException
<RequestContext>(new HttpSysException((int)statusCode));
System.Data.Common (1)
System\Data\Common\DbConnection.cs (1)
80
return ValueTask.
FromException
<DbTransaction>(e);
System.Net.Http (3)
System\Net\Http\SocketsHttpHandler\Http2Stream.cs (2)
1525
public override ValueTask<int> ReadAsync(Memory<byte> buffer, CancellationToken cancellationToken) => ValueTask.
FromException
<int>(new NotSupportedException(SR.net_http_content_writeonly_stream));
1611
return ValueTask.
FromException
<int>(ExceptionDispatchInfo.SetCurrentStackTrace(new ObjectDisposedException(nameof(Http2ReadStream))));
System\Net\Http\SocketsHttpHandler\Http3RequestStream.cs (1)
1479
return ValueTask.
FromException
<int>(new ObjectDisposedException(nameof(Http3RequestStream)));
System.Net.Sockets (7)
System\Net\Sockets\Socket.Tasks.cs (7)
1060
ValueTask.
FromException
<Socket>(CreateException(error));
1080
ValueTask.
FromException
<int>(CreateException(error));
1099
ValueTask.
FromException
<SocketReceiveFromResult>(CreateException(error));
1117
ValueTask.
FromException
<int>(CreateException(error));
1138
ValueTask.
FromException
<SocketReceiveMessageFromResult>(CreateException(error));
1158
ValueTask.
FromException
<int>(CreateException(error));
1210
ValueTask.
FromException
<int>(CreateException(error));
System.Net.WebSockets (1)
System\Net\WebSockets\ManagedWebSocket.cs (1)
395
return ValueTask.
FromException
<ValueWebSocketReceiveResult>(exc);
System.Private.CoreLib (2)
src\libraries\System.Private.CoreLib\src\System\IO\MemoryStream.cs (1)
422
return ValueTask.
FromException
<int>(exception);
src\libraries\System.Private.CoreLib\src\System\IO\UnmanagedMemoryStream.cs (1)
473
return ValueTask.
FromException
<int>(ex);
System.Security.Cryptography (1)
System\Security\Cryptography\CryptoStream.cs (1)
227
return ValueTask.
FromException
<int>(new NotSupportedException(SR.NotSupported_UnreadableStream));
System.Threading.Channels (2)
System\Threading\Channels\UnboundedPriorityChannel.cs (2)
172
ValueTask.
FromException
<bool>(parent._doneWriting) :
312
doneWriting != ChannelUtilities.s_doneWritingSentinel ? ValueTask.
FromException
<bool>(doneWriting) :