Ejemplo n.º 1
0
 internal SweepJob(string description, IDictionary <string, string> properties, IDictionary <string, string> tags, string computeId, string displayName, string experimentName, IdentityConfiguration identity, bool?isArchived, JobType jobType, ScheduleBase schedule, IDictionary <string, JobService> services, JobStatus?status, EarlyTerminationPolicy earlyTermination, IDictionary <string, JobInput> inputs, SweepJobLimits limits, Objective objective, IDictionary <string, JobOutput> outputs, SamplingAlgorithm samplingAlgorithm, BinaryData searchSpace, TrialComponent trial) : base(description, properties, tags, computeId, displayName, experimentName, identity, isArchived, jobType, schedule, services, status)
 {
     EarlyTermination  = earlyTermination;
     Inputs            = inputs;
     Limits            = limits;
     Objective         = objective;
     Outputs           = outputs;
     SamplingAlgorithm = samplingAlgorithm;
     SearchSpace       = searchSpace;
     Trial             = trial;
     JobType           = jobType;
 }
Ejemplo n.º 2
0
        internal static AutoMLJob DeserializeAutoMLJob(JsonElement element)
        {
            Optional <string> environmentId = default;
            Optional <IDictionary <string, string> >    environmentVariables = default;
            Optional <IDictionary <string, JobOutput> > outputs   = default;
            Optional <ResourceConfiguration>            resources = default;
            AutoMLVertical    taskDetails                         = default;
            Optional <string> computeId                           = default;
            Optional <string> displayName                         = default;
            Optional <string> experimentName                      = default;
            Optional <IdentityConfiguration> identity             = default;
            Optional <bool>         isArchived                    = default;
            JobType                 jobType                       = default;
            Optional <ScheduleBase> schedule                      = default;
            Optional <IDictionary <string, JobService> > services = default;
            Optional <JobStatus> status                           = default;
            Optional <string>    description                      = default;
            Optional <IDictionary <string, string> > properties   = default;
            Optional <IDictionary <string, string> > tags         = default;

            foreach (var property in element.EnumerateObject())
            {
                if (property.NameEquals("environmentId"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        environmentId = null;
                        continue;
                    }
                    environmentId = property.Value.GetString();
                    continue;
                }
                if (property.NameEquals("environmentVariables"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        environmentVariables = null;
                        continue;
                    }
                    Dictionary <string, string> dictionary = new Dictionary <string, string>();
                    foreach (var property0 in property.Value.EnumerateObject())
                    {
                        if (property0.Value.ValueKind == JsonValueKind.Null)
                        {
                            dictionary.Add(property0.Name, null);
                        }
                        else
                        {
                            dictionary.Add(property0.Name, property0.Value.GetString());
                        }
                    }
                    environmentVariables = dictionary;
                    continue;
                }
                if (property.NameEquals("outputs"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        outputs = null;
                        continue;
                    }
                    Dictionary <string, JobOutput> dictionary = new Dictionary <string, JobOutput>();
                    foreach (var property0 in property.Value.EnumerateObject())
                    {
                        if (property0.Value.ValueKind == JsonValueKind.Null)
                        {
                            dictionary.Add(property0.Name, null);
                        }
                        else
                        {
                            dictionary.Add(property0.Name, JobOutput.DeserializeJobOutput(property0.Value));
                        }
                    }
                    outputs = dictionary;
                    continue;
                }
                if (property.NameEquals("resources"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        resources = null;
                        continue;
                    }
                    resources = ResourceConfiguration.DeserializeResourceConfiguration(property.Value);
                    continue;
                }
                if (property.NameEquals("taskDetails"))
                {
                    taskDetails = AutoMLVertical.DeserializeAutoMLVertical(property.Value);
                    continue;
                }
                if (property.NameEquals("computeId"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        computeId = null;
                        continue;
                    }
                    computeId = property.Value.GetString();
                    continue;
                }
                if (property.NameEquals("displayName"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        displayName = null;
                        continue;
                    }
                    displayName = property.Value.GetString();
                    continue;
                }
                if (property.NameEquals("experimentName"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        experimentName = null;
                        continue;
                    }
                    experimentName = property.Value.GetString();
                    continue;
                }
                if (property.NameEquals("identity"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        identity = null;
                        continue;
                    }
                    identity = IdentityConfiguration.DeserializeIdentityConfiguration(property.Value);
                    continue;
                }
                if (property.NameEquals("isArchived"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        property.ThrowNonNullablePropertyIsNull();
                        continue;
                    }
                    isArchived = property.Value.GetBoolean();
                    continue;
                }
                if (property.NameEquals("jobType"))
                {
                    jobType = new JobType(property.Value.GetString());
                    continue;
                }
                if (property.NameEquals("schedule"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        schedule = null;
                        continue;
                    }
                    schedule = ScheduleBase.DeserializeScheduleBase(property.Value);
                    continue;
                }
                if (property.NameEquals("services"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        services = null;
                        continue;
                    }
                    Dictionary <string, JobService> dictionary = new Dictionary <string, JobService>();
                    foreach (var property0 in property.Value.EnumerateObject())
                    {
                        if (property0.Value.ValueKind == JsonValueKind.Null)
                        {
                            dictionary.Add(property0.Name, null);
                        }
                        else
                        {
                            dictionary.Add(property0.Name, JobService.DeserializeJobService(property0.Value));
                        }
                    }
                    services = dictionary;
                    continue;
                }
                if (property.NameEquals("status"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        property.ThrowNonNullablePropertyIsNull();
                        continue;
                    }
                    status = new JobStatus(property.Value.GetString());
                    continue;
                }
                if (property.NameEquals("description"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        description = null;
                        continue;
                    }
                    description = property.Value.GetString();
                    continue;
                }
                if (property.NameEquals("properties"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        properties = null;
                        continue;
                    }
                    Dictionary <string, string> dictionary = new Dictionary <string, string>();
                    foreach (var property0 in property.Value.EnumerateObject())
                    {
                        if (property0.Value.ValueKind == JsonValueKind.Null)
                        {
                            dictionary.Add(property0.Name, null);
                        }
                        else
                        {
                            dictionary.Add(property0.Name, property0.Value.GetString());
                        }
                    }
                    properties = dictionary;
                    continue;
                }
                if (property.NameEquals("tags"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        tags = null;
                        continue;
                    }
                    Dictionary <string, string> dictionary = new Dictionary <string, string>();
                    foreach (var property0 in property.Value.EnumerateObject())
                    {
                        if (property0.Value.ValueKind == JsonValueKind.Null)
                        {
                            dictionary.Add(property0.Name, null);
                        }
                        else
                        {
                            dictionary.Add(property0.Name, property0.Value.GetString());
                        }
                    }
                    tags = dictionary;
                    continue;
                }
            }
            return(new AutoMLJob(description.Value, Optional.ToDictionary(properties), Optional.ToDictionary(tags), computeId.Value, displayName.Value, experimentName.Value, identity.Value, Optional.ToNullable(isArchived), jobType, schedule.Value, Optional.ToDictionary(services), Optional.ToNullable(status), environmentId.Value, Optional.ToDictionary(environmentVariables), Optional.ToDictionary(outputs), resources.Value, taskDetails));
        }
