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

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

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

/** Tenant Configuration Synchronization State. */
@Fluent
public final class TenantConfigurationSyncStateContractProperties {
    /*
     * The name of Git branch.
     */
    @JsonProperty(value = "branch")
    private String branch;

    /*
     * The latest commit Id.
     */
    @JsonProperty(value = "commitId")
    private String commitId;

    /*
     * value indicating if last sync was save (true) or deploy (false)
     * operation.
     */
    @JsonProperty(value = "isExport")
    private Boolean isExport;

    /*
     * value indicating if last synchronization was later than the
     * configuration change.
     */
    @JsonProperty(value = "isSynced")
    private Boolean isSynced;

    /*
     * value indicating whether Git configuration access is enabled.
     */
    @JsonProperty(value = "isGitEnabled")
    private Boolean isGitEnabled;

    /*
     * The date of the latest synchronization. The date conforms to the
     * following format: `yyyy-MM-ddTHH:mm:ssZ` as specified by the ISO 8601
     * standard.
     *
     */
    @JsonProperty(value = "syncDate")
    private OffsetDateTime syncDate;

    /*
     * The date of the latest configuration change. The date conforms to the
     * following format: `yyyy-MM-ddTHH:mm:ssZ` as specified by the ISO 8601
     * standard.
     *
     */
    @JsonProperty(value = "configurationChangeDate")
    private OffsetDateTime configurationChangeDate;

    /*
     * Most recent tenant configuration operation identifier
     */
    @JsonProperty(value = "lastOperationId")
    private String lastOperationId;

    /**
     * Get the branch property: The name of Git branch.
     *
     * @return the branch value.
     */
    public String branch() {
        return this.branch;
    }

    /**
     * Set the branch property: The name of Git branch.
     *
     * @param branch the branch value to set.
     * @return the TenantConfigurationSyncStateContractProperties object itself.
     */
    public TenantConfigurationSyncStateContractProperties withBranch(String branch) {
        this.branch = branch;
        return this;
    }

    /**
     * Get the commitId property: The latest commit Id.
     *
     * @return the commitId value.
     */
    public String commitId() {
        return this.commitId;
    }

    /**
     * Set the commitId property: The latest commit Id.
     *
     * @param commitId the commitId value to set.
     * @return the TenantConfigurationSyncStateContractProperties object itself.
     */
    public TenantConfigurationSyncStateContractProperties withCommitId(String commitId) {
        this.commitId = commitId;
        return this;
    }

    /**
     * Get the isExport property: value indicating if last sync was save (true) or deploy (false) operation.
     *
     * @return the isExport value.
     */
    public Boolean isExport() {
        return this.isExport;
    }

    /**
     * Set the isExport property: value indicating if last sync was save (true) or deploy (false) operation.
     *
     * @param isExport the isExport value to set.
     * @return the TenantConfigurationSyncStateContractProperties object itself.
     */
    public TenantConfigurationSyncStateContractProperties withIsExport(Boolean isExport) {
        this.isExport = isExport;
        return this;
    }

    /**
     * Get the isSynced property: value indicating if last synchronization was later than the configuration change.
     *
     * @return the isSynced value.
     */
    public Boolean isSynced() {
        return this.isSynced;
    }

    /**
     * Set the isSynced property: value indicating if last synchronization was later than the configuration change.
     *
     * @param isSynced the isSynced value to set.
     * @return the TenantConfigurationSyncStateContractProperties object itself.
     */
    public TenantConfigurationSyncStateContractProperties withIsSynced(Boolean isSynced) {
        this.isSynced = isSynced;
        return this;
    }

    /**
     * Get the isGitEnabled property: value indicating whether Git configuration access is enabled.
     *
     * @return the isGitEnabled value.
     */
    public Boolean isGitEnabled() {
        return this.isGitEnabled;
    }

    /**
     * Set the isGitEnabled property: value indicating whether Git configuration access is enabled.
     *
     * @param isGitEnabled the isGitEnabled value to set.
     * @return the TenantConfigurationSyncStateContractProperties object itself.
     */
    public TenantConfigurationSyncStateContractProperties withIsGitEnabled(Boolean isGitEnabled) {
        this.isGitEnabled = isGitEnabled;
        return this;
    }

    /**
     * Get the syncDate property: The date of the latest synchronization. The date conforms to the following format:
     * `yyyy-MM-ddTHH:mm:ssZ` as specified by the ISO 8601 standard.
     *
     * @return the syncDate value.
     */
    public OffsetDateTime syncDate() {
        return this.syncDate;
    }

    /**
     * Set the syncDate property: The date of the latest synchronization. The date conforms to the following format:
     * `yyyy-MM-ddTHH:mm:ssZ` as specified by the ISO 8601 standard.
     *
     * @param syncDate the syncDate value to set.
     * @return the TenantConfigurationSyncStateContractProperties object itself.
     */
    public TenantConfigurationSyncStateContractProperties withSyncDate(OffsetDateTime syncDate) {
        this.syncDate = syncDate;
        return this;
    }

    /**
     * Get the configurationChangeDate property: The date of the latest configuration change. The date conforms to the
     * following format: `yyyy-MM-ddTHH:mm:ssZ` as specified by the ISO 8601 standard.
     *
     * @return the configurationChangeDate value.
     */
    public OffsetDateTime configurationChangeDate() {
        return this.configurationChangeDate;
    }

    /**
     * Set the configurationChangeDate property: The date of the latest configuration change. The date conforms to the
     * following format: `yyyy-MM-ddTHH:mm:ssZ` as specified by the ISO 8601 standard.
     *
     * @param configurationChangeDate the configurationChangeDate value to set.
     * @return the TenantConfigurationSyncStateContractProperties object itself.
     */
    public TenantConfigurationSyncStateContractProperties withConfigurationChangeDate(
        OffsetDateTime configurationChangeDate) {
        this.configurationChangeDate = configurationChangeDate;
        return this;
    }

    /**
     * Get the lastOperationId property: Most recent tenant configuration operation identifier.
     *
     * @return the lastOperationId value.
     */
    public String lastOperationId() {
        return this.lastOperationId;
    }

    /**
     * Set the lastOperationId property: Most recent tenant configuration operation identifier.
     *
     * @param lastOperationId the lastOperationId value to set.
     * @return the TenantConfigurationSyncStateContractProperties object itself.
     */
    public TenantConfigurationSyncStateContractProperties withLastOperationId(String lastOperationId) {
        this.lastOperationId = lastOperationId;
        return this;
    }

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