Skip to content

Commit 2e9bb0a

Browse files
committed
C# updates to ASP.NET Core types
1 parent 8d01751 commit 2e9bb0a

4 files changed

Lines changed: 7 additions & 8 deletions

articles/azure-functions/functions-add-output-binding-cosmos-db-vs-code.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -170,9 +170,9 @@ In this code, `arg_name` identifies the binding parameter referenced in your cod
170170
## Add code that uses the output binding
171171

172172
::: zone pivot="programming-language-csharp"
173-
Replace the existing Run method with the following code:
173+
Replace the existing `Run` method with the following code:
174174

175-
:::code language="csharp" source="~/functions-docs-csharp/functions-add-output-binding-cosmos-db-isolated/HttpExample.cs" range="11-34":::
175+
:::code language="csharp" source="~/functions-docs-csharp/functions-add-output-binding-cosmos-db-isolated/HttpExample.cs" range="17-34":::
176176

177177
::: zone-end
178178
::: zone pivot="programming-language-javascript"

articles/azure-functions/functions-triggers-bindings.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ For C# class library functions, you configure triggers and bindings by decoratin
4646

4747
The HTTP trigger (`HttpTrigger`) is defined on the `Run` method for a function named `HttpExample` that returns a `MultiResponse` object:
4848

49-
:::code language="csharp" source="~/functions-docs-csharp/functions-add-output-binding-storage-queue-isolated/HttpExample.cs" range="11-14":::
49+
:::code language="csharp" source="~/functions-docs-csharp/functions-add-output-binding-storage-queue-isolated/HttpExample.cs" range="17-18":::
5050

5151
This example shows the `MultiResponse` object definition. The object definition returns `HttpResponse` to the HTTP request and writes a message to a storage queue by using a `QueueOutput` binding:
5252

includes/functions-add-output-binding-example-all-languages.md

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,7 @@ Because an HTTP triggered function also returns an HTTP response, the function r
1313

1414
```csharp
1515
[Function("HttpExample")]
16-
public static MultiResponse Run([HttpTrigger(AuthorizationLevel.Function, "get", "post")] HttpRequest req,
17-
FunctionContext executionContext)
16+
public MultiResponse Run([HttpTrigger(AuthorizationLevel.Function, "get", "post")] HttpRequest req)
1817
{
1918
```
2019

@@ -29,7 +28,7 @@ public class MultiResponse
2928
}
3029
```
3130

32-
When applying that example to your own project, you might need to change `HttpRequest` to `HttpRequestData` and `IActionResult` to `HttpResponseData`, depending on if you are using [ASP.NET Core integration](../articles/azure-functions/dotnet-isolated-process-guide.md#aspnet-core-integration) or not.
31+
This example uses [ASP.NET Core integration](../articles/azure-functions/dotnet-isolated-process-guide.md#aspnet-core-integration). If you aren't using ASP.NET Core integration, you need to change `HttpRequest` to `HttpRequestData` and `IActionResult` to `HttpResponseData`.
3332

3433
### [In-process](#tab/in-process)
3534
:::code language="csharp" source="~/functions-docs-csharp/functions-add-output-binding-storage-queue-cli/HttpExample.cs" range="14-18" highlight="4":::

includes/functions-add-storage-binding-csharp-library-code.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,9 +9,9 @@ ms.custom: devdivchpfy22
99

1010
# [Isolated worker model](#tab/isolated-process)
1111

12-
Replace the existing `HttpExample` class with the following code:
12+
Replace the existing `Run` method with the following code:
1313

14-
:::code language="csharp" source="~/functions-docs-csharp/functions-add-output-binding-storage-queue-isolated/HttpExample.cs" range="11-32":::
14+
:::code language="csharp" source="~/functions-docs-csharp/functions-add-output-binding-storage-queue-isolated/HttpExample.cs" range="17-31":::
1515

1616
# [In-process model](#tab/in-process)
1717

0 commit comments

Comments
 (0)