Ejemplo n.º 3
0
 internal PipelineJob(string description, IDictionary <string, string> properties, IDictionary <string, string> tags, string computeId, string displayName, string experimentName, IdentityConfiguration identity, bool?isArchived, JobType jobType, ScheduleBase schedule, IDictionary <string, JobService> services, JobStatus?status, IDictionary <string, JobInput> inputs, IDictionary <string, BinaryData> jobs, IDictionary <string, JobOutput> outputs, BinaryData settings) : base(description, properties, tags, computeId, displayName, experimentName, identity, isArchived, jobType, schedule, services, status)
 {
     Inputs   = inputs;
     Jobs     = jobs;
     Outputs  = outputs;
     Settings = settings;
     JobType  = jobType;
 }
Ejemplo n.º 4
0
        internal static MachineLearningJobProperties DeserializeMachineLearningJobProperties(JsonElement element)
        {
            if (element.TryGetProperty("jobType", out JsonElement discriminator))
            {
                switch (discriminator.GetString())
                {
                case "AutoML": return(AutoMLJob.DeserializeAutoMLJob(element));

                case "Command": return(CommandJob.DeserializeCommandJob(element));

                case "Pipeline": return(PipelineJob.DeserializePipelineJob(element));

                case "Sweep": return(SweepJob.DeserializeSweepJob(element));
                }
            }
            Optional <string> computeId                           = default;
            Optional <string> displayName                         = default;
            Optional <string> experimentName                      = default;
            Optional <IdentityConfiguration> identity             = default;
            Optional <bool>         isArchived                    = default;
            JobType                 jobType                       = default;
            Optional <ScheduleBase> schedule                      = default;
            Optional <IDictionary <string, JobService> > services = default;
            Optional <JobStatus> status                           = default;
            Optional <string>    description                      = default;
            Optional <IDictionary <string, string> > properties   = default;
            Optional <IDictionary <string, string> > tags         = default;

            foreach (var property in element.EnumerateObject())
            {
                if (property.NameEquals("computeId"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        computeId = null;
                        continue;
                    }
                    computeId = property.Value.GetString();
                    continue;
                }
                if (property.NameEquals("displayName"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        displayName = null;
                        continue;
                    }
                    displayName = property.Value.GetString();
                    continue;
                }
                if (property.NameEquals("experimentName"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        experimentName = null;
                        continue;
                    }
                    experimentName = property.Value.GetString();
                    continue;
                }
                if (property.NameEquals("identity"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        identity = null;
                        continue;
                    }
                    identity = IdentityConfiguration.DeserializeIdentityConfiguration(property.Value);
                    continue;
                }
                if (property.NameEquals("isArchived"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        property.ThrowNonNullablePropertyIsNull();
                        continue;
                    }
                    isArchived = property.Value.GetBoolean();
                    continue;
                }
                if (property.NameEquals("jobType"))
                {
                    jobType = new JobType(property.Value.GetString());
                    continue;
                }
                if (property.NameEquals("schedule"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        schedule = null;
                        continue;
                    }
                    schedule = ScheduleBase.DeserializeScheduleBase(property.Value);
                    continue;
                }
                if (property.NameEquals("services"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        services = null;
                        continue;
                    }
                    Dictionary <string, JobService> dictionary = new Dictionary <string, JobService>();
                    foreach (var property0 in property.Value.EnumerateObject())
                    {
                        if (property0.Value.ValueKind == JsonValueKind.Null)
                        {
                            dictionary.Add(property0.Name, null);
                        }
                        else
                        {
                            dictionary.Add(property0.Name, JobService.DeserializeJobService(property0.Value));
                        }
                    }
                    services = dictionary;
                    continue;
                }
                if (property.NameEquals("status"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        property.ThrowNonNullablePropertyIsNull();
                        continue;
                    }
                    status = new JobStatus(property.Value.GetString());
                    continue;
                }
                if (property.NameEquals("description"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        description = null;
                        continue;
                    }
                    description = property.Value.GetString();
                    continue;
                }
                if (property.NameEquals("properties"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        properties = null;
                        continue;
                    }
                    Dictionary <string, string> dictionary = new Dictionary <string, string>();
                    foreach (var property0 in property.Value.EnumerateObject())
                    {
                        if (property0.Value.ValueKind == JsonValueKind.Null)
                        {
                            dictionary.Add(property0.Name, null);
                        }
                        else
                        {
                            dictionary.Add(property0.Name, property0.Value.GetString());
                        }
                    }
                    properties = dictionary;
                    continue;
                }
                if (property.NameEquals("tags"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        tags = null;
                        continue;
                    }
                    Dictionary <string, string> dictionary = new Dictionary <string, string>();
                    foreach (var property0 in property.Value.EnumerateObject())
                    {
                        if (property0.Value.ValueKind == JsonValueKind.Null)
                        {
                            dictionary.Add(property0.Name, null);
                        }
                        else
                        {
                            dictionary.Add(property0.Name, property0.Value.GetString());
                        }
                    }
                    tags = dictionary;
                    continue;
                }
            }
            return(new MachineLearningJobProperties(description.Value, Optional.ToDictionary(properties), Optional.ToDictionary(tags), computeId.Value, displayName.Value, experimentName.Value, identity.Value, Optional.ToNullable(isArchived), jobType, schedule.Value, Optional.ToDictionary(services), Optional.ToNullable(status)));
        }
