diff --git a/src/AutoRest.CSharp/LowLevel/Output/OperationMethodChainBuilder.cs b/src/AutoRest.CSharp/LowLevel/Output/OperationMethodChainBuilder.cs index e40e68fb36f..d18cdff87cc 100644 --- a/src/AutoRest.CSharp/LowLevel/Output/OperationMethodChainBuilder.cs +++ b/src/AutoRest.CSharp/LowLevel/Output/OperationMethodChainBuilder.cs @@ -118,7 +118,14 @@ private bool IsConvenienceMethodMeaningful() private bool HasAmbiguityBetweenProtocolAndConvenience() { - return _orderedParameters.Where(parameter => parameter.Convenience != KnownParameters.CancellationTokenParameter).All(parameter => IsParameterTypeHasValueOverlap(parameter.Convenience, parameter.Protocol)); + var userDefinedParameters = _orderedParameters.Where(parameter => parameter.Convenience != KnownParameters.CancellationTokenParameter); + int protocolRequired = userDefinedParameters.Select(p => p.Protocol).WhereNotNull().Where(p => !p.IsOptionalInSignature).Count(); + int convenienceRequired = userDefinedParameters.Select(p => p.Convenience).WhereNotNull().Where(p => !p.IsOptionalInSignature).Count(); + if (protocolRequired != convenienceRequired) + { + return false; + } + return userDefinedParameters.Where(p => p.Protocol != null && !p.Protocol.IsOptionalInSignature).All(parameter => IsParameterTypeSame(parameter.Convenience, parameter.Protocol)); } private bool ShouldRequestContextOptional() @@ -150,21 +157,6 @@ private bool IsParameterTypeSame(Parameter? first, Parameter? second) return object.Equals(first?.Type, second?.Type); } - private bool IsParameterTypeHasValueOverlap(Parameter? first, Parameter? second) - { - if (IsParameterTypeSame(first, second)) - { - return true; - } - - if (first != null && second != null && first.Type.IsNullable && second.Type.IsNullable) - { - return true; - } - - return false; - } - private ReturnTypeChain BuildReturnTypes() { var operationBodyTypes = Operation.Responses.Where(r => !r.IsErrorResponse).Select(r => r.BodyType).Distinct().ToArray(); diff --git a/test/AutoRest.TestServer.Tests/ConvenienceMethodTests.cs b/test/AutoRest.TestServer.Tests/ConvenienceMethodTests.cs index 058c307d0ed..2222582e4f4 100644 --- a/test/AutoRest.TestServer.Tests/ConvenienceMethodTests.cs +++ b/test/AutoRest.TestServer.Tests/ConvenienceMethodTests.cs @@ -99,8 +99,8 @@ public void ProtocolRequiredQueryScenario() [Test] public void ProtocolOptionalModelScenario() { - var protocolInUpdate = typeof(ConvenienceInCadlClient).GetMethod("ProtocolOptionalModel"); - var convenienceInUpdate = typeof(ConvenienceInCadlClient).GetMethod("ProtocolOptionalModelValue"); + var protocolInUpdate = typeof(ConvenienceInCadlClient).GetMethod("ProtocolOptionalModel", new[] { typeof(RequestContent), typeof(RequestContext) }); + var convenienceInUpdate = typeof(ConvenienceInCadlClient).GetMethod("ProtocolOptionalModel", new[] { typeof(Model), typeof(CancellationToken) }); Assert.AreEqual(true, protocolInUpdate.GetParameters().Last().IsOptional); Assert.AreEqual(false, protocolInUpdate.GetParameters().First().IsOptional); // This is RequestContent, which is actually optional. Assert.AreEqual(true, convenienceInUpdate.GetParameters().First().IsOptional); @@ -165,8 +165,8 @@ public void ConvenienceRequiredQueryWithRequiredScenario() [Test] public void ConvenienceOptionalModelWithOptionalScenario() { - var protocolInUpdate = typeof(ConvenienceInCadlClient).GetMethod("ConvenienceOptionalModelWithOptional"); - var convenienceInUpdate = typeof(ConvenienceInCadlClient).GetMethod("ConvenienceOptionalModelWithOptionalValue"); + var protocolInUpdate = typeof(ConvenienceInCadlClient).GetMethod("ConvenienceOptionalModelWithOptional", new[] { typeof(RequestContent), typeof(RequestContext) }); + var convenienceInUpdate = typeof(ConvenienceInCadlClient).GetMethod("ConvenienceOptionalModelWithOptional", new[] { typeof(Model), typeof(CancellationToken) }); Assert.AreEqual(true, protocolInUpdate.GetParameters().Last().IsOptional); Assert.AreEqual(false, protocolInUpdate.GetParameters().First().IsOptional); // This is RequestContent, which is actually optional. Assert.AreEqual(true, convenienceInUpdate.GetParameters().First().IsOptional); @@ -189,7 +189,7 @@ public void ConvenienceOptionalModelWithRequiredScenario() { var protocolInUpdate = typeof(ConvenienceInCadlClient).GetMethod("ConvenienceOptionalModelWithRequired", new[] { typeof(RequestContent), typeof(RequestContext) }); var convenienceInUpdate = typeof(ConvenienceInCadlClient).GetMethod("ConvenienceOptionalModelWithRequired", new[] { typeof(Model), typeof(CancellationToken) }); - Assert.AreEqual(false, protocolInUpdate.GetParameters().Last().IsOptional); + Assert.AreEqual(true, protocolInUpdate.GetParameters().Last().IsOptional); Assert.AreEqual(false, protocolInUpdate.GetParameters().First().IsOptional); // This is RequestContent, which is actually optional. Assert.AreEqual(true, convenienceInUpdate.GetParameters().First().IsOptional); } @@ -232,7 +232,7 @@ public void NoConvenienceRequiredBodyScenario() public void NoConvenienceOptionalBodyScenario() { var protocolInUpdate = typeof(ConvenienceInCadlClient).GetMethod("NoConvenienceOptionalBody"); - Assert.AreEqual(false, protocolInUpdate.GetParameters().Last().IsOptional); + Assert.AreEqual(true, protocolInUpdate.GetParameters().Last().IsOptional); } [Test] diff --git a/test/AutoRest.TestServerLowLevel.Tests/LowLevel/ParameterSequenceTests.cs b/test/AutoRest.TestServerLowLevel.Tests/LowLevel/ParameterSequenceTests.cs index c85786edecb..584261eb2f8 100644 --- a/test/AutoRest.TestServerLowLevel.Tests/LowLevel/ParameterSequenceTests.cs +++ b/test/AutoRest.TestServerLowLevel.Tests/LowLevel/ParameterSequenceTests.cs @@ -17,7 +17,7 @@ public class ParameterSequenceTests { [TestCase(typeof(ParametersLowlevelClient), "OptionalPathParameters", new Type[] { typeof(int), typeof(string), typeof(int), typeof(RequestContext) }, new string[] { "id", "name", "skip", "context" }, new bool[] { false, false, false, true })] [TestCase(typeof(ParametersLowlevelClient), "OptionalPathParametersWithMixedSequence", new Type[] { typeof(int), typeof(string), typeof(int), typeof(RequestContext) }, new string[] { "id", "name", "skip", "context" }, new bool[] { false, false, false, true })] - [TestCase(typeof(ParametersLowlevelClient), "OptionalPathBodyParametersWithMixedSequence", new Type[] { typeof(int), typeof(string), typeof(int), typeof(int), typeof(RequestContent), typeof(int), typeof(RequestContext) }, new string[] { "id", "name", "skip", "max", "content", "top", "context" }, new bool[] { false, false, false, false, false, false, false })] + [TestCase(typeof(ParametersLowlevelClient), "OptionalPathBodyParametersWithMixedSequence", new Type[] { typeof(int), typeof(string), typeof(int), typeof(int), typeof(RequestContent), typeof(int), typeof(RequestContext) }, new string[] { "id", "name", "skip", "max", "content", "top", "context" }, new bool[] { false, false, false, false, false, true, true })] [TestCase(typeof(ParametersCadlClient), "Operation", new Type[] { typeof(int), typeof(int), typeof(CancellationToken) }, new string[] { "start", "end", "cancellationToken" }, new bool[] { false, true, true })] [TestCase(typeof(ParametersCadlClient), "Operation", new Type[] { typeof(int), typeof(int), typeof(RequestContext) }, new string[] { "start", "end", "context" }, new bool[] { false, false, false })] [TestCase(typeof(ParametersCadlClient), "Operation2", new Type[] { typeof(int), typeof(int), typeof(CancellationToken) }, new string[] { "end", "start", "cancellationToken" }, new bool[] { false, true, true })] diff --git a/test/AutoRest.TestServerLowLevel.Tests/RequestContextAllOptionalTests.cs b/test/AutoRest.TestServerLowLevel.Tests/RequestContextAllOptionalTests.cs index e155eb49a3a..0b035769890 100644 --- a/test/AutoRest.TestServerLowLevel.Tests/RequestContextAllOptionalTests.cs +++ b/test/AutoRest.TestServerLowLevel.Tests/RequestContextAllOptionalTests.cs @@ -50,7 +50,7 @@ public void RequestBodyResponseBody() Assert.AreEqual(parameters[0].ParameterType, typeof(RequestContent)); Assert.AreEqual(parameters[0].IsOptional, false); Assert.AreEqual(parameters[1].ParameterType, typeof(RequestContext)); - Assert.AreEqual(parameters[1].IsOptional, false); + Assert.AreEqual(parameters[1].IsOptional, true); } [Test] @@ -76,7 +76,7 @@ public void RequestBodyNoResponseBody() Assert.AreEqual(parameters[0].ParameterType, typeof(RequestContent)); Assert.AreEqual(parameters[0].IsOptional, false); Assert.AreEqual(parameters[1].ParameterType, typeof(RequestContext)); - Assert.AreEqual(parameters[1].IsOptional, false); + Assert.AreEqual(parameters[1].IsOptional, true); } } } diff --git a/test/TestProjects/Accessibility-LowLevel-NoAuth/src/Generated/AccessibilityClient.cs b/test/TestProjects/Accessibility-LowLevel-NoAuth/src/Generated/AccessibilityClient.cs index 4acd05b8378..591efccd083 100644 --- a/test/TestProjects/Accessibility-LowLevel-NoAuth/src/Generated/AccessibilityClient.cs +++ b/test/TestProjects/Accessibility-LowLevel-NoAuth/src/Generated/AccessibilityClient.cs @@ -60,7 +60,7 @@ public AccessibilityClient(Uri endpoint, AccessibilityClientOptions options) /// Service returned a non-success status code. /// The response returned from the service. /// - public virtual async Task OperationAsync(RequestContent content, RequestContext context) + public virtual async Task OperationAsync(RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("AccessibilityClient.Operation"); scope.Start(); @@ -91,7 +91,7 @@ public virtual async Task OperationAsync(RequestContent content, Reque /// Service returned a non-success status code. /// The response returned from the service. /// - public virtual Response Operation(RequestContent content, RequestContext context) + public virtual Response Operation(RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("AccessibilityClient.Operation"); scope.Start(); @@ -122,7 +122,7 @@ public virtual Response Operation(RequestContent content, RequestContext context /// Service returned a non-success status code. /// The response returned from the service. /// - internal virtual async Task OperationInternalAsync(RequestContent content, RequestContext context) + internal virtual async Task OperationInternalAsync(RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("AccessibilityClient.OperationInternal"); scope.Start(); @@ -153,7 +153,7 @@ internal virtual async Task OperationInternalAsync(RequestContent cont /// Service returned a non-success status code. /// The response returned from the service. /// - internal virtual Response OperationInternal(RequestContent content, RequestContext context) + internal virtual Response OperationInternal(RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("AccessibilityClient.OperationInternal"); scope.Start(); diff --git a/test/TestProjects/Accessibility-LowLevel-NoAuth/src/Generated/Docs/AccessibilityClient.xml b/test/TestProjects/Accessibility-LowLevel-NoAuth/src/Generated/Docs/AccessibilityClient.xml index df7752b2e50..eda969abdec 100644 --- a/test/TestProjects/Accessibility-LowLevel-NoAuth/src/Generated/Docs/AccessibilityClient.xml +++ b/test/TestProjects/Accessibility-LowLevel-NoAuth/src/Generated/Docs/AccessibilityClient.xml @@ -3,26 +3,26 @@ -This sample shows how to call OperationAsync with required parameters and request content. +This sample shows how to call OperationAsync with required request content. "; -Response response = await client.OperationAsync(RequestContent.Create(data), new RequestContext()); +Response response = await client.OperationAsync(RequestContent.Create(data)); Console.WriteLine(response.Status); ]]> -This sample shows how to call Operation with required parameters and request content. +This sample shows how to call Operation with required request content. "; -Response response = client.Operation(RequestContent.Create(data), new RequestContext()); +Response response = client.Operation(RequestContent.Create(data)); Console.WriteLine(response.Status); ]]> diff --git a/test/TestProjects/Accessibility-LowLevel-NoAuth/tests/Generated/Samples/Samples_AccessibilityClient.cs b/test/TestProjects/Accessibility-LowLevel-NoAuth/tests/Generated/Samples/Samples_AccessibilityClient.cs index ea360eb0ddc..e4db01b1f11 100644 --- a/test/TestProjects/Accessibility-LowLevel-NoAuth/tests/Generated/Samples/Samples_AccessibilityClient.cs +++ b/test/TestProjects/Accessibility-LowLevel-NoAuth/tests/Generated/Samples/Samples_AccessibilityClient.cs @@ -27,7 +27,7 @@ public void Example_Operation() var data = ""; - Response response = client.Operation(RequestContent.Create(data), new RequestContext()); + Response response = client.Operation(RequestContent.Create(data)); Console.WriteLine(response.Status); } @@ -39,7 +39,7 @@ public void Example_Operation_AllParameters() var data = ""; - Response response = client.Operation(RequestContent.Create(data), new RequestContext()); + Response response = client.Operation(RequestContent.Create(data)); Console.WriteLine(response.Status); } @@ -51,7 +51,7 @@ public async Task Example_Operation_Async() var data = ""; - Response response = await client.OperationAsync(RequestContent.Create(data), new RequestContext()); + Response response = await client.OperationAsync(RequestContent.Create(data)); Console.WriteLine(response.Status); } @@ -63,7 +63,7 @@ public async Task Example_Operation_AllParameters_Async() var data = ""; - Response response = await client.OperationAsync(RequestContent.Create(data), new RequestContext()); + Response response = await client.OperationAsync(RequestContent.Create(data)); Console.WriteLine(response.Status); } } diff --git a/test/TestProjects/Accessibility-LowLevel-TokenAuth/src/Generated/AccessibilityClient.cs b/test/TestProjects/Accessibility-LowLevel-TokenAuth/src/Generated/AccessibilityClient.cs index 414707e4d11..d8510552e58 100644 --- a/test/TestProjects/Accessibility-LowLevel-TokenAuth/src/Generated/AccessibilityClient.cs +++ b/test/TestProjects/Accessibility-LowLevel-TokenAuth/src/Generated/AccessibilityClient.cs @@ -72,7 +72,7 @@ public AccessibilityClient(TokenCredential credential, Uri endpoint, Accessibili /// Service returned a non-success status code. /// The response returned from the service. /// - public virtual async Task OperationAsync(RequestContent content, RequestContext context) + public virtual async Task OperationAsync(RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("AccessibilityClient.Operation"); scope.Start(); @@ -103,7 +103,7 @@ public virtual async Task OperationAsync(RequestContent content, Reque /// Service returned a non-success status code. /// The response returned from the service. /// - public virtual Response Operation(RequestContent content, RequestContext context) + public virtual Response Operation(RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("AccessibilityClient.Operation"); scope.Start(); @@ -134,7 +134,7 @@ public virtual Response Operation(RequestContent content, RequestContext context /// Service returned a non-success status code. /// The response returned from the service. /// - internal virtual async Task OperationInternalAsync(RequestContent content, RequestContext context) + internal virtual async Task OperationInternalAsync(RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("AccessibilityClient.OperationInternal"); scope.Start(); @@ -165,7 +165,7 @@ internal virtual async Task OperationInternalAsync(RequestContent cont /// Service returned a non-success status code. /// The response returned from the service. /// - internal virtual Response OperationInternal(RequestContent content, RequestContext context) + internal virtual Response OperationInternal(RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("AccessibilityClient.OperationInternal"); scope.Start(); diff --git a/test/TestProjects/Accessibility-LowLevel-TokenAuth/src/Generated/Docs/AccessibilityClient.xml b/test/TestProjects/Accessibility-LowLevel-TokenAuth/src/Generated/Docs/AccessibilityClient.xml index cbd4d79b4dc..6c0bff7f08b 100644 --- a/test/TestProjects/Accessibility-LowLevel-TokenAuth/src/Generated/Docs/AccessibilityClient.xml +++ b/test/TestProjects/Accessibility-LowLevel-TokenAuth/src/Generated/Docs/AccessibilityClient.xml @@ -3,28 +3,28 @@ -This sample shows how to call OperationAsync with required parameters and request content. +This sample shows how to call OperationAsync with required request content. "; -Response response = await client.OperationAsync(RequestContent.Create(data), new RequestContext()); +Response response = await client.OperationAsync(RequestContent.Create(data)); Console.WriteLine(response.Status); ]]> -This sample shows how to call Operation with required parameters and request content. +This sample shows how to call Operation with required request content. "; -Response response = client.Operation(RequestContent.Create(data), new RequestContext()); +Response response = client.Operation(RequestContent.Create(data)); Console.WriteLine(response.Status); ]]> diff --git a/test/TestProjects/Accessibility-LowLevel-TokenAuth/tests/Generated/Samples/Samples_AccessibilityClient.cs b/test/TestProjects/Accessibility-LowLevel-TokenAuth/tests/Generated/Samples/Samples_AccessibilityClient.cs index e6cade9e1eb..6dd2a750215 100644 --- a/test/TestProjects/Accessibility-LowLevel-TokenAuth/tests/Generated/Samples/Samples_AccessibilityClient.cs +++ b/test/TestProjects/Accessibility-LowLevel-TokenAuth/tests/Generated/Samples/Samples_AccessibilityClient.cs @@ -28,7 +28,7 @@ public void Example_Operation() var data = ""; - Response response = client.Operation(RequestContent.Create(data), new RequestContext()); + Response response = client.Operation(RequestContent.Create(data)); Console.WriteLine(response.Status); } @@ -41,7 +41,7 @@ public void Example_Operation_AllParameters() var data = ""; - Response response = client.Operation(RequestContent.Create(data), new RequestContext()); + Response response = client.Operation(RequestContent.Create(data)); Console.WriteLine(response.Status); } @@ -54,7 +54,7 @@ public async Task Example_Operation_Async() var data = ""; - Response response = await client.OperationAsync(RequestContent.Create(data), new RequestContext()); + Response response = await client.OperationAsync(RequestContent.Create(data)); Console.WriteLine(response.Status); } @@ -67,7 +67,7 @@ public async Task Example_Operation_AllParameters_Async() var data = ""; - Response response = await client.OperationAsync(RequestContent.Create(data), new RequestContext()); + Response response = await client.OperationAsync(RequestContent.Create(data)); Console.WriteLine(response.Status); } } diff --git a/test/TestProjects/Accessibility-LowLevel/src/Generated/AccessibilityClient.cs b/test/TestProjects/Accessibility-LowLevel/src/Generated/AccessibilityClient.cs index d11df3702b5..9da436f2904 100644 --- a/test/TestProjects/Accessibility-LowLevel/src/Generated/AccessibilityClient.cs +++ b/test/TestProjects/Accessibility-LowLevel/src/Generated/AccessibilityClient.cs @@ -72,7 +72,7 @@ public AccessibilityClient(AzureKeyCredential credential, Uri endpoint, Accessib /// Service returned a non-success status code. /// The response returned from the service. /// - public virtual async Task OperationAsync(RequestContent content, RequestContext context) + public virtual async Task OperationAsync(RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("AccessibilityClient.Operation"); scope.Start(); @@ -103,7 +103,7 @@ public virtual async Task OperationAsync(RequestContent content, Reque /// Service returned a non-success status code. /// The response returned from the service. /// - public virtual Response Operation(RequestContent content, RequestContext context) + public virtual Response Operation(RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("AccessibilityClient.Operation"); scope.Start(); @@ -134,7 +134,7 @@ public virtual Response Operation(RequestContent content, RequestContext context /// Service returned a non-success status code. /// The response returned from the service. /// - internal virtual async Task OperationInternalAsync(RequestContent content, RequestContext context) + internal virtual async Task OperationInternalAsync(RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("AccessibilityClient.OperationInternal"); scope.Start(); @@ -165,7 +165,7 @@ internal virtual async Task OperationInternalAsync(RequestContent cont /// Service returned a non-success status code. /// The response returned from the service. /// - internal virtual Response OperationInternal(RequestContent content, RequestContext context) + internal virtual Response OperationInternal(RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("AccessibilityClient.OperationInternal"); scope.Start(); diff --git a/test/TestProjects/Accessibility-LowLevel/src/Generated/Docs/AccessibilityClient.xml b/test/TestProjects/Accessibility-LowLevel/src/Generated/Docs/AccessibilityClient.xml index 616ac92853f..164728de8b1 100644 --- a/test/TestProjects/Accessibility-LowLevel/src/Generated/Docs/AccessibilityClient.xml +++ b/test/TestProjects/Accessibility-LowLevel/src/Generated/Docs/AccessibilityClient.xml @@ -3,28 +3,28 @@ -This sample shows how to call OperationAsync with required parameters and request content. +This sample shows how to call OperationAsync with required request content. "); var client = new AccessibilityClient(credential); var data = ""; -Response response = await client.OperationAsync(RequestContent.Create(data), new RequestContext()); +Response response = await client.OperationAsync(RequestContent.Create(data)); Console.WriteLine(response.Status); ]]> -This sample shows how to call Operation with required parameters and request content. +This sample shows how to call Operation with required request content. "); var client = new AccessibilityClient(credential); var data = ""; -Response response = client.Operation(RequestContent.Create(data), new RequestContext()); +Response response = client.Operation(RequestContent.Create(data)); Console.WriteLine(response.Status); ]]> diff --git a/test/TestProjects/Accessibility-LowLevel/tests/Generated/Samples/Samples_AccessibilityClient.cs b/test/TestProjects/Accessibility-LowLevel/tests/Generated/Samples/Samples_AccessibilityClient.cs index 4397579e085..83c3cca78f8 100644 --- a/test/TestProjects/Accessibility-LowLevel/tests/Generated/Samples/Samples_AccessibilityClient.cs +++ b/test/TestProjects/Accessibility-LowLevel/tests/Generated/Samples/Samples_AccessibilityClient.cs @@ -28,7 +28,7 @@ public void Example_Operation() var data = ""; - Response response = client.Operation(RequestContent.Create(data), new RequestContext()); + Response response = client.Operation(RequestContent.Create(data)); Console.WriteLine(response.Status); } @@ -41,7 +41,7 @@ public void Example_Operation_AllParameters() var data = ""; - Response response = client.Operation(RequestContent.Create(data), new RequestContext()); + Response response = client.Operation(RequestContent.Create(data)); Console.WriteLine(response.Status); } @@ -54,7 +54,7 @@ public async Task Example_Operation_Async() var data = ""; - Response response = await client.OperationAsync(RequestContent.Create(data), new RequestContext()); + Response response = await client.OperationAsync(RequestContent.Create(data)); Console.WriteLine(response.Status); } @@ -67,7 +67,7 @@ public async Task Example_Operation_AllParameters_Async() var data = ""; - Response response = await client.OperationAsync(RequestContent.Create(data), new RequestContext()); + Response response = await client.OperationAsync(RequestContent.Create(data)); Console.WriteLine(response.Status); } } diff --git a/test/TestProjects/CollapseRequestCondition-LowLevel/src/Generated/Docs/MatchConditionCollapseClient.xml b/test/TestProjects/CollapseRequestCondition-LowLevel/src/Generated/Docs/MatchConditionCollapseClient.xml index 334a473e29d..4ca67f9ca0b 100644 --- a/test/TestProjects/CollapseRequestCondition-LowLevel/src/Generated/Docs/MatchConditionCollapseClient.xml +++ b/test/TestProjects/CollapseRequestCondition-LowLevel/src/Generated/Docs/MatchConditionCollapseClient.xml @@ -50,7 +50,17 @@ var client = new MatchConditionCollapseClient(credential); var data = ""; -Response response = await client.CollapsePutAsync(RequestContent.Create(data), new MatchConditions { IfMatch = new ETag("") }, new RequestContext()); +Response response = await client.CollapsePutAsync(RequestContent.Create(data)); +Console.WriteLine(response.Status); +]]> +This sample shows how to call CollapsePutAsync with all parameters and request content. +"); +var client = new MatchConditionCollapseClient(credential); + +var data = ""; + +Response response = await client.CollapsePutAsync(RequestContent.Create(data), new MatchConditions { IfMatch = new ETag("") }); Console.WriteLine(response.Status); ]]> @@ -64,7 +74,17 @@ var client = new MatchConditionCollapseClient(credential); var data = ""; -Response response = client.CollapsePut(RequestContent.Create(data), new MatchConditions { IfMatch = new ETag("") }, new RequestContext()); +Response response = client.CollapsePut(RequestContent.Create(data)); +Console.WriteLine(response.Status); +]]> +This sample shows how to call CollapsePut with all parameters and request content. +"); +var client = new MatchConditionCollapseClient(credential); + +var data = ""; + +Response response = client.CollapsePut(RequestContent.Create(data), new MatchConditions { IfMatch = new ETag("") }); Console.WriteLine(response.Status); ]]> diff --git a/test/TestProjects/CollapseRequestCondition-LowLevel/src/Generated/Docs/NonCollapseClient.xml b/test/TestProjects/CollapseRequestCondition-LowLevel/src/Generated/Docs/NonCollapseClient.xml index beb88f0d582..a5e9841cf49 100644 --- a/test/TestProjects/CollapseRequestCondition-LowLevel/src/Generated/Docs/NonCollapseClient.xml +++ b/test/TestProjects/CollapseRequestCondition-LowLevel/src/Generated/Docs/NonCollapseClient.xml @@ -10,7 +10,17 @@ var client = new NonCollapseClient(credential); var data = ""; -Response response = await client.IfMatchPutAsync(RequestContent.Create(data), null, new RequestContext()); +Response response = await client.IfMatchPutAsync(RequestContent.Create(data)); +Console.WriteLine(response.Status); +]]> +This sample shows how to call IfMatchPutAsync with all parameters and request content. +"); +var client = new NonCollapseClient(credential); + +var data = ""; + +Response response = await client.IfMatchPutAsync(RequestContent.Create(data), null); Console.WriteLine(response.Status); ]]> @@ -24,7 +34,17 @@ var client = new NonCollapseClient(credential); var data = ""; -Response response = client.IfMatchPut(RequestContent.Create(data), null, new RequestContext()); +Response response = client.IfMatchPut(RequestContent.Create(data)); +Console.WriteLine(response.Status); +]]> +This sample shows how to call IfMatchPut with all parameters and request content. +"); +var client = new NonCollapseClient(credential); + +var data = ""; + +Response response = client.IfMatchPut(RequestContent.Create(data), null); Console.WriteLine(response.Status); ]]> @@ -38,7 +58,17 @@ var client = new NonCollapseClient(credential); var data = ""; -Response response = await client.IfNoneMatchPutAsync(RequestContent.Create(data), null, new RequestContext()); +Response response = await client.IfNoneMatchPutAsync(RequestContent.Create(data)); +Console.WriteLine(response.Status); +]]> +This sample shows how to call IfNoneMatchPutAsync with all parameters and request content. +"); +var client = new NonCollapseClient(credential); + +var data = ""; + +Response response = await client.IfNoneMatchPutAsync(RequestContent.Create(data), null); Console.WriteLine(response.Status); ]]> @@ -52,7 +82,17 @@ var client = new NonCollapseClient(credential); var data = ""; -Response response = client.IfNoneMatchPut(RequestContent.Create(data), null, new RequestContext()); +Response response = client.IfNoneMatchPut(RequestContent.Create(data)); +Console.WriteLine(response.Status); +]]> +This sample shows how to call IfNoneMatchPut with all parameters and request content. +"); +var client = new NonCollapseClient(credential); + +var data = ""; + +Response response = client.IfNoneMatchPut(RequestContent.Create(data), null); Console.WriteLine(response.Status); ]]> diff --git a/test/TestProjects/CollapseRequestCondition-LowLevel/src/Generated/Docs/RequestConditionCollapseClient.xml b/test/TestProjects/CollapseRequestCondition-LowLevel/src/Generated/Docs/RequestConditionCollapseClient.xml index 1f5961aa69e..6dd0bff02a0 100644 --- a/test/TestProjects/CollapseRequestCondition-LowLevel/src/Generated/Docs/RequestConditionCollapseClient.xml +++ b/test/TestProjects/CollapseRequestCondition-LowLevel/src/Generated/Docs/RequestConditionCollapseClient.xml @@ -10,7 +10,17 @@ var client = new RequestConditionCollapseClient(credential); var data = ""; -Response response = await client.CollapsePutAsync(RequestContent.Create(data), null, new RequestContext()); +Response response = await client.CollapsePutAsync(RequestContent.Create(data)); +Console.WriteLine(response.Status); +]]> +This sample shows how to call CollapsePutAsync with all parameters and request content. +"); +var client = new RequestConditionCollapseClient(credential); + +var data = ""; + +Response response = await client.CollapsePutAsync(RequestContent.Create(data), null); Console.WriteLine(response.Status); ]]> @@ -24,7 +34,17 @@ var client = new RequestConditionCollapseClient(credential); var data = ""; -Response response = client.CollapsePut(RequestContent.Create(data), null, new RequestContext()); +Response response = client.CollapsePut(RequestContent.Create(data)); +Console.WriteLine(response.Status); +]]> +This sample shows how to call CollapsePut with all parameters and request content. +"); +var client = new RequestConditionCollapseClient(credential); + +var data = ""; + +Response response = client.CollapsePut(RequestContent.Create(data), null); Console.WriteLine(response.Status); ]]> diff --git a/test/TestProjects/CollapseRequestCondition-LowLevel/src/Generated/MatchConditionCollapseClient.cs b/test/TestProjects/CollapseRequestCondition-LowLevel/src/Generated/MatchConditionCollapseClient.cs index 01b64b35203..e31d08cbc43 100644 --- a/test/TestProjects/CollapseRequestCondition-LowLevel/src/Generated/MatchConditionCollapseClient.cs +++ b/test/TestProjects/CollapseRequestCondition-LowLevel/src/Generated/MatchConditionCollapseClient.cs @@ -137,7 +137,7 @@ public virtual Response CollapseGetWithHead(string otherHeader = null, MatchCond /// Service returned a non-success status code. /// The response returned from the service. /// - public virtual async Task CollapsePutAsync(RequestContent content, MatchConditions matchConditions, RequestContext context) + public virtual async Task CollapsePutAsync(RequestContent content, MatchConditions matchConditions = null, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("MatchConditionCollapseClient.CollapsePut"); scope.Start(); @@ -169,7 +169,7 @@ public virtual async Task CollapsePutAsync(RequestContent content, Mat /// Service returned a non-success status code. /// The response returned from the service. /// - public virtual Response CollapsePut(RequestContent content, MatchConditions matchConditions, RequestContext context) + public virtual Response CollapsePut(RequestContent content, MatchConditions matchConditions = null, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("MatchConditionCollapseClient.CollapsePut"); scope.Start(); diff --git a/test/TestProjects/CollapseRequestCondition-LowLevel/src/Generated/NonCollapseClient.cs b/test/TestProjects/CollapseRequestCondition-LowLevel/src/Generated/NonCollapseClient.cs index 0725db57683..f082757096d 100644 --- a/test/TestProjects/CollapseRequestCondition-LowLevel/src/Generated/NonCollapseClient.cs +++ b/test/TestProjects/CollapseRequestCondition-LowLevel/src/Generated/NonCollapseClient.cs @@ -73,7 +73,7 @@ public NonCollapseClient(AzureKeyCredential credential, Uri endpoint, CollapseRe /// Service returned a non-success status code. /// The response returned from the service. /// - public virtual async Task IfMatchPutAsync(RequestContent content, ETag? ifMatch, RequestContext context) + public virtual async Task IfMatchPutAsync(RequestContent content, ETag? ifMatch = null, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("NonCollapseClient.IfMatchPut"); scope.Start(); @@ -105,7 +105,7 @@ public virtual async Task IfMatchPutAsync(RequestContent content, ETag /// Service returned a non-success status code. /// The response returned from the service. /// - public virtual Response IfMatchPut(RequestContent content, ETag? ifMatch, RequestContext context) + public virtual Response IfMatchPut(RequestContent content, ETag? ifMatch = null, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("NonCollapseClient.IfMatchPut"); scope.Start(); @@ -137,7 +137,7 @@ public virtual Response IfMatchPut(RequestContent content, ETag? ifMatch, Reques /// Service returned a non-success status code. /// The response returned from the service. /// - public virtual async Task IfNoneMatchPutAsync(RequestContent content, ETag? ifNoneMatch, RequestContext context) + public virtual async Task IfNoneMatchPutAsync(RequestContent content, ETag? ifNoneMatch = null, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("NonCollapseClient.IfNoneMatchPut"); scope.Start(); @@ -169,7 +169,7 @@ public virtual async Task IfNoneMatchPutAsync(RequestContent content, /// Service returned a non-success status code. /// The response returned from the service. /// - public virtual Response IfNoneMatchPut(RequestContent content, ETag? ifNoneMatch, RequestContext context) + public virtual Response IfNoneMatchPut(RequestContent content, ETag? ifNoneMatch = null, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("NonCollapseClient.IfNoneMatchPut"); scope.Start(); diff --git a/test/TestProjects/CollapseRequestCondition-LowLevel/src/Generated/RequestConditionCollapseClient.cs b/test/TestProjects/CollapseRequestCondition-LowLevel/src/Generated/RequestConditionCollapseClient.cs index 29ddcb2c172..be69eabb3bb 100644 --- a/test/TestProjects/CollapseRequestCondition-LowLevel/src/Generated/RequestConditionCollapseClient.cs +++ b/test/TestProjects/CollapseRequestCondition-LowLevel/src/Generated/RequestConditionCollapseClient.cs @@ -73,7 +73,7 @@ public RequestConditionCollapseClient(AzureKeyCredential credential, Uri endpoin /// Service returned a non-success status code. /// The response returned from the service. /// - public virtual async Task CollapsePutAsync(RequestContent content, RequestConditions requestConditions, RequestContext context) + public virtual async Task CollapsePutAsync(RequestContent content, RequestConditions requestConditions = null, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("RequestConditionCollapseClient.CollapsePut"); scope.Start(); @@ -105,7 +105,7 @@ public virtual async Task CollapsePutAsync(RequestContent content, Req /// Service returned a non-success status code. /// The response returned from the service. /// - public virtual Response CollapsePut(RequestContent content, RequestConditions requestConditions, RequestContext context) + public virtual Response CollapsePut(RequestContent content, RequestConditions requestConditions = null, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("RequestConditionCollapseClient.CollapsePut"); scope.Start(); diff --git a/test/TestProjects/CollapseRequestCondition-LowLevel/tests/Generated/Samples/Samples_MatchConditionCollapseClient.cs b/test/TestProjects/CollapseRequestCondition-LowLevel/tests/Generated/Samples/Samples_MatchConditionCollapseClient.cs index c3045f4f9ba..98b76f686d0 100644 --- a/test/TestProjects/CollapseRequestCondition-LowLevel/tests/Generated/Samples/Samples_MatchConditionCollapseClient.cs +++ b/test/TestProjects/CollapseRequestCondition-LowLevel/tests/Generated/Samples/Samples_MatchConditionCollapseClient.cs @@ -72,7 +72,7 @@ public void Example_CollapsePut() var data = ""; - Response response = client.CollapsePut(RequestContent.Create(data), new MatchConditions { IfMatch = new ETag("") }, new RequestContext()); + Response response = client.CollapsePut(RequestContent.Create(data)); Console.WriteLine(response.Status); } @@ -85,7 +85,7 @@ public void Example_CollapsePut_AllParameters() var data = ""; - Response response = client.CollapsePut(RequestContent.Create(data), new MatchConditions { IfMatch = new ETag("") }, new RequestContext()); + Response response = client.CollapsePut(RequestContent.Create(data), new MatchConditions { IfMatch = new ETag("") }); Console.WriteLine(response.Status); } @@ -98,7 +98,7 @@ public async Task Example_CollapsePut_Async() var data = ""; - Response response = await client.CollapsePutAsync(RequestContent.Create(data), new MatchConditions { IfMatch = new ETag("") }, new RequestContext()); + Response response = await client.CollapsePutAsync(RequestContent.Create(data)); Console.WriteLine(response.Status); } @@ -111,7 +111,7 @@ public async Task Example_CollapsePut_AllParameters_Async() var data = ""; - Response response = await client.CollapsePutAsync(RequestContent.Create(data), new MatchConditions { IfMatch = new ETag("") }, new RequestContext()); + Response response = await client.CollapsePutAsync(RequestContent.Create(data), new MatchConditions { IfMatch = new ETag("") }); Console.WriteLine(response.Status); } diff --git a/test/TestProjects/CollapseRequestCondition-LowLevel/tests/Generated/Samples/Samples_NonCollapseClient.cs b/test/TestProjects/CollapseRequestCondition-LowLevel/tests/Generated/Samples/Samples_NonCollapseClient.cs index 938ed3a2f03..17b7437678b 100644 --- a/test/TestProjects/CollapseRequestCondition-LowLevel/tests/Generated/Samples/Samples_NonCollapseClient.cs +++ b/test/TestProjects/CollapseRequestCondition-LowLevel/tests/Generated/Samples/Samples_NonCollapseClient.cs @@ -28,7 +28,7 @@ public void Example_IfMatchPut() var data = ""; - Response response = client.IfMatchPut(RequestContent.Create(data), null, new RequestContext()); + Response response = client.IfMatchPut(RequestContent.Create(data)); Console.WriteLine(response.Status); } @@ -41,7 +41,7 @@ public void Example_IfMatchPut_AllParameters() var data = ""; - Response response = client.IfMatchPut(RequestContent.Create(data), null, new RequestContext()); + Response response = client.IfMatchPut(RequestContent.Create(data), null); Console.WriteLine(response.Status); } @@ -54,7 +54,7 @@ public async Task Example_IfMatchPut_Async() var data = ""; - Response response = await client.IfMatchPutAsync(RequestContent.Create(data), null, new RequestContext()); + Response response = await client.IfMatchPutAsync(RequestContent.Create(data)); Console.WriteLine(response.Status); } @@ -67,7 +67,7 @@ public async Task Example_IfMatchPut_AllParameters_Async() var data = ""; - Response response = await client.IfMatchPutAsync(RequestContent.Create(data), null, new RequestContext()); + Response response = await client.IfMatchPutAsync(RequestContent.Create(data), null); Console.WriteLine(response.Status); } @@ -80,7 +80,7 @@ public void Example_IfNoneMatchPut() var data = ""; - Response response = client.IfNoneMatchPut(RequestContent.Create(data), null, new RequestContext()); + Response response = client.IfNoneMatchPut(RequestContent.Create(data)); Console.WriteLine(response.Status); } @@ -93,7 +93,7 @@ public void Example_IfNoneMatchPut_AllParameters() var data = ""; - Response response = client.IfNoneMatchPut(RequestContent.Create(data), null, new RequestContext()); + Response response = client.IfNoneMatchPut(RequestContent.Create(data), null); Console.WriteLine(response.Status); } @@ -106,7 +106,7 @@ public async Task Example_IfNoneMatchPut_Async() var data = ""; - Response response = await client.IfNoneMatchPutAsync(RequestContent.Create(data), null, new RequestContext()); + Response response = await client.IfNoneMatchPutAsync(RequestContent.Create(data)); Console.WriteLine(response.Status); } @@ -119,7 +119,7 @@ public async Task Example_IfNoneMatchPut_AllParameters_Async() var data = ""; - Response response = await client.IfNoneMatchPutAsync(RequestContent.Create(data), null, new RequestContext()); + Response response = await client.IfNoneMatchPutAsync(RequestContent.Create(data), null); Console.WriteLine(response.Status); } } diff --git a/test/TestProjects/CollapseRequestCondition-LowLevel/tests/Generated/Samples/Samples_RequestConditionCollapseClient.cs b/test/TestProjects/CollapseRequestCondition-LowLevel/tests/Generated/Samples/Samples_RequestConditionCollapseClient.cs index ef234613af6..f0d51525bd6 100644 --- a/test/TestProjects/CollapseRequestCondition-LowLevel/tests/Generated/Samples/Samples_RequestConditionCollapseClient.cs +++ b/test/TestProjects/CollapseRequestCondition-LowLevel/tests/Generated/Samples/Samples_RequestConditionCollapseClient.cs @@ -28,7 +28,7 @@ public void Example_CollapsePut() var data = ""; - Response response = client.CollapsePut(RequestContent.Create(data), null, new RequestContext()); + Response response = client.CollapsePut(RequestContent.Create(data)); Console.WriteLine(response.Status); } @@ -41,7 +41,7 @@ public void Example_CollapsePut_AllParameters() var data = ""; - Response response = client.CollapsePut(RequestContent.Create(data), null, new RequestContext()); + Response response = client.CollapsePut(RequestContent.Create(data), null); Console.WriteLine(response.Status); } @@ -54,7 +54,7 @@ public async Task Example_CollapsePut_Async() var data = ""; - Response response = await client.CollapsePutAsync(RequestContent.Create(data), null, new RequestContext()); + Response response = await client.CollapsePutAsync(RequestContent.Create(data)); Console.WriteLine(response.Status); } @@ -67,7 +67,7 @@ public async Task Example_CollapsePut_AllParameters_Async() var data = ""; - Response response = await client.CollapsePutAsync(RequestContent.Create(data), null, new RequestContext()); + Response response = await client.CollapsePutAsync(RequestContent.Create(data), null); Console.WriteLine(response.Status); } diff --git a/test/TestProjects/ConvenienceUpdate-TypeSpec/src/Generated/ConvenienceInCadlClient.cs b/test/TestProjects/ConvenienceUpdate-TypeSpec/src/Generated/ConvenienceInCadlClient.cs index 66804c79af5..5031cecf264 100644 --- a/test/TestProjects/ConvenienceUpdate-TypeSpec/src/Generated/ConvenienceInCadlClient.cs +++ b/test/TestProjects/ConvenienceUpdate-TypeSpec/src/Generated/ConvenienceInCadlClient.cs @@ -387,7 +387,7 @@ public virtual Response NoConvenienceRequiredBody(RequestContent content, Reques /// Service returned a non-success status code. /// The response returned from the service. /// - public virtual async Task NoConvenienceOptionalBodyAsync(RequestContent content, RequestContext context) + public virtual async Task NoConvenienceOptionalBodyAsync(RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("ConvenienceInCadlClient.NoConvenienceOptionalBody"); scope.Start(); @@ -418,7 +418,7 @@ public virtual async Task NoConvenienceOptionalBodyAsync(RequestConten /// Service returned a non-success status code. /// The response returned from the service. /// - public virtual Response NoConvenienceOptionalBody(RequestContent content, RequestContext context) + public virtual Response NoConvenienceOptionalBody(RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("ConvenienceInCadlClient.NoConvenienceOptionalBody"); scope.Start(); @@ -1095,43 +1095,23 @@ public virtual Response ProtocolRequiredQuery(int required, RequestContext conte /// Initial operation only has protocol method with optional model parameter. In the updated version, we add the convenience method. /// The Model to use. /// The cancellation token to use. - /// - public virtual async Task ProtocolOptionalModelValueAsync(Model optional = null, CancellationToken cancellationToken = default) + /// + public virtual async Task ProtocolOptionalModelAsync(Model optional = null, CancellationToken cancellationToken = default) { - using var scope = ClientDiagnostics.CreateScope("ConvenienceInCadlClient.ProtocolOptionalModelValue"); - scope.Start(); - try - { - RequestContext context = FromCancellationToken(cancellationToken); - Response response = await ProtocolOptionalModelAsync(optional?.ToRequestContent(), context).ConfigureAwait(false); - return response; - } - catch (Exception e) - { - scope.Failed(e); - throw; - } + RequestContext context = FromCancellationToken(cancellationToken); + Response response = await ProtocolOptionalModelAsync(optional?.ToRequestContent(), context).ConfigureAwait(false); + return response; } /// Initial operation only has protocol method with optional model parameter. In the updated version, we add the convenience method. /// The Model to use. /// The cancellation token to use. - /// - public virtual Response ProtocolOptionalModelValue(Model optional = null, CancellationToken cancellationToken = default) + /// + public virtual Response ProtocolOptionalModel(Model optional = null, CancellationToken cancellationToken = default) { - using var scope = ClientDiagnostics.CreateScope("ConvenienceInCadlClient.ProtocolOptionalModelValue"); - scope.Start(); - try - { - RequestContext context = FromCancellationToken(cancellationToken); - Response response = ProtocolOptionalModel(optional?.ToRequestContent(), context); - return response; - } - catch (Exception e) - { - scope.Failed(e); - throw; - } + RequestContext context = FromCancellationToken(cancellationToken); + Response response = ProtocolOptionalModel(optional?.ToRequestContent(), context); + return response; } /// @@ -1144,7 +1124,7 @@ public virtual Response ProtocolOptionalModelValue(Model optional = null, Cancel /// /// /// - /// Please try the simpler convenience overload with strongly typed models first. + /// Please try the simpler convenience overload with strongly typed models first. /// /// /// @@ -1180,7 +1160,7 @@ public virtual async Task ProtocolOptionalModelAsync(RequestContent co /// /// /// - /// Please try the simpler convenience overload with strongly typed models first. + /// Please try the simpler convenience overload with strongly typed models first. /// /// /// @@ -1731,43 +1711,23 @@ public virtual Response ConvenienceRequiredQueryWithRequired(int required, Reque /// Operation has protocol method with optional body parameter and optional RequestContext and convenience method. /// The Model to use. /// The cancellation token to use. - /// - public virtual async Task ConvenienceOptionalModelWithOptionalValueAsync(Model optional = null, CancellationToken cancellationToken = default) + /// + public virtual async Task ConvenienceOptionalModelWithOptionalAsync(Model optional = null, CancellationToken cancellationToken = default) { - using var scope = ClientDiagnostics.CreateScope("ConvenienceInCadlClient.ConvenienceOptionalModelWithOptionalValue"); - scope.Start(); - try - { - RequestContext context = FromCancellationToken(cancellationToken); - Response response = await ConvenienceOptionalModelWithOptionalAsync(optional?.ToRequestContent(), context).ConfigureAwait(false); - return response; - } - catch (Exception e) - { - scope.Failed(e); - throw; - } + RequestContext context = FromCancellationToken(cancellationToken); + Response response = await ConvenienceOptionalModelWithOptionalAsync(optional?.ToRequestContent(), context).ConfigureAwait(false); + return response; } /// Operation has protocol method with optional body parameter and optional RequestContext and convenience method. /// The Model to use. /// The cancellation token to use. - /// - public virtual Response ConvenienceOptionalModelWithOptionalValue(Model optional = null, CancellationToken cancellationToken = default) + /// + public virtual Response ConvenienceOptionalModelWithOptional(Model optional = null, CancellationToken cancellationToken = default) { - using var scope = ClientDiagnostics.CreateScope("ConvenienceInCadlClient.ConvenienceOptionalModelWithOptionalValue"); - scope.Start(); - try - { - RequestContext context = FromCancellationToken(cancellationToken); - Response response = ConvenienceOptionalModelWithOptional(optional?.ToRequestContent(), context); - return response; - } - catch (Exception e) - { - scope.Failed(e); - throw; - } + RequestContext context = FromCancellationToken(cancellationToken); + Response response = ConvenienceOptionalModelWithOptional(optional?.ToRequestContent(), context); + return response; } /// @@ -1780,7 +1740,7 @@ public virtual Response ConvenienceOptionalModelWithOptionalValue(Model optional /// /// /// - /// Please try the simpler convenience overload with strongly typed models first. + /// Please try the simpler convenience overload with strongly typed models first. /// /// /// @@ -1816,7 +1776,7 @@ public virtual async Task ConvenienceOptionalModelWithOptionalAsync(Re /// /// /// - /// Please try the simpler convenience overload with strongly typed models first. + /// Please try the simpler convenience overload with strongly typed models first. /// /// /// @@ -1990,7 +1950,7 @@ public virtual Response ConvenienceOptionalModelWithRequired(Model optional = nu /// Service returned a non-success status code. /// The response returned from the service. /// - public virtual async Task ConvenienceOptionalModelWithRequiredAsync(RequestContent content, RequestContext context) + public virtual async Task ConvenienceOptionalModelWithRequiredAsync(RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("ConvenienceInCadlClient.ConvenienceOptionalModelWithRequired"); scope.Start(); @@ -2026,7 +1986,7 @@ public virtual async Task ConvenienceOptionalModelWithRequiredAsync(Re /// Service returned a non-success status code. /// The response returned from the service. /// - public virtual Response ConvenienceOptionalModelWithRequired(RequestContent content, RequestContext context) + public virtual Response ConvenienceOptionalModelWithRequired(RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("ConvenienceInCadlClient.ConvenienceOptionalModelWithRequired"); scope.Start(); diff --git a/test/TestProjects/ConvenienceUpdate-TypeSpec/src/Generated/Docs/ConvenienceInCadlClient.xml b/test/TestProjects/ConvenienceUpdate-TypeSpec/src/Generated/Docs/ConvenienceInCadlClient.xml index 7194851ef85..c97fd051e66 100644 --- a/test/TestProjects/ConvenienceUpdate-TypeSpec/src/Generated/Docs/ConvenienceInCadlClient.xml +++ b/test/TestProjects/ConvenienceUpdate-TypeSpec/src/Generated/Docs/ConvenienceInCadlClient.xml @@ -179,7 +179,7 @@ Console.WriteLine(response.Status); -This sample shows how to call NoConvenienceOptionalBodyAsync with required parameters and request content. +This sample shows how to call NoConvenienceOptionalBodyAsync with required request content. ", }; -Response response = await client.NoConvenienceOptionalBodyAsync(RequestContent.Create(data), new RequestContext()); +Response response = await client.NoConvenienceOptionalBodyAsync(RequestContent.Create(data)); Console.WriteLine(response.Status); ]]> -This sample shows how to call NoConvenienceOptionalBody with required parameters and request content. +This sample shows how to call NoConvenienceOptionalBody with required request content. ", }; -Response response = client.NoConvenienceOptionalBody(RequestContent.Create(data), new RequestContext()); +Response response = client.NoConvenienceOptionalBody(RequestContent.Create(data)); Console.WriteLine(response.Status); ]]> @@ -499,25 +499,25 @@ Console.WriteLine(result.GetProperty("id").ToString()); ]]> - + -This sample shows how to call ProtocolOptionalModelValueAsync with required parameters. +This sample shows how to call ProtocolOptionalModelAsync with required parameters. "); -var result = await client.ProtocolOptionalModelValueAsync(optional); +var result = await client.ProtocolOptionalModelAsync(optional); ]]> - + -This sample shows how to call ProtocolOptionalModelValue with required parameters. +This sample shows how to call ProtocolOptionalModel with required parameters. "); -var result = client.ProtocolOptionalModelValue(optional); +var result = client.ProtocolOptionalModel(optional); ]]> @@ -805,25 +805,25 @@ Console.WriteLine(result.GetProperty("id").ToString()); ]]> - + -This sample shows how to call ConvenienceOptionalModelWithOptionalValueAsync with required parameters. +This sample shows how to call ConvenienceOptionalModelWithOptionalAsync with required parameters. "); -var result = await client.ConvenienceOptionalModelWithOptionalValueAsync(optional); +var result = await client.ConvenienceOptionalModelWithOptionalAsync(optional); ]]> - + -This sample shows how to call ConvenienceOptionalModelWithOptionalValue with required parameters. +This sample shows how to call ConvenienceOptionalModelWithOptional with required parameters. "); -var result = client.ConvenienceOptionalModelWithOptionalValue(optional); +var result = client.ConvenienceOptionalModelWithOptional(optional); ]]> @@ -933,7 +933,7 @@ var result = client.ConvenienceOptionalModelWithRequired(optional); -This sample shows how to call ConvenienceOptionalModelWithRequiredAsync with required parameters and request content. +This sample shows how to call ConvenienceOptionalModelWithRequiredAsync with required request content. ", }; -Response response = await client.ConvenienceOptionalModelWithRequiredAsync(RequestContent.Create(data), new RequestContext()); +Response response = await client.ConvenienceOptionalModelWithRequiredAsync(RequestContent.Create(data)); Console.WriteLine(response.Status); ]]> -This sample shows how to call ConvenienceOptionalModelWithRequired with required parameters and request content. +This sample shows how to call ConvenienceOptionalModelWithRequired with required request content. ", }; -Response response = client.ConvenienceOptionalModelWithRequired(RequestContent.Create(data), new RequestContext()); +Response response = client.ConvenienceOptionalModelWithRequired(RequestContent.Create(data)); Console.WriteLine(response.Status); ]]> diff --git a/test/TestProjects/ConvenienceUpdate-TypeSpec/tests/Generated/Samples/Samples_ConvenienceInCadlClient.cs b/test/TestProjects/ConvenienceUpdate-TypeSpec/tests/Generated/Samples/Samples_ConvenienceInCadlClient.cs index 15dadf10d3d..9cc1bc902a2 100644 --- a/test/TestProjects/ConvenienceUpdate-TypeSpec/tests/Generated/Samples/Samples_ConvenienceInCadlClient.cs +++ b/test/TestProjects/ConvenienceUpdate-TypeSpec/tests/Generated/Samples/Samples_ConvenienceInCadlClient.cs @@ -266,7 +266,7 @@ public void Example_NoConvenienceOptionalBody() id = "", }; - Response response = client.NoConvenienceOptionalBody(RequestContent.Create(data), new RequestContext()); + Response response = client.NoConvenienceOptionalBody(RequestContent.Create(data)); Console.WriteLine(response.Status); } @@ -281,7 +281,7 @@ public void Example_NoConvenienceOptionalBody_AllParameters() id = "", }; - Response response = client.NoConvenienceOptionalBody(RequestContent.Create(data), new RequestContext()); + Response response = client.NoConvenienceOptionalBody(RequestContent.Create(data)); Console.WriteLine(response.Status); } @@ -296,7 +296,7 @@ public async Task Example_NoConvenienceOptionalBody_Async() id = "", }; - Response response = await client.NoConvenienceOptionalBodyAsync(RequestContent.Create(data), new RequestContext()); + Response response = await client.NoConvenienceOptionalBodyAsync(RequestContent.Create(data)); Console.WriteLine(response.Status); } @@ -311,7 +311,7 @@ public async Task Example_NoConvenienceOptionalBody_AllParameters_Async() id = "", }; - Response response = await client.NoConvenienceOptionalBodyAsync(RequestContent.Create(data), new RequestContext()); + Response response = await client.NoConvenienceOptionalBodyAsync(RequestContent.Create(data)); Console.WriteLine(response.Status); } @@ -742,12 +742,12 @@ public async Task Example_ProtocolOptionalModel_AllParameters_Async() [Test] [Ignore("Only validating compilation of examples")] - public async Task Example_ProtocolOptionalModelValue_Convenience_Async() + public async Task Example_ProtocolOptionalModel_Convenience_Async() { var client = new ConvenienceInCadlClient(); var optional = new Model(""); - var result = await client.ProtocolOptionalModelValueAsync(optional); + var result = await client.ProtocolOptionalModelAsync(optional); } [Test] @@ -1110,12 +1110,12 @@ public async Task Example_ConvenienceOptionalModelWithOptional_AllParameters_Asy [Test] [Ignore("Only validating compilation of examples")] - public async Task Example_ConvenienceOptionalModelWithOptionalValue_Convenience_Async() + public async Task Example_ConvenienceOptionalModelWithOptional_Convenience_Async() { var client = new ConvenienceInCadlClient(); var optional = new Model(""); - var result = await client.ConvenienceOptionalModelWithOptionalValueAsync(optional); + var result = await client.ConvenienceOptionalModelWithOptionalAsync(optional); } [Test] @@ -1199,7 +1199,7 @@ public void Example_ConvenienceOptionalModelWithRequired() id = "", }; - Response response = client.ConvenienceOptionalModelWithRequired(RequestContent.Create(data), new RequestContext()); + Response response = client.ConvenienceOptionalModelWithRequired(RequestContent.Create(data)); Console.WriteLine(response.Status); } @@ -1214,7 +1214,7 @@ public void Example_ConvenienceOptionalModelWithRequired_AllParameters() id = "", }; - Response response = client.ConvenienceOptionalModelWithRequired(RequestContent.Create(data), new RequestContext()); + Response response = client.ConvenienceOptionalModelWithRequired(RequestContent.Create(data)); Console.WriteLine(response.Status); } @@ -1229,7 +1229,7 @@ public async Task Example_ConvenienceOptionalModelWithRequired_Async() id = "", }; - Response response = await client.ConvenienceOptionalModelWithRequiredAsync(RequestContent.Create(data), new RequestContext()); + Response response = await client.ConvenienceOptionalModelWithRequiredAsync(RequestContent.Create(data)); Console.WriteLine(response.Status); } @@ -1244,7 +1244,7 @@ public async Task Example_ConvenienceOptionalModelWithRequired_AllParameters_Asy id = "", }; - Response response = await client.ConvenienceOptionalModelWithRequiredAsync(RequestContent.Create(data), new RequestContext()); + Response response = await client.ConvenienceOptionalModelWithRequiredAsync(RequestContent.Create(data)); Console.WriteLine(response.Status); } diff --git a/test/TestProjects/Parameters-LowLevel/src/Generated/Docs/ParametersLowlevelClient.xml b/test/TestProjects/Parameters-LowLevel/src/Generated/Docs/ParametersLowlevelClient.xml index 515b9c43223..62925e4644f 100644 --- a/test/TestProjects/Parameters-LowLevel/src/Generated/Docs/ParametersLowlevelClient.xml +++ b/test/TestProjects/Parameters-LowLevel/src/Generated/Docs/ParametersLowlevelClient.xml @@ -31,19 +31,19 @@ Console.WriteLine(result.ToString()); -This sample shows how to call RequestBodyResponseBodyAsync with required parameters and parse the result. +This sample shows how to call RequestBodyResponseBodyAsync and parse the result. "); var client = new ParametersLowlevelClient(credential); var data = new {}; -Response response = await client.RequestBodyResponseBodyAsync(RequestContent.Create(data), new RequestContext()); +Response response = await client.RequestBodyResponseBodyAsync(RequestContent.Create(data)); JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; Console.WriteLine(result.ToString()); ]]> -This sample shows how to call RequestBodyResponseBodyAsync with all parameters and request content, and how to parse the result. +This sample shows how to call RequestBodyResponseBodyAsync with all request content, and how to parse the result. "); var client = new ParametersLowlevelClient(credential); @@ -53,7 +53,7 @@ var data = new { Status = "", }; -Response response = await client.RequestBodyResponseBodyAsync(RequestContent.Create(data), new RequestContext()); +Response response = await client.RequestBodyResponseBodyAsync(RequestContent.Create(data)); JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; Console.WriteLine(result.GetProperty("Code").ToString()); @@ -63,19 +63,19 @@ Console.WriteLine(result.GetProperty("Status").ToString()); -This sample shows how to call RequestBodyResponseBody with required parameters and parse the result. +This sample shows how to call RequestBodyResponseBody and parse the result. "); var client = new ParametersLowlevelClient(credential); var data = new {}; -Response response = client.RequestBodyResponseBody(RequestContent.Create(data), new RequestContext()); +Response response = client.RequestBodyResponseBody(RequestContent.Create(data)); JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; Console.WriteLine(result.ToString()); ]]> -This sample shows how to call RequestBodyResponseBody with all parameters and request content, and how to parse the result. +This sample shows how to call RequestBodyResponseBody with all request content, and how to parse the result. "); var client = new ParametersLowlevelClient(credential); @@ -85,7 +85,7 @@ var data = new { Status = "", }; -Response response = client.RequestBodyResponseBody(RequestContent.Create(data), new RequestContext()); +Response response = client.RequestBodyResponseBody(RequestContent.Create(data)); JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; Console.WriteLine(result.GetProperty("Code").ToString()); @@ -147,28 +147,28 @@ Console.WriteLine(response.Status); -This sample shows how to call RequestBodyNoResponseBodyAsync with required parameters and request content. +This sample shows how to call RequestBodyNoResponseBodyAsync with required request content. "); var client = new ParametersLowlevelClient(credential); var data = ""; -Response response = await client.RequestBodyNoResponseBodyAsync(RequestContent.Create(data), new RequestContext()); +Response response = await client.RequestBodyNoResponseBodyAsync(RequestContent.Create(data)); Console.WriteLine(response.Status); ]]> -This sample shows how to call RequestBodyNoResponseBody with required parameters and request content. +This sample shows how to call RequestBodyNoResponseBody with required request content. "); var client = new ParametersLowlevelClient(credential); var data = ""; -Response response = client.RequestBodyNoResponseBody(RequestContent.Create(data), new RequestContext()); +Response response = client.RequestBodyNoResponseBody(RequestContent.Create(data)); Console.WriteLine(response.Status); ]]> @@ -230,7 +230,7 @@ var client = new ParametersLowlevelClient(credential); var data = new {}; -Response response = await client.OptionalPathBodyParametersWithMixedSequenceAsync(1234, "", 1234, 1234, RequestContent.Create(data), 1234, new RequestContext()); +Response response = await client.OptionalPathBodyParametersWithMixedSequenceAsync(1234, "", 1234, 1234, RequestContent.Create(data)); Console.WriteLine(response.Status); ]]> This sample shows how to call OptionalPathBodyParametersWithMixedSequenceAsync with all parameters and request content. @@ -243,7 +243,7 @@ var data = new { Status = "", }; -Response response = await client.OptionalPathBodyParametersWithMixedSequenceAsync(1234, "", 1234, 1234, RequestContent.Create(data), 1234, new RequestContext()); +Response response = await client.OptionalPathBodyParametersWithMixedSequenceAsync(1234, "", 1234, 1234, RequestContent.Create(data), 1234); Console.WriteLine(response.Status); ]]> @@ -257,7 +257,7 @@ var client = new ParametersLowlevelClient(credential); var data = new {}; -Response response = client.OptionalPathBodyParametersWithMixedSequence(1234, "", 1234, 1234, RequestContent.Create(data), 1234, new RequestContext()); +Response response = client.OptionalPathBodyParametersWithMixedSequence(1234, "", 1234, 1234, RequestContent.Create(data)); Console.WriteLine(response.Status); ]]> This sample shows how to call OptionalPathBodyParametersWithMixedSequence with all parameters and request content. @@ -270,7 +270,7 @@ var data = new { Status = "", }; -Response response = client.OptionalPathBodyParametersWithMixedSequence(1234, "", 1234, 1234, RequestContent.Create(data), 1234, new RequestContext()); +Response response = client.OptionalPathBodyParametersWithMixedSequence(1234, "", 1234, 1234, RequestContent.Create(data), 1234); Console.WriteLine(response.Status); ]]> @@ -284,7 +284,7 @@ var client = new ParametersLowlevelClient(credential); var data = new {}; -Response response = await client.RepeatableActionAsync(1234, "", RequestContent.Create(data), new RequestContext()); +Response response = await client.RepeatableActionAsync(1234, "", RequestContent.Create(data)); Console.WriteLine(response.Status); ]]> This sample shows how to call RepeatableActionAsync with all parameters and request content. @@ -297,7 +297,7 @@ var data = new { Status = "", }; -Response response = await client.RepeatableActionAsync(1234, "", RequestContent.Create(data), new RequestContext()); +Response response = await client.RepeatableActionAsync(1234, "", RequestContent.Create(data)); Console.WriteLine(response.Status); ]]> @@ -311,7 +311,7 @@ var client = new ParametersLowlevelClient(credential); var data = new {}; -Response response = client.RepeatableAction(1234, "", RequestContent.Create(data), new RequestContext()); +Response response = client.RepeatableAction(1234, "", RequestContent.Create(data)); Console.WriteLine(response.Status); ]]> This sample shows how to call RepeatableAction with all parameters and request content. @@ -324,7 +324,7 @@ var data = new { Status = "", }; -Response response = client.RepeatableAction(1234, "", RequestContent.Create(data), new RequestContext()); +Response response = client.RepeatableAction(1234, "", RequestContent.Create(data)); Console.WriteLine(response.Status); ]]> diff --git a/test/TestProjects/Parameters-LowLevel/src/Generated/ParametersLowlevelClient.cs b/test/TestProjects/Parameters-LowLevel/src/Generated/ParametersLowlevelClient.cs index 7184df3df40..09ffd372777 100644 --- a/test/TestProjects/Parameters-LowLevel/src/Generated/ParametersLowlevelClient.cs +++ b/test/TestProjects/Parameters-LowLevel/src/Generated/ParametersLowlevelClient.cs @@ -140,7 +140,7 @@ public virtual Response NoRequestBodyResponseBody(int id, int skip, int? top, st /// Service returned a non-success status code. /// The response returned from the service. /// - public virtual async Task RequestBodyResponseBodyAsync(RequestContent content, RequestContext context) + public virtual async Task RequestBodyResponseBodyAsync(RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("ParametersLowlevelClient.RequestBodyResponseBody"); scope.Start(); @@ -171,7 +171,7 @@ public virtual async Task RequestBodyResponseBodyAsync(RequestContent /// Service returned a non-success status code. /// The response returned from the service. /// - public virtual Response RequestBodyResponseBody(RequestContent content, RequestContext context) + public virtual Response RequestBodyResponseBody(RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("ParametersLowlevelClient.RequestBodyResponseBody"); scope.Start(); @@ -330,7 +330,7 @@ public virtual Response NoRequestBodyNoResponseBody(RequestContext context = nul /// Service returned a non-success status code. /// The response returned from the service. /// - public virtual async Task RequestBodyNoResponseBodyAsync(RequestContent content, RequestContext context) + public virtual async Task RequestBodyNoResponseBodyAsync(RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("ParametersLowlevelClient.RequestBodyNoResponseBody"); scope.Start(); @@ -361,7 +361,7 @@ public virtual async Task RequestBodyNoResponseBodyAsync(RequestConten /// Service returned a non-success status code. /// The response returned from the service. /// - public virtual Response RequestBodyNoResponseBody(RequestContent content, RequestContext context) + public virtual Response RequestBodyNoResponseBody(RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("ParametersLowlevelClient.RequestBodyNoResponseBody"); scope.Start(); @@ -547,7 +547,7 @@ public virtual Response OptionalPathParametersWithMixedSequence(int id, string n /// Service returned a non-success status code. /// The response returned from the service. /// - public virtual async Task OptionalPathBodyParametersWithMixedSequenceAsync(int id, string name, int skip, int max, RequestContent content, int? top, RequestContext context) + public virtual async Task OptionalPathBodyParametersWithMixedSequenceAsync(int id, string name, int skip, int max, RequestContent content, int? top = null, RequestContext context = null) { Argument.AssertNotNullOrEmpty(name, nameof(name)); @@ -587,7 +587,7 @@ public virtual async Task OptionalPathBodyParametersWithMixedSequenceA /// Service returned a non-success status code. /// The response returned from the service. /// - public virtual Response OptionalPathBodyParametersWithMixedSequence(int id, string name, int skip, int max, RequestContent content, int? top, RequestContext context) + public virtual Response OptionalPathBodyParametersWithMixedSequence(int id, string name, int skip, int max, RequestContent content, int? top = null, RequestContext context = null) { Argument.AssertNotNullOrEmpty(name, nameof(name)); @@ -624,7 +624,7 @@ public virtual Response OptionalPathBodyParametersWithMixedSequence(int id, stri /// Service returned a non-success status code. /// The response returned from the service. /// - public virtual async Task RepeatableActionAsync(int id, string name, RequestContent content, RequestContext context) + public virtual async Task RepeatableActionAsync(int id, string name, RequestContent content, RequestContext context = null) { Argument.AssertNotNullOrEmpty(name, nameof(name)); @@ -661,7 +661,7 @@ public virtual async Task RepeatableActionAsync(int id, string name, R /// Service returned a non-success status code. /// The response returned from the service. /// - public virtual Response RepeatableAction(int id, string name, RequestContent content, RequestContext context) + public virtual Response RepeatableAction(int id, string name, RequestContent content, RequestContext context = null) { Argument.AssertNotNullOrEmpty(name, nameof(name)); diff --git a/test/TestProjects/Parameters-LowLevel/tests/Generated/Samples/Samples_ParametersLowlevelClient.cs b/test/TestProjects/Parameters-LowLevel/tests/Generated/Samples/Samples_ParametersLowlevelClient.cs index e68ab46136e..5d94a793dc6 100644 --- a/test/TestProjects/Parameters-LowLevel/tests/Generated/Samples/Samples_ParametersLowlevelClient.cs +++ b/test/TestProjects/Parameters-LowLevel/tests/Generated/Samples/Samples_ParametersLowlevelClient.cs @@ -80,7 +80,7 @@ public void Example_RequestBodyResponseBody() var data = new { }; - Response response = client.RequestBodyResponseBody(RequestContent.Create(data), new RequestContext()); + Response response = client.RequestBodyResponseBody(RequestContent.Create(data)); JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; Console.WriteLine(result.ToString()); @@ -99,7 +99,7 @@ public void Example_RequestBodyResponseBody_AllParameters() Status = "", }; - Response response = client.RequestBodyResponseBody(RequestContent.Create(data), new RequestContext()); + Response response = client.RequestBodyResponseBody(RequestContent.Create(data)); JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; Console.WriteLine(result.GetProperty("Code").ToString()); @@ -115,7 +115,7 @@ public async Task Example_RequestBodyResponseBody_Async() var data = new { }; - Response response = await client.RequestBodyResponseBodyAsync(RequestContent.Create(data), new RequestContext()); + Response response = await client.RequestBodyResponseBodyAsync(RequestContent.Create(data)); JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; Console.WriteLine(result.ToString()); @@ -134,7 +134,7 @@ public async Task Example_RequestBodyResponseBody_AllParameters_Async() Status = "", }; - Response response = await client.RequestBodyResponseBodyAsync(RequestContent.Create(data), new RequestContext()); + Response response = await client.RequestBodyResponseBodyAsync(RequestContent.Create(data)); JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; Console.WriteLine(result.GetProperty("Code").ToString()); @@ -246,7 +246,7 @@ public void Example_RequestBodyNoResponseBody() var data = ""; - Response response = client.RequestBodyNoResponseBody(RequestContent.Create(data), new RequestContext()); + Response response = client.RequestBodyNoResponseBody(RequestContent.Create(data)); Console.WriteLine(response.Status); } @@ -259,7 +259,7 @@ public void Example_RequestBodyNoResponseBody_AllParameters() var data = ""; - Response response = client.RequestBodyNoResponseBody(RequestContent.Create(data), new RequestContext()); + Response response = client.RequestBodyNoResponseBody(RequestContent.Create(data)); Console.WriteLine(response.Status); } @@ -272,7 +272,7 @@ public async Task Example_RequestBodyNoResponseBody_Async() var data = ""; - Response response = await client.RequestBodyNoResponseBodyAsync(RequestContent.Create(data), new RequestContext()); + Response response = await client.RequestBodyNoResponseBodyAsync(RequestContent.Create(data)); Console.WriteLine(response.Status); } @@ -285,7 +285,7 @@ public async Task Example_RequestBodyNoResponseBody_AllParameters_Async() var data = ""; - Response response = await client.RequestBodyNoResponseBodyAsync(RequestContent.Create(data), new RequestContext()); + Response response = await client.RequestBodyNoResponseBodyAsync(RequestContent.Create(data)); Console.WriteLine(response.Status); } @@ -386,7 +386,7 @@ public void Example_OptionalPathBodyParametersWithMixedSequence() var data = new { }; - Response response = client.OptionalPathBodyParametersWithMixedSequence(1234, "", 1234, 1234, RequestContent.Create(data), 1234, new RequestContext()); + Response response = client.OptionalPathBodyParametersWithMixedSequence(1234, "", 1234, 1234, RequestContent.Create(data)); Console.WriteLine(response.Status); } @@ -403,7 +403,7 @@ public void Example_OptionalPathBodyParametersWithMixedSequence_AllParameters() Status = "", }; - Response response = client.OptionalPathBodyParametersWithMixedSequence(1234, "", 1234, 1234, RequestContent.Create(data), 1234, new RequestContext()); + Response response = client.OptionalPathBodyParametersWithMixedSequence(1234, "", 1234, 1234, RequestContent.Create(data), 1234); Console.WriteLine(response.Status); } @@ -416,7 +416,7 @@ public async Task Example_OptionalPathBodyParametersWithMixedSequence_Async() var data = new { }; - Response response = await client.OptionalPathBodyParametersWithMixedSequenceAsync(1234, "", 1234, 1234, RequestContent.Create(data), 1234, new RequestContext()); + Response response = await client.OptionalPathBodyParametersWithMixedSequenceAsync(1234, "", 1234, 1234, RequestContent.Create(data)); Console.WriteLine(response.Status); } @@ -433,7 +433,7 @@ public async Task Example_OptionalPathBodyParametersWithMixedSequence_AllParamet Status = "", }; - Response response = await client.OptionalPathBodyParametersWithMixedSequenceAsync(1234, "", 1234, 1234, RequestContent.Create(data), 1234, new RequestContext()); + Response response = await client.OptionalPathBodyParametersWithMixedSequenceAsync(1234, "", 1234, 1234, RequestContent.Create(data), 1234); Console.WriteLine(response.Status); } @@ -446,7 +446,7 @@ public void Example_RepeatableAction() var data = new { }; - Response response = client.RepeatableAction(1234, "", RequestContent.Create(data), new RequestContext()); + Response response = client.RepeatableAction(1234, "", RequestContent.Create(data)); Console.WriteLine(response.Status); } @@ -463,7 +463,7 @@ public void Example_RepeatableAction_AllParameters() Status = "", }; - Response response = client.RepeatableAction(1234, "", RequestContent.Create(data), new RequestContext()); + Response response = client.RepeatableAction(1234, "", RequestContent.Create(data)); Console.WriteLine(response.Status); } @@ -476,7 +476,7 @@ public async Task Example_RepeatableAction_Async() var data = new { }; - Response response = await client.RepeatableActionAsync(1234, "", RequestContent.Create(data), new RequestContext()); + Response response = await client.RepeatableActionAsync(1234, "", RequestContent.Create(data)); Console.WriteLine(response.Status); } @@ -493,7 +493,7 @@ public async Task Example_RepeatableAction_AllParameters_Async() Status = "", }; - Response response = await client.RepeatableActionAsync(1234, "", RequestContent.Create(data), new RequestContext()); + Response response = await client.RepeatableActionAsync(1234, "", RequestContent.Create(data)); Console.WriteLine(response.Status); } } diff --git a/test/TestProjects/ProtocolMethodsInRestClient/Generated/FirstTemplateRestClient.cs b/test/TestProjects/ProtocolMethodsInRestClient/Generated/FirstTemplateRestClient.cs index dbafaad1e26..600f1ba67d4 100644 --- a/test/TestProjects/ProtocolMethodsInRestClient/Generated/FirstTemplateRestClient.cs +++ b/test/TestProjects/ProtocolMethodsInRestClient/Generated/FirstTemplateRestClient.cs @@ -127,7 +127,7 @@ internal HttpMessage CreateCreateRequest(RequestContent content, RequestContext /// The request context, which can override default behaviors of the client pipeline on a per-call basis. /// Service returned a non-success status code. /// The response returned from the service. - public virtual async Task CreateAsync(RequestContent content, RequestContext context) + public virtual async Task CreateAsync(RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("FirstTemplateClient.Create"); scope.Start(); @@ -157,7 +157,7 @@ public virtual async Task CreateAsync(RequestContent content, RequestC /// The request context, which can override default behaviors of the client pipeline on a per-call basis. /// Service returned a non-success status code. /// The response returned from the service. - public virtual Response Create(RequestContent content, RequestContext context) + public virtual Response Create(RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("FirstTemplateClient.Create"); scope.Start(); diff --git a/test/TestServerProjectsLowLevel/body-string/src/Generated/Docs/StringClient.xml b/test/TestServerProjectsLowLevel/body-string/src/Generated/Docs/StringClient.xml index 925b4e081c0..61d7aa5b018 100644 --- a/test/TestServerProjectsLowLevel/body-string/src/Generated/Docs/StringClient.xml +++ b/test/TestServerProjectsLowLevel/body-string/src/Generated/Docs/StringClient.xml @@ -31,28 +31,28 @@ Console.WriteLine(result.ToString()); -This sample shows how to call PutNullAsync with required parameters and request content. +This sample shows how to call PutNullAsync with required request content. "); var client = new StringClient(credential); var data = ""; -Response response = await client.PutNullAsync(RequestContent.Create(data), new RequestContext()); +Response response = await client.PutNullAsync(RequestContent.Create(data)); Console.WriteLine(response.Status); ]]> -This sample shows how to call PutNull with required parameters and request content. +This sample shows how to call PutNull with required request content. "); var client = new StringClient(credential); var data = ""; -Response response = client.PutNull(RequestContent.Create(data), new RequestContext()); +Response response = client.PutNull(RequestContent.Create(data)); Console.WriteLine(response.Status); ]]> diff --git a/test/TestServerProjectsLowLevel/body-string/src/Generated/StringClient.cs b/test/TestServerProjectsLowLevel/body-string/src/Generated/StringClient.cs index 38778ac5800..cec3881cbae 100644 --- a/test/TestServerProjectsLowLevel/body-string/src/Generated/StringClient.cs +++ b/test/TestServerProjectsLowLevel/body-string/src/Generated/StringClient.cs @@ -132,7 +132,7 @@ public virtual Response GetNull(RequestContext context) /// Service returned a non-success status code. /// The response returned from the service. /// - public virtual async Task PutNullAsync(RequestContent content, RequestContext context) + public virtual async Task PutNullAsync(RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("StringClient.PutNull"); scope.Start(); @@ -163,7 +163,7 @@ public virtual async Task PutNullAsync(RequestContent content, Request /// Service returned a non-success status code. /// The response returned from the service. /// - public virtual Response PutNull(RequestContent content, RequestContext context) + public virtual Response PutNull(RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("StringClient.PutNull"); scope.Start(); diff --git a/test/TestServerProjectsLowLevel/body-string/tests/Generated/Samples/Samples_StringClient.cs b/test/TestServerProjectsLowLevel/body-string/tests/Generated/Samples/Samples_StringClient.cs index f80bd7e93c2..eb22dc66913 100644 --- a/test/TestServerProjectsLowLevel/body-string/tests/Generated/Samples/Samples_StringClient.cs +++ b/test/TestServerProjectsLowLevel/body-string/tests/Generated/Samples/Samples_StringClient.cs @@ -80,7 +80,7 @@ public void Example_PutNull() var data = ""; - Response response = client.PutNull(RequestContent.Create(data), new RequestContext()); + Response response = client.PutNull(RequestContent.Create(data)); Console.WriteLine(response.Status); } @@ -93,7 +93,7 @@ public void Example_PutNull_AllParameters() var data = ""; - Response response = client.PutNull(RequestContent.Create(data), new RequestContext()); + Response response = client.PutNull(RequestContent.Create(data)); Console.WriteLine(response.Status); } @@ -106,7 +106,7 @@ public async Task Example_PutNull_Async() var data = ""; - Response response = await client.PutNullAsync(RequestContent.Create(data), new RequestContext()); + Response response = await client.PutNullAsync(RequestContent.Create(data)); Console.WriteLine(response.Status); } @@ -119,7 +119,7 @@ public async Task Example_PutNull_AllParameters_Async() var data = ""; - Response response = await client.PutNullAsync(RequestContent.Create(data), new RequestContext()); + Response response = await client.PutNullAsync(RequestContent.Create(data)); Console.WriteLine(response.Status); } diff --git a/test/TestServerProjectsLowLevel/lro/src/Generated/Docs/LRORetrysClient.xml b/test/TestServerProjectsLowLevel/lro/src/Generated/Docs/LRORetrysClient.xml index 99f12eb8e11..8380452499a 100644 --- a/test/TestServerProjectsLowLevel/lro/src/Generated/Docs/LRORetrysClient.xml +++ b/test/TestServerProjectsLowLevel/lro/src/Generated/Docs/LRORetrysClient.xml @@ -10,7 +10,7 @@ var client = new LRORetrysClient(credential); var data = new {}; -var operation = await client.Put201CreatingSucceeded200Async(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.Put201CreatingSucceeded200Async(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -31,7 +31,7 @@ var data = new { location = "", }; -var operation = await client.Put201CreatingSucceeded200Async(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.Put201CreatingSucceeded200Async(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -54,7 +54,7 @@ var client = new LRORetrysClient(credential); var data = new {}; -var operation = client.Put201CreatingSucceeded200(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.Put201CreatingSucceeded200(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -75,7 +75,7 @@ var data = new { location = "", }; -var operation = client.Put201CreatingSucceeded200(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.Put201CreatingSucceeded200(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -98,7 +98,7 @@ var client = new LRORetrysClient(credential); var data = new {}; -var operation = await client.PutAsyncRelativeRetrySucceededAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.PutAsyncRelativeRetrySucceededAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -119,7 +119,7 @@ var data = new { location = "", }; -var operation = await client.PutAsyncRelativeRetrySucceededAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.PutAsyncRelativeRetrySucceededAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -142,7 +142,7 @@ var client = new LRORetrysClient(credential); var data = new {}; -var operation = client.PutAsyncRelativeRetrySucceeded(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.PutAsyncRelativeRetrySucceeded(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -163,7 +163,7 @@ var data = new { location = "", }; -var operation = client.PutAsyncRelativeRetrySucceeded(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.PutAsyncRelativeRetrySucceeded(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -280,7 +280,7 @@ var client = new LRORetrysClient(credential); var data = new {}; -var operation = await client.Post202Retry200Async(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.Post202Retry200Async(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); ]]> @@ -299,7 +299,7 @@ var data = new { location = "", }; -var operation = await client.Post202Retry200Async(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.Post202Retry200Async(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); ]]> @@ -314,7 +314,7 @@ var client = new LRORetrysClient(credential); var data = new {}; -var operation = client.Post202Retry200(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.Post202Retry200(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); ]]> @@ -333,7 +333,7 @@ var data = new { location = "", }; -var operation = client.Post202Retry200(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.Post202Retry200(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); ]]> @@ -348,7 +348,7 @@ var client = new LRORetrysClient(credential); var data = new {}; -var operation = await client.PostAsyncRelativeRetrySucceededAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.PostAsyncRelativeRetrySucceededAsync(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); ]]> @@ -367,7 +367,7 @@ var data = new { location = "", }; -var operation = await client.PostAsyncRelativeRetrySucceededAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.PostAsyncRelativeRetrySucceededAsync(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); ]]> @@ -382,7 +382,7 @@ var client = new LRORetrysClient(credential); var data = new {}; -var operation = client.PostAsyncRelativeRetrySucceeded(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.PostAsyncRelativeRetrySucceeded(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); ]]> @@ -401,7 +401,7 @@ var data = new { location = "", }; -var operation = client.PostAsyncRelativeRetrySucceeded(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.PostAsyncRelativeRetrySucceeded(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); ]]> diff --git a/test/TestServerProjectsLowLevel/lro/src/Generated/Docs/LROsClient.xml b/test/TestServerProjectsLowLevel/lro/src/Generated/Docs/LROsClient.xml index 5b7d95c0d79..1af869fa2c5 100644 --- a/test/TestServerProjectsLowLevel/lro/src/Generated/Docs/LROsClient.xml +++ b/test/TestServerProjectsLowLevel/lro/src/Generated/Docs/LROsClient.xml @@ -10,7 +10,7 @@ var client = new LROsClient(credential); var data = new {}; -var operation = await client.Put200SucceededAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.Put200SucceededAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -31,7 +31,7 @@ var data = new { location = "", }; -var operation = await client.Put200SucceededAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.Put200SucceededAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -54,7 +54,7 @@ var client = new LROsClient(credential); var data = new {}; -var operation = client.Put200Succeeded(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.Put200Succeeded(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -75,7 +75,7 @@ var data = new { location = "", }; -var operation = client.Put200Succeeded(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.Put200Succeeded(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -98,7 +98,7 @@ var client = new LROsClient(credential); var data = new {}; -var operation = await client.Patch200SucceededIgnoreHeadersAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.Patch200SucceededIgnoreHeadersAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -119,7 +119,7 @@ var data = new { location = "", }; -var operation = await client.Patch200SucceededIgnoreHeadersAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.Patch200SucceededIgnoreHeadersAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -142,7 +142,7 @@ var client = new LROsClient(credential); var data = new {}; -var operation = client.Patch200SucceededIgnoreHeaders(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.Patch200SucceededIgnoreHeaders(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -163,7 +163,7 @@ var data = new { location = "", }; -var operation = client.Patch200SucceededIgnoreHeaders(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.Patch200SucceededIgnoreHeaders(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -186,7 +186,7 @@ var client = new LROsClient(credential); var data = new {}; -var operation = await client.Patch201RetryWithAsyncHeaderAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.Patch201RetryWithAsyncHeaderAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -207,7 +207,7 @@ var data = new { location = "", }; -var operation = await client.Patch201RetryWithAsyncHeaderAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.Patch201RetryWithAsyncHeaderAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -230,7 +230,7 @@ var client = new LROsClient(credential); var data = new {}; -var operation = client.Patch201RetryWithAsyncHeader(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.Patch201RetryWithAsyncHeader(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -251,7 +251,7 @@ var data = new { location = "", }; -var operation = client.Patch201RetryWithAsyncHeader(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.Patch201RetryWithAsyncHeader(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -274,7 +274,7 @@ var client = new LROsClient(credential); var data = new {}; -var operation = await client.Patch202RetryWithAsyncAndLocationHeaderAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.Patch202RetryWithAsyncAndLocationHeaderAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -295,7 +295,7 @@ var data = new { location = "", }; -var operation = await client.Patch202RetryWithAsyncAndLocationHeaderAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.Patch202RetryWithAsyncAndLocationHeaderAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -318,7 +318,7 @@ var client = new LROsClient(credential); var data = new {}; -var operation = client.Patch202RetryWithAsyncAndLocationHeader(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.Patch202RetryWithAsyncAndLocationHeader(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -339,7 +339,7 @@ var data = new { location = "", }; -var operation = client.Patch202RetryWithAsyncAndLocationHeader(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.Patch202RetryWithAsyncAndLocationHeader(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -362,7 +362,7 @@ var client = new LROsClient(credential); var data = new {}; -var operation = await client.Put201SucceededAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.Put201SucceededAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -383,7 +383,7 @@ var data = new { location = "", }; -var operation = await client.Put201SucceededAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.Put201SucceededAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -406,7 +406,7 @@ var client = new LROsClient(credential); var data = new {}; -var operation = client.Put201Succeeded(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.Put201Succeeded(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -427,7 +427,7 @@ var data = new { location = "", }; -var operation = client.Put201Succeeded(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.Put201Succeeded(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -492,7 +492,7 @@ var client = new LROsClient(credential); var data = new {}; -var operation = await client.Put200SucceededNoStateAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.Put200SucceededNoStateAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -513,7 +513,7 @@ var data = new { location = "", }; -var operation = await client.Put200SucceededNoStateAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.Put200SucceededNoStateAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -536,7 +536,7 @@ var client = new LROsClient(credential); var data = new {}; -var operation = client.Put200SucceededNoState(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.Put200SucceededNoState(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -557,7 +557,7 @@ var data = new { location = "", }; -var operation = client.Put200SucceededNoState(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.Put200SucceededNoState(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -580,7 +580,7 @@ var client = new LROsClient(credential); var data = new {}; -var operation = await client.Put202Retry200Async(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.Put202Retry200Async(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -601,7 +601,7 @@ var data = new { location = "", }; -var operation = await client.Put202Retry200Async(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.Put202Retry200Async(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -624,7 +624,7 @@ var client = new LROsClient(credential); var data = new {}; -var operation = client.Put202Retry200(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.Put202Retry200(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -645,7 +645,7 @@ var data = new { location = "", }; -var operation = client.Put202Retry200(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.Put202Retry200(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -668,7 +668,7 @@ var client = new LROsClient(credential); var data = new {}; -var operation = await client.Put201CreatingSucceeded200Async(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.Put201CreatingSucceeded200Async(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -689,7 +689,7 @@ var data = new { location = "", }; -var operation = await client.Put201CreatingSucceeded200Async(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.Put201CreatingSucceeded200Async(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -712,7 +712,7 @@ var client = new LROsClient(credential); var data = new {}; -var operation = client.Put201CreatingSucceeded200(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.Put201CreatingSucceeded200(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -733,7 +733,7 @@ var data = new { location = "", }; -var operation = client.Put201CreatingSucceeded200(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.Put201CreatingSucceeded200(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -756,7 +756,7 @@ var client = new LROsClient(credential); var data = new {}; -var operation = await client.Put200UpdatingSucceeded204Async(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.Put200UpdatingSucceeded204Async(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -777,7 +777,7 @@ var data = new { location = "", }; -var operation = await client.Put200UpdatingSucceeded204Async(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.Put200UpdatingSucceeded204Async(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -800,7 +800,7 @@ var client = new LROsClient(credential); var data = new {}; -var operation = client.Put200UpdatingSucceeded204(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.Put200UpdatingSucceeded204(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -821,7 +821,7 @@ var data = new { location = "", }; -var operation = client.Put200UpdatingSucceeded204(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.Put200UpdatingSucceeded204(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -844,7 +844,7 @@ var client = new LROsClient(credential); var data = new {}; -var operation = await client.Put201CreatingFailed200Async(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.Put201CreatingFailed200Async(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -865,7 +865,7 @@ var data = new { location = "", }; -var operation = await client.Put201CreatingFailed200Async(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.Put201CreatingFailed200Async(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -888,7 +888,7 @@ var client = new LROsClient(credential); var data = new {}; -var operation = client.Put201CreatingFailed200(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.Put201CreatingFailed200(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -909,7 +909,7 @@ var data = new { location = "", }; -var operation = client.Put201CreatingFailed200(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.Put201CreatingFailed200(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -932,7 +932,7 @@ var client = new LROsClient(credential); var data = new {}; -var operation = await client.Put200Acceptedcanceled200Async(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.Put200Acceptedcanceled200Async(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -953,7 +953,7 @@ var data = new { location = "", }; -var operation = await client.Put200Acceptedcanceled200Async(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.Put200Acceptedcanceled200Async(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -976,7 +976,7 @@ var client = new LROsClient(credential); var data = new {}; -var operation = client.Put200Acceptedcanceled200(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.Put200Acceptedcanceled200(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -997,7 +997,7 @@ var data = new { location = "", }; -var operation = client.Put200Acceptedcanceled200(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.Put200Acceptedcanceled200(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1020,7 +1020,7 @@ var client = new LROsClient(credential); var data = new {}; -var operation = await client.PutNoHeaderInRetryAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.PutNoHeaderInRetryAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1041,7 +1041,7 @@ var data = new { location = "", }; -var operation = await client.PutNoHeaderInRetryAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.PutNoHeaderInRetryAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1064,7 +1064,7 @@ var client = new LROsClient(credential); var data = new {}; -var operation = client.PutNoHeaderInRetry(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.PutNoHeaderInRetry(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1085,7 +1085,7 @@ var data = new { location = "", }; -var operation = client.PutNoHeaderInRetry(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.PutNoHeaderInRetry(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1108,7 +1108,7 @@ var client = new LROsClient(credential); var data = new {}; -var operation = await client.PutAsyncRetrySucceededAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.PutAsyncRetrySucceededAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1129,7 +1129,7 @@ var data = new { location = "", }; -var operation = await client.PutAsyncRetrySucceededAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.PutAsyncRetrySucceededAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1152,7 +1152,7 @@ var client = new LROsClient(credential); var data = new {}; -var operation = client.PutAsyncRetrySucceeded(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.PutAsyncRetrySucceeded(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1173,7 +1173,7 @@ var data = new { location = "", }; -var operation = client.PutAsyncRetrySucceeded(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.PutAsyncRetrySucceeded(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1196,7 +1196,7 @@ var client = new LROsClient(credential); var data = new {}; -var operation = await client.PutAsyncNoRetrySucceededAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.PutAsyncNoRetrySucceededAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1217,7 +1217,7 @@ var data = new { location = "", }; -var operation = await client.PutAsyncNoRetrySucceededAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.PutAsyncNoRetrySucceededAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1240,7 +1240,7 @@ var client = new LROsClient(credential); var data = new {}; -var operation = client.PutAsyncNoRetrySucceeded(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.PutAsyncNoRetrySucceeded(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1261,7 +1261,7 @@ var data = new { location = "", }; -var operation = client.PutAsyncNoRetrySucceeded(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.PutAsyncNoRetrySucceeded(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1284,7 +1284,7 @@ var client = new LROsClient(credential); var data = new {}; -var operation = await client.PutAsyncRetryFailedAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.PutAsyncRetryFailedAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1305,7 +1305,7 @@ var data = new { location = "", }; -var operation = await client.PutAsyncRetryFailedAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.PutAsyncRetryFailedAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1328,7 +1328,7 @@ var client = new LROsClient(credential); var data = new {}; -var operation = client.PutAsyncRetryFailed(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.PutAsyncRetryFailed(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1349,7 +1349,7 @@ var data = new { location = "", }; -var operation = client.PutAsyncRetryFailed(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.PutAsyncRetryFailed(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1372,7 +1372,7 @@ var client = new LROsClient(credential); var data = new {}; -var operation = await client.PutAsyncNoRetrycanceledAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.PutAsyncNoRetrycanceledAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1393,7 +1393,7 @@ var data = new { location = "", }; -var operation = await client.PutAsyncNoRetrycanceledAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.PutAsyncNoRetrycanceledAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1416,7 +1416,7 @@ var client = new LROsClient(credential); var data = new {}; -var operation = client.PutAsyncNoRetrycanceled(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.PutAsyncNoRetrycanceled(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1437,7 +1437,7 @@ var data = new { location = "", }; -var operation = client.PutAsyncNoRetrycanceled(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.PutAsyncNoRetrycanceled(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1460,7 +1460,7 @@ var client = new LROsClient(credential); var data = new {}; -var operation = await client.PutAsyncNoHeaderInRetryAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.PutAsyncNoHeaderInRetryAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1481,7 +1481,7 @@ var data = new { location = "", }; -var operation = await client.PutAsyncNoHeaderInRetryAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.PutAsyncNoHeaderInRetryAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1504,7 +1504,7 @@ var client = new LROsClient(credential); var data = new {}; -var operation = client.PutAsyncNoHeaderInRetry(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.PutAsyncNoHeaderInRetry(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1525,7 +1525,7 @@ var data = new { location = "", }; -var operation = client.PutAsyncNoHeaderInRetry(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.PutAsyncNoHeaderInRetry(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1548,7 +1548,7 @@ var client = new LROsClient(credential); var data = new {}; -var operation = await client.PutNonResourceAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.PutNonResourceAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1564,7 +1564,7 @@ var data = new { id = "", }; -var operation = await client.PutNonResourceAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.PutNonResourceAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1582,7 +1582,7 @@ var client = new LROsClient(credential); var data = new {}; -var operation = client.PutNonResource(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.PutNonResource(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1598,7 +1598,7 @@ var data = new { id = "", }; -var operation = client.PutNonResource(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.PutNonResource(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1616,7 +1616,7 @@ var client = new LROsClient(credential); var data = new {}; -var operation = await client.PutAsyncNonResourceAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.PutAsyncNonResourceAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1632,7 +1632,7 @@ var data = new { id = "", }; -var operation = await client.PutAsyncNonResourceAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.PutAsyncNonResourceAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1650,7 +1650,7 @@ var client = new LROsClient(credential); var data = new {}; -var operation = client.PutAsyncNonResource(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.PutAsyncNonResource(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1666,7 +1666,7 @@ var data = new { id = "", }; -var operation = client.PutAsyncNonResource(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.PutAsyncNonResource(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1684,7 +1684,7 @@ var client = new LROsClient(credential); var data = new {}; -var operation = await client.PutSubResourceAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.PutSubResourceAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1701,7 +1701,7 @@ var data = new { }, }; -var operation = await client.PutSubResourceAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.PutSubResourceAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1720,7 +1720,7 @@ var client = new LROsClient(credential); var data = new {}; -var operation = client.PutSubResource(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.PutSubResource(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1737,7 +1737,7 @@ var data = new { }, }; -var operation = client.PutSubResource(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.PutSubResource(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1756,7 +1756,7 @@ var client = new LROsClient(credential); var data = new {}; -var operation = await client.PutAsyncSubResourceAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.PutAsyncSubResourceAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1773,7 +1773,7 @@ var data = new { }, }; -var operation = await client.PutAsyncSubResourceAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.PutAsyncSubResourceAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1792,7 +1792,7 @@ var client = new LROsClient(credential); var data = new {}; -var operation = client.PutAsyncSubResource(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.PutAsyncSubResource(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1809,7 +1809,7 @@ var data = new { }, }; -var operation = client.PutAsyncSubResource(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.PutAsyncSubResource(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -2252,7 +2252,7 @@ var client = new LROsClient(credential); var data = new {}; -var operation = await client.Post202Retry200Async(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.Post202Retry200Async(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); ]]> @@ -2271,7 +2271,7 @@ var data = new { location = "", }; -var operation = await client.Post202Retry200Async(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.Post202Retry200Async(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); ]]> @@ -2286,7 +2286,7 @@ var client = new LROsClient(credential); var data = new {}; -var operation = client.Post202Retry200(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.Post202Retry200(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); ]]> @@ -2305,7 +2305,7 @@ var data = new { location = "", }; -var operation = client.Post202Retry200(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.Post202Retry200(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); ]]> @@ -2320,7 +2320,7 @@ var client = new LROsClient(credential); var data = new {}; -var operation = await client.Post202NoRetry204Async(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.Post202NoRetry204Async(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -2341,7 +2341,7 @@ var data = new { location = "", }; -var operation = await client.Post202NoRetry204Async(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.Post202NoRetry204Async(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -2364,7 +2364,7 @@ var client = new LROsClient(credential); var data = new {}; -var operation = client.Post202NoRetry204(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.Post202NoRetry204(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -2385,7 +2385,7 @@ var data = new { location = "", }; -var operation = client.Post202NoRetry204(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.Post202NoRetry204(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -2534,7 +2534,7 @@ var client = new LROsClient(credential); var data = new {}; -var operation = await client.PostAsyncRetrySucceededAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.PostAsyncRetrySucceededAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -2555,7 +2555,7 @@ var data = new { location = "", }; -var operation = await client.PostAsyncRetrySucceededAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.PostAsyncRetrySucceededAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -2578,7 +2578,7 @@ var client = new LROsClient(credential); var data = new {}; -var operation = client.PostAsyncRetrySucceeded(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.PostAsyncRetrySucceeded(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -2599,7 +2599,7 @@ var data = new { location = "", }; -var operation = client.PostAsyncRetrySucceeded(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.PostAsyncRetrySucceeded(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -2622,7 +2622,7 @@ var client = new LROsClient(credential); var data = new {}; -var operation = await client.PostAsyncNoRetrySucceededAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.PostAsyncNoRetrySucceededAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -2643,7 +2643,7 @@ var data = new { location = "", }; -var operation = await client.PostAsyncNoRetrySucceededAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.PostAsyncNoRetrySucceededAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -2666,7 +2666,7 @@ var client = new LROsClient(credential); var data = new {}; -var operation = client.PostAsyncNoRetrySucceeded(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.PostAsyncNoRetrySucceeded(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -2687,7 +2687,7 @@ var data = new { location = "", }; -var operation = client.PostAsyncNoRetrySucceeded(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.PostAsyncNoRetrySucceeded(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -2710,7 +2710,7 @@ var client = new LROsClient(credential); var data = new {}; -var operation = await client.PostAsyncRetryFailedAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.PostAsyncRetryFailedAsync(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); ]]> @@ -2729,7 +2729,7 @@ var data = new { location = "", }; -var operation = await client.PostAsyncRetryFailedAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.PostAsyncRetryFailedAsync(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); ]]> @@ -2744,7 +2744,7 @@ var client = new LROsClient(credential); var data = new {}; -var operation = client.PostAsyncRetryFailed(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.PostAsyncRetryFailed(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); ]]> @@ -2763,7 +2763,7 @@ var data = new { location = "", }; -var operation = client.PostAsyncRetryFailed(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.PostAsyncRetryFailed(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); ]]> @@ -2778,7 +2778,7 @@ var client = new LROsClient(credential); var data = new {}; -var operation = await client.PostAsyncRetrycanceledAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.PostAsyncRetrycanceledAsync(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); ]]> @@ -2797,7 +2797,7 @@ var data = new { location = "", }; -var operation = await client.PostAsyncRetrycanceledAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.PostAsyncRetrycanceledAsync(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); ]]> @@ -2812,7 +2812,7 @@ var client = new LROsClient(credential); var data = new {}; -var operation = client.PostAsyncRetrycanceled(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.PostAsyncRetrycanceled(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); ]]> @@ -2831,7 +2831,7 @@ var data = new { location = "", }; -var operation = client.PostAsyncRetrycanceled(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.PostAsyncRetrycanceled(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); ]]> diff --git a/test/TestServerProjectsLowLevel/lro/src/Generated/Docs/LROsCustomHeaderClient.xml b/test/TestServerProjectsLowLevel/lro/src/Generated/Docs/LROsCustomHeaderClient.xml index 086b644fe3f..e49b78958d1 100644 --- a/test/TestServerProjectsLowLevel/lro/src/Generated/Docs/LROsCustomHeaderClient.xml +++ b/test/TestServerProjectsLowLevel/lro/src/Generated/Docs/LROsCustomHeaderClient.xml @@ -10,7 +10,7 @@ var client = new LROsCustomHeaderClient(credential); var data = new {}; -var operation = await client.PutAsyncRetrySucceededAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.PutAsyncRetrySucceededAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -31,7 +31,7 @@ var data = new { location = "", }; -var operation = await client.PutAsyncRetrySucceededAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.PutAsyncRetrySucceededAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -54,7 +54,7 @@ var client = new LROsCustomHeaderClient(credential); var data = new {}; -var operation = client.PutAsyncRetrySucceeded(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.PutAsyncRetrySucceeded(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -75,7 +75,7 @@ var data = new { location = "", }; -var operation = client.PutAsyncRetrySucceeded(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.PutAsyncRetrySucceeded(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -98,7 +98,7 @@ var client = new LROsCustomHeaderClient(credential); var data = new {}; -var operation = await client.Put201CreatingSucceeded200Async(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.Put201CreatingSucceeded200Async(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -119,7 +119,7 @@ var data = new { location = "", }; -var operation = await client.Put201CreatingSucceeded200Async(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.Put201CreatingSucceeded200Async(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -142,7 +142,7 @@ var client = new LROsCustomHeaderClient(credential); var data = new {}; -var operation = client.Put201CreatingSucceeded200(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.Put201CreatingSucceeded200(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -163,7 +163,7 @@ var data = new { location = "", }; -var operation = client.Put201CreatingSucceeded200(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.Put201CreatingSucceeded200(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -186,7 +186,7 @@ var client = new LROsCustomHeaderClient(credential); var data = new {}; -var operation = await client.Post202Retry200Async(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.Post202Retry200Async(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); ]]> @@ -205,7 +205,7 @@ var data = new { location = "", }; -var operation = await client.Post202Retry200Async(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.Post202Retry200Async(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); ]]> @@ -220,7 +220,7 @@ var client = new LROsCustomHeaderClient(credential); var data = new {}; -var operation = client.Post202Retry200(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.Post202Retry200(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); ]]> @@ -239,7 +239,7 @@ var data = new { location = "", }; -var operation = client.Post202Retry200(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.Post202Retry200(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); ]]> @@ -254,7 +254,7 @@ var client = new LROsCustomHeaderClient(credential); var data = new {}; -var operation = await client.PostAsyncRetrySucceededAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.PostAsyncRetrySucceededAsync(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); ]]> @@ -273,7 +273,7 @@ var data = new { location = "", }; -var operation = await client.PostAsyncRetrySucceededAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.PostAsyncRetrySucceededAsync(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); ]]> @@ -288,7 +288,7 @@ var client = new LROsCustomHeaderClient(credential); var data = new {}; -var operation = client.PostAsyncRetrySucceeded(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.PostAsyncRetrySucceeded(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); ]]> @@ -307,7 +307,7 @@ var data = new { location = "", }; -var operation = client.PostAsyncRetrySucceeded(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.PostAsyncRetrySucceeded(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); ]]> diff --git a/test/TestServerProjectsLowLevel/lro/src/Generated/Docs/LrosaDsClient.xml b/test/TestServerProjectsLowLevel/lro/src/Generated/Docs/LrosaDsClient.xml index 30ed7df04f3..00b835a6003 100644 --- a/test/TestServerProjectsLowLevel/lro/src/Generated/Docs/LrosaDsClient.xml +++ b/test/TestServerProjectsLowLevel/lro/src/Generated/Docs/LrosaDsClient.xml @@ -10,7 +10,7 @@ var client = new LrosaDsClient(credential); var data = new {}; -var operation = await client.PutNonRetry400Async(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.PutNonRetry400Async(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -31,7 +31,7 @@ var data = new { location = "", }; -var operation = await client.PutNonRetry400Async(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.PutNonRetry400Async(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -54,7 +54,7 @@ var client = new LrosaDsClient(credential); var data = new {}; -var operation = client.PutNonRetry400(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.PutNonRetry400(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -75,7 +75,7 @@ var data = new { location = "", }; -var operation = client.PutNonRetry400(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.PutNonRetry400(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -98,7 +98,7 @@ var client = new LrosaDsClient(credential); var data = new {}; -var operation = await client.PutNonRetry201Creating400Async(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.PutNonRetry201Creating400Async(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -119,7 +119,7 @@ var data = new { location = "", }; -var operation = await client.PutNonRetry201Creating400Async(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.PutNonRetry201Creating400Async(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -142,7 +142,7 @@ var client = new LrosaDsClient(credential); var data = new {}; -var operation = client.PutNonRetry201Creating400(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.PutNonRetry201Creating400(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -163,7 +163,7 @@ var data = new { location = "", }; -var operation = client.PutNonRetry201Creating400(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.PutNonRetry201Creating400(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -186,7 +186,7 @@ var client = new LrosaDsClient(credential); var data = new {}; -var operation = await client.PutNonRetry201Creating400InvalidJsonAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.PutNonRetry201Creating400InvalidJsonAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -207,7 +207,7 @@ var data = new { location = "", }; -var operation = await client.PutNonRetry201Creating400InvalidJsonAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.PutNonRetry201Creating400InvalidJsonAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -230,7 +230,7 @@ var client = new LrosaDsClient(credential); var data = new {}; -var operation = client.PutNonRetry201Creating400InvalidJson(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.PutNonRetry201Creating400InvalidJson(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -251,7 +251,7 @@ var data = new { location = "", }; -var operation = client.PutNonRetry201Creating400InvalidJson(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.PutNonRetry201Creating400InvalidJson(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -274,7 +274,7 @@ var client = new LrosaDsClient(credential); var data = new {}; -var operation = await client.PutAsyncRelativeRetry400Async(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.PutAsyncRelativeRetry400Async(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -295,7 +295,7 @@ var data = new { location = "", }; -var operation = await client.PutAsyncRelativeRetry400Async(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.PutAsyncRelativeRetry400Async(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -318,7 +318,7 @@ var client = new LrosaDsClient(credential); var data = new {}; -var operation = client.PutAsyncRelativeRetry400(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.PutAsyncRelativeRetry400(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -339,7 +339,7 @@ var data = new { location = "", }; -var operation = client.PutAsyncRelativeRetry400(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.PutAsyncRelativeRetry400(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -440,7 +440,7 @@ var client = new LrosaDsClient(credential); var data = new {}; -var operation = await client.PostNonRetry400Async(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.PostNonRetry400Async(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); ]]> @@ -459,7 +459,7 @@ var data = new { location = "", }; -var operation = await client.PostNonRetry400Async(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.PostNonRetry400Async(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); ]]> @@ -474,7 +474,7 @@ var client = new LrosaDsClient(credential); var data = new {}; -var operation = client.PostNonRetry400(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.PostNonRetry400(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); ]]> @@ -493,7 +493,7 @@ var data = new { location = "", }; -var operation = client.PostNonRetry400(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.PostNonRetry400(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); ]]> @@ -508,7 +508,7 @@ var client = new LrosaDsClient(credential); var data = new {}; -var operation = await client.Post202NonRetry400Async(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.Post202NonRetry400Async(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); ]]> @@ -527,7 +527,7 @@ var data = new { location = "", }; -var operation = await client.Post202NonRetry400Async(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.Post202NonRetry400Async(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); ]]> @@ -542,7 +542,7 @@ var client = new LrosaDsClient(credential); var data = new {}; -var operation = client.Post202NonRetry400(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.Post202NonRetry400(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); ]]> @@ -561,7 +561,7 @@ var data = new { location = "", }; -var operation = client.Post202NonRetry400(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.Post202NonRetry400(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); ]]> @@ -576,7 +576,7 @@ var client = new LrosaDsClient(credential); var data = new {}; -var operation = await client.PostAsyncRelativeRetry400Async(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.PostAsyncRelativeRetry400Async(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); ]]> @@ -595,7 +595,7 @@ var data = new { location = "", }; -var operation = await client.PostAsyncRelativeRetry400Async(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.PostAsyncRelativeRetry400Async(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); ]]> @@ -610,7 +610,7 @@ var client = new LrosaDsClient(credential); var data = new {}; -var operation = client.PostAsyncRelativeRetry400(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.PostAsyncRelativeRetry400(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); ]]> @@ -629,7 +629,7 @@ var data = new { location = "", }; -var operation = client.PostAsyncRelativeRetry400(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.PostAsyncRelativeRetry400(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); ]]> @@ -644,7 +644,7 @@ var client = new LrosaDsClient(credential); var data = new {}; -var operation = await client.PutError201NoProvisioningStatePayloadAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.PutError201NoProvisioningStatePayloadAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -665,7 +665,7 @@ var data = new { location = "", }; -var operation = await client.PutError201NoProvisioningStatePayloadAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.PutError201NoProvisioningStatePayloadAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -688,7 +688,7 @@ var client = new LrosaDsClient(credential); var data = new {}; -var operation = client.PutError201NoProvisioningStatePayload(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.PutError201NoProvisioningStatePayload(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -709,7 +709,7 @@ var data = new { location = "", }; -var operation = client.PutError201NoProvisioningStatePayload(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.PutError201NoProvisioningStatePayload(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -732,7 +732,7 @@ var client = new LrosaDsClient(credential); var data = new {}; -var operation = await client.PutAsyncRelativeRetryNoStatusAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.PutAsyncRelativeRetryNoStatusAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -753,7 +753,7 @@ var data = new { location = "", }; -var operation = await client.PutAsyncRelativeRetryNoStatusAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.PutAsyncRelativeRetryNoStatusAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -776,7 +776,7 @@ var client = new LrosaDsClient(credential); var data = new {}; -var operation = client.PutAsyncRelativeRetryNoStatus(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.PutAsyncRelativeRetryNoStatus(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -797,7 +797,7 @@ var data = new { location = "", }; -var operation = client.PutAsyncRelativeRetryNoStatus(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.PutAsyncRelativeRetryNoStatus(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -820,7 +820,7 @@ var client = new LrosaDsClient(credential); var data = new {}; -var operation = await client.PutAsyncRelativeRetryNoStatusPayloadAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.PutAsyncRelativeRetryNoStatusPayloadAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -841,7 +841,7 @@ var data = new { location = "", }; -var operation = await client.PutAsyncRelativeRetryNoStatusPayloadAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.PutAsyncRelativeRetryNoStatusPayloadAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -864,7 +864,7 @@ var client = new LrosaDsClient(credential); var data = new {}; -var operation = client.PutAsyncRelativeRetryNoStatusPayload(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.PutAsyncRelativeRetryNoStatusPayload(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -885,7 +885,7 @@ var data = new { location = "", }; -var operation = client.PutAsyncRelativeRetryNoStatusPayload(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.PutAsyncRelativeRetryNoStatusPayload(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -960,7 +960,7 @@ var client = new LrosaDsClient(credential); var data = new {}; -var operation = await client.Post202NoLocationAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.Post202NoLocationAsync(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); ]]> @@ -979,7 +979,7 @@ var data = new { location = "", }; -var operation = await client.Post202NoLocationAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.Post202NoLocationAsync(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); ]]> @@ -994,7 +994,7 @@ var client = new LrosaDsClient(credential); var data = new {}; -var operation = client.Post202NoLocation(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.Post202NoLocation(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); ]]> @@ -1013,7 +1013,7 @@ var data = new { location = "", }; -var operation = client.Post202NoLocation(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.Post202NoLocation(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); ]]> @@ -1028,7 +1028,7 @@ var client = new LrosaDsClient(credential); var data = new {}; -var operation = await client.PostAsyncRelativeRetryNoPayloadAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.PostAsyncRelativeRetryNoPayloadAsync(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); ]]> @@ -1047,7 +1047,7 @@ var data = new { location = "", }; -var operation = await client.PostAsyncRelativeRetryNoPayloadAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.PostAsyncRelativeRetryNoPayloadAsync(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); ]]> @@ -1062,7 +1062,7 @@ var client = new LrosaDsClient(credential); var data = new {}; -var operation = client.PostAsyncRelativeRetryNoPayload(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.PostAsyncRelativeRetryNoPayload(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); ]]> @@ -1081,7 +1081,7 @@ var data = new { location = "", }; -var operation = client.PostAsyncRelativeRetryNoPayload(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.PostAsyncRelativeRetryNoPayload(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); ]]> @@ -1096,7 +1096,7 @@ var client = new LrosaDsClient(credential); var data = new {}; -var operation = await client.Put200InvalidJsonAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.Put200InvalidJsonAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1117,7 +1117,7 @@ var data = new { location = "", }; -var operation = await client.Put200InvalidJsonAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.Put200InvalidJsonAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1140,7 +1140,7 @@ var client = new LrosaDsClient(credential); var data = new {}; -var operation = client.Put200InvalidJson(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.Put200InvalidJson(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1161,7 +1161,7 @@ var data = new { location = "", }; -var operation = client.Put200InvalidJson(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.Put200InvalidJson(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1184,7 +1184,7 @@ var client = new LrosaDsClient(credential); var data = new {}; -var operation = await client.PutAsyncRelativeRetryInvalidHeaderAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.PutAsyncRelativeRetryInvalidHeaderAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1205,7 +1205,7 @@ var data = new { location = "", }; -var operation = await client.PutAsyncRelativeRetryInvalidHeaderAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.PutAsyncRelativeRetryInvalidHeaderAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1228,7 +1228,7 @@ var client = new LrosaDsClient(credential); var data = new {}; -var operation = client.PutAsyncRelativeRetryInvalidHeader(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.PutAsyncRelativeRetryInvalidHeader(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1249,7 +1249,7 @@ var data = new { location = "", }; -var operation = client.PutAsyncRelativeRetryInvalidHeader(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.PutAsyncRelativeRetryInvalidHeader(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1272,7 +1272,7 @@ var client = new LrosaDsClient(credential); var data = new {}; -var operation = await client.PutAsyncRelativeRetryInvalidJsonPollingAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.PutAsyncRelativeRetryInvalidJsonPollingAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1293,7 +1293,7 @@ var data = new { location = "", }; -var operation = await client.PutAsyncRelativeRetryInvalidJsonPollingAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.PutAsyncRelativeRetryInvalidJsonPollingAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1316,7 +1316,7 @@ var client = new LrosaDsClient(credential); var data = new {}; -var operation = client.PutAsyncRelativeRetryInvalidJsonPolling(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.PutAsyncRelativeRetryInvalidJsonPolling(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1337,7 +1337,7 @@ var data = new { location = "", }; -var operation = client.PutAsyncRelativeRetryInvalidJsonPolling(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.PutAsyncRelativeRetryInvalidJsonPolling(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1438,7 +1438,7 @@ var client = new LrosaDsClient(credential); var data = new {}; -var operation = await client.Post202RetryInvalidHeaderAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.Post202RetryInvalidHeaderAsync(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); ]]> @@ -1457,7 +1457,7 @@ var data = new { location = "", }; -var operation = await client.Post202RetryInvalidHeaderAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.Post202RetryInvalidHeaderAsync(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); ]]> @@ -1472,7 +1472,7 @@ var client = new LrosaDsClient(credential); var data = new {}; -var operation = client.Post202RetryInvalidHeader(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.Post202RetryInvalidHeader(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); ]]> @@ -1491,7 +1491,7 @@ var data = new { location = "", }; -var operation = client.Post202RetryInvalidHeader(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.Post202RetryInvalidHeader(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); ]]> @@ -1506,7 +1506,7 @@ var client = new LrosaDsClient(credential); var data = new {}; -var operation = await client.PostAsyncRelativeRetryInvalidHeaderAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.PostAsyncRelativeRetryInvalidHeaderAsync(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); ]]> @@ -1525,7 +1525,7 @@ var data = new { location = "", }; -var operation = await client.PostAsyncRelativeRetryInvalidHeaderAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.PostAsyncRelativeRetryInvalidHeaderAsync(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); ]]> @@ -1540,7 +1540,7 @@ var client = new LrosaDsClient(credential); var data = new {}; -var operation = client.PostAsyncRelativeRetryInvalidHeader(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.PostAsyncRelativeRetryInvalidHeader(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); ]]> @@ -1559,7 +1559,7 @@ var data = new { location = "", }; -var operation = client.PostAsyncRelativeRetryInvalidHeader(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.PostAsyncRelativeRetryInvalidHeader(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); ]]> @@ -1574,7 +1574,7 @@ var client = new LrosaDsClient(credential); var data = new {}; -var operation = await client.PostAsyncRelativeRetryInvalidJsonPollingAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.PostAsyncRelativeRetryInvalidJsonPollingAsync(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); ]]> @@ -1593,7 +1593,7 @@ var data = new { location = "", }; -var operation = await client.PostAsyncRelativeRetryInvalidJsonPollingAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = await client.PostAsyncRelativeRetryInvalidJsonPollingAsync(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); ]]> @@ -1608,7 +1608,7 @@ var client = new LrosaDsClient(credential); var data = new {}; -var operation = client.PostAsyncRelativeRetryInvalidJsonPolling(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.PostAsyncRelativeRetryInvalidJsonPolling(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); ]]> @@ -1627,7 +1627,7 @@ var data = new { location = "", }; -var operation = client.PostAsyncRelativeRetryInvalidJsonPolling(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); +var operation = client.PostAsyncRelativeRetryInvalidJsonPolling(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); ]]> diff --git a/test/TestServerProjectsLowLevel/lro/src/Generated/LRORetrysClient.cs b/test/TestServerProjectsLowLevel/lro/src/Generated/LRORetrysClient.cs index cd162b781b1..9268f39358e 100644 --- a/test/TestServerProjectsLowLevel/lro/src/Generated/LRORetrysClient.cs +++ b/test/TestServerProjectsLowLevel/lro/src/Generated/LRORetrysClient.cs @@ -73,7 +73,7 @@ public LRORetrysClient(AzureKeyCredential credential, Uri endpoint, AutoRestLong /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual async Task> Put201CreatingSucceeded200Async(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual async Task> Put201CreatingSucceeded200Async(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LRORetrysClient.Put201CreatingSucceeded200"); scope.Start(); @@ -105,7 +105,7 @@ public virtual async Task> Put201CreatingSucceeded200Async /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual Operation Put201CreatingSucceeded200(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual Operation Put201CreatingSucceeded200(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LRORetrysClient.Put201CreatingSucceeded200"); scope.Start(); @@ -137,7 +137,7 @@ public virtual Operation Put201CreatingSucceeded200(WaitUntil waitUn /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual async Task> PutAsyncRelativeRetrySucceededAsync(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual async Task> PutAsyncRelativeRetrySucceededAsync(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LRORetrysClient.PutAsyncRelativeRetrySucceeded"); scope.Start(); @@ -169,7 +169,7 @@ public virtual async Task> PutAsyncRelativeRetrySucceededA /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual Operation PutAsyncRelativeRetrySucceeded(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual Operation PutAsyncRelativeRetrySucceeded(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LRORetrysClient.PutAsyncRelativeRetrySucceeded"); scope.Start(); @@ -387,7 +387,7 @@ public virtual Operation DeleteAsyncRelativeRetrySucceeded(WaitUntil waitUntil, /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual async Task Post202Retry200Async(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual async Task Post202Retry200Async(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LRORetrysClient.Post202Retry200"); scope.Start(); @@ -419,7 +419,7 @@ public virtual async Task Post202Retry200Async(WaitUntil waitUntil, R /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual Operation Post202Retry200(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual Operation Post202Retry200(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LRORetrysClient.Post202Retry200"); scope.Start(); @@ -451,7 +451,7 @@ public virtual Operation Post202Retry200(WaitUntil waitUntil, RequestContent con /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual async Task PostAsyncRelativeRetrySucceededAsync(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual async Task PostAsyncRelativeRetrySucceededAsync(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LRORetrysClient.PostAsyncRelativeRetrySucceeded"); scope.Start(); @@ -483,7 +483,7 @@ public virtual async Task PostAsyncRelativeRetrySucceededAsync(WaitUn /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual Operation PostAsyncRelativeRetrySucceeded(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual Operation PostAsyncRelativeRetrySucceeded(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LRORetrysClient.PostAsyncRelativeRetrySucceeded"); scope.Start(); diff --git a/test/TestServerProjectsLowLevel/lro/src/Generated/LROsClient.cs b/test/TestServerProjectsLowLevel/lro/src/Generated/LROsClient.cs index fead27ac220..4abb285d9a4 100644 --- a/test/TestServerProjectsLowLevel/lro/src/Generated/LROsClient.cs +++ b/test/TestServerProjectsLowLevel/lro/src/Generated/LROsClient.cs @@ -73,7 +73,7 @@ public LROsClient(AzureKeyCredential credential, Uri endpoint, AutoRestLongRunni /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual async Task> Put200SucceededAsync(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual async Task> Put200SucceededAsync(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LROsClient.Put200Succeeded"); scope.Start(); @@ -105,7 +105,7 @@ public virtual async Task> Put200SucceededAsync(WaitUntil /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual Operation Put200Succeeded(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual Operation Put200Succeeded(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LROsClient.Put200Succeeded"); scope.Start(); @@ -137,7 +137,7 @@ public virtual Operation Put200Succeeded(WaitUntil waitUntil, Reques /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual async Task> Patch200SucceededIgnoreHeadersAsync(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual async Task> Patch200SucceededIgnoreHeadersAsync(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LROsClient.Patch200SucceededIgnoreHeaders"); scope.Start(); @@ -169,7 +169,7 @@ public virtual async Task> Patch200SucceededIgnoreHeadersA /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual Operation Patch200SucceededIgnoreHeaders(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual Operation Patch200SucceededIgnoreHeaders(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LROsClient.Patch200SucceededIgnoreHeaders"); scope.Start(); @@ -201,7 +201,7 @@ public virtual Operation Patch200SucceededIgnoreHeaders(WaitUntil wa /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual async Task> Patch201RetryWithAsyncHeaderAsync(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual async Task> Patch201RetryWithAsyncHeaderAsync(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LROsClient.Patch201RetryWithAsyncHeader"); scope.Start(); @@ -233,7 +233,7 @@ public virtual async Task> Patch201RetryWithAsyncHeaderAsy /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual Operation Patch201RetryWithAsyncHeader(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual Operation Patch201RetryWithAsyncHeader(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LROsClient.Patch201RetryWithAsyncHeader"); scope.Start(); @@ -265,7 +265,7 @@ public virtual Operation Patch201RetryWithAsyncHeader(WaitUntil wait /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual async Task> Patch202RetryWithAsyncAndLocationHeaderAsync(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual async Task> Patch202RetryWithAsyncAndLocationHeaderAsync(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LROsClient.Patch202RetryWithAsyncAndLocationHeader"); scope.Start(); @@ -297,7 +297,7 @@ public virtual async Task> Patch202RetryWithAsyncAndLocati /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual Operation Patch202RetryWithAsyncAndLocationHeader(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual Operation Patch202RetryWithAsyncAndLocationHeader(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LROsClient.Patch202RetryWithAsyncAndLocationHeader"); scope.Start(); @@ -329,7 +329,7 @@ public virtual Operation Patch202RetryWithAsyncAndLocationHeader(Wai /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual async Task> Put201SucceededAsync(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual async Task> Put201SucceededAsync(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LROsClient.Put201Succeeded"); scope.Start(); @@ -361,7 +361,7 @@ public virtual async Task> Put201SucceededAsync(WaitUntil /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual Operation Put201Succeeded(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual Operation Put201Succeeded(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LROsClient.Put201Succeeded"); scope.Start(); @@ -455,7 +455,7 @@ public virtual Operation Post202List(WaitUntil waitUntil, RequestCon /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual async Task> Put200SucceededNoStateAsync(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual async Task> Put200SucceededNoStateAsync(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LROsClient.Put200SucceededNoState"); scope.Start(); @@ -487,7 +487,7 @@ public virtual async Task> Put200SucceededNoStateAsync(Wai /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual Operation Put200SucceededNoState(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual Operation Put200SucceededNoState(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LROsClient.Put200SucceededNoState"); scope.Start(); @@ -519,7 +519,7 @@ public virtual Operation Put200SucceededNoState(WaitUntil waitUntil, /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual async Task> Put202Retry200Async(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual async Task> Put202Retry200Async(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LROsClient.Put202Retry200"); scope.Start(); @@ -551,7 +551,7 @@ public virtual async Task> Put202Retry200Async(WaitUntil w /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual Operation Put202Retry200(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual Operation Put202Retry200(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LROsClient.Put202Retry200"); scope.Start(); @@ -583,7 +583,7 @@ public virtual Operation Put202Retry200(WaitUntil waitUntil, Request /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual async Task> Put201CreatingSucceeded200Async(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual async Task> Put201CreatingSucceeded200Async(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LROsClient.Put201CreatingSucceeded200"); scope.Start(); @@ -615,7 +615,7 @@ public virtual async Task> Put201CreatingSucceeded200Async /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual Operation Put201CreatingSucceeded200(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual Operation Put201CreatingSucceeded200(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LROsClient.Put201CreatingSucceeded200"); scope.Start(); @@ -647,7 +647,7 @@ public virtual Operation Put201CreatingSucceeded200(WaitUntil waitUn /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual async Task> Put200UpdatingSucceeded204Async(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual async Task> Put200UpdatingSucceeded204Async(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LROsClient.Put200UpdatingSucceeded204"); scope.Start(); @@ -679,7 +679,7 @@ public virtual async Task> Put200UpdatingSucceeded204Async /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual Operation Put200UpdatingSucceeded204(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual Operation Put200UpdatingSucceeded204(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LROsClient.Put200UpdatingSucceeded204"); scope.Start(); @@ -711,7 +711,7 @@ public virtual Operation Put200UpdatingSucceeded204(WaitUntil waitUn /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual async Task> Put201CreatingFailed200Async(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual async Task> Put201CreatingFailed200Async(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LROsClient.Put201CreatingFailed200"); scope.Start(); @@ -743,7 +743,7 @@ public virtual async Task> Put201CreatingFailed200Async(Wa /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual Operation Put201CreatingFailed200(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual Operation Put201CreatingFailed200(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LROsClient.Put201CreatingFailed200"); scope.Start(); @@ -775,7 +775,7 @@ public virtual Operation Put201CreatingFailed200(WaitUntil waitUntil /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual async Task> Put200Acceptedcanceled200Async(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual async Task> Put200Acceptedcanceled200Async(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LROsClient.Put200Acceptedcanceled200"); scope.Start(); @@ -807,7 +807,7 @@ public virtual async Task> Put200Acceptedcanceled200Async( /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual Operation Put200Acceptedcanceled200(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual Operation Put200Acceptedcanceled200(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LROsClient.Put200Acceptedcanceled200"); scope.Start(); @@ -839,7 +839,7 @@ public virtual Operation Put200Acceptedcanceled200(WaitUntil waitUnt /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual async Task> PutNoHeaderInRetryAsync(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual async Task> PutNoHeaderInRetryAsync(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LROsClient.PutNoHeaderInRetry"); scope.Start(); @@ -871,7 +871,7 @@ public virtual async Task> PutNoHeaderInRetryAsync(WaitUnt /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual Operation PutNoHeaderInRetry(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual Operation PutNoHeaderInRetry(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LROsClient.PutNoHeaderInRetry"); scope.Start(); @@ -903,7 +903,7 @@ public virtual Operation PutNoHeaderInRetry(WaitUntil waitUntil, Req /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual async Task> PutAsyncRetrySucceededAsync(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual async Task> PutAsyncRetrySucceededAsync(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LROsClient.PutAsyncRetrySucceeded"); scope.Start(); @@ -935,7 +935,7 @@ public virtual async Task> PutAsyncRetrySucceededAsync(Wai /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual Operation PutAsyncRetrySucceeded(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual Operation PutAsyncRetrySucceeded(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LROsClient.PutAsyncRetrySucceeded"); scope.Start(); @@ -967,7 +967,7 @@ public virtual Operation PutAsyncRetrySucceeded(WaitUntil waitUntil, /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual async Task> PutAsyncNoRetrySucceededAsync(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual async Task> PutAsyncNoRetrySucceededAsync(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LROsClient.PutAsyncNoRetrySucceeded"); scope.Start(); @@ -999,7 +999,7 @@ public virtual async Task> PutAsyncNoRetrySucceededAsync(W /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual Operation PutAsyncNoRetrySucceeded(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual Operation PutAsyncNoRetrySucceeded(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LROsClient.PutAsyncNoRetrySucceeded"); scope.Start(); @@ -1031,7 +1031,7 @@ public virtual Operation PutAsyncNoRetrySucceeded(WaitUntil waitUnti /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual async Task> PutAsyncRetryFailedAsync(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual async Task> PutAsyncRetryFailedAsync(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LROsClient.PutAsyncRetryFailed"); scope.Start(); @@ -1063,7 +1063,7 @@ public virtual async Task> PutAsyncRetryFailedAsync(WaitUn /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual Operation PutAsyncRetryFailed(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual Operation PutAsyncRetryFailed(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LROsClient.PutAsyncRetryFailed"); scope.Start(); @@ -1095,7 +1095,7 @@ public virtual Operation PutAsyncRetryFailed(WaitUntil waitUntil, Re /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual async Task> PutAsyncNoRetrycanceledAsync(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual async Task> PutAsyncNoRetrycanceledAsync(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LROsClient.PutAsyncNoRetrycanceled"); scope.Start(); @@ -1127,7 +1127,7 @@ public virtual async Task> PutAsyncNoRetrycanceledAsync(Wa /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual Operation PutAsyncNoRetrycanceled(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual Operation PutAsyncNoRetrycanceled(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LROsClient.PutAsyncNoRetrycanceled"); scope.Start(); @@ -1159,7 +1159,7 @@ public virtual Operation PutAsyncNoRetrycanceled(WaitUntil waitUntil /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual async Task> PutAsyncNoHeaderInRetryAsync(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual async Task> PutAsyncNoHeaderInRetryAsync(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LROsClient.PutAsyncNoHeaderInRetry"); scope.Start(); @@ -1191,7 +1191,7 @@ public virtual async Task> PutAsyncNoHeaderInRetryAsync(Wa /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual Operation PutAsyncNoHeaderInRetry(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual Operation PutAsyncNoHeaderInRetry(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LROsClient.PutAsyncNoHeaderInRetry"); scope.Start(); @@ -1223,7 +1223,7 @@ public virtual Operation PutAsyncNoHeaderInRetry(WaitUntil waitUntil /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual async Task> PutNonResourceAsync(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual async Task> PutNonResourceAsync(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LROsClient.PutNonResource"); scope.Start(); @@ -1255,7 +1255,7 @@ public virtual async Task> PutNonResourceAsync(WaitUntil w /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual Operation PutNonResource(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual Operation PutNonResource(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LROsClient.PutNonResource"); scope.Start(); @@ -1287,7 +1287,7 @@ public virtual Operation PutNonResource(WaitUntil waitUntil, Request /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual async Task> PutAsyncNonResourceAsync(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual async Task> PutAsyncNonResourceAsync(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LROsClient.PutAsyncNonResource"); scope.Start(); @@ -1319,7 +1319,7 @@ public virtual async Task> PutAsyncNonResourceAsync(WaitUn /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual Operation PutAsyncNonResource(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual Operation PutAsyncNonResource(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LROsClient.PutAsyncNonResource"); scope.Start(); @@ -1351,7 +1351,7 @@ public virtual Operation PutAsyncNonResource(WaitUntil waitUntil, Re /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual async Task> PutSubResourceAsync(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual async Task> PutSubResourceAsync(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LROsClient.PutSubResource"); scope.Start(); @@ -1383,7 +1383,7 @@ public virtual async Task> PutSubResourceAsync(WaitUntil w /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual Operation PutSubResource(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual Operation PutSubResource(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LROsClient.PutSubResource"); scope.Start(); @@ -1415,7 +1415,7 @@ public virtual Operation PutSubResource(WaitUntil waitUntil, Request /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual async Task> PutAsyncSubResourceAsync(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual async Task> PutAsyncSubResourceAsync(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LROsClient.PutAsyncSubResource"); scope.Start(); @@ -1447,7 +1447,7 @@ public virtual async Task> PutAsyncSubResourceAsync(WaitUn /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual Operation PutAsyncSubResource(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual Operation PutAsyncSubResource(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LROsClient.PutAsyncSubResource"); scope.Start(); @@ -2285,7 +2285,7 @@ public virtual Operation Post200WithPayload(WaitUntil waitUntil, Req /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual async Task Post202Retry200Async(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual async Task Post202Retry200Async(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LROsClient.Post202Retry200"); scope.Start(); @@ -2317,7 +2317,7 @@ public virtual async Task Post202Retry200Async(WaitUntil waitUntil, R /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual Operation Post202Retry200(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual Operation Post202Retry200(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LROsClient.Post202Retry200"); scope.Start(); @@ -2349,7 +2349,7 @@ public virtual Operation Post202Retry200(WaitUntil waitUntil, RequestContent con /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual async Task> Post202NoRetry204Async(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual async Task> Post202NoRetry204Async(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LROsClient.Post202NoRetry204"); scope.Start(); @@ -2381,7 +2381,7 @@ public virtual async Task> Post202NoRetry204Async(WaitUnti /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual Operation Post202NoRetry204(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual Operation Post202NoRetry204(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LROsClient.Post202NoRetry204"); scope.Start(); @@ -2599,7 +2599,7 @@ public virtual Operation PostDoubleHeadersFinalAzureHeaderGetDefault /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual async Task> PostAsyncRetrySucceededAsync(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual async Task> PostAsyncRetrySucceededAsync(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LROsClient.PostAsyncRetrySucceeded"); scope.Start(); @@ -2631,7 +2631,7 @@ public virtual async Task> PostAsyncRetrySucceededAsync(Wa /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual Operation PostAsyncRetrySucceeded(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual Operation PostAsyncRetrySucceeded(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LROsClient.PostAsyncRetrySucceeded"); scope.Start(); @@ -2663,7 +2663,7 @@ public virtual Operation PostAsyncRetrySucceeded(WaitUntil waitUntil /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual async Task> PostAsyncNoRetrySucceededAsync(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual async Task> PostAsyncNoRetrySucceededAsync(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LROsClient.PostAsyncNoRetrySucceeded"); scope.Start(); @@ -2695,7 +2695,7 @@ public virtual async Task> PostAsyncNoRetrySucceededAsync( /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual Operation PostAsyncNoRetrySucceeded(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual Operation PostAsyncNoRetrySucceeded(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LROsClient.PostAsyncNoRetrySucceeded"); scope.Start(); @@ -2727,7 +2727,7 @@ public virtual Operation PostAsyncNoRetrySucceeded(WaitUntil waitUnt /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual async Task PostAsyncRetryFailedAsync(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual async Task PostAsyncRetryFailedAsync(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LROsClient.PostAsyncRetryFailed"); scope.Start(); @@ -2759,7 +2759,7 @@ public virtual async Task PostAsyncRetryFailedAsync(WaitUntil waitUnt /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual Operation PostAsyncRetryFailed(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual Operation PostAsyncRetryFailed(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LROsClient.PostAsyncRetryFailed"); scope.Start(); @@ -2791,7 +2791,7 @@ public virtual Operation PostAsyncRetryFailed(WaitUntil waitUntil, RequestConten /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual async Task PostAsyncRetrycanceledAsync(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual async Task PostAsyncRetrycanceledAsync(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LROsClient.PostAsyncRetrycanceled"); scope.Start(); @@ -2823,7 +2823,7 @@ public virtual async Task PostAsyncRetrycanceledAsync(WaitUntil waitU /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual Operation PostAsyncRetrycanceled(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual Operation PostAsyncRetrycanceled(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LROsClient.PostAsyncRetrycanceled"); scope.Start(); diff --git a/test/TestServerProjectsLowLevel/lro/src/Generated/LROsCustomHeaderClient.cs b/test/TestServerProjectsLowLevel/lro/src/Generated/LROsCustomHeaderClient.cs index 2366aed153f..8c5c5754459 100644 --- a/test/TestServerProjectsLowLevel/lro/src/Generated/LROsCustomHeaderClient.cs +++ b/test/TestServerProjectsLowLevel/lro/src/Generated/LROsCustomHeaderClient.cs @@ -73,7 +73,7 @@ public LROsCustomHeaderClient(AzureKeyCredential credential, Uri endpoint, AutoR /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual async Task> PutAsyncRetrySucceededAsync(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual async Task> PutAsyncRetrySucceededAsync(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LROsCustomHeaderClient.PutAsyncRetrySucceeded"); scope.Start(); @@ -105,7 +105,7 @@ public virtual async Task> PutAsyncRetrySucceededAsync(Wai /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual Operation PutAsyncRetrySucceeded(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual Operation PutAsyncRetrySucceeded(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LROsCustomHeaderClient.PutAsyncRetrySucceeded"); scope.Start(); @@ -137,7 +137,7 @@ public virtual Operation PutAsyncRetrySucceeded(WaitUntil waitUntil, /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual async Task> Put201CreatingSucceeded200Async(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual async Task> Put201CreatingSucceeded200Async(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LROsCustomHeaderClient.Put201CreatingSucceeded200"); scope.Start(); @@ -169,7 +169,7 @@ public virtual async Task> Put201CreatingSucceeded200Async /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual Operation Put201CreatingSucceeded200(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual Operation Put201CreatingSucceeded200(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LROsCustomHeaderClient.Put201CreatingSucceeded200"); scope.Start(); @@ -201,7 +201,7 @@ public virtual Operation Put201CreatingSucceeded200(WaitUntil waitUn /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual async Task Post202Retry200Async(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual async Task Post202Retry200Async(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LROsCustomHeaderClient.Post202Retry200"); scope.Start(); @@ -233,7 +233,7 @@ public virtual async Task Post202Retry200Async(WaitUntil waitUntil, R /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual Operation Post202Retry200(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual Operation Post202Retry200(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LROsCustomHeaderClient.Post202Retry200"); scope.Start(); @@ -265,7 +265,7 @@ public virtual Operation Post202Retry200(WaitUntil waitUntil, RequestContent con /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual async Task PostAsyncRetrySucceededAsync(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual async Task PostAsyncRetrySucceededAsync(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LROsCustomHeaderClient.PostAsyncRetrySucceeded"); scope.Start(); @@ -297,7 +297,7 @@ public virtual async Task PostAsyncRetrySucceededAsync(WaitUntil wait /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual Operation PostAsyncRetrySucceeded(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual Operation PostAsyncRetrySucceeded(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LROsCustomHeaderClient.PostAsyncRetrySucceeded"); scope.Start(); diff --git a/test/TestServerProjectsLowLevel/lro/src/Generated/LrosaDsClient.cs b/test/TestServerProjectsLowLevel/lro/src/Generated/LrosaDsClient.cs index 39e4b8dcd1a..ce4774384bb 100644 --- a/test/TestServerProjectsLowLevel/lro/src/Generated/LrosaDsClient.cs +++ b/test/TestServerProjectsLowLevel/lro/src/Generated/LrosaDsClient.cs @@ -73,7 +73,7 @@ public LrosaDsClient(AzureKeyCredential credential, Uri endpoint, AutoRestLongRu /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual async Task> PutNonRetry400Async(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual async Task> PutNonRetry400Async(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LrosaDsClient.PutNonRetry400"); scope.Start(); @@ -105,7 +105,7 @@ public virtual async Task> PutNonRetry400Async(WaitUntil w /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual Operation PutNonRetry400(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual Operation PutNonRetry400(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LrosaDsClient.PutNonRetry400"); scope.Start(); @@ -137,7 +137,7 @@ public virtual Operation PutNonRetry400(WaitUntil waitUntil, Request /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual async Task> PutNonRetry201Creating400Async(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual async Task> PutNonRetry201Creating400Async(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LrosaDsClient.PutNonRetry201Creating400"); scope.Start(); @@ -169,7 +169,7 @@ public virtual async Task> PutNonRetry201Creating400Async( /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual Operation PutNonRetry201Creating400(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual Operation PutNonRetry201Creating400(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LrosaDsClient.PutNonRetry201Creating400"); scope.Start(); @@ -201,7 +201,7 @@ public virtual Operation PutNonRetry201Creating400(WaitUntil waitUnt /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual async Task> PutNonRetry201Creating400InvalidJsonAsync(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual async Task> PutNonRetry201Creating400InvalidJsonAsync(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LrosaDsClient.PutNonRetry201Creating400InvalidJson"); scope.Start(); @@ -233,7 +233,7 @@ public virtual async Task> PutNonRetry201Creating400Invali /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual Operation PutNonRetry201Creating400InvalidJson(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual Operation PutNonRetry201Creating400InvalidJson(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LrosaDsClient.PutNonRetry201Creating400InvalidJson"); scope.Start(); @@ -265,7 +265,7 @@ public virtual Operation PutNonRetry201Creating400InvalidJson(WaitUn /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual async Task> PutAsyncRelativeRetry400Async(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual async Task> PutAsyncRelativeRetry400Async(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LrosaDsClient.PutAsyncRelativeRetry400"); scope.Start(); @@ -297,7 +297,7 @@ public virtual async Task> PutAsyncRelativeRetry400Async(W /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual Operation PutAsyncRelativeRetry400(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual Operation PutAsyncRelativeRetry400(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LrosaDsClient.PutAsyncRelativeRetry400"); scope.Start(); @@ -515,7 +515,7 @@ public virtual Operation DeleteAsyncRelativeRetry400(WaitUntil waitUntil, Reques /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual async Task PostNonRetry400Async(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual async Task PostNonRetry400Async(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LrosaDsClient.PostNonRetry400"); scope.Start(); @@ -547,7 +547,7 @@ public virtual async Task PostNonRetry400Async(WaitUntil waitUntil, R /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual Operation PostNonRetry400(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual Operation PostNonRetry400(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LrosaDsClient.PostNonRetry400"); scope.Start(); @@ -579,7 +579,7 @@ public virtual Operation PostNonRetry400(WaitUntil waitUntil, RequestContent con /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual async Task Post202NonRetry400Async(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual async Task Post202NonRetry400Async(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LrosaDsClient.Post202NonRetry400"); scope.Start(); @@ -611,7 +611,7 @@ public virtual async Task Post202NonRetry400Async(WaitUntil waitUntil /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual Operation Post202NonRetry400(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual Operation Post202NonRetry400(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LrosaDsClient.Post202NonRetry400"); scope.Start(); @@ -643,7 +643,7 @@ public virtual Operation Post202NonRetry400(WaitUntil waitUntil, RequestContent /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual async Task PostAsyncRelativeRetry400Async(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual async Task PostAsyncRelativeRetry400Async(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LrosaDsClient.PostAsyncRelativeRetry400"); scope.Start(); @@ -675,7 +675,7 @@ public virtual async Task PostAsyncRelativeRetry400Async(WaitUntil wa /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual Operation PostAsyncRelativeRetry400(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual Operation PostAsyncRelativeRetry400(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LrosaDsClient.PostAsyncRelativeRetry400"); scope.Start(); @@ -707,7 +707,7 @@ public virtual Operation PostAsyncRelativeRetry400(WaitUntil waitUntil, RequestC /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual async Task> PutError201NoProvisioningStatePayloadAsync(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual async Task> PutError201NoProvisioningStatePayloadAsync(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LrosaDsClient.PutError201NoProvisioningStatePayload"); scope.Start(); @@ -739,7 +739,7 @@ public virtual async Task> PutError201NoProvisioningStateP /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual Operation PutError201NoProvisioningStatePayload(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual Operation PutError201NoProvisioningStatePayload(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LrosaDsClient.PutError201NoProvisioningStatePayload"); scope.Start(); @@ -771,7 +771,7 @@ public virtual Operation PutError201NoProvisioningStatePayload(WaitU /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual async Task> PutAsyncRelativeRetryNoStatusAsync(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual async Task> PutAsyncRelativeRetryNoStatusAsync(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LrosaDsClient.PutAsyncRelativeRetryNoStatus"); scope.Start(); @@ -803,7 +803,7 @@ public virtual async Task> PutAsyncRelativeRetryNoStatusAs /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual Operation PutAsyncRelativeRetryNoStatus(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual Operation PutAsyncRelativeRetryNoStatus(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LrosaDsClient.PutAsyncRelativeRetryNoStatus"); scope.Start(); @@ -835,7 +835,7 @@ public virtual Operation PutAsyncRelativeRetryNoStatus(WaitUntil wai /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual async Task> PutAsyncRelativeRetryNoStatusPayloadAsync(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual async Task> PutAsyncRelativeRetryNoStatusPayloadAsync(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LrosaDsClient.PutAsyncRelativeRetryNoStatusPayload"); scope.Start(); @@ -867,7 +867,7 @@ public virtual async Task> PutAsyncRelativeRetryNoStatusPa /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual Operation PutAsyncRelativeRetryNoStatusPayload(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual Operation PutAsyncRelativeRetryNoStatusPayload(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LrosaDsClient.PutAsyncRelativeRetryNoStatusPayload"); scope.Start(); @@ -1023,7 +1023,7 @@ public virtual Operation DeleteAsyncRelativeRetryNoStatus(WaitUntil waitUntil, R /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual async Task Post202NoLocationAsync(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual async Task Post202NoLocationAsync(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LrosaDsClient.Post202NoLocation"); scope.Start(); @@ -1055,7 +1055,7 @@ public virtual async Task Post202NoLocationAsync(WaitUntil waitUntil, /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual Operation Post202NoLocation(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual Operation Post202NoLocation(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LrosaDsClient.Post202NoLocation"); scope.Start(); @@ -1087,7 +1087,7 @@ public virtual Operation Post202NoLocation(WaitUntil waitUntil, RequestContent c /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual async Task PostAsyncRelativeRetryNoPayloadAsync(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual async Task PostAsyncRelativeRetryNoPayloadAsync(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LrosaDsClient.PostAsyncRelativeRetryNoPayload"); scope.Start(); @@ -1119,7 +1119,7 @@ public virtual async Task PostAsyncRelativeRetryNoPayloadAsync(WaitUn /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual Operation PostAsyncRelativeRetryNoPayload(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual Operation PostAsyncRelativeRetryNoPayload(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LrosaDsClient.PostAsyncRelativeRetryNoPayload"); scope.Start(); @@ -1151,7 +1151,7 @@ public virtual Operation PostAsyncRelativeRetryNoPayload(WaitUntil waitUntil, Re /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual async Task> Put200InvalidJsonAsync(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual async Task> Put200InvalidJsonAsync(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LrosaDsClient.Put200InvalidJson"); scope.Start(); @@ -1183,7 +1183,7 @@ public virtual async Task> Put200InvalidJsonAsync(WaitUnti /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual Operation Put200InvalidJson(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual Operation Put200InvalidJson(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LrosaDsClient.Put200InvalidJson"); scope.Start(); @@ -1215,7 +1215,7 @@ public virtual Operation Put200InvalidJson(WaitUntil waitUntil, Requ /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual async Task> PutAsyncRelativeRetryInvalidHeaderAsync(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual async Task> PutAsyncRelativeRetryInvalidHeaderAsync(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LrosaDsClient.PutAsyncRelativeRetryInvalidHeader"); scope.Start(); @@ -1247,7 +1247,7 @@ public virtual async Task> PutAsyncRelativeRetryInvalidHea /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual Operation PutAsyncRelativeRetryInvalidHeader(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual Operation PutAsyncRelativeRetryInvalidHeader(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LrosaDsClient.PutAsyncRelativeRetryInvalidHeader"); scope.Start(); @@ -1279,7 +1279,7 @@ public virtual Operation PutAsyncRelativeRetryInvalidHeader(WaitUnti /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual async Task> PutAsyncRelativeRetryInvalidJsonPollingAsync(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual async Task> PutAsyncRelativeRetryInvalidJsonPollingAsync(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LrosaDsClient.PutAsyncRelativeRetryInvalidJsonPolling"); scope.Start(); @@ -1311,7 +1311,7 @@ public virtual async Task> PutAsyncRelativeRetryInvalidJso /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual Operation PutAsyncRelativeRetryInvalidJsonPolling(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual Operation PutAsyncRelativeRetryInvalidJsonPolling(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LrosaDsClient.PutAsyncRelativeRetryInvalidJsonPolling"); scope.Start(); @@ -1529,7 +1529,7 @@ public virtual Operation DeleteAsyncRelativeRetryInvalidJsonPolling(WaitUntil wa /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual async Task Post202RetryInvalidHeaderAsync(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual async Task Post202RetryInvalidHeaderAsync(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LrosaDsClient.Post202RetryInvalidHeader"); scope.Start(); @@ -1561,7 +1561,7 @@ public virtual async Task Post202RetryInvalidHeaderAsync(WaitUntil wa /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual Operation Post202RetryInvalidHeader(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual Operation Post202RetryInvalidHeader(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LrosaDsClient.Post202RetryInvalidHeader"); scope.Start(); @@ -1593,7 +1593,7 @@ public virtual Operation Post202RetryInvalidHeader(WaitUntil waitUntil, RequestC /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual async Task PostAsyncRelativeRetryInvalidHeaderAsync(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual async Task PostAsyncRelativeRetryInvalidHeaderAsync(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LrosaDsClient.PostAsyncRelativeRetryInvalidHeader"); scope.Start(); @@ -1625,7 +1625,7 @@ public virtual async Task PostAsyncRelativeRetryInvalidHeaderAsync(Wa /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual Operation PostAsyncRelativeRetryInvalidHeader(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual Operation PostAsyncRelativeRetryInvalidHeader(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LrosaDsClient.PostAsyncRelativeRetryInvalidHeader"); scope.Start(); @@ -1657,7 +1657,7 @@ public virtual Operation PostAsyncRelativeRetryInvalidHeader(WaitUntil waitUntil /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual async Task PostAsyncRelativeRetryInvalidJsonPollingAsync(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual async Task PostAsyncRelativeRetryInvalidJsonPollingAsync(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LrosaDsClient.PostAsyncRelativeRetryInvalidJsonPolling"); scope.Start(); @@ -1689,7 +1689,7 @@ public virtual async Task PostAsyncRelativeRetryInvalidJsonPollingAsy /// Service returned a non-success status code. /// The representing an asynchronous operation on the service. /// - public virtual Operation PostAsyncRelativeRetryInvalidJsonPolling(WaitUntil waitUntil, RequestContent content, RequestContext context) + public virtual Operation PostAsyncRelativeRetryInvalidJsonPolling(WaitUntil waitUntil, RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("LrosaDsClient.PostAsyncRelativeRetryInvalidJsonPolling"); scope.Start(); diff --git a/test/TestServerProjectsLowLevel/lro/tests/Generated/Samples/Samples_LRORetrysClient.cs b/test/TestServerProjectsLowLevel/lro/tests/Generated/Samples/Samples_LRORetrysClient.cs index 6738f279d06..d00cb08289e 100644 --- a/test/TestServerProjectsLowLevel/lro/tests/Generated/Samples/Samples_LRORetrysClient.cs +++ b/test/TestServerProjectsLowLevel/lro/tests/Generated/Samples/Samples_LRORetrysClient.cs @@ -28,7 +28,7 @@ public void Example_Put201CreatingSucceeded200() var data = new { }; - var operation = client.Put201CreatingSucceeded200(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.Put201CreatingSucceeded200(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -55,7 +55,7 @@ public void Example_Put201CreatingSucceeded200_AllParameters() location = "", }; - var operation = client.Put201CreatingSucceeded200(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.Put201CreatingSucceeded200(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -77,7 +77,7 @@ public async Task Example_Put201CreatingSucceeded200_Async() var data = new { }; - var operation = await client.Put201CreatingSucceeded200Async(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.Put201CreatingSucceeded200Async(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -104,7 +104,7 @@ public async Task Example_Put201CreatingSucceeded200_AllParameters_Async() location = "", }; - var operation = await client.Put201CreatingSucceeded200Async(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.Put201CreatingSucceeded200Async(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -126,7 +126,7 @@ public void Example_PutAsyncRelativeRetrySucceeded() var data = new { }; - var operation = client.PutAsyncRelativeRetrySucceeded(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.PutAsyncRelativeRetrySucceeded(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -153,7 +153,7 @@ public void Example_PutAsyncRelativeRetrySucceeded_AllParameters() location = "", }; - var operation = client.PutAsyncRelativeRetrySucceeded(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.PutAsyncRelativeRetrySucceeded(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -175,7 +175,7 @@ public async Task Example_PutAsyncRelativeRetrySucceeded_Async() var data = new { }; - var operation = await client.PutAsyncRelativeRetrySucceededAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.PutAsyncRelativeRetrySucceededAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -202,7 +202,7 @@ public async Task Example_PutAsyncRelativeRetrySucceeded_AllParameters_Async() location = "", }; - var operation = await client.PutAsyncRelativeRetrySucceededAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.PutAsyncRelativeRetrySucceededAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -388,7 +388,7 @@ public void Example_Post202Retry200() var data = new { }; - var operation = client.Post202Retry200(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.Post202Retry200(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); } @@ -413,7 +413,7 @@ public void Example_Post202Retry200_AllParameters() location = "", }; - var operation = client.Post202Retry200(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.Post202Retry200(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); } @@ -427,7 +427,7 @@ public async Task Example_Post202Retry200_Async() var data = new { }; - var operation = await client.Post202Retry200Async(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.Post202Retry200Async(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); } @@ -452,7 +452,7 @@ public async Task Example_Post202Retry200_AllParameters_Async() location = "", }; - var operation = await client.Post202Retry200Async(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.Post202Retry200Async(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); } @@ -466,7 +466,7 @@ public void Example_PostAsyncRelativeRetrySucceeded() var data = new { }; - var operation = client.PostAsyncRelativeRetrySucceeded(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.PostAsyncRelativeRetrySucceeded(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); } @@ -491,7 +491,7 @@ public void Example_PostAsyncRelativeRetrySucceeded_AllParameters() location = "", }; - var operation = client.PostAsyncRelativeRetrySucceeded(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.PostAsyncRelativeRetrySucceeded(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); } @@ -505,7 +505,7 @@ public async Task Example_PostAsyncRelativeRetrySucceeded_Async() var data = new { }; - var operation = await client.PostAsyncRelativeRetrySucceededAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.PostAsyncRelativeRetrySucceededAsync(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); } @@ -530,7 +530,7 @@ public async Task Example_PostAsyncRelativeRetrySucceeded_AllParameters_Async() location = "", }; - var operation = await client.PostAsyncRelativeRetrySucceededAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.PostAsyncRelativeRetrySucceededAsync(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); } diff --git a/test/TestServerProjectsLowLevel/lro/tests/Generated/Samples/Samples_LROsClient.cs b/test/TestServerProjectsLowLevel/lro/tests/Generated/Samples/Samples_LROsClient.cs index 73b2c551af8..291104e1452 100644 --- a/test/TestServerProjectsLowLevel/lro/tests/Generated/Samples/Samples_LROsClient.cs +++ b/test/TestServerProjectsLowLevel/lro/tests/Generated/Samples/Samples_LROsClient.cs @@ -28,7 +28,7 @@ public void Example_Put200Succeeded() var data = new { }; - var operation = client.Put200Succeeded(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.Put200Succeeded(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -55,7 +55,7 @@ public void Example_Put200Succeeded_AllParameters() location = "", }; - var operation = client.Put200Succeeded(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.Put200Succeeded(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -77,7 +77,7 @@ public async Task Example_Put200Succeeded_Async() var data = new { }; - var operation = await client.Put200SucceededAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.Put200SucceededAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -104,7 +104,7 @@ public async Task Example_Put200Succeeded_AllParameters_Async() location = "", }; - var operation = await client.Put200SucceededAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.Put200SucceededAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -126,7 +126,7 @@ public void Example_Patch200SucceededIgnoreHeaders() var data = new { }; - var operation = client.Patch200SucceededIgnoreHeaders(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.Patch200SucceededIgnoreHeaders(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -153,7 +153,7 @@ public void Example_Patch200SucceededIgnoreHeaders_AllParameters() location = "", }; - var operation = client.Patch200SucceededIgnoreHeaders(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.Patch200SucceededIgnoreHeaders(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -175,7 +175,7 @@ public async Task Example_Patch200SucceededIgnoreHeaders_Async() var data = new { }; - var operation = await client.Patch200SucceededIgnoreHeadersAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.Patch200SucceededIgnoreHeadersAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -202,7 +202,7 @@ public async Task Example_Patch200SucceededIgnoreHeaders_AllParameters_Async() location = "", }; - var operation = await client.Patch200SucceededIgnoreHeadersAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.Patch200SucceededIgnoreHeadersAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -224,7 +224,7 @@ public void Example_Patch201RetryWithAsyncHeader() var data = new { }; - var operation = client.Patch201RetryWithAsyncHeader(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.Patch201RetryWithAsyncHeader(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -251,7 +251,7 @@ public void Example_Patch201RetryWithAsyncHeader_AllParameters() location = "", }; - var operation = client.Patch201RetryWithAsyncHeader(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.Patch201RetryWithAsyncHeader(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -273,7 +273,7 @@ public async Task Example_Patch201RetryWithAsyncHeader_Async() var data = new { }; - var operation = await client.Patch201RetryWithAsyncHeaderAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.Patch201RetryWithAsyncHeaderAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -300,7 +300,7 @@ public async Task Example_Patch201RetryWithAsyncHeader_AllParameters_Async() location = "", }; - var operation = await client.Patch201RetryWithAsyncHeaderAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.Patch201RetryWithAsyncHeaderAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -322,7 +322,7 @@ public void Example_Patch202RetryWithAsyncAndLocationHeader() var data = new { }; - var operation = client.Patch202RetryWithAsyncAndLocationHeader(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.Patch202RetryWithAsyncAndLocationHeader(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -349,7 +349,7 @@ public void Example_Patch202RetryWithAsyncAndLocationHeader_AllParameters() location = "", }; - var operation = client.Patch202RetryWithAsyncAndLocationHeader(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.Patch202RetryWithAsyncAndLocationHeader(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -371,7 +371,7 @@ public async Task Example_Patch202RetryWithAsyncAndLocationHeader_Async() var data = new { }; - var operation = await client.Patch202RetryWithAsyncAndLocationHeaderAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.Patch202RetryWithAsyncAndLocationHeaderAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -398,7 +398,7 @@ public async Task Example_Patch202RetryWithAsyncAndLocationHeader_AllParameters_ location = "", }; - var operation = await client.Patch202RetryWithAsyncAndLocationHeaderAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.Patch202RetryWithAsyncAndLocationHeaderAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -420,7 +420,7 @@ public void Example_Put201Succeeded() var data = new { }; - var operation = client.Put201Succeeded(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.Put201Succeeded(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -447,7 +447,7 @@ public void Example_Put201Succeeded_AllParameters() location = "", }; - var operation = client.Put201Succeeded(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.Put201Succeeded(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -469,7 +469,7 @@ public async Task Example_Put201Succeeded_Async() var data = new { }; - var operation = await client.Put201SucceededAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.Put201SucceededAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -496,7 +496,7 @@ public async Task Example_Put201Succeeded_AllParameters_Async() location = "", }; - var operation = await client.Put201SucceededAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.Put201SucceededAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -586,7 +586,7 @@ public void Example_Put200SucceededNoState() var data = new { }; - var operation = client.Put200SucceededNoState(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.Put200SucceededNoState(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -613,7 +613,7 @@ public void Example_Put200SucceededNoState_AllParameters() location = "", }; - var operation = client.Put200SucceededNoState(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.Put200SucceededNoState(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -635,7 +635,7 @@ public async Task Example_Put200SucceededNoState_Async() var data = new { }; - var operation = await client.Put200SucceededNoStateAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.Put200SucceededNoStateAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -662,7 +662,7 @@ public async Task Example_Put200SucceededNoState_AllParameters_Async() location = "", }; - var operation = await client.Put200SucceededNoStateAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.Put200SucceededNoStateAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -684,7 +684,7 @@ public void Example_Put202Retry200() var data = new { }; - var operation = client.Put202Retry200(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.Put202Retry200(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -711,7 +711,7 @@ public void Example_Put202Retry200_AllParameters() location = "", }; - var operation = client.Put202Retry200(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.Put202Retry200(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -733,7 +733,7 @@ public async Task Example_Put202Retry200_Async() var data = new { }; - var operation = await client.Put202Retry200Async(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.Put202Retry200Async(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -760,7 +760,7 @@ public async Task Example_Put202Retry200_AllParameters_Async() location = "", }; - var operation = await client.Put202Retry200Async(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.Put202Retry200Async(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -782,7 +782,7 @@ public void Example_Put201CreatingSucceeded200() var data = new { }; - var operation = client.Put201CreatingSucceeded200(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.Put201CreatingSucceeded200(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -809,7 +809,7 @@ public void Example_Put201CreatingSucceeded200_AllParameters() location = "", }; - var operation = client.Put201CreatingSucceeded200(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.Put201CreatingSucceeded200(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -831,7 +831,7 @@ public async Task Example_Put201CreatingSucceeded200_Async() var data = new { }; - var operation = await client.Put201CreatingSucceeded200Async(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.Put201CreatingSucceeded200Async(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -858,7 +858,7 @@ public async Task Example_Put201CreatingSucceeded200_AllParameters_Async() location = "", }; - var operation = await client.Put201CreatingSucceeded200Async(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.Put201CreatingSucceeded200Async(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -880,7 +880,7 @@ public void Example_Put200UpdatingSucceeded204() var data = new { }; - var operation = client.Put200UpdatingSucceeded204(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.Put200UpdatingSucceeded204(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -907,7 +907,7 @@ public void Example_Put200UpdatingSucceeded204_AllParameters() location = "", }; - var operation = client.Put200UpdatingSucceeded204(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.Put200UpdatingSucceeded204(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -929,7 +929,7 @@ public async Task Example_Put200UpdatingSucceeded204_Async() var data = new { }; - var operation = await client.Put200UpdatingSucceeded204Async(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.Put200UpdatingSucceeded204Async(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -956,7 +956,7 @@ public async Task Example_Put200UpdatingSucceeded204_AllParameters_Async() location = "", }; - var operation = await client.Put200UpdatingSucceeded204Async(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.Put200UpdatingSucceeded204Async(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -978,7 +978,7 @@ public void Example_Put201CreatingFailed200() var data = new { }; - var operation = client.Put201CreatingFailed200(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.Put201CreatingFailed200(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1005,7 +1005,7 @@ public void Example_Put201CreatingFailed200_AllParameters() location = "", }; - var operation = client.Put201CreatingFailed200(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.Put201CreatingFailed200(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1027,7 +1027,7 @@ public async Task Example_Put201CreatingFailed200_Async() var data = new { }; - var operation = await client.Put201CreatingFailed200Async(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.Put201CreatingFailed200Async(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1054,7 +1054,7 @@ public async Task Example_Put201CreatingFailed200_AllParameters_Async() location = "", }; - var operation = await client.Put201CreatingFailed200Async(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.Put201CreatingFailed200Async(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1076,7 +1076,7 @@ public void Example_Put200Acceptedcanceled200() var data = new { }; - var operation = client.Put200Acceptedcanceled200(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.Put200Acceptedcanceled200(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1103,7 +1103,7 @@ public void Example_Put200Acceptedcanceled200_AllParameters() location = "", }; - var operation = client.Put200Acceptedcanceled200(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.Put200Acceptedcanceled200(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1125,7 +1125,7 @@ public async Task Example_Put200Acceptedcanceled200_Async() var data = new { }; - var operation = await client.Put200Acceptedcanceled200Async(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.Put200Acceptedcanceled200Async(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1152,7 +1152,7 @@ public async Task Example_Put200Acceptedcanceled200_AllParameters_Async() location = "", }; - var operation = await client.Put200Acceptedcanceled200Async(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.Put200Acceptedcanceled200Async(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1174,7 +1174,7 @@ public void Example_PutNoHeaderInRetry() var data = new { }; - var operation = client.PutNoHeaderInRetry(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.PutNoHeaderInRetry(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1201,7 +1201,7 @@ public void Example_PutNoHeaderInRetry_AllParameters() location = "", }; - var operation = client.PutNoHeaderInRetry(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.PutNoHeaderInRetry(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1223,7 +1223,7 @@ public async Task Example_PutNoHeaderInRetry_Async() var data = new { }; - var operation = await client.PutNoHeaderInRetryAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.PutNoHeaderInRetryAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1250,7 +1250,7 @@ public async Task Example_PutNoHeaderInRetry_AllParameters_Async() location = "", }; - var operation = await client.PutNoHeaderInRetryAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.PutNoHeaderInRetryAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1272,7 +1272,7 @@ public void Example_PutAsyncRetrySucceeded() var data = new { }; - var operation = client.PutAsyncRetrySucceeded(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.PutAsyncRetrySucceeded(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1299,7 +1299,7 @@ public void Example_PutAsyncRetrySucceeded_AllParameters() location = "", }; - var operation = client.PutAsyncRetrySucceeded(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.PutAsyncRetrySucceeded(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1321,7 +1321,7 @@ public async Task Example_PutAsyncRetrySucceeded_Async() var data = new { }; - var operation = await client.PutAsyncRetrySucceededAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.PutAsyncRetrySucceededAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1348,7 +1348,7 @@ public async Task Example_PutAsyncRetrySucceeded_AllParameters_Async() location = "", }; - var operation = await client.PutAsyncRetrySucceededAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.PutAsyncRetrySucceededAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1370,7 +1370,7 @@ public void Example_PutAsyncNoRetrySucceeded() var data = new { }; - var operation = client.PutAsyncNoRetrySucceeded(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.PutAsyncNoRetrySucceeded(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1397,7 +1397,7 @@ public void Example_PutAsyncNoRetrySucceeded_AllParameters() location = "", }; - var operation = client.PutAsyncNoRetrySucceeded(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.PutAsyncNoRetrySucceeded(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1419,7 +1419,7 @@ public async Task Example_PutAsyncNoRetrySucceeded_Async() var data = new { }; - var operation = await client.PutAsyncNoRetrySucceededAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.PutAsyncNoRetrySucceededAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1446,7 +1446,7 @@ public async Task Example_PutAsyncNoRetrySucceeded_AllParameters_Async() location = "", }; - var operation = await client.PutAsyncNoRetrySucceededAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.PutAsyncNoRetrySucceededAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1468,7 +1468,7 @@ public void Example_PutAsyncRetryFailed() var data = new { }; - var operation = client.PutAsyncRetryFailed(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.PutAsyncRetryFailed(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1495,7 +1495,7 @@ public void Example_PutAsyncRetryFailed_AllParameters() location = "", }; - var operation = client.PutAsyncRetryFailed(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.PutAsyncRetryFailed(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1517,7 +1517,7 @@ public async Task Example_PutAsyncRetryFailed_Async() var data = new { }; - var operation = await client.PutAsyncRetryFailedAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.PutAsyncRetryFailedAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1544,7 +1544,7 @@ public async Task Example_PutAsyncRetryFailed_AllParameters_Async() location = "", }; - var operation = await client.PutAsyncRetryFailedAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.PutAsyncRetryFailedAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1566,7 +1566,7 @@ public void Example_PutAsyncNoRetrycanceled() var data = new { }; - var operation = client.PutAsyncNoRetrycanceled(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.PutAsyncNoRetrycanceled(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1593,7 +1593,7 @@ public void Example_PutAsyncNoRetrycanceled_AllParameters() location = "", }; - var operation = client.PutAsyncNoRetrycanceled(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.PutAsyncNoRetrycanceled(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1615,7 +1615,7 @@ public async Task Example_PutAsyncNoRetrycanceled_Async() var data = new { }; - var operation = await client.PutAsyncNoRetrycanceledAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.PutAsyncNoRetrycanceledAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1642,7 +1642,7 @@ public async Task Example_PutAsyncNoRetrycanceled_AllParameters_Async() location = "", }; - var operation = await client.PutAsyncNoRetrycanceledAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.PutAsyncNoRetrycanceledAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1664,7 +1664,7 @@ public void Example_PutAsyncNoHeaderInRetry() var data = new { }; - var operation = client.PutAsyncNoHeaderInRetry(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.PutAsyncNoHeaderInRetry(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1691,7 +1691,7 @@ public void Example_PutAsyncNoHeaderInRetry_AllParameters() location = "", }; - var operation = client.PutAsyncNoHeaderInRetry(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.PutAsyncNoHeaderInRetry(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1713,7 +1713,7 @@ public async Task Example_PutAsyncNoHeaderInRetry_Async() var data = new { }; - var operation = await client.PutAsyncNoHeaderInRetryAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.PutAsyncNoHeaderInRetryAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1740,7 +1740,7 @@ public async Task Example_PutAsyncNoHeaderInRetry_AllParameters_Async() location = "", }; - var operation = await client.PutAsyncNoHeaderInRetryAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.PutAsyncNoHeaderInRetryAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1762,7 +1762,7 @@ public void Example_PutNonResource() var data = new { }; - var operation = client.PutNonResource(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.PutNonResource(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1782,7 +1782,7 @@ public void Example_PutNonResource_AllParameters() id = "", }; - var operation = client.PutNonResource(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.PutNonResource(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1799,7 +1799,7 @@ public async Task Example_PutNonResource_Async() var data = new { }; - var operation = await client.PutNonResourceAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.PutNonResourceAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1819,7 +1819,7 @@ public async Task Example_PutNonResource_AllParameters_Async() id = "", }; - var operation = await client.PutNonResourceAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.PutNonResourceAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1836,7 +1836,7 @@ public void Example_PutAsyncNonResource() var data = new { }; - var operation = client.PutAsyncNonResource(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.PutAsyncNonResource(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1856,7 +1856,7 @@ public void Example_PutAsyncNonResource_AllParameters() id = "", }; - var operation = client.PutAsyncNonResource(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.PutAsyncNonResource(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1873,7 +1873,7 @@ public async Task Example_PutAsyncNonResource_Async() var data = new { }; - var operation = await client.PutAsyncNonResourceAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.PutAsyncNonResourceAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1893,7 +1893,7 @@ public async Task Example_PutAsyncNonResource_AllParameters_Async() id = "", }; - var operation = await client.PutAsyncNonResourceAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.PutAsyncNonResourceAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1910,7 +1910,7 @@ public void Example_PutSubResource() var data = new { }; - var operation = client.PutSubResource(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.PutSubResource(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1932,7 +1932,7 @@ public void Example_PutSubResource_AllParameters() }, }; - var operation = client.PutSubResource(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.PutSubResource(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1950,7 +1950,7 @@ public async Task Example_PutSubResource_Async() var data = new { }; - var operation = await client.PutSubResourceAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.PutSubResourceAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1972,7 +1972,7 @@ public async Task Example_PutSubResource_AllParameters_Async() }, }; - var operation = await client.PutSubResourceAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.PutSubResourceAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1990,7 +1990,7 @@ public void Example_PutAsyncSubResource() var data = new { }; - var operation = client.PutAsyncSubResource(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.PutAsyncSubResource(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -2012,7 +2012,7 @@ public void Example_PutAsyncSubResource_AllParameters() }, }; - var operation = client.PutAsyncSubResource(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.PutAsyncSubResource(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -2030,7 +2030,7 @@ public async Task Example_PutAsyncSubResource_Async() var data = new { }; - var operation = await client.PutAsyncSubResourceAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.PutAsyncSubResourceAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -2052,7 +2052,7 @@ public async Task Example_PutAsyncSubResource_AllParameters_Async() }, }; - var operation = await client.PutAsyncSubResourceAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.PutAsyncSubResourceAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -2804,7 +2804,7 @@ public void Example_Post202Retry200() var data = new { }; - var operation = client.Post202Retry200(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.Post202Retry200(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); } @@ -2829,7 +2829,7 @@ public void Example_Post202Retry200_AllParameters() location = "", }; - var operation = client.Post202Retry200(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.Post202Retry200(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); } @@ -2843,7 +2843,7 @@ public async Task Example_Post202Retry200_Async() var data = new { }; - var operation = await client.Post202Retry200Async(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.Post202Retry200Async(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); } @@ -2868,7 +2868,7 @@ public async Task Example_Post202Retry200_AllParameters_Async() location = "", }; - var operation = await client.Post202Retry200Async(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.Post202Retry200Async(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); } @@ -2882,7 +2882,7 @@ public void Example_Post202NoRetry204() var data = new { }; - var operation = client.Post202NoRetry204(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.Post202NoRetry204(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -2909,7 +2909,7 @@ public void Example_Post202NoRetry204_AllParameters() location = "", }; - var operation = client.Post202NoRetry204(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.Post202NoRetry204(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -2931,7 +2931,7 @@ public async Task Example_Post202NoRetry204_Async() var data = new { }; - var operation = await client.Post202NoRetry204Async(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.Post202NoRetry204Async(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -2958,7 +2958,7 @@ public async Task Example_Post202NoRetry204_AllParameters_Async() location = "", }; - var operation = await client.Post202NoRetry204Async(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.Post202NoRetry204Async(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -3184,7 +3184,7 @@ public void Example_PostAsyncRetrySucceeded() var data = new { }; - var operation = client.PostAsyncRetrySucceeded(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.PostAsyncRetrySucceeded(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -3211,7 +3211,7 @@ public void Example_PostAsyncRetrySucceeded_AllParameters() location = "", }; - var operation = client.PostAsyncRetrySucceeded(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.PostAsyncRetrySucceeded(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -3233,7 +3233,7 @@ public async Task Example_PostAsyncRetrySucceeded_Async() var data = new { }; - var operation = await client.PostAsyncRetrySucceededAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.PostAsyncRetrySucceededAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -3260,7 +3260,7 @@ public async Task Example_PostAsyncRetrySucceeded_AllParameters_Async() location = "", }; - var operation = await client.PostAsyncRetrySucceededAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.PostAsyncRetrySucceededAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -3282,7 +3282,7 @@ public void Example_PostAsyncNoRetrySucceeded() var data = new { }; - var operation = client.PostAsyncNoRetrySucceeded(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.PostAsyncNoRetrySucceeded(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -3309,7 +3309,7 @@ public void Example_PostAsyncNoRetrySucceeded_AllParameters() location = "", }; - var operation = client.PostAsyncNoRetrySucceeded(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.PostAsyncNoRetrySucceeded(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -3331,7 +3331,7 @@ public async Task Example_PostAsyncNoRetrySucceeded_Async() var data = new { }; - var operation = await client.PostAsyncNoRetrySucceededAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.PostAsyncNoRetrySucceededAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -3358,7 +3358,7 @@ public async Task Example_PostAsyncNoRetrySucceeded_AllParameters_Async() location = "", }; - var operation = await client.PostAsyncNoRetrySucceededAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.PostAsyncNoRetrySucceededAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -3380,7 +3380,7 @@ public void Example_PostAsyncRetryFailed() var data = new { }; - var operation = client.PostAsyncRetryFailed(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.PostAsyncRetryFailed(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); } @@ -3405,7 +3405,7 @@ public void Example_PostAsyncRetryFailed_AllParameters() location = "", }; - var operation = client.PostAsyncRetryFailed(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.PostAsyncRetryFailed(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); } @@ -3419,7 +3419,7 @@ public async Task Example_PostAsyncRetryFailed_Async() var data = new { }; - var operation = await client.PostAsyncRetryFailedAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.PostAsyncRetryFailedAsync(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); } @@ -3444,7 +3444,7 @@ public async Task Example_PostAsyncRetryFailed_AllParameters_Async() location = "", }; - var operation = await client.PostAsyncRetryFailedAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.PostAsyncRetryFailedAsync(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); } @@ -3458,7 +3458,7 @@ public void Example_PostAsyncRetrycanceled() var data = new { }; - var operation = client.PostAsyncRetrycanceled(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.PostAsyncRetrycanceled(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); } @@ -3483,7 +3483,7 @@ public void Example_PostAsyncRetrycanceled_AllParameters() location = "", }; - var operation = client.PostAsyncRetrycanceled(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.PostAsyncRetrycanceled(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); } @@ -3497,7 +3497,7 @@ public async Task Example_PostAsyncRetrycanceled_Async() var data = new { }; - var operation = await client.PostAsyncRetrycanceledAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.PostAsyncRetrycanceledAsync(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); } @@ -3522,7 +3522,7 @@ public async Task Example_PostAsyncRetrycanceled_AllParameters_Async() location = "", }; - var operation = await client.PostAsyncRetrycanceledAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.PostAsyncRetrycanceledAsync(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); } diff --git a/test/TestServerProjectsLowLevel/lro/tests/Generated/Samples/Samples_LROsCustomHeaderClient.cs b/test/TestServerProjectsLowLevel/lro/tests/Generated/Samples/Samples_LROsCustomHeaderClient.cs index b6bcbcf9251..d19f2bced23 100644 --- a/test/TestServerProjectsLowLevel/lro/tests/Generated/Samples/Samples_LROsCustomHeaderClient.cs +++ b/test/TestServerProjectsLowLevel/lro/tests/Generated/Samples/Samples_LROsCustomHeaderClient.cs @@ -28,7 +28,7 @@ public void Example_PutAsyncRetrySucceeded() var data = new { }; - var operation = client.PutAsyncRetrySucceeded(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.PutAsyncRetrySucceeded(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -55,7 +55,7 @@ public void Example_PutAsyncRetrySucceeded_AllParameters() location = "", }; - var operation = client.PutAsyncRetrySucceeded(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.PutAsyncRetrySucceeded(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -77,7 +77,7 @@ public async Task Example_PutAsyncRetrySucceeded_Async() var data = new { }; - var operation = await client.PutAsyncRetrySucceededAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.PutAsyncRetrySucceededAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -104,7 +104,7 @@ public async Task Example_PutAsyncRetrySucceeded_AllParameters_Async() location = "", }; - var operation = await client.PutAsyncRetrySucceededAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.PutAsyncRetrySucceededAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -126,7 +126,7 @@ public void Example_Put201CreatingSucceeded200() var data = new { }; - var operation = client.Put201CreatingSucceeded200(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.Put201CreatingSucceeded200(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -153,7 +153,7 @@ public void Example_Put201CreatingSucceeded200_AllParameters() location = "", }; - var operation = client.Put201CreatingSucceeded200(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.Put201CreatingSucceeded200(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -175,7 +175,7 @@ public async Task Example_Put201CreatingSucceeded200_Async() var data = new { }; - var operation = await client.Put201CreatingSucceeded200Async(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.Put201CreatingSucceeded200Async(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -202,7 +202,7 @@ public async Task Example_Put201CreatingSucceeded200_AllParameters_Async() location = "", }; - var operation = await client.Put201CreatingSucceeded200Async(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.Put201CreatingSucceeded200Async(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -224,7 +224,7 @@ public void Example_Post202Retry200() var data = new { }; - var operation = client.Post202Retry200(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.Post202Retry200(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); } @@ -249,7 +249,7 @@ public void Example_Post202Retry200_AllParameters() location = "", }; - var operation = client.Post202Retry200(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.Post202Retry200(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); } @@ -263,7 +263,7 @@ public async Task Example_Post202Retry200_Async() var data = new { }; - var operation = await client.Post202Retry200Async(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.Post202Retry200Async(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); } @@ -288,7 +288,7 @@ public async Task Example_Post202Retry200_AllParameters_Async() location = "", }; - var operation = await client.Post202Retry200Async(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.Post202Retry200Async(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); } @@ -302,7 +302,7 @@ public void Example_PostAsyncRetrySucceeded() var data = new { }; - var operation = client.PostAsyncRetrySucceeded(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.PostAsyncRetrySucceeded(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); } @@ -327,7 +327,7 @@ public void Example_PostAsyncRetrySucceeded_AllParameters() location = "", }; - var operation = client.PostAsyncRetrySucceeded(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.PostAsyncRetrySucceeded(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); } @@ -341,7 +341,7 @@ public async Task Example_PostAsyncRetrySucceeded_Async() var data = new { }; - var operation = await client.PostAsyncRetrySucceededAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.PostAsyncRetrySucceededAsync(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); } @@ -366,7 +366,7 @@ public async Task Example_PostAsyncRetrySucceeded_AllParameters_Async() location = "", }; - var operation = await client.PostAsyncRetrySucceededAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.PostAsyncRetrySucceededAsync(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); } diff --git a/test/TestServerProjectsLowLevel/lro/tests/Generated/Samples/Samples_LrosaDsClient.cs b/test/TestServerProjectsLowLevel/lro/tests/Generated/Samples/Samples_LrosaDsClient.cs index ca38484702b..63be7fd0e1e 100644 --- a/test/TestServerProjectsLowLevel/lro/tests/Generated/Samples/Samples_LrosaDsClient.cs +++ b/test/TestServerProjectsLowLevel/lro/tests/Generated/Samples/Samples_LrosaDsClient.cs @@ -28,7 +28,7 @@ public void Example_PutNonRetry400() var data = new { }; - var operation = client.PutNonRetry400(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.PutNonRetry400(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -55,7 +55,7 @@ public void Example_PutNonRetry400_AllParameters() location = "", }; - var operation = client.PutNonRetry400(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.PutNonRetry400(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -77,7 +77,7 @@ public async Task Example_PutNonRetry400_Async() var data = new { }; - var operation = await client.PutNonRetry400Async(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.PutNonRetry400Async(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -104,7 +104,7 @@ public async Task Example_PutNonRetry400_AllParameters_Async() location = "", }; - var operation = await client.PutNonRetry400Async(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.PutNonRetry400Async(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -126,7 +126,7 @@ public void Example_PutNonRetry201Creating400() var data = new { }; - var operation = client.PutNonRetry201Creating400(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.PutNonRetry201Creating400(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -153,7 +153,7 @@ public void Example_PutNonRetry201Creating400_AllParameters() location = "", }; - var operation = client.PutNonRetry201Creating400(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.PutNonRetry201Creating400(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -175,7 +175,7 @@ public async Task Example_PutNonRetry201Creating400_Async() var data = new { }; - var operation = await client.PutNonRetry201Creating400Async(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.PutNonRetry201Creating400Async(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -202,7 +202,7 @@ public async Task Example_PutNonRetry201Creating400_AllParameters_Async() location = "", }; - var operation = await client.PutNonRetry201Creating400Async(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.PutNonRetry201Creating400Async(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -224,7 +224,7 @@ public void Example_PutNonRetry201Creating400InvalidJson() var data = new { }; - var operation = client.PutNonRetry201Creating400InvalidJson(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.PutNonRetry201Creating400InvalidJson(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -251,7 +251,7 @@ public void Example_PutNonRetry201Creating400InvalidJson_AllParameters() location = "", }; - var operation = client.PutNonRetry201Creating400InvalidJson(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.PutNonRetry201Creating400InvalidJson(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -273,7 +273,7 @@ public async Task Example_PutNonRetry201Creating400InvalidJson_Async() var data = new { }; - var operation = await client.PutNonRetry201Creating400InvalidJsonAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.PutNonRetry201Creating400InvalidJsonAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -300,7 +300,7 @@ public async Task Example_PutNonRetry201Creating400InvalidJson_AllParameters_Asy location = "", }; - var operation = await client.PutNonRetry201Creating400InvalidJsonAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.PutNonRetry201Creating400InvalidJsonAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -322,7 +322,7 @@ public void Example_PutAsyncRelativeRetry400() var data = new { }; - var operation = client.PutAsyncRelativeRetry400(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.PutAsyncRelativeRetry400(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -349,7 +349,7 @@ public void Example_PutAsyncRelativeRetry400_AllParameters() location = "", }; - var operation = client.PutAsyncRelativeRetry400(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.PutAsyncRelativeRetry400(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -371,7 +371,7 @@ public async Task Example_PutAsyncRelativeRetry400_Async() var data = new { }; - var operation = await client.PutAsyncRelativeRetry400Async(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.PutAsyncRelativeRetry400Async(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -398,7 +398,7 @@ public async Task Example_PutAsyncRelativeRetry400_AllParameters_Async() location = "", }; - var operation = await client.PutAsyncRelativeRetry400Async(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.PutAsyncRelativeRetry400Async(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -564,7 +564,7 @@ public void Example_PostNonRetry400() var data = new { }; - var operation = client.PostNonRetry400(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.PostNonRetry400(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); } @@ -589,7 +589,7 @@ public void Example_PostNonRetry400_AllParameters() location = "", }; - var operation = client.PostNonRetry400(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.PostNonRetry400(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); } @@ -603,7 +603,7 @@ public async Task Example_PostNonRetry400_Async() var data = new { }; - var operation = await client.PostNonRetry400Async(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.PostNonRetry400Async(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); } @@ -628,7 +628,7 @@ public async Task Example_PostNonRetry400_AllParameters_Async() location = "", }; - var operation = await client.PostNonRetry400Async(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.PostNonRetry400Async(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); } @@ -642,7 +642,7 @@ public void Example_Post202NonRetry400() var data = new { }; - var operation = client.Post202NonRetry400(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.Post202NonRetry400(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); } @@ -667,7 +667,7 @@ public void Example_Post202NonRetry400_AllParameters() location = "", }; - var operation = client.Post202NonRetry400(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.Post202NonRetry400(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); } @@ -681,7 +681,7 @@ public async Task Example_Post202NonRetry400_Async() var data = new { }; - var operation = await client.Post202NonRetry400Async(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.Post202NonRetry400Async(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); } @@ -706,7 +706,7 @@ public async Task Example_Post202NonRetry400_AllParameters_Async() location = "", }; - var operation = await client.Post202NonRetry400Async(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.Post202NonRetry400Async(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); } @@ -720,7 +720,7 @@ public void Example_PostAsyncRelativeRetry400() var data = new { }; - var operation = client.PostAsyncRelativeRetry400(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.PostAsyncRelativeRetry400(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); } @@ -745,7 +745,7 @@ public void Example_PostAsyncRelativeRetry400_AllParameters() location = "", }; - var operation = client.PostAsyncRelativeRetry400(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.PostAsyncRelativeRetry400(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); } @@ -759,7 +759,7 @@ public async Task Example_PostAsyncRelativeRetry400_Async() var data = new { }; - var operation = await client.PostAsyncRelativeRetry400Async(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.PostAsyncRelativeRetry400Async(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); } @@ -784,7 +784,7 @@ public async Task Example_PostAsyncRelativeRetry400_AllParameters_Async() location = "", }; - var operation = await client.PostAsyncRelativeRetry400Async(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.PostAsyncRelativeRetry400Async(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); } @@ -798,7 +798,7 @@ public void Example_PutError201NoProvisioningStatePayload() var data = new { }; - var operation = client.PutError201NoProvisioningStatePayload(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.PutError201NoProvisioningStatePayload(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -825,7 +825,7 @@ public void Example_PutError201NoProvisioningStatePayload_AllParameters() location = "", }; - var operation = client.PutError201NoProvisioningStatePayload(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.PutError201NoProvisioningStatePayload(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -847,7 +847,7 @@ public async Task Example_PutError201NoProvisioningStatePayload_Async() var data = new { }; - var operation = await client.PutError201NoProvisioningStatePayloadAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.PutError201NoProvisioningStatePayloadAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -874,7 +874,7 @@ public async Task Example_PutError201NoProvisioningStatePayload_AllParameters_As location = "", }; - var operation = await client.PutError201NoProvisioningStatePayloadAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.PutError201NoProvisioningStatePayloadAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -896,7 +896,7 @@ public void Example_PutAsyncRelativeRetryNoStatus() var data = new { }; - var operation = client.PutAsyncRelativeRetryNoStatus(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.PutAsyncRelativeRetryNoStatus(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -923,7 +923,7 @@ public void Example_PutAsyncRelativeRetryNoStatus_AllParameters() location = "", }; - var operation = client.PutAsyncRelativeRetryNoStatus(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.PutAsyncRelativeRetryNoStatus(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -945,7 +945,7 @@ public async Task Example_PutAsyncRelativeRetryNoStatus_Async() var data = new { }; - var operation = await client.PutAsyncRelativeRetryNoStatusAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.PutAsyncRelativeRetryNoStatusAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -972,7 +972,7 @@ public async Task Example_PutAsyncRelativeRetryNoStatus_AllParameters_Async() location = "", }; - var operation = await client.PutAsyncRelativeRetryNoStatusAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.PutAsyncRelativeRetryNoStatusAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -994,7 +994,7 @@ public void Example_PutAsyncRelativeRetryNoStatusPayload() var data = new { }; - var operation = client.PutAsyncRelativeRetryNoStatusPayload(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.PutAsyncRelativeRetryNoStatusPayload(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1021,7 +1021,7 @@ public void Example_PutAsyncRelativeRetryNoStatusPayload_AllParameters() location = "", }; - var operation = client.PutAsyncRelativeRetryNoStatusPayload(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.PutAsyncRelativeRetryNoStatusPayload(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1043,7 +1043,7 @@ public async Task Example_PutAsyncRelativeRetryNoStatusPayload_Async() var data = new { }; - var operation = await client.PutAsyncRelativeRetryNoStatusPayloadAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.PutAsyncRelativeRetryNoStatusPayloadAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1070,7 +1070,7 @@ public async Task Example_PutAsyncRelativeRetryNoStatusPayload_AllParameters_Asy location = "", }; - var operation = await client.PutAsyncRelativeRetryNoStatusPayloadAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.PutAsyncRelativeRetryNoStatusPayloadAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1188,7 +1188,7 @@ public void Example_Post202NoLocation() var data = new { }; - var operation = client.Post202NoLocation(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.Post202NoLocation(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); } @@ -1213,7 +1213,7 @@ public void Example_Post202NoLocation_AllParameters() location = "", }; - var operation = client.Post202NoLocation(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.Post202NoLocation(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); } @@ -1227,7 +1227,7 @@ public async Task Example_Post202NoLocation_Async() var data = new { }; - var operation = await client.Post202NoLocationAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.Post202NoLocationAsync(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); } @@ -1252,7 +1252,7 @@ public async Task Example_Post202NoLocation_AllParameters_Async() location = "", }; - var operation = await client.Post202NoLocationAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.Post202NoLocationAsync(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); } @@ -1266,7 +1266,7 @@ public void Example_PostAsyncRelativeRetryNoPayload() var data = new { }; - var operation = client.PostAsyncRelativeRetryNoPayload(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.PostAsyncRelativeRetryNoPayload(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); } @@ -1291,7 +1291,7 @@ public void Example_PostAsyncRelativeRetryNoPayload_AllParameters() location = "", }; - var operation = client.PostAsyncRelativeRetryNoPayload(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.PostAsyncRelativeRetryNoPayload(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); } @@ -1305,7 +1305,7 @@ public async Task Example_PostAsyncRelativeRetryNoPayload_Async() var data = new { }; - var operation = await client.PostAsyncRelativeRetryNoPayloadAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.PostAsyncRelativeRetryNoPayloadAsync(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); } @@ -1330,7 +1330,7 @@ public async Task Example_PostAsyncRelativeRetryNoPayload_AllParameters_Async() location = "", }; - var operation = await client.PostAsyncRelativeRetryNoPayloadAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.PostAsyncRelativeRetryNoPayloadAsync(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); } @@ -1344,7 +1344,7 @@ public void Example_Put200InvalidJson() var data = new { }; - var operation = client.Put200InvalidJson(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.Put200InvalidJson(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1371,7 +1371,7 @@ public void Example_Put200InvalidJson_AllParameters() location = "", }; - var operation = client.Put200InvalidJson(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.Put200InvalidJson(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1393,7 +1393,7 @@ public async Task Example_Put200InvalidJson_Async() var data = new { }; - var operation = await client.Put200InvalidJsonAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.Put200InvalidJsonAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1420,7 +1420,7 @@ public async Task Example_Put200InvalidJson_AllParameters_Async() location = "", }; - var operation = await client.Put200InvalidJsonAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.Put200InvalidJsonAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1442,7 +1442,7 @@ public void Example_PutAsyncRelativeRetryInvalidHeader() var data = new { }; - var operation = client.PutAsyncRelativeRetryInvalidHeader(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.PutAsyncRelativeRetryInvalidHeader(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1469,7 +1469,7 @@ public void Example_PutAsyncRelativeRetryInvalidHeader_AllParameters() location = "", }; - var operation = client.PutAsyncRelativeRetryInvalidHeader(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.PutAsyncRelativeRetryInvalidHeader(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1491,7 +1491,7 @@ public async Task Example_PutAsyncRelativeRetryInvalidHeader_Async() var data = new { }; - var operation = await client.PutAsyncRelativeRetryInvalidHeaderAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.PutAsyncRelativeRetryInvalidHeaderAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1518,7 +1518,7 @@ public async Task Example_PutAsyncRelativeRetryInvalidHeader_AllParameters_Async location = "", }; - var operation = await client.PutAsyncRelativeRetryInvalidHeaderAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.PutAsyncRelativeRetryInvalidHeaderAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1540,7 +1540,7 @@ public void Example_PutAsyncRelativeRetryInvalidJsonPolling() var data = new { }; - var operation = client.PutAsyncRelativeRetryInvalidJsonPolling(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.PutAsyncRelativeRetryInvalidJsonPolling(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1567,7 +1567,7 @@ public void Example_PutAsyncRelativeRetryInvalidJsonPolling_AllParameters() location = "", }; - var operation = client.PutAsyncRelativeRetryInvalidJsonPolling(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.PutAsyncRelativeRetryInvalidJsonPolling(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1589,7 +1589,7 @@ public async Task Example_PutAsyncRelativeRetryInvalidJsonPolling_Async() var data = new { }; - var operation = await client.PutAsyncRelativeRetryInvalidJsonPollingAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.PutAsyncRelativeRetryInvalidJsonPollingAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1616,7 +1616,7 @@ public async Task Example_PutAsyncRelativeRetryInvalidJsonPolling_AllParameters_ location = "", }; - var operation = await client.PutAsyncRelativeRetryInvalidJsonPollingAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.PutAsyncRelativeRetryInvalidJsonPollingAsync(WaitUntil.Completed, RequestContent.Create(data)); BinaryData responseData = operation.Value; JsonElement result = JsonDocument.Parse(responseData.ToStream()).RootElement; @@ -1782,7 +1782,7 @@ public void Example_Post202RetryInvalidHeader() var data = new { }; - var operation = client.Post202RetryInvalidHeader(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.Post202RetryInvalidHeader(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); } @@ -1807,7 +1807,7 @@ public void Example_Post202RetryInvalidHeader_AllParameters() location = "", }; - var operation = client.Post202RetryInvalidHeader(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.Post202RetryInvalidHeader(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); } @@ -1821,7 +1821,7 @@ public async Task Example_Post202RetryInvalidHeader_Async() var data = new { }; - var operation = await client.Post202RetryInvalidHeaderAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.Post202RetryInvalidHeaderAsync(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); } @@ -1846,7 +1846,7 @@ public async Task Example_Post202RetryInvalidHeader_AllParameters_Async() location = "", }; - var operation = await client.Post202RetryInvalidHeaderAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.Post202RetryInvalidHeaderAsync(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); } @@ -1860,7 +1860,7 @@ public void Example_PostAsyncRelativeRetryInvalidHeader() var data = new { }; - var operation = client.PostAsyncRelativeRetryInvalidHeader(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.PostAsyncRelativeRetryInvalidHeader(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); } @@ -1885,7 +1885,7 @@ public void Example_PostAsyncRelativeRetryInvalidHeader_AllParameters() location = "", }; - var operation = client.PostAsyncRelativeRetryInvalidHeader(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.PostAsyncRelativeRetryInvalidHeader(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); } @@ -1899,7 +1899,7 @@ public async Task Example_PostAsyncRelativeRetryInvalidHeader_Async() var data = new { }; - var operation = await client.PostAsyncRelativeRetryInvalidHeaderAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.PostAsyncRelativeRetryInvalidHeaderAsync(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); } @@ -1924,7 +1924,7 @@ public async Task Example_PostAsyncRelativeRetryInvalidHeader_AllParameters_Asyn location = "", }; - var operation = await client.PostAsyncRelativeRetryInvalidHeaderAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.PostAsyncRelativeRetryInvalidHeaderAsync(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); } @@ -1938,7 +1938,7 @@ public void Example_PostAsyncRelativeRetryInvalidJsonPolling() var data = new { }; - var operation = client.PostAsyncRelativeRetryInvalidJsonPolling(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.PostAsyncRelativeRetryInvalidJsonPolling(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); } @@ -1963,7 +1963,7 @@ public void Example_PostAsyncRelativeRetryInvalidJsonPolling_AllParameters() location = "", }; - var operation = client.PostAsyncRelativeRetryInvalidJsonPolling(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = client.PostAsyncRelativeRetryInvalidJsonPolling(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); } @@ -1977,7 +1977,7 @@ public async Task Example_PostAsyncRelativeRetryInvalidJsonPolling_Async() var data = new { }; - var operation = await client.PostAsyncRelativeRetryInvalidJsonPollingAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.PostAsyncRelativeRetryInvalidJsonPollingAsync(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); } @@ -2002,7 +2002,7 @@ public async Task Example_PostAsyncRelativeRetryInvalidJsonPolling_AllParameters location = "", }; - var operation = await client.PostAsyncRelativeRetryInvalidJsonPollingAsync(WaitUntil.Completed, RequestContent.Create(data), new RequestContext()); + var operation = await client.PostAsyncRelativeRetryInvalidJsonPollingAsync(WaitUntil.Completed, RequestContent.Create(data)); Console.WriteLine(operation.GetRawResponse().Status); } diff --git a/test/TestServerProjectsLowLevel/media_types/src/Generated/Docs/MediaTypesClient.xml b/test/TestServerProjectsLowLevel/media_types/src/Generated/Docs/MediaTypesClient.xml index 01d242063d8..b8bbdd834df 100644 --- a/test/TestServerProjectsLowLevel/media_types/src/Generated/Docs/MediaTypesClient.xml +++ b/test/TestServerProjectsLowLevel/media_types/src/Generated/Docs/MediaTypesClient.xml @@ -10,7 +10,7 @@ var client = new MediaTypesClient(credential); var data = File.OpenRead(""); -Response response = await client.AnalyzeBodyAsync(RequestContent.Create(data), ContentType.ApplicationOctetStream, new RequestContext()); +Response response = await client.AnalyzeBodyAsync(RequestContent.Create(data), ContentType.ApplicationOctetStream); JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; Console.WriteLine(result.ToString()); @@ -26,7 +26,7 @@ var client = new MediaTypesClient(credential); var data = File.OpenRead(""); -Response response = client.AnalyzeBody(RequestContent.Create(data), ContentType.ApplicationOctetStream, new RequestContext()); +Response response = client.AnalyzeBody(RequestContent.Create(data), ContentType.ApplicationOctetStream); JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; Console.WriteLine(result.ToString()); @@ -42,7 +42,7 @@ var client = new MediaTypesClient(credential); var data = File.OpenRead(""); -Response response = await client.AnalyzeBodyNoAcceptHeaderAsync(RequestContent.Create(data), ContentType.ApplicationOctetStream, new RequestContext()); +Response response = await client.AnalyzeBodyNoAcceptHeaderAsync(RequestContent.Create(data), ContentType.ApplicationOctetStream); Console.WriteLine(response.Status); ]]> @@ -56,21 +56,21 @@ var client = new MediaTypesClient(credential); var data = File.OpenRead(""); -Response response = client.AnalyzeBodyNoAcceptHeader(RequestContent.Create(data), ContentType.ApplicationOctetStream, new RequestContext()); +Response response = client.AnalyzeBodyNoAcceptHeader(RequestContent.Create(data), ContentType.ApplicationOctetStream); Console.WriteLine(response.Status); ]]> -This sample shows how to call ContentTypeWithEncodingAsync with required parameters and request content and parse the result. +This sample shows how to call ContentTypeWithEncodingAsync with required request content and parse the result. "); var client = new MediaTypesClient(credential); var data = ""; -Response response = await client.ContentTypeWithEncodingAsync(RequestContent.Create(data), new RequestContext()); +Response response = await client.ContentTypeWithEncodingAsync(RequestContent.Create(data)); JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; Console.WriteLine(result.ToString()); @@ -79,14 +79,14 @@ Console.WriteLine(result.ToString()); -This sample shows how to call ContentTypeWithEncoding with required parameters and request content and parse the result. +This sample shows how to call ContentTypeWithEncoding with required request content and parse the result. "); var client = new MediaTypesClient(credential); var data = ""; -Response response = client.ContentTypeWithEncoding(RequestContent.Create(data), new RequestContext()); +Response response = client.ContentTypeWithEncoding(RequestContent.Create(data)); JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; Console.WriteLine(result.ToString()); diff --git a/test/TestServerProjectsLowLevel/media_types/src/Generated/MediaTypesClient.cs b/test/TestServerProjectsLowLevel/media_types/src/Generated/MediaTypesClient.cs index a5399755af0..14e20eb68d6 100644 --- a/test/TestServerProjectsLowLevel/media_types/src/Generated/MediaTypesClient.cs +++ b/test/TestServerProjectsLowLevel/media_types/src/Generated/MediaTypesClient.cs @@ -73,7 +73,7 @@ public MediaTypesClient(AzureKeyCredential credential, Uri endpoint, MediaTypesC /// Service returned a non-success status code. /// The response returned from the service. /// - public virtual async Task AnalyzeBodyAsync(RequestContent content, ContentType contentType, RequestContext context) + public virtual async Task AnalyzeBodyAsync(RequestContent content, ContentType contentType, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("MediaTypesClient.AnalyzeBody"); scope.Start(); @@ -105,7 +105,7 @@ public virtual async Task AnalyzeBodyAsync(RequestContent content, Con /// Service returned a non-success status code. /// The response returned from the service. /// - public virtual Response AnalyzeBody(RequestContent content, ContentType contentType, RequestContext context) + public virtual Response AnalyzeBody(RequestContent content, ContentType contentType, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("MediaTypesClient.AnalyzeBody"); scope.Start(); @@ -137,7 +137,7 @@ public virtual Response AnalyzeBody(RequestContent content, ContentType contentT /// Service returned a non-success status code. /// The response returned from the service. /// - public virtual async Task AnalyzeBodyNoAcceptHeaderAsync(RequestContent content, ContentType contentType, RequestContext context) + public virtual async Task AnalyzeBodyNoAcceptHeaderAsync(RequestContent content, ContentType contentType, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("MediaTypesClient.AnalyzeBodyNoAcceptHeader"); scope.Start(); @@ -169,7 +169,7 @@ public virtual async Task AnalyzeBodyNoAcceptHeaderAsync(RequestConten /// Service returned a non-success status code. /// The response returned from the service. /// - public virtual Response AnalyzeBodyNoAcceptHeader(RequestContent content, ContentType contentType, RequestContext context) + public virtual Response AnalyzeBodyNoAcceptHeader(RequestContent content, ContentType contentType, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("MediaTypesClient.AnalyzeBodyNoAcceptHeader"); scope.Start(); @@ -200,7 +200,7 @@ public virtual Response AnalyzeBodyNoAcceptHeader(RequestContent content, Conten /// Service returned a non-success status code. /// The response returned from the service. /// - public virtual async Task ContentTypeWithEncodingAsync(RequestContent content, RequestContext context) + public virtual async Task ContentTypeWithEncodingAsync(RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("MediaTypesClient.ContentTypeWithEncoding"); scope.Start(); @@ -231,7 +231,7 @@ public virtual async Task ContentTypeWithEncodingAsync(RequestContent /// Service returned a non-success status code. /// The response returned from the service. /// - public virtual Response ContentTypeWithEncoding(RequestContent content, RequestContext context) + public virtual Response ContentTypeWithEncoding(RequestContent content, RequestContext context = null) { using var scope = ClientDiagnostics.CreateScope("MediaTypesClient.ContentTypeWithEncoding"); scope.Start(); diff --git a/test/TestServerProjectsLowLevel/media_types/tests/Generated/Samples/Samples_MediaTypesClient.cs b/test/TestServerProjectsLowLevel/media_types/tests/Generated/Samples/Samples_MediaTypesClient.cs index bc21a056da0..137c353fada 100644 --- a/test/TestServerProjectsLowLevel/media_types/tests/Generated/Samples/Samples_MediaTypesClient.cs +++ b/test/TestServerProjectsLowLevel/media_types/tests/Generated/Samples/Samples_MediaTypesClient.cs @@ -28,7 +28,7 @@ public void Example_AnalyzeBody() var data = File.OpenRead(""); - Response response = client.AnalyzeBody(RequestContent.Create(data), ContentType.ApplicationOctetStream, new RequestContext()); + Response response = client.AnalyzeBody(RequestContent.Create(data), ContentType.ApplicationOctetStream); JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; Console.WriteLine(result.ToString()); @@ -43,7 +43,7 @@ public void Example_AnalyzeBody_AllParameters() var data = File.OpenRead(""); - Response response = client.AnalyzeBody(RequestContent.Create(data), ContentType.ApplicationOctetStream, new RequestContext()); + Response response = client.AnalyzeBody(RequestContent.Create(data), ContentType.ApplicationOctetStream); JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; Console.WriteLine(result.ToString()); @@ -58,7 +58,7 @@ public async Task Example_AnalyzeBody_Async() var data = File.OpenRead(""); - Response response = await client.AnalyzeBodyAsync(RequestContent.Create(data), ContentType.ApplicationOctetStream, new RequestContext()); + Response response = await client.AnalyzeBodyAsync(RequestContent.Create(data), ContentType.ApplicationOctetStream); JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; Console.WriteLine(result.ToString()); @@ -73,7 +73,7 @@ public async Task Example_AnalyzeBody_AllParameters_Async() var data = File.OpenRead(""); - Response response = await client.AnalyzeBodyAsync(RequestContent.Create(data), ContentType.ApplicationOctetStream, new RequestContext()); + Response response = await client.AnalyzeBodyAsync(RequestContent.Create(data), ContentType.ApplicationOctetStream); JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; Console.WriteLine(result.ToString()); @@ -88,7 +88,7 @@ public void Example_AnalyzeBodyNoAcceptHeader() var data = File.OpenRead(""); - Response response = client.AnalyzeBodyNoAcceptHeader(RequestContent.Create(data), ContentType.ApplicationOctetStream, new RequestContext()); + Response response = client.AnalyzeBodyNoAcceptHeader(RequestContent.Create(data), ContentType.ApplicationOctetStream); Console.WriteLine(response.Status); } @@ -101,7 +101,7 @@ public void Example_AnalyzeBodyNoAcceptHeader_AllParameters() var data = File.OpenRead(""); - Response response = client.AnalyzeBodyNoAcceptHeader(RequestContent.Create(data), ContentType.ApplicationOctetStream, new RequestContext()); + Response response = client.AnalyzeBodyNoAcceptHeader(RequestContent.Create(data), ContentType.ApplicationOctetStream); Console.WriteLine(response.Status); } @@ -114,7 +114,7 @@ public async Task Example_AnalyzeBodyNoAcceptHeader_Async() var data = File.OpenRead(""); - Response response = await client.AnalyzeBodyNoAcceptHeaderAsync(RequestContent.Create(data), ContentType.ApplicationOctetStream, new RequestContext()); + Response response = await client.AnalyzeBodyNoAcceptHeaderAsync(RequestContent.Create(data), ContentType.ApplicationOctetStream); Console.WriteLine(response.Status); } @@ -127,7 +127,7 @@ public async Task Example_AnalyzeBodyNoAcceptHeader_AllParameters_Async() var data = File.OpenRead(""); - Response response = await client.AnalyzeBodyNoAcceptHeaderAsync(RequestContent.Create(data), ContentType.ApplicationOctetStream, new RequestContext()); + Response response = await client.AnalyzeBodyNoAcceptHeaderAsync(RequestContent.Create(data), ContentType.ApplicationOctetStream); Console.WriteLine(response.Status); } @@ -140,7 +140,7 @@ public void Example_ContentTypeWithEncoding() var data = ""; - Response response = client.ContentTypeWithEncoding(RequestContent.Create(data), new RequestContext()); + Response response = client.ContentTypeWithEncoding(RequestContent.Create(data)); JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; Console.WriteLine(result.ToString()); @@ -155,7 +155,7 @@ public void Example_ContentTypeWithEncoding_AllParameters() var data = ""; - Response response = client.ContentTypeWithEncoding(RequestContent.Create(data), new RequestContext()); + Response response = client.ContentTypeWithEncoding(RequestContent.Create(data)); JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; Console.WriteLine(result.ToString()); @@ -170,7 +170,7 @@ public async Task Example_ContentTypeWithEncoding_Async() var data = ""; - Response response = await client.ContentTypeWithEncodingAsync(RequestContent.Create(data), new RequestContext()); + Response response = await client.ContentTypeWithEncodingAsync(RequestContent.Create(data)); JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; Console.WriteLine(result.ToString()); @@ -185,7 +185,7 @@ public async Task Example_ContentTypeWithEncoding_AllParameters_Async() var data = ""; - Response response = await client.ContentTypeWithEncodingAsync(RequestContent.Create(data), new RequestContext()); + Response response = await client.ContentTypeWithEncodingAsync(RequestContent.Create(data)); JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; Console.WriteLine(result.ToString());