internal StartDataFlowDebugSessionRequest(string sessionId, DataFlowResource dataFlow, IReadOnlyList <DatasetResource> datasets, IReadOnlyList <LinkedServiceResource> linkedServices, object staging, object debugSettings, bool?incrementalDebug) { SessionId = sessionId; DataFlow = dataFlow; Datasets = datasets; LinkedServices = linkedServices; Staging = staging; DebugSettings = debugSettings; IncrementalDebug = incrementalDebug; }
internal static StartDataFlowDebugSessionRequest DeserializeStartDataFlowDebugSessionRequest(JsonElement element) { Optional <string> sessionId = default; Optional <DataFlowResource> dataFlow = default; Optional <IList <DataFlowResource> > dataFlows = default; Optional <IList <DatasetResource> > datasets = default; Optional <IList <LinkedServiceResource> > linkedServices = default; Optional <object> staging = default; Optional <object> debugSettings = default; Optional <bool> incrementalDebug = default; foreach (var property in element.EnumerateObject()) { if (property.NameEquals("sessionId")) { sessionId = property.Value.GetString(); continue; } if (property.NameEquals("dataFlow")) { if (property.Value.ValueKind == JsonValueKind.Null) { property.ThrowNonNullablePropertyIsNull(); continue; } dataFlow = DataFlowResource.DeserializeDataFlowResource(property.Value); continue; } if (property.NameEquals("dataFlows")) { if (property.Value.ValueKind == JsonValueKind.Null) { property.ThrowNonNullablePropertyIsNull(); continue; } List <DataFlowResource> array = new List <DataFlowResource>(); foreach (var item in property.Value.EnumerateArray()) { array.Add(DataFlowResource.DeserializeDataFlowResource(item)); } dataFlows = array; continue; } if (property.NameEquals("datasets")) { if (property.Value.ValueKind == JsonValueKind.Null) { property.ThrowNonNullablePropertyIsNull(); continue; } List <DatasetResource> array = new List <DatasetResource>(); foreach (var item in property.Value.EnumerateArray()) { array.Add(DatasetResource.DeserializeDatasetResource(item)); } datasets = array; continue; } if (property.NameEquals("linkedServices")) { if (property.Value.ValueKind == JsonValueKind.Null) { property.ThrowNonNullablePropertyIsNull(); continue; } List <LinkedServiceResource> array = new List <LinkedServiceResource>(); foreach (var item in property.Value.EnumerateArray()) { array.Add(LinkedServiceResource.DeserializeLinkedServiceResource(item)); } linkedServices = array; continue; } if (property.NameEquals("staging")) { if (property.Value.ValueKind == JsonValueKind.Null) { property.ThrowNonNullablePropertyIsNull(); continue; } staging = property.Value.GetObject(); continue; } if (property.NameEquals("debugSettings")) { if (property.Value.ValueKind == JsonValueKind.Null) { property.ThrowNonNullablePropertyIsNull(); continue; } debugSettings = property.Value.GetObject(); continue; } if (property.NameEquals("incrementalDebug")) { if (property.Value.ValueKind == JsonValueKind.Null) { property.ThrowNonNullablePropertyIsNull(); continue; } incrementalDebug = property.Value.GetBoolean(); continue; } } return(new StartDataFlowDebugSessionRequest(sessionId.Value, dataFlow.Value, Optional.ToList(dataFlows), Optional.ToList(datasets), Optional.ToList(linkedServices), staging.Value, debugSettings.Value, Optional.ToNullable(incrementalDebug))); }