1 write to Result
Microsoft.AspNetCore.SignalR.Common (1)
Protocol\CompletionMessage.cs (1)
45Result = result;
115 references to Result
Microsoft.AspNetCore.Components.Server (1)
src\SignalR\common\Protocols.MessagePack\src\Protocol\MessagePackHubProtocolWorker.cs (1)
543WriteArgument(message.Result, ref writer);
Microsoft.AspNetCore.Components.Server.Tests (5)
src\SignalR\common\SignalR.Common\test\Internal\Protocol\TestBinder.cs (1)
30_returnType = c.Result?.GetType() ?? typeof(object);
src\SignalR\common\SignalR.Common\test\Internal\Protocol\TestHubMessageEqualityComparer.cs (4)
57&& (Equals(x.Result, y.Result) || SequenceEqual(x.Result, y.Result));
Microsoft.AspNetCore.SignalR.Client.Core (2)
Internal\InvocationRequest.cs (2)
93if (completionMessage.Result != null) 193_completionSource.TrySetResult(completionMessage.Result);
Microsoft.AspNetCore.SignalR.Common (3)
Protocol\CompletionMessage.cs (2)
53var resultField = HasResult ? $", {nameof(Result)}: {Result ?? "<<null>>"}" : string.Empty;
Protocol\RawResult.cs (1)
23/// Stores the raw serialized bytes of a <see cref="CompletionMessage.Result"/> for forwarding to another server.
Microsoft.AspNetCore.SignalR.Common.Tests (15)
Internal\Protocol\JsonHubProtocolTests.cs (1)
202PersonEqual(todo, completionMessage.Result);
Internal\Protocol\JsonHubProtocolTestsBase.cs (4)
298var dt = Assert.IsType<DateTime>(invocationMessage.Result); 458Assert.Equal(testData.Result, completion.Result); 477Assert.Null(completion.Result); 493Assert.Null(completion.Result);
Internal\Protocol\MessagePackHubProtocolTests.cs (5)
42var resultDateTime = (DateTime)completionMessage.Result; 71var resultDateTimeOffset = (DateTimeOffset)completionMessage.Result; 238Assert.Equal(testData.Result, completion.Result); 255Assert.Null(completion.Result); 268Assert.Null(completion.Result);
Internal\Protocol\TestBinder.cs (1)
30_returnType = c.Result?.GetType() ?? typeof(object);
Internal\Protocol\TestHubMessageEqualityComparer.cs (4)
57&& (Equals(x.Result, y.Result) || SequenceEqual(x.Result, y.Result));
Microsoft.AspNetCore.SignalR.Core (1)
src\SignalR\common\Shared\ClientResultsManager.cs (1)
26tcs.SetResult((T)completionMessage.Result!);
Microsoft.AspNetCore.SignalR.Microbenchmarks (1)
TestBinder.cs (1)
27_returnType = c.Result?.GetType() ?? typeof(object);
Microsoft.AspNetCore.SignalR.Protocols.Json (3)
Protocol\JsonHubProtocol.cs (3)
602if (message.Result == null) 608if (message.Result is RawResult result) 614SerializeObject(writer, message.Result);
Microsoft.AspNetCore.SignalR.Protocols.MessagePack (1)
Protocol\MessagePackHubProtocolWorker.cs (1)
543WriteArgument(message.Result, ref writer);
Microsoft.AspNetCore.SignalR.Protocols.NewtonsoftJson (2)
Protocol\NewtonsoftJsonHubProtocol.cs (2)
602if (message.Result is RawResult result) 612PayloadSerializer.Serialize(writer, message.Result);
Microsoft.AspNetCore.SignalR.StackExchangeRedis (1)
src\SignalR\common\Shared\ClientResultsManager.cs (1)
26tcs.SetResult((T)completionMessage.Result!);
Microsoft.AspNetCore.SignalR.Tests (80)
HubConnectionHandlerTests.Activity.cs (2)
60var res = (string)completionMessage.Result; 142var res = (string)completionMessage.Result;
HubConnectionHandlerTests.ClientResult.cs (11)
34Assert.Equal(9L, completion.Result); 224Assert.Equal(new ClientResults(11, 7), completion.Result); 263Assert.Equal(9L, completion.Result); 269Assert.Equal(10L, completion.Result); 275Assert.Equal(11L, completion.Result); 316Assert.Equal(43L, completionMessage.Result); 393Assert.Equal("test", completion.Result); 438Assert.Equal("test", completion.Result); 471Assert.Equal(5L, completion.Result); 476Assert.Equal(43L, completionMessage.Result); 514Assert.Equal(43, completionMessage.Result);
HubConnectionHandlerTests.cs (59)
407Assert.Equal("hello", completionMessage.Result); 445Assert.Equal("hello", completionMessage.Result); 563Assert.Equal("one", completionMessage.Result); 568Assert.Equal("two", completionMessage.Result); 614Assert.Equal("one", completionMessage.Result); 619Assert.Equal("two", completionMessage.Result); 624Assert.Equal("three", completionMessage.Result); 806var result = (await client.InvokeAsync(nameof(MethodHub.TaskValueMethod)).DefaultTimeout()).Result; 832var result = (await client.InvokeAsync(nameof(MethodHub.ValueTaskValueMethod)).DefaultTimeout()).Result; 858var result = (await client.InvokeAsync(nameof(MethodHub.ValueTaskMethod)).DefaultTimeout()).Result; 882var result = (await client.InvokeAsync("echo", "hello").DefaultTimeout()).Result; 1051var result = (await client.InvokeAsync(nameof(MethodHub.VoidMethod)).DefaultTimeout()).Result; 1076var result = (await client.InvokeAsync("RenamedMethod").DefaultTimeout()).Result; 1102var result = (await client.InvokeAsync("RenamedVirtualMethod").DefaultTimeout()).Result; 1165var result = (await client.InvokeAsync(nameof(MethodHub.ConcatString), (byte)32, 42, 'm', "string").DefaultTimeout()).Result; 1190var result = (await client.InvokeAsync(nameof(InheritedHub.BaseMethod), "string").DefaultTimeout()).Result; 1215var result = (await client.InvokeAsync(nameof(InheritedHub.VirtualMethod), 10).DefaultTimeout()).Result; 1702var result = (await firstClient.InvokeAsync("GroupSendMethod", "testGroup", "test").DefaultTimeout()).Result; 1710result = (await secondClient.InvokeAsync(nameof(MethodHub.GroupAddMethod), "testGroup").DefaultTimeout()).Result; 1746var result = (await firstClient.InvokeAsync("GroupSendMethod", "testGroup", "test").DefaultTimeout()).Result; 1799var result = (await firstClient.InvokeAsync("GroupSendMethod", "testGroup", "test").DefaultTimeout()).Result; 2628var result = (await client.InvokeAsync(nameof(MethodHub.HasHttpContext)).DefaultTimeout()).Result; 2653var result = (await client.InvokeAsync(nameof(MethodHub.HasHttpContext)).DefaultTimeout()).Result; 3193Assert.Equal(42L, completion.Result); 3354Assert.Equal(12L, longRunningCompletion.Result); 3360Assert.Equal(21L, simpleCompletion.Result); 3406Assert.Equal(21L, simpleCompletion.Result); 3416Assert.Equal(12L, longRunningCompletion.Result); 3473Assert.Equal(12L, longRunningCompletion.Result); 3479Assert.Equal(21L, simpleCompletion.Result); 3486Assert.Equal(12L, longRunningCompletion.Result); 3527Assert.Equal(21L, completion.Result); 3636Assert.Equal("BEANED", result.Result); 3659var result = ((JArray)response.Result).ToArray<object>(); 3699Assert.Equal(words[int.Parse(id, CultureInfo.InvariantCulture)], ((CompletionMessage)response).Result); 3754var result = ((JArray)response.Result).ToArray<object>(); 3782Assert.Equal(21L, completion.Result); 3788Assert.Null(response.Result); 3883Assert.Equal("510", response.Result); 3932Assert.Equal("error identified and caught", (string)((CompletionMessage)response).Result); 4004Assert.True((bool)response.Result); 4070Assert.Equal("hello world", simpleCompletion.Result); 4143Assert.Null(simpleCompletion.Result); 4180Assert.Null(simpleCompletion.Result); 4230Assert.Null(simpleCompletion.Result); 4679Assert.True(Assert.IsType<bool>(res.Result)); 4698Assert.True(Assert.IsType<bool>(res.Result)); 4724Assert.Equal(25L, response.Result); 4785Assert.Equal(1L, res.Result); 4806Assert.Equal(1L, res.Result); 4831Assert.Equal(1L, res.Result); 4876Assert.Equal(1L, res.Result); 4939Assert.Equal(43L, res.Result); 4962Assert.Equal(1183L, res.Result); 4986Assert.Equal(11L, res.Result); 5009Assert.Equal(45L, res.Result); 5032Assert.Equal(445L, res.Result); 5185Assert.Equal("test", completionMessage.Result); 5222Assert.Equal("t", completionMessage.Result);
HubConnectionHandlerTestUtils\Utils.cs (2)
36Assert.Equal(expectedCompletion.Result, actualCompletion.Result);
HubFilterTests.cs (6)
163Assert.Equal("hello", completion.Result); 703Assert.Null(message.Result); 740Assert.Equal("Hello", message.Result); 777Assert.Equal("Hello", message.Result); 816Assert.Equal("Hello", message.Result); 853Assert.Equal("Hello", message.Result);