/*
 * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except
 * in compliance with the License. You may obtain a copy of the License at
 *
 * http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software distributed under the License
 * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express
 * or implied. See the License for the specific language governing permissions and limitations under
 * the License.
 */
/*
 * This code was generated by https://github.com/googleapis/google-api-java-client-services/
 * Modify at your own risk.
 */

package com.google.api.services.baremetalsolution.v2.model;

/**
 * A Network.
 *
 * <p> This is the Java data model class that specifies how to parse/serialize into the JSON that is
 * transmitted over HTTP when working with the Bare Metal Solution API. For a detailed explanation
 * see:
 * <a href="https://developers.google.com/api-client-library/java/google-http-java-client/json">https://developers.google.com/api-client-library/java/google-http-java-client/json</a>
 * </p>
 *
 * @author Google, Inc.
 */
@SuppressWarnings("javadoc")
public final class Network extends com.google.api.client.json.GenericJson {

  /**
   * The cidr of the Network.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private java.lang.String cidr;

  /**
   * Output only. Gateway ip address.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private java.lang.String gatewayIp;

  /**
   * An identifier for the `Network`, generated by the backend.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private java.lang.String id;

  /**
   * IP address configured.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private java.lang.String ipAddress;

  /**
   * Whether network uses standard frames or jumbo ones.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private java.lang.Boolean jumboFramesEnabled;

  /**
   * Labels as key value pairs.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private java.util.Map<String, java.lang.String> labels;

  /**
   * List of physical interfaces.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private java.util.List<java.lang.String> macAddress;

  /**
   * Input only. List of mount points to attach the network to.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private java.util.List<NetworkMountPoint> mountPoints;

  /**
   * Output only. The resource name of this `Network`. Resource names are schemeless URIs that
   * follow the conventions in https://cloud.google.com/apis/design/resource_names. Format:
   * `projects/{project}/locations/{location}/networks/{network}`
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private java.lang.String name;

  /**
   * Output only. Pod name.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private java.lang.String pod;

  /**
   * List of IP address reservations in this network. When updating this field, an error will be
   * generated if a reservation conflicts with an IP address already allocated to a physical server.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private java.util.List<NetworkAddressReservation> reservations;

  /**
   * IP range for reserved for services (e.g. NFS).
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private java.lang.String servicesCidr;

  /**
   * The Network state.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private java.lang.String state;

  /**
   * The type of this network.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private java.lang.String type;

  /**
   * The vlan id of the Network.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private java.lang.String vlanId;

  /**
   * The vrf for the Network.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private VRF vrf;

  /**
   * The cidr of the Network.
   * @return value or {@code null} for none
   */
  public java.lang.String getCidr() {
    return cidr;
  }

  /**
   * The cidr of the Network.
   * @param cidr cidr or {@code null} for none
   */
  public Network setCidr(java.lang.String cidr) {
    this.cidr = cidr;
    return this;
  }

  /**
   * Output only. Gateway ip address.
   * @return value or {@code null} for none
   */
  public java.lang.String getGatewayIp() {
    return gatewayIp;
  }

  /**
   * Output only. Gateway ip address.
   * @param gatewayIp gatewayIp or {@code null} for none
   */
  public Network setGatewayIp(java.lang.String gatewayIp) {
    this.gatewayIp = gatewayIp;
    return this;
  }

  /**
   * An identifier for the `Network`, generated by the backend.
   * @return value or {@code null} for none
   */
  public java.lang.String getId() {
    return id;
  }

  /**
   * An identifier for the `Network`, generated by the backend.
   * @param id id or {@code null} for none
   */
  public Network setId(java.lang.String id) {
    this.id = id;
    return this;
  }

  /**
   * IP address configured.
   * @return value or {@code null} for none
   */
  public java.lang.String getIpAddress() {
    return ipAddress;
  }

  /**
   * IP address configured.
   * @param ipAddress ipAddress or {@code null} for none
   */
  public Network setIpAddress(java.lang.String ipAddress) {
    this.ipAddress = ipAddress;
    return this;
  }

  /**
   * Whether network uses standard frames or jumbo ones.
   * @return value or {@code null} for none
   */
  public java.lang.Boolean getJumboFramesEnabled() {
    return jumboFramesEnabled;
  }

  /**
   * Whether network uses standard frames or jumbo ones.
   * @param jumboFramesEnabled jumboFramesEnabled or {@code null} for none
   */
  public Network setJumboFramesEnabled(java.lang.Boolean jumboFramesEnabled) {
    this.jumboFramesEnabled = jumboFramesEnabled;
    return this;
  }

  /**
   * Labels as key value pairs.
   * @return value or {@code null} for none
   */
  public java.util.Map<String, java.lang.String> getLabels() {
    return labels;
  }

