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

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

import com.azure.core.annotation.Immutable;
import com.azure.core.management.ProxyResource;
import com.fasterxml.jackson.annotation.JsonProperty;

/** Secure score item data model. */
@Immutable
public final class SecureScoreItemInner extends ProxyResource {
    /*
     * Secure score item
     */
    @JsonProperty(value = "properties", access = JsonProperty.Access.WRITE_ONLY)
    private SecureScoreItemProperties innerProperties;

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

    /**
     * Get the innerProperties property: Secure score item.
     *
     * @return the innerProperties value.
     */
    private SecureScoreItemProperties innerProperties() {
        return this.innerProperties;
    }

    /**
     * Get the displayName property: The initiative’s name.
     *
     * @return the displayName value.
     */
    public String displayName() {
        return this.innerProperties() == null ? null : this.innerProperties().displayName();
    }

    /**
     * Get the weight property: The relative weight for each subscription. Used when calculating an aggregated secure
     * score for multiple subscriptions.
     *
     * @return the weight value.
     */
    public Long weight() {
        return this.innerProperties() == null ? null : this.innerProperties().weight();
    }

    /**
     * Get the max property: Maximum score available.
     *
     * @return the max value.
     */
    public Integer max() {
        return this.innerProperties() == null ? null : this.innerProperties().max();
    }

    /**
     * Get the current property: Current score.
     *
     * @return the current value.
     */
    public Double current() {
        return this.innerProperties() == null ? null : this.innerProperties().current();
    }

    /**
     * Get the percentage property: Ratio of the current score divided by the maximum. Rounded to 4 digits after the
     * decimal point.
     *
     * @return the percentage value.
     */
    public Double percentage() {
        return this.innerProperties() == null ? null : this.innerProperties().percentage();
    }

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