Skip to content

Commit 7a84c69

Browse files
authored
add params (#43770)
1 parent a596a57 commit 7a84c69

File tree

4 files changed

+6
-0
lines changed

4 files changed

+6
-0
lines changed

sdk/core/azure-core-experimental/src/main/java/com/azure/core/experimental/http/DynamicRequest.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -71,6 +71,7 @@
7171
* DynamicResponse response = dynamicRequest
7272
* .setUrl("https://petstore.example.com/pet/{petId}") // may already be set if request is created from a client
7373
* .setPathParam("petId", "2343245")
74+
* .setHttpMethod(HttpMethod.POST)
7475
* .send(); // makes the service call
7576
* </pre>
7677
* <!-- end com.azure.core.experimental.http.dynamicrequest.getrequest -->

sdk/core/azure-core-experimental/src/main/java/com/azure/core/experimental/http/DynamicResponse.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,7 @@
5252
* DynamicResponse response = dynamicRequest
5353
* .setUrl&#40;&quot;https:&#47;&#47;petstore.example.com&#47;pet&#47;&#123;petId&#125;&quot;&#41; &#47;&#47; may already be set if request is created from a client
5454
* .setPathParam&#40;&quot;petId&quot;, &quot;2343245&quot;&#41;
55+
* .setHttpMethod&#40;HttpMethod.POST&#41;
5556
* .send&#40;&#41;; &#47;&#47; makes the service call
5657
*
5758
* &#47;&#47; Check the HTTP status

sdk/core/azure-core-experimental/src/samples/java/com/azure/core/experimental/http/DynamicRequestJavaDocCodeSnippets.java

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44
package com.azure.core.experimental.http;
55

66
import com.azure.core.http.HttpHeaderName;
7+
import com.azure.core.http.HttpMethod;
78
import com.azure.core.http.HttpPipeline;
89
import com.azure.core.http.HttpPipelineBuilder;
910
import com.azure.core.util.BinaryData;
@@ -41,6 +42,7 @@ public void getRequestSample() {
4142
DynamicResponse response = dynamicRequest
4243
.setUrl("https://petstore.example.com/pet/{petId}") // may already be set if request is created from a client
4344
.setPathParam("petId", "2343245")
45+
.setHttpMethod(HttpMethod.POST)
4446
.send(); // makes the service call
4547
// END: com.azure.core.experimental.http.dynamicrequest.getrequest
4648
}

sdk/core/azure-core-experimental/src/samples/java/com/azure/core/experimental/http/DynamicResponseJavaDocCodeSnippets.java

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33

44
package com.azure.core.experimental.http;
55

6+
import com.azure.core.http.HttpMethod;
67
import com.azure.core.util.BinaryData;
78
import com.azure.json.models.JsonArray;
89
import com.azure.json.models.JsonNumber;
@@ -24,6 +25,7 @@ public void readResponse() {
2425
DynamicResponse response = dynamicRequest
2526
.setUrl("https://petstore.example.com/pet/{petId}") // may already be set if request is created from a client
2627
.setPathParam("petId", "2343245")
28+
.setHttpMethod(HttpMethod.POST)
2729
.send(); // makes the service call
2830

2931
// Check the HTTP status

0 commit comments

Comments
 (0)