// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
// Code generated by Microsoft (R) AutoRest Code Generator.

package com.azure.resourcemanager.automation.fluent.models;

import com.azure.core.annotation.Fluent;
import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonProperty;
import java.time.OffsetDateTime;
import java.util.Map;

/** Definition of the test job. */
@Fluent
public final class TestJobInner {
    /*
     * Gets or sets the creation time of the test job.
     */
    @JsonProperty(value = "creationTime")
    private OffsetDateTime creationTime;

    /*
     * Gets or sets the status of the test job.
     */
    @JsonProperty(value = "status")
    private String status;

    /*
     * Gets or sets the status details of the test job.
     */
    @JsonProperty(value = "statusDetails")
    private String statusDetails;

    /*
     * Gets or sets the runOn which specifies the group name where the job is to be executed.
     */
    @JsonProperty(value = "runOn")
    private String runOn;

    /*
     * Gets or sets the start time of the test job.
     */
    @JsonProperty(value = "startTime")
    private OffsetDateTime startTime;

    /*
     * Gets or sets the end time of the test job.
     */
    @JsonProperty(value = "endTime")
    private OffsetDateTime endTime;

    /*
     * Gets or sets the exception of the test job.
     */
    @JsonProperty(value = "exception")
    private String exception;

    /*
     * Gets or sets the last modified time of the test job.
     */
    @JsonProperty(value = "lastModifiedTime")
    private OffsetDateTime lastModifiedTime;

    /*
     * Gets or sets the last status modified time of the test job.
     */
    @JsonProperty(value = "lastStatusModifiedTime")
    private OffsetDateTime lastStatusModifiedTime;

    /*
     * Gets or sets the parameters of the test job.
     */
    @JsonProperty(value = "parameters")
    @JsonInclude(value = JsonInclude.Include.NON_NULL, content = JsonInclude.Include.ALWAYS)
    private Map<String, String> parameters;

    /*
     * The activity-level tracing options of the runbook.
     */
    @JsonProperty(value = "logActivityTrace")
    private Integer logActivityTrace;

    /**
     * Get the creationTime property: Gets or sets the creation time of the test job.
     *
     * @return the creationTime value.
     */
    public OffsetDateTime creationTime() {
        return this.creationTime;
    }

    /**
     * Set the creationTime property: Gets or sets the creation time of the test job.
     *
     * @param creationTime the creationTime value to set.
     * @return the TestJobInner object itself.
     */
    public TestJobInner withCreationTime(OffsetDateTime creationTime) {
        this.creationTime = creationTime;
        return this;
    }

    /**
     * Get the status property: Gets or sets the status of the test job.
     *
     * @return the status value.
     */
    public String status() {
        return this.status;
    }

    /**
     * Set the status property: Gets or sets the status of the test job.
     *
     * @param status the status value to set.
     * @return the TestJobInner object itself.
     */
    public TestJobInner withStatus(String status) {
        this.status = status;
        return this;
    }

    /**
     * Get the statusDetails property: Gets or sets the status details of the test job.
     *
     * @return the statusDetails value.
     */
    public String statusDetails() {
        return this.statusDetails;
    }

    /**
     * Set the statusDetails property: Gets or sets the status details of the test job.
     *
     * @param statusDetails the statusDetails value to set.
     * @return the TestJobInner object itself.
     */
    public TestJobInner withStatusDetails(String statusDetails) {
        this.statusDetails = statusDetails;
        return this;
    }

    /**
     * Get the runOn property: Gets or sets the runOn which specifies the group name where the job is to be executed.
     *
     * @return the runOn value.
     */
    public String runOn() {
        return this.runOn;
    }

    /**
     * Set the runOn property: Gets or sets the runOn which specifies the group name where the job is to be executed.
     *
     * @param runOn the runOn value to set.
     * @return the TestJobInner object itself.
     */
    public TestJobInner withRunOn(String runOn) {
        this.runOn = runOn;
        return this;
    }