  /**
   * Labels as key value pairs.
   * @param labels labels or {@code null} for none
   */
  public Network setLabels(java.util.Map<String, java.lang.String> labels) {
    this.labels = labels;
    return this;
  }

  /**
   * List of physical interfaces.
   * @return value or {@code null} for none
   */
  public java.util.List<java.lang.String> getMacAddress() {
    return macAddress;
  }

  /**
   * List of physical interfaces.
   * @param macAddress macAddress or {@code null} for none
   */
  public Network setMacAddress(java.util.List<java.lang.String> macAddress) {
    this.macAddress = macAddress;
    return this;
  }

  /**
   * Input only. List of mount points to attach the network to.
   * @return value or {@code null} for none
   */
  public java.util.List<NetworkMountPoint> getMountPoints() {
    return mountPoints;
  }

  /**
   * Input only. List of mount points to attach the network to.
   * @param mountPoints mountPoints or {@code null} for none
   */
  public Network setMountPoints(java.util.List<NetworkMountPoint> mountPoints) {
    this.mountPoints = mountPoints;
    return this;
  }

  /**
   * Output only. The resource name of this `Network`. Resource names are schemeless URIs that
   * follow the conventions in https://cloud.google.com/apis/design/resource_names. Format:
   * `projects/{project}/locations/{location}/networks/{network}`
   * @return value or {@code null} for none
   */
  public java.lang.String getName() {
    return name;
  }

  /**
   * Output only. The resource name of this `Network`. Resource names are schemeless URIs that
   * follow the conventions in https://cloud.google.com/apis/design/resource_names. Format:
   * `projects/{project}/locations/{location}/networks/{network}`
   * @param name name or {@code null} for none
   */
  public Network setName(java.lang.String name) {
    this.name = name;
    return this;
  }

  /**
   * Output only. Pod name.
   * @return value or {@code null} for none
   */
  public java.lang.String getPod() {
    return pod;
  }

  /**
   * Output only. Pod name.
   * @param pod pod or {@code null} for none
   */
  public Network setPod(java.lang.String pod) {
    this.pod = pod;
    return this;
  }

  /**
   * List of IP address reservations in this network. When updating this field, an error will be
   * generated if a reservation conflicts with an IP address already allocated to a physical server.
   * @return value or {@code null} for none
   */
  public java.util.List<NetworkAddressReservation> getReservations() {
    return reservations;
  }

  /**
   * List of IP address reservations in this network. When updating this field, an error will be
   * generated if a reservation conflicts with an IP address already allocated to a physical server.
   * @param reservations reservations or {@code null} for none
   */
  public Network setReservations(java.util.List<NetworkAddressReservation> reservations) {
    this.reservations = reservations;
    return this;
  }

  /**
   * IP range for reserved for services (e.g. NFS).
   * @return value or {@code null} for none
   */
  public java.lang.String getServicesCidr() {
    return servicesCidr;
  }

  /**
   * IP range for reserved for services (e.g. NFS).
   * @param servicesCidr servicesCidr or {@code null} for none
   */
  public Network setServicesCidr(java.lang.String servicesCidr) {
    this.servicesCidr = servicesCidr;
    return this;
  }

  /**
   * The Network state.
   * @return value or {@code null} for none
   */
  public java.lang.String getState() {
    return state;
  }

  /**
   * The Network state.
   * @param state state or {@code null} for none
   */
  public Network setState(java.lang.String state) {
    this.state = state;
    return this;
  }

  /**
   * The type of this network.
   * @return value or {@code null} for none
   */
  public java.lang.String getType() {
    return type;
  }

  /**
   * The type of this network.
   * @param type type or {@code null} for none
   */
  public Network setType(java.lang.String type) {
    this.type = type;
    return this;
  }

  /**
   * The vlan id of the Network.
   * @return value or {@code null} for none
   */
  public java.lang.String getVlanId() {
    return vlanId;
  }

  /**
   * The vlan id of the Network.
   * @param vlanId vlanId or {@code null} for none
   */
  public Network setVlanId(java.lang.String vlanId) {
    this.vlanId = vlanId;
    return this;
  }

  /**
   * The vrf for the Network.
   * @return value or {@code null} for none
   */
  public VRF getVrf() {
    return vrf;
  }

  /**
   * The vrf for the Network.
   * @param vrf vrf or {@code null} for none
   */
  public Network setVrf(VRF vrf) {
    this.vrf = vrf;
    return this;
  }

  @Override
  public Network set(String fieldName, Object value) {
    return (Network) super.set(fieldName, value);
  }

  @Override
  public Network clone() {
    return (Network) super.clone();
  }

}