Ejemplo n.º 5
0
 void IUtf8JsonSerializable.Write(Utf8JsonWriter writer)
 {
     writer.WriteStartObject();
     if (Optional.IsDefined(EnvironmentId))
     {
         if (EnvironmentId != null)
         {
             writer.WritePropertyName("environmentId");
             writer.WriteStringValue(EnvironmentId);
         }
         else
         {
             writer.WriteNull("environmentId");
         }
     }
     if (Optional.IsCollectionDefined(EnvironmentVariables))
     {
         if (EnvironmentVariables != null)
         {
             writer.WritePropertyName("environmentVariables");
             writer.WriteStartObject();
             foreach (var item in EnvironmentVariables)
             {
                 writer.WritePropertyName(item.Key);
                 writer.WriteStringValue(item.Value);
             }
             writer.WriteEndObject();
         }
         else
         {
             writer.WriteNull("environmentVariables");
         }
     }
     if (Optional.IsCollectionDefined(Outputs))
     {
         if (Outputs != null)
         {
             writer.WritePropertyName("outputs");
             writer.WriteStartObject();
             foreach (var item in Outputs)
             {
                 writer.WritePropertyName(item.Key);
                 writer.WriteObjectValue(item.Value);
             }
             writer.WriteEndObject();
         }
         else
         {
             writer.WriteNull("outputs");
         }
     }
     if (Optional.IsDefined(Resources))
     {
         if (Resources != null)
         {
             writer.WritePropertyName("resources");
             writer.WriteObjectValue(Resources);
         }
         else
         {
             writer.WriteNull("resources");
         }
     }
     writer.WritePropertyName("taskDetails");
     writer.WriteObjectValue(TaskDetails);
     if (Optional.IsDefined(ComputeId))
     {
         if (ComputeId != null)
         {
             writer.WritePropertyName("computeId");
             writer.WriteStringValue(ComputeId);
         }
         else
         {
             writer.WriteNull("computeId");
         }
     }
     if (Optional.IsDefined(DisplayName))
     {
         if (DisplayName != null)
         {
             writer.WritePropertyName("displayName");
             writer.WriteStringValue(DisplayName);
         }
         else
         {
             writer.WriteNull("displayName");
         }
     }
     if (Optional.IsDefined(ExperimentName))
     {
         if (ExperimentName != null)
         {
             writer.WritePropertyName("experimentName");
             writer.WriteStringValue(ExperimentName);
         }
         else
         {
             writer.WriteNull("experimentName");
         }
     }
     if (Optional.IsDefined(Identity))
     {
         if (Identity != null)
         {
             writer.WritePropertyName("identity");
             writer.WriteObjectValue(Identity);
         }
         else
         {
             writer.WriteNull("identity");
         }
     }
     if (Optional.IsDefined(IsArchived))
     {
         writer.WritePropertyName("isArchived");
         writer.WriteBooleanValue(IsArchived.Value);
     }
     writer.WritePropertyName("jobType");
     writer.WriteStringValue(JobType.ToString());
     if (Optional.IsDefined(Schedule))
     {
         if (Schedule != null)
         {
             writer.WritePropertyName("schedule");
             writer.WriteObjectValue(Schedule);
         }
         else
         {
             writer.WriteNull("schedule");
         }
     }
     if (Optional.IsCollectionDefined(Services))
     {
         if (Services != null)
         {
             writer.WritePropertyName("services");
             writer.WriteStartObject();
             foreach (var item in Services)
             {
                 writer.WritePropertyName(item.Key);
                 writer.WriteObjectValue(item.Value);
             }
             writer.WriteEndObject();
         }
         else
         {
             writer.WriteNull("services");
         }
     }
     if (Optional.IsDefined(Description))
     {
         if (Description != null)
         {
             writer.WritePropertyName("description");
             writer.WriteStringValue(Description);
         }
         else
         {
             writer.WriteNull("description");
         }
     }
     if (Optional.IsCollectionDefined(Properties))
     {
         if (Properties != null)
         {
             writer.WritePropertyName("properties");
             writer.WriteStartObject();
             foreach (var item in Properties)
             {
                 writer.WritePropertyName(item.Key);
                 writer.WriteStringValue(item.Value);
             }
             writer.WriteEndObject();
         }
         else
         {
             writer.WriteNull("properties");
         }
     }
     if (Optional.IsCollectionDefined(Tags))
     {
         if (Tags != null)
         {
             writer.WritePropertyName("tags");
             writer.WriteStartObject();
             foreach (var item in Tags)
             {
                 writer.WritePropertyName(item.Key);
                 writer.WriteStringValue(item.Value);
             }
             writer.WriteEndObject();
         }
         else
         {
             writer.WriteNull("tags");
         }
     }
     writer.WriteEndObject();
 }
