internal static TasksStateTasksEntityRecognitionPiiTasksItem DeserializeTasksStateTasksEntityRecognitionPiiTasksItem(JsonElement element)
        {
            Optional <PiiResult> results            = default;
            DateTimeOffset       lastUpdateDateTime = default;
            Optional <string>    taskName           = default;
            State status = default;

            foreach (var property in element.EnumerateObject())
            {
                if (property.NameEquals("results"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        property.ThrowNonNullablePropertyIsNull();
                        continue;
                    }
                    results = PiiResult.DeserializePiiResult(property.Value);
                    continue;
                }
                if (property.NameEquals("lastUpdateDateTime"))
                {
                    lastUpdateDateTime = property.Value.GetDateTimeOffset("O");
                    continue;
                }
                if (property.NameEquals("taskName"))
                {
                    taskName = property.Value.GetString();
                    continue;
                }
                if (property.NameEquals("status"))
                {
                    status = property.Value.GetString().ToState();
                    continue;
                }
            }
            return(new TasksStateTasksEntityRecognitionPiiTasksItem(lastUpdateDateTime, taskName.Value, status, results.Value));
        }
 internal TasksStateTasksEntityRecognitionPiiTasksItem(DateTimeOffset lastUpdateDateTime, string taskName, State status, PiiResult results) : base(lastUpdateDateTime, taskName, status)
 {
     Results = results;
 }
Exemple #3
0
 internal PiiTaskResult(PiiResult results)
 {
     Results = results;
 }