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

package com.azure.resourcemanager.reservations.implementation;

import com.azure.resourcemanager.reservations.fluent.models.ChangeDirectoryResponseInner;
import com.azure.resourcemanager.reservations.models.ChangeDirectoryResponse;
import com.azure.resourcemanager.reservations.models.ChangeDirectoryResult;
import java.util.Collections;
import java.util.List;

public final class ChangeDirectoryResponseImpl implements ChangeDirectoryResponse {
    private ChangeDirectoryResponseInner innerObject;

    private final com.azure.resourcemanager.reservations.ReservationsManager serviceManager;

    ChangeDirectoryResponseImpl(
        ChangeDirectoryResponseInner innerObject,
        com.azure.resourcemanager.reservations.ReservationsManager serviceManager) {
        this.innerObject = innerObject;
        this.serviceManager = serviceManager;
    }

    public ChangeDirectoryResult reservationOrder() {
        return this.innerModel().reservationOrder();
    }

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

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

    private com.azure.resourcemanager.reservations.ReservationsManager manager() {
        return this.serviceManager;
    }
}
