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

package com.azure.resourcemanager.scvmm.models;

import com.azure.core.annotation.Fluent;
import com.fasterxml.jackson.annotation.JsonProperty;
import java.util.List;

/** Defines the resource properties. */
@Fluent
public final class NetworkProfileUpdate {
    /*
     * Gets or sets the list of network interfaces associated with the virtual
     * machine.
     */
    @JsonProperty(value = "networkInterfaces")
    private List<NetworkInterfacesUpdate> networkInterfaces;

    /**
     * Get the networkInterfaces property: Gets or sets the list of network interfaces associated with the virtual
     * machine.
     *
     * @return the networkInterfaces value.
     */
    public List<NetworkInterfacesUpdate> networkInterfaces() {
        return this.networkInterfaces;
    }

    /**
     * Set the networkInterfaces property: Gets or sets the list of network interfaces associated with the virtual
     * machine.
     *
     * @param networkInterfaces the networkInterfaces value to set.
     * @return the NetworkProfileUpdate object itself.
     */
    public NetworkProfileUpdate withNetworkInterfaces(List<NetworkInterfacesUpdate> networkInterfaces) {
        this.networkInterfaces = networkInterfaces;
        return this;
    }

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