Ejemplo n.º 6
0
        void IUtf8JsonSerializable.Write(Utf8JsonWriter writer)
        {
            writer.WriteStartObject();
            if (Optional.IsDefined(EarlyTermination))
            {
                if (EarlyTermination != null)
                {
                    writer.WritePropertyName("earlyTermination");
                    writer.WriteObjectValue(EarlyTermination);
                }
                else
                {
                    writer.WriteNull("earlyTermination");
                }
            }
            if (Optional.IsCollectionDefined(Inputs))
            {
                if (Inputs != null)
                {
                    writer.WritePropertyName("inputs");
                    writer.WriteStartObject();
                    foreach (var item in Inputs)
                    {
                        writer.WritePropertyName(item.Key);
                        writer.WriteObjectValue(item.Value);
                    }
                    writer.WriteEndObject();
                }
                else
                {
                    writer.WriteNull("inputs");
                }
            }
            if (Optional.IsDefined(Limits))
            {
                if (Limits != null)
                {
                    writer.WritePropertyName("limits");
                    writer.WriteObjectValue(Limits);
                }
                else
                {
                    writer.WriteNull("limits");
                }
            }
            writer.WritePropertyName("objective");
            writer.WriteObjectValue(Objective);
            if (Optional.IsCollectionDefined(Outputs))
            {
                if (Outputs != null)
                {
                    writer.WritePropertyName("outputs");
                    writer.WriteStartObject();
                    foreach (var item in Outputs)
                    {
                        writer.WritePropertyName(item.Key);
                        writer.WriteObjectValue(item.Value);
                    }
                    writer.WriteEndObject();
                }
                else
                {
                    writer.WriteNull("outputs");
                }
            }
            writer.WritePropertyName("samplingAlgorithm");
            writer.WriteObjectValue(SamplingAlgorithm);
            writer.WritePropertyName("searchSpace");
#if NET6_0_OR_GREATER
            writer.WriteRawValue(SearchSpace);
#else
            JsonSerializer.Serialize(writer, JsonDocument.Parse(SearchSpace.ToString()).RootElement);
#endif
            writer.WritePropertyName("trial");
            writer.WriteObjectValue(Trial);
            if (Optional.IsDefined(ComputeId))
            {
                if (ComputeId != null)
                {
                    writer.WritePropertyName("computeId");
                    writer.WriteStringValue(ComputeId);
                }
                else
                {
                    writer.WriteNull("computeId");
                }
            }
            if (Optional.IsDefined(DisplayName))
            {
                if (DisplayName != null)
                {
                    writer.WritePropertyName("displayName");
                    writer.WriteStringValue(DisplayName);
                }
                else
                {
                    writer.WriteNull("displayName");
                }
            }
            if (Optional.IsDefined(ExperimentName))
            {
                if (ExperimentName != null)
                {
                    writer.WritePropertyName("experimentName");
                    writer.WriteStringValue(ExperimentName);
                }
                else
                {
                    writer.WriteNull("experimentName");
                }
            }
            if (Optional.IsDefined(Identity))
            {
                if (Identity != null)
                {
                    writer.WritePropertyName("identity");
                    writer.WriteObjectValue(Identity);
                }
                else
                {
                    writer.WriteNull("identity");
                }
            }
            if (Optional.IsDefined(IsArchived))
            {
                writer.WritePropertyName("isArchived");
                writer.WriteBooleanValue(IsArchived.Value);
            }
            writer.WritePropertyName("jobType");
            writer.WriteStringValue(JobType.ToString());
            if (Optional.IsDefined(Schedule))
            {
                if (Schedule != null)
                {
                    writer.WritePropertyName("schedule");
                    writer.WriteObjectValue(Schedule);
                }
                else
                {
                    writer.WriteNull("schedule");
                }
            }
            if (Optional.IsCollectionDefined(Services))
            {
                if (Services != null)
                {
                    writer.WritePropertyName("services");
                    writer.WriteStartObject();
                    foreach (var item in Services)
                    {
                        writer.WritePropertyName(item.Key);
                        writer.WriteObjectValue(item.Value);
                    }
                    writer.WriteEndObject();
                }
                else
                {
                    writer.WriteNull("services");
                }
            }
            if (Optional.IsDefined(Description))
            {
                if (Description != null)
                {
                    writer.WritePropertyName("description");
                    writer.WriteStringValue(Description);
                }
                else
                {
                    writer.WriteNull("description");
                }
            }
            if (Optional.IsCollectionDefined(Properties))
            {
                if (Properties != null)
                {
                    writer.WritePropertyName("properties");
                    writer.WriteStartObject();
                    foreach (var item in Properties)
                    {
                        writer.WritePropertyName(item.Key);
                        writer.WriteStringValue(item.Value);
                    }
                    writer.WriteEndObject();
                }
                else
                {
                    writer.WriteNull("properties");
                }
            }
            if (Optional.IsCollectionDefined(Tags))
            {
                if (Tags != null)
                {
                    writer.WritePropertyName("tags");
                    writer.WriteStartObject();
                    foreach (var item in Tags)
                    {
                        writer.WritePropertyName(item.Key);
                        writer.WriteStringValue(item.Value);
                    }
                    writer.WriteEndObject();
                }
                else
                {
                    writer.WriteNull("tags");
                }
            }
            writer.WriteEndObject();
        }
