mirror of
https://github.com/microsoft/agent-framework.git
synced 2026-06-16 21:04:09 +08:00
- Add UTF-8 BOM to 20 .cs files across DurableTask, AzureFunctions, unit tests, and workflow samples - Remove unnecessary using directive in 07_SubWorkflows/Executors.cs Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
42 lines
2.0 KiB
C#
42 lines
2.0 KiB
C#
// Copyright (c) Microsoft. All rights reserved.
|
|
|
|
using System.Text.Json.Serialization;
|
|
|
|
namespace Microsoft.Agents.AI.DurableTask.Workflows;
|
|
|
|
/// <summary>
|
|
/// Source-generated JSON serialization context for durable workflow types.
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// <para>
|
|
/// This context provides AOT-compatible and trimmer-safe JSON serialization for the
|
|
/// internal data transfer types used by the durable workflow infrastructure:
|
|
/// </para>
|
|
/// <list type="bullet">
|
|
/// <item><description><see cref="DurableActivityInput"/>: Activity input wrapper with state</description></item>
|
|
/// <item><description><see cref="DurableExecutorOutput"/>: Executor output wrapper with results, events, and state updates</description></item>
|
|
/// <item><description><see cref="TypedPayload"/>: Serialized payload wrapper with type info (events and messages)</description></item>
|
|
/// <item><description><see cref="DurableWorkflowLiveStatus"/>: Live status payload (streaming events and pending request ports)</description></item>
|
|
/// </list>
|
|
/// <para>
|
|
/// Note: User-defined executor input/output types still use reflection-based serialization
|
|
/// since their types are not known at compile time.
|
|
/// </para>
|
|
/// </remarks>
|
|
[JsonSourceGenerationOptions(
|
|
WriteIndented = false,
|
|
DefaultIgnoreCondition = JsonIgnoreCondition.WhenWritingNull,
|
|
PropertyNamingPolicy = JsonKnownNamingPolicy.CamelCase)]
|
|
[JsonSerializable(typeof(DurableActivityInput))]
|
|
[JsonSerializable(typeof(DurableExecutorOutput))]
|
|
[JsonSerializable(typeof(TypedPayload))]
|
|
[JsonSerializable(typeof(List<TypedPayload>))]
|
|
[JsonSerializable(typeof(DurableWorkflowLiveStatus))]
|
|
[JsonSerializable(typeof(DurableWorkflowResult))]
|
|
[JsonSerializable(typeof(PendingRequestPortStatus))]
|
|
[JsonSerializable(typeof(List<PendingRequestPortStatus>))]
|
|
[JsonSerializable(typeof(List<string>))]
|
|
[JsonSerializable(typeof(Dictionary<string, string>))]
|
|
[JsonSerializable(typeof(Dictionary<string, string?>))]
|
|
internal partial class DurableWorkflowJsonContext : JsonSerializerContext;
|