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

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

import com.azure.core.annotation.Immutable;
import com.azure.resourcemanager.azurestack.models.ComputeRole;
import com.azure.resourcemanager.azurestack.models.DataDiskImage;
import com.azure.resourcemanager.azurestack.models.OperatingSystem;
import com.azure.resourcemanager.azurestack.models.OsDiskImage;
import com.fasterxml.jackson.annotation.JsonProperty;
import java.util.List;

/** Extended description about the product required for installing it into Azure Stack. */
@Immutable
public final class ExtendedProductInner {
    /*
     * The URI to the .azpkg file that provides information required for showing product in the gallery.
     */
    @JsonProperty(value = "galleryPackageBlobSasUri", access = JsonProperty.Access.WRITE_ONLY)
    private String galleryPackageBlobSasUri;

    /*
     * Specifies the kind of the product (virtualMachine or virtualMachineExtension).
     */
    @JsonProperty(value = "productKind", access = JsonProperty.Access.WRITE_ONLY)
    private String productKind;

    /*
     * Specifies additional properties describing the product.
     */
    @JsonProperty(value = "properties", access = JsonProperty.Access.WRITE_ONLY)
    private ExtendedProductProperties innerProperties;

    /** Creates an instance of ExtendedProductInner class. */
    public ExtendedProductInner() {
    }

    /**
     * Get the galleryPackageBlobSasUri property: The URI to the .azpkg file that provides information required for
     * showing product in the gallery.
     *
     * @return the galleryPackageBlobSasUri value.
     */
    public String galleryPackageBlobSasUri() {
        return this.galleryPackageBlobSasUri;
    }

    /**
     * Get the productKind property: Specifies the kind of the product (virtualMachine or virtualMachineExtension).
     *
     * @return the productKind value.
     */
    public String productKind() {
        return this.productKind;
    }

    /**
     * Get the innerProperties property: Specifies additional properties describing the product.
     *
     * @return the innerProperties value.
     */
    private ExtendedProductProperties innerProperties() {
        return this.innerProperties;
    }

    /**
     * Get the version property: Specifies product version.
     *
     * @return the version value.
     */
    public String version() {
        return this.innerProperties() == null ? null : this.innerProperties().version();
    }

    /**
     * Get the osDiskImage property: OS disk image used by product.
     *
     * @return the osDiskImage value.
     */
    public OsDiskImage osDiskImage() {
        return this.innerProperties() == null ? null : this.innerProperties().osDiskImage();
    }

    /**
     * Get the dataDiskImages property: List of attached data disks.
     *
     * @return the dataDiskImages value.
     */
    public List<DataDiskImage> dataDiskImages() {
        return this.innerProperties() == null ? null : this.innerProperties().dataDiskImages();
    }

    /**
     * Get the computeRole property: Specifies kind of compute role included in the package.
     *
     * @return the computeRole value.
     */
    public ComputeRole computeRole() {
        return this.innerProperties() == null ? null : this.innerProperties().computeRole();
    }

    /**
     * Get the isSystemExtension property: Specifies if product is a Virtual Machine Extension.
     *
     * @return the isSystemExtension value.
     */
    public Boolean isSystemExtension() {
        return this.innerProperties() == null ? null : this.innerProperties().isSystemExtension();
    }

    /**
     * Get the uri property: The URI.
     *
     * @return the uri value.
     */
    public String uri() {
        return this.innerProperties() == null ? null : this.innerProperties().uri();
    }

    /**
     * Get the supportMultipleExtensions property: Indicates if specified product supports multiple extensions.
     *
     * @return the supportMultipleExtensions value.
     */
    public Boolean supportMultipleExtensions() {
        return this.innerProperties() == null ? null : this.innerProperties().supportMultipleExtensions();
    }

    /**
     * Get the vmOsType property: Specifies operating system used by the product.
     *
     * @return the vmOsType value.
     */
    public OperatingSystem vmOsType() {
        return this.innerProperties() == null ? null : this.innerProperties().vmOsType();
    }

    /**
     * Get the vmScaleSetEnabled property: Indicates if virtual machine Scale Set is enabled in the specified product.
     *
     * @return the vmScaleSetEnabled value.
     */
    public Boolean vmScaleSetEnabled() {
        return this.innerProperties() == null ? null : this.innerProperties().vmScaleSetEnabled();
    }

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