Ejemplo n.º 7
0
        internal static SweepJob DeserializeSweepJob(JsonElement element)
        {
            Optional <EarlyTerminationPolicy>          earlyTermination = default;
            Optional <IDictionary <string, JobInput> > inputs           = default;
            Optional <SweepJobLimits> limits = default;
            Objective objective = default;
            Optional <IDictionary <string, JobOutput> > outputs = default;
            SamplingAlgorithm samplingAlgorithm                   = default;
            BinaryData        searchSpace                         = default;
            TrialComponent    trial                               = default;
            Optional <string> computeId                           = default;
            Optional <string> displayName                         = default;
            Optional <string> experimentName                      = default;
            Optional <IdentityConfiguration> identity             = default;
            Optional <bool>         isArchived                    = default;
            JobType                 jobType                       = default;
            Optional <ScheduleBase> schedule                      = default;
            Optional <IDictionary <string, JobService> > services = default;
            Optional <JobStatus> status                           = default;
            Optional <string>    description                      = default;
            Optional <IDictionary <string, string> > properties   = default;
            Optional <IDictionary <string, string> > tags         = default;

            foreach (var property in element.EnumerateObject())
            {
                if (property.NameEquals("earlyTermination"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        earlyTermination = null;
                        continue;
                    }
                    earlyTermination = EarlyTerminationPolicy.DeserializeEarlyTerminationPolicy(property.Value);
                    continue;
                }
                if (property.NameEquals("inputs"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        inputs = null;
                        continue;
                    }
                    Dictionary <string, JobInput> dictionary = new Dictionary <string, JobInput>();
                    foreach (var property0 in property.Value.EnumerateObject())
                    {
                        if (property0.Value.ValueKind == JsonValueKind.Null)
                        {
                            dictionary.Add(property0.Name, null);
                        }
                        else
                        {
                            dictionary.Add(property0.Name, JobInput.DeserializeJobInput(property0.Value));
                        }
                    }
                    inputs = dictionary;
                    continue;
                }
                if (property.NameEquals("limits"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        limits = null;
                        continue;
                    }
                    limits = SweepJobLimits.DeserializeSweepJobLimits(property.Value);
                    continue;
                }
                if (property.NameEquals("objective"))
                {
                    objective = Objective.DeserializeObjective(property.Value);
                    continue;
                }
                if (property.NameEquals("outputs"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        outputs = null;
                        continue;
                    }
                    Dictionary <string, JobOutput> dictionary = new Dictionary <string, JobOutput>();
                    foreach (var property0 in property.Value.EnumerateObject())
                    {
                        if (property0.Value.ValueKind == JsonValueKind.Null)
                        {
                            dictionary.Add(property0.Name, null);
                        }
                        else
                        {
                            dictionary.Add(property0.Name, JobOutput.DeserializeJobOutput(property0.Value));
                        }
                    }
                    outputs = dictionary;
                    continue;
                }
                if (property.NameEquals("samplingAlgorithm"))
                {
                    samplingAlgorithm = SamplingAlgorithm.DeserializeSamplingAlgorithm(property.Value);
                    continue;
                }
                if (property.NameEquals("searchSpace"))
                {
                    searchSpace = BinaryData.FromString(property.Value.GetRawText());
                    continue;
                }
                if (property.NameEquals("trial"))
                {
                    trial = TrialComponent.DeserializeTrialComponent(property.Value);
                    continue;
                }
                if (property.NameEquals("computeId"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        computeId = null;
                        continue;
                    }
                    computeId = property.Value.GetString();
                    continue;
                }
                if (property.NameEquals("displayName"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        displayName = null;
                        continue;
                    }
                    displayName = property.Value.GetString();
                    continue;
                }
                if (property.NameEquals("experimentName"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        experimentName = null;
                        continue;
                    }
                    experimentName = property.Value.GetString();
                    continue;
                }
                if (property.NameEquals("identity"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        identity = null;
                        continue;
                    }
                    identity = IdentityConfiguration.DeserializeIdentityConfiguration(property.Value);
                    continue;
                }
                if (property.NameEquals("isArchived"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        property.ThrowNonNullablePropertyIsNull();
                        continue;
                    }
                    isArchived = property.Value.GetBoolean();
                    continue;
                }
                if (property.NameEquals("jobType"))
                {
                    jobType = new JobType(property.Value.GetString());
                    continue;
                }
                if (property.NameEquals("schedule"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        schedule = null;
                        continue;
                    }
                    schedule = ScheduleBase.DeserializeScheduleBase(property.Value);
                    continue;
                }
                if (property.NameEquals("services"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        services = null;
                        continue;
                    }
                    Dictionary <string, JobService> dictionary = new Dictionary <string, JobService>();
                    foreach (var property0 in property.Value.EnumerateObject())
                    {
                        if (property0.Value.ValueKind == JsonValueKind.Null)
                        {
                            dictionary.Add(property0.Name, null);
                        }
                        else
                        {
                            dictionary.Add(property0.Name, JobService.DeserializeJobService(property0.Value));
                        }
                    }
                    services = dictionary;
                    continue;
                }
                if (property.NameEquals("status"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        property.ThrowNonNullablePropertyIsNull();
                        continue;
                    }
                    status = new JobStatus(property.Value.GetString());
                    continue;
                }
                if (property.NameEquals("description"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        description = null;
                        continue;
                    }
                    description = property.Value.GetString();
                    continue;
                }
                if (property.NameEquals("properties"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        properties = null;
                        continue;
                    }
                    Dictionary <string, string> dictionary = new Dictionary <string, string>();
                    foreach (var property0 in property.Value.EnumerateObject())
                    {
                        if (property0.Value.ValueKind == JsonValueKind.Null)
                        {
                            dictionary.Add(property0.Name, null);
                        }
                        else
                        {
                            dictionary.Add(property0.Name, property0.Value.GetString());
                        }
                    }
                    properties = dictionary;
                    continue;
                }
                if (property.NameEquals("tags"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        tags = null;
                        continue;
                    }
                    Dictionary <string, string> dictionary = new Dictionary <string, string>();
                    foreach (var property0 in property.Value.EnumerateObject())
                    {
                        if (property0.Value.ValueKind == JsonValueKind.Null)
                        {
                            dictionary.Add(property0.Name, null);
                        }
                        else
                        {
                            dictionary.Add(property0.Name, property0.Value.GetString());
                        }
                    }
                    tags = dictionary;
                    continue;
                }
            }
            return(new SweepJob(description.Value, Optional.ToDictionary(properties), Optional.ToDictionary(tags), computeId.Value, displayName.Value, experimentName.Value, identity.Value, Optional.ToNullable(isArchived), jobType, schedule.Value, Optional.ToDictionary(services), Optional.ToNullable(status), earlyTermination.Value, Optional.ToDictionary(inputs), limits.Value, objective, Optional.ToDictionary(outputs), samplingAlgorithm, searchSpace, trial));
        }