    /**
     * Get the startTime property: Gets or sets the start time of the test job.
     *
     * @return the startTime value.
     */
    public OffsetDateTime startTime() {
        return this.startTime;
    }

    /**
     * Set the startTime property: Gets or sets the start time of the test job.
     *
     * @param startTime the startTime value to set.
     * @return the TestJobInner object itself.
     */
    public TestJobInner withStartTime(OffsetDateTime startTime) {
        this.startTime = startTime;
        return this;
    }

    /**
     * Get the endTime property: Gets or sets the end time of the test job.
     *
     * @return the endTime value.
     */
    public OffsetDateTime endTime() {
        return this.endTime;
    }

    /**
     * Set the endTime property: Gets or sets the end time of the test job.
     *
     * @param endTime the endTime value to set.
     * @return the TestJobInner object itself.
     */
    public TestJobInner withEndTime(OffsetDateTime endTime) {
        this.endTime = endTime;
        return this;
    }

    /**
     * Get the exception property: Gets or sets the exception of the test job.
     *
     * @return the exception value.
     */
    public String exception() {
        return this.exception;
    }

    /**
     * Set the exception property: Gets or sets the exception of the test job.
     *
     * @param exception the exception value to set.
     * @return the TestJobInner object itself.
     */
    public TestJobInner withException(String exception) {
        this.exception = exception;
        return this;
    }

    /**
     * Get the lastModifiedTime property: Gets or sets the last modified time of the test job.
     *
     * @return the lastModifiedTime value.
     */
    public OffsetDateTime lastModifiedTime() {
        return this.lastModifiedTime;
    }

    /**
     * Set the lastModifiedTime property: Gets or sets the last modified time of the test job.
     *
     * @param lastModifiedTime the lastModifiedTime value to set.
     * @return the TestJobInner object itself.
     */
    public TestJobInner withLastModifiedTime(OffsetDateTime lastModifiedTime) {
        this.lastModifiedTime = lastModifiedTime;
        return this;
    }

    /**
     * Get the lastStatusModifiedTime property: Gets or sets the last status modified time of the test job.
     *
     * @return the lastStatusModifiedTime value.
     */
    public OffsetDateTime lastStatusModifiedTime() {
        return this.lastStatusModifiedTime;
    }

    /**
     * Set the lastStatusModifiedTime property: Gets or sets the last status modified time of the test job.
     *
     * @param lastStatusModifiedTime the lastStatusModifiedTime value to set.
     * @return the TestJobInner object itself.
     */
    public TestJobInner withLastStatusModifiedTime(OffsetDateTime lastStatusModifiedTime) {
        this.lastStatusModifiedTime = lastStatusModifiedTime;
        return this;
    }

    /**
     * Get the parameters property: Gets or sets the parameters of the test job.
     *
     * @return the parameters value.
     */
    public Map<String, String> parameters() {
        return this.parameters;
    }

    /**
     * Set the parameters property: Gets or sets the parameters of the test job.
     *
     * @param parameters the parameters value to set.
     * @return the TestJobInner object itself.
     */
    public TestJobInner withParameters(Map<String, String> parameters) {
        this.parameters = parameters;
        return this;
    }

    /**
     * Get the logActivityTrace property: The activity-level tracing options of the runbook.
     *
     * @return the logActivityTrace value.
     */
    public Integer logActivityTrace() {
        return this.logActivityTrace;
    }

    /**
     * Set the logActivityTrace property: The activity-level tracing options of the runbook.
     *
     * @param logActivityTrace the logActivityTrace value to set.
     * @return the TestJobInner object itself.
     */
    public TestJobInner withLogActivityTrace(Integer logActivityTrace) {
        this.logActivityTrace = logActivityTrace;
        return this;
    }

    /**
     * Validates the instance.
     *
     * @throws IllegalArgumentException thrown if the instance is not valid.
     */
    public void validate() {
    }
}
