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

package com.azure.resourcemanager.consumption.implementation;

import com.azure.resourcemanager.consumption.fluent.models.BalanceInner;
import com.azure.resourcemanager.consumption.models.Balance;
import com.azure.resourcemanager.consumption.models.BalancePropertiesAdjustmentDetailsItem;
import com.azure.resourcemanager.consumption.models.BalancePropertiesNewPurchasesDetailsItem;
import com.azure.resourcemanager.consumption.models.BillingFrequency;
import java.math.BigDecimal;
import java.util.Collections;
import java.util.List;
import java.util.Map;

public final class BalanceImpl implements Balance {
    private BalanceInner innerObject;

    private final com.azure.resourcemanager.consumption.ConsumptionManager serviceManager;

    BalanceImpl(BalanceInner innerObject, com.azure.resourcemanager.consumption.ConsumptionManager serviceManager) {
        this.innerObject = innerObject;
        this.serviceManager = serviceManager;
    }

    public String id() {
        return this.innerModel().id();
    }

    public String name() {
        return this.innerModel().name();
    }

    public String type() {
        return this.innerModel().type();
    }

    public String etag() {
        return this.innerModel().etag();
    }

    public Map<String, String> tags() {
        Map<String, String> inner = this.innerModel().tags();
        if (inner != null) {
            return Collections.unmodifiableMap(inner);
        } else {
            return Collections.emptyMap();
        }
    }

    public String currency() {
        return this.innerModel().currency();
    }

    public BigDecimal beginningBalance() {
        return this.innerModel().beginningBalance();
    }

    public BigDecimal endingBalance() {
        return this.innerModel().endingBalance();
    }

    public BigDecimal newPurchases() {
        return this.innerModel().newPurchases();
    }

    public BigDecimal adjustments() {
        return this.innerModel().adjustments();
    }

    public BigDecimal utilized() {
        return this.innerModel().utilized();
    }

    public BigDecimal serviceOverage() {
        return this.innerModel().serviceOverage();
    }

    public BigDecimal chargesBilledSeparately() {
        return this.innerModel().chargesBilledSeparately();
    }

    public BigDecimal totalOverage() {
        return this.innerModel().totalOverage();
    }

    public BigDecimal totalUsage() {
        return this.innerModel().totalUsage();
    }

    public BigDecimal azureMarketplaceServiceCharges() {
        return this.innerModel().azureMarketplaceServiceCharges();
    }

    public BillingFrequency billingFrequency() {
        return this.innerModel().billingFrequency();
    }

    public Boolean priceHidden() {
        return this.innerModel().priceHidden();
    }

    public List<BalancePropertiesNewPurchasesDetailsItem> newPurchasesDetails() {
        List<BalancePropertiesNewPurchasesDetailsItem> inner = this.innerModel().newPurchasesDetails();
        if (inner != null) {
            return Collections.unmodifiableList(inner);
        } else {
            return Collections.emptyList();
        }
    }

    public List<BalancePropertiesAdjustmentDetailsItem> adjustmentDetails() {
        List<BalancePropertiesAdjustmentDetailsItem> inner = this.innerModel().adjustmentDetails();
        if (inner != null) {
            return Collections.unmodifiableList(inner);
        } else {
            return Collections.emptyList();
        }
    }

    public BalanceInner innerModel() {
        return this.innerObject;
    }

    private com.azure.resourcemanager.consumption.ConsumptionManager manager() {
        return this.serviceManager;
    }
}