Ejemplo n.º 8
0
 internal AutoMLJob(string description, IDictionary <string, string> properties, IDictionary <string, string> tags, string computeId, string displayName, string experimentName, IdentityConfiguration identity, bool?isArchived, JobType jobType, ScheduleBase schedule, IDictionary <string, JobService> services, JobStatus?status, string environmentId, IDictionary <string, string> environmentVariables, IDictionary <string, JobOutput> outputs, ResourceConfiguration resources, AutoMLVertical taskDetails) : base(description, properties, tags, computeId, displayName, experimentName, identity, isArchived, jobType, schedule, services, status)
 {
     EnvironmentId        = environmentId;
     EnvironmentVariables = environmentVariables;
     Outputs     = outputs;
     Resources   = resources;
     TaskDetails = taskDetails;
     JobType     = jobType;
 }
Ejemplo n.º 9
0
 internal MachineLearningJobProperties(string description, IDictionary <string, string> properties, IDictionary <string, string> tags, string computeId, string displayName, string experimentName, IdentityConfiguration identity, bool?isArchived, JobType jobType, ScheduleBase schedule, IDictionary <string, JobService> services, JobStatus?status) : base(description, properties, tags)
 {
     ComputeId      = computeId;
     DisplayName    = displayName;
     ExperimentName = experimentName;
     Identity       = identity;
     IsArchived     = isArchived;
     JobType        = jobType;
     Schedule       = schedule;
     Services       = services;
     Status         = status;
 }
Ejemplo n.º 10
0
        internal static PipelineJob DeserializePipelineJob(JsonElement element)
        {
            Optional <IDictionary <string, JobInput> >   inputs  = default;
            Optional <IDictionary <string, BinaryData> > jobs    = default;
            Optional <IDictionary <string, JobOutput> >  outputs = default;
            Optional <BinaryData>            settings            = default;
            Optional <string>                computeId           = default;
            Optional <string>                displayName         = default;
            Optional <string>                experimentName      = default;
            Optional <IdentityConfiguration> identity            = default;
            Optional <bool>         isArchived = default;
            JobType                 jobType    = default;
            Optional <ScheduleBase> schedule   = default;
            Optional <IDictionary <string, JobService> > services = default;
            Optional <JobStatus> status      = default;
            Optional <string>    description = default;
            Optional <IDictionary <string, string> > properties = default;
            Optional <IDictionary <string, string> > tags       = default;

            foreach (var property in element.EnumerateObject())
            {
                if (property.NameEquals("inputs"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        inputs = null;
                        continue;
                    }
                    Dictionary <string, JobInput> dictionary = new Dictionary <string, JobInput>();
                    foreach (var property0 in property.Value.EnumerateObject())
                    {
                        if (property0.Value.ValueKind == JsonValueKind.Null)
                        {
                            dictionary.Add(property0.Name, null);
                        }
                        else
                        {
                            dictionary.Add(property0.Name, JobInput.DeserializeJobInput(property0.Value));
                        }
                    }
                    inputs = dictionary;
                    continue;
                }
                if (property.NameEquals("jobs"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        jobs = null;
                        continue;
                    }
                    Dictionary <string, BinaryData> dictionary = new Dictionary <string, BinaryData>();
                    foreach (var property0 in property.Value.EnumerateObject())
                    {
                        dictionary.Add(property0.Name, BinaryData.FromString(property0.Value.GetRawText()));
                    }
                    jobs = dictionary;
                    continue;
                }
                if (property.NameEquals("outputs"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        outputs = null;
                        continue;
                    }
                    Dictionary <string, JobOutput> dictionary = new Dictionary <string, JobOutput>();
                    foreach (var property0 in property.Value.EnumerateObject())
                    {
                        if (property0.Value.ValueKind == JsonValueKind.Null)
                        {
                            dictionary.Add(property0.Name, null);
                        }
                        else
                        {
                            dictionary.Add(property0.Name, JobOutput.DeserializeJobOutput(property0.Value));
                        }
                    }
                    outputs = dictionary;
                    continue;
                }
                if (property.NameEquals("settings"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        settings = null;
                        continue;
                    }
                    settings = BinaryData.FromString(property.Value.GetRawText());
                    continue;
                }
                if (property.NameEquals("computeId"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        computeId = null;
                        continue;
                    }
                    computeId = property.Value.GetString();
                    continue;
                }
                if (property.NameEquals("displayName"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        displayName = null;
                        continue;
                    }
                    displayName = property.Value.GetString();
                    continue;
                }
                if (property.NameEquals("experimentName"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        experimentName = null;
                        continue;
                    }
                    experimentName = property.Value.GetString();
                    continue;
                }
                if (property.NameEquals("identity"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        identity = null;
                        continue;
                    }
                    identity = IdentityConfiguration.DeserializeIdentityConfiguration(property.Value);
                    continue;
                }
                if (property.NameEquals("isArchived"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        property.ThrowNonNullablePropertyIsNull();
                        continue;
                    }
                    isArchived = property.Value.GetBoolean();
                    continue;
                }
                if (property.NameEquals("jobType"))
                {
                    jobType = new JobType(property.Value.GetString());
                    continue;
                }
                if (property.NameEquals("schedule"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        schedule = null;
                        continue;
                    }
                    schedule = ScheduleBase.DeserializeScheduleBase(property.Value);
                    continue;
                }
                if (property.NameEquals("services"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        services = null;
                        continue;
                    }
                    Dictionary <string, JobService> dictionary = new Dictionary <string, JobService>();
                    foreach (var property0 in property.Value.EnumerateObject())
                    {
                        if (property0.Value.ValueKind == JsonValueKind.Null)
                        {
                            dictionary.Add(property0.Name, null);
                        }
                        else
                        {
                            dictionary.Add(property0.Name, JobService.DeserializeJobService(property0.Value));
                        }
                    }
                    services = dictionary;
                    continue;
                }
                if (property.NameEquals("status"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        property.ThrowNonNullablePropertyIsNull();
                        continue;
                    }
                    status = new JobStatus(property.Value.GetString());
                    continue;
                }
                if (property.NameEquals("description"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        description = null;
                        continue;
                    }
                    description = property.Value.GetString();
                    continue;
                }
                if (property.NameEquals("properties"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        properties = null;
                        continue;
                    }
                    Dictionary <string, string> dictionary = new Dictionary <string, string>();
                    foreach (var property0 in property.Value.EnumerateObject())
                    {
                        if (property0.Value.ValueKind == JsonValueKind.Null)
                        {
                            dictionary.Add(property0.Name, null);
                        }
                        else
                        {
                            dictionary.Add(property0.Name, property0.Value.GetString());
                        }
                    }
                    properties = dictionary;
                    continue;
                }
                if (property.NameEquals("tags"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        tags = null;
                        continue;
                    }
                    Dictionary <string, string> dictionary = new Dictionary <string, string>();
                    foreach (var property0 in property.Value.EnumerateObject())
                    {
                        if (property0.Value.ValueKind == JsonValueKind.Null)
                        {
                            dictionary.Add(property0.Name, null);
                        }
                        else
                        {
                            dictionary.Add(property0.Name, property0.Value.GetString());
                        }
                    }
                    tags = dictionary;
                    continue;
                }
            }
            return(new PipelineJob(description.Value, Optional.ToDictionary(properties), Optional.ToDictionary(tags), computeId.Value, displayName.Value, experimentName.Value, identity.Value, Optional.ToNullable(isArchived), jobType, schedule.Value, Optional.ToDictionary(services), Optional.ToNullable(status), Optional.ToDictionary(inputs), Optional.ToDictionary(jobs), Optional.ToDictionary(outputs), settings.Value));
        }
Ejemplo n.º 11
0
        internal static CommandJob DeserializeCommandJob(JsonElement element)
        {
            Optional <string> codeId  = default;
            string            command = default;
            Optional <DistributionConfiguration> distribution = default;
            string environmentId = default;
            Optional <IDictionary <string, string> >   environmentVariables = default;
            Optional <IDictionary <string, JobInput> > inputs = default;
            Optional <CommandJobLimits> limits = default;
            Optional <IDictionary <string, JobOutput> > outputs = default;
            Optional <BinaryData>            parameters         = default;
            Optional <ResourceConfiguration> resources          = default;
            Optional <string> computeId                           = default;
            Optional <string> displayName                         = default;
            Optional <string> experimentName                      = default;
            Optional <IdentityConfiguration> identity             = default;
            Optional <bool>         isArchived                    = default;
            JobType                 jobType                       = default;
            Optional <ScheduleBase> schedule                      = default;
            Optional <IDictionary <string, JobService> > services = default;
            Optional <JobStatus> status                           = default;
            Optional <string>    description                      = default;
            Optional <IDictionary <string, string> > properties   = default;
            Optional <IDictionary <string, string> > tags         = default;

            foreach (var property in element.EnumerateObject())
            {
                if (property.NameEquals("codeId"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        codeId = null;
                        continue;
                    }
                    codeId = property.Value.GetString();
                    continue;
                }
                if (property.NameEquals("command"))
                {
                    command = property.Value.GetString();
                    continue;
                }
                if (property.NameEquals("distribution"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        distribution = null;
                        continue;
                    }
                    distribution = DistributionConfiguration.DeserializeDistributionConfiguration(property.Value);
                    continue;
                }
                if (property.NameEquals("environmentId"))
                {
                    environmentId = property.Value.GetString();
                    continue;
                }
                if (property.NameEquals("environmentVariables"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        environmentVariables = null;
                        continue;
                    }
                    Dictionary <string, string> dictionary = new Dictionary <string, string>();
                    foreach (var property0 in property.Value.EnumerateObject())
                    {
                        if (property0.Value.ValueKind == JsonValueKind.Null)
                        {
                            dictionary.Add(property0.Name, null);
                        }
                        else
                        {
                            dictionary.Add(property0.Name, property0.Value.GetString());
                        }
                    }
                    environmentVariables = dictionary;
                    continue;
                }
                if (property.NameEquals("inputs"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        inputs = null;
                        continue;
                    }
                    Dictionary <string, JobInput> dictionary = new Dictionary <string, JobInput>();
                    foreach (var property0 in property.Value.EnumerateObject())
                    {
                        if (property0.Value.ValueKind == JsonValueKind.Null)
                        {
                            dictionary.Add(property0.Name, null);
                        }
                        else
                        {
                            dictionary.Add(property0.Name, JobInput.DeserializeJobInput(property0.Value));
                        }
                    }
                    inputs = dictionary;
                    continue;
                }
                if (property.NameEquals("limits"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        limits = null;
                        continue;
                    }
                    limits = CommandJobLimits.DeserializeCommandJobLimits(property.Value);
                    continue;
                }
                if (property.NameEquals("outputs"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        outputs = null;
                        continue;
                    }
                    Dictionary <string, JobOutput> dictionary = new Dictionary <string, JobOutput>();
                    foreach (var property0 in property.Value.EnumerateObject())
                    {
                        if (property0.Value.ValueKind == JsonValueKind.Null)
                        {
                            dictionary.Add(property0.Name, null);
                        }
                        else
                        {
                            dictionary.Add(property0.Name, JobOutput.DeserializeJobOutput(property0.Value));
                        }
                    }
                    outputs = dictionary;
                    continue;
                }
                if (property.NameEquals("parameters"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        parameters = null;
                        continue;
                    }
                    parameters = BinaryData.FromString(property.Value.GetRawText());
                    continue;
                }
                if (property.NameEquals("resources"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        resources = null;
                        continue;
                    }
                    resources = ResourceConfiguration.DeserializeResourceConfiguration(property.Value);
                    continue;
                }
                if (property.NameEquals("computeId"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        computeId = null;
                        continue;
                    }
                    computeId = property.Value.GetString();
                    continue;
                }
                if (property.NameEquals("displayName"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        displayName = null;
                        continue;
                    }
                    displayName = property.Value.GetString();
                    continue;
                }
                if (property.NameEquals("experimentName"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        experimentName = null;
                        continue;
                    }
                    experimentName = property.Value.GetString();
                    continue;
                }
                if (property.NameEquals("identity"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        identity = null;
                        continue;
                    }
                    identity = IdentityConfiguration.DeserializeIdentityConfiguration(property.Value);
                    continue;
                }
                if (property.NameEquals("isArchived"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        property.ThrowNonNullablePropertyIsNull();
                        continue;
                    }
                    isArchived = property.Value.GetBoolean();
                    continue;
                }
                if (property.NameEquals("jobType"))
                {
                    jobType = new JobType(property.Value.GetString());
                    continue;
                }
                if (property.NameEquals("schedule"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        schedule = null;
                        continue;
                    }
                    schedule = ScheduleBase.DeserializeScheduleBase(property.Value);
                    continue;
                }
                if (property.NameEquals("services"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        services = null;
                        continue;
                    }
                    Dictionary <string, JobService> dictionary = new Dictionary <string, JobService>();
                    foreach (var property0 in property.Value.EnumerateObject())
                    {
                        if (property0.Value.ValueKind == JsonValueKind.Null)
                        {
                            dictionary.Add(property0.Name, null);
                        }
                        else
                        {
                            dictionary.Add(property0.Name, JobService.DeserializeJobService(property0.Value));
                        }
                    }
                    services = dictionary;
                    continue;
                }
                if (property.NameEquals("status"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        property.ThrowNonNullablePropertyIsNull();
                        continue;
                    }
                    status = new JobStatus(property.Value.GetString());
                    continue;
                }
                if (property.NameEquals("description"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        description = null;
                        continue;
                    }
                    description = property.Value.GetString();
                    continue;
                }
                if (property.NameEquals("properties"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        properties = null;
                        continue;
                    }
                    Dictionary <string, string> dictionary = new Dictionary <string, string>();
                    foreach (var property0 in property.Value.EnumerateObject())
                    {
                        if (property0.Value.ValueKind == JsonValueKind.Null)
                        {
                            dictionary.Add(property0.Name, null);
                        }
                        else
                        {
                            dictionary.Add(property0.Name, property0.Value.GetString());
                        }
                    }
                    properties = dictionary;
                    continue;
                }
                if (property.NameEquals("tags"))
                {
                    if (property.Value.ValueKind == JsonValueKind.Null)
                    {
                        tags = null;
                        continue;
                    }
                    Dictionary <string, string> dictionary = new Dictionary <string, string>();
                    foreach (var property0 in property.Value.EnumerateObject())
                    {
                        if (property0.Value.ValueKind == JsonValueKind.Null)
                        {
                            dictionary.Add(property0.Name, null);
                        }
                        else
                        {
                            dictionary.Add(property0.Name, property0.Value.GetString());
                        }
                    }
                    tags = dictionary;
                    continue;
                }
            }
            return(new CommandJob(description.Value, Optional.ToDictionary(properties), Optional.ToDictionary(tags), computeId.Value, displayName.Value, experimentName.Value, identity.Value, Optional.ToNullable(isArchived), jobType, schedule.Value, Optional.ToDictionary(services), Optional.ToNullable(status), codeId.Value, command, distribution.Value, environmentId, Optional.ToDictionary(environmentVariables), Optional.ToDictionary(inputs), limits.Value, Optional.ToDictionary(outputs), parameters.Value, resources.Value));
        }
Ejemplo n.º 12
0
 internal CommandJob(string description, IDictionary <string, string> properties, IDictionary <string, string> tags, string computeId, string displayName, string experimentName, IdentityConfiguration identity, bool?isArchived, JobType jobType, ScheduleBase schedule, IDictionary <string, JobService> services, JobStatus?status, string codeId, string command, DistributionConfiguration distribution, string environmentId, IDictionary <string, string> environmentVariables, IDictionary <string, JobInput> inputs, CommandJobLimits limits, IDictionary <string, JobOutput> outputs, BinaryData parameters, ResourceConfiguration resources) : base(description, properties, tags, computeId, displayName, experimentName, identity, isArchived, jobType, schedule, services, status)
 {
     CodeId               = codeId;
     Command              = command;
     Distribution         = distribution;
     EnvironmentId        = environmentId;
     EnvironmentVariables = environmentVariables;
     Inputs               = inputs;
     Limits               = limits;
     Outputs              = outputs;
     Parameters           = parameters;
     Resources            = resources;
     JobType              = jobType;
 }