All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.google.api.services.compute.model.AttachedDiskInitializeParams Maven / Gradle / Ivy

There is a newer version: v1-rev20250107-2.0.0
Show newest version
/*
 * Copyright 2010 Google Inc.
 *
 * 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://code.google.com/p/google-apis-client-generator/
 * (build: 2016-05-27 16:00:31 UTC)
 * on 2016-07-07 at 07:34:17 UTC 
 * Modify at your own risk.
 */

package com.google.api.services.compute.model;

/**
 * [Input Only] Specifies the parameters for a new disk that will be created alongside the new
 * instance. Use initialization parameters to create boot disks or local SSDs attached to the new
 * instance.
 *
 * This property is mutually exclusive with the source property; you can only define one or the
 * other, but not both.
 *
 * 

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 Compute Engine API. For a detailed explanation see: * http://code.google.com/p/google-http-java-client/wiki/JSON *

* * @author Google, Inc. */ @SuppressWarnings("javadoc") public final class AttachedDiskInitializeParams extends com.google.api.client.json.GenericJson { /** * Specifies the disk name. If not specified, the default is to use the name of the instance. * The value may be {@code null}. */ @com.google.api.client.util.Key private java.lang.String diskName; /** * Specifies the size of the disk in base-2 GB. * The value may be {@code null}. */ @com.google.api.client.util.Key @com.google.api.client.json.JsonString private java.lang.Long diskSizeGb; /** * Specifies the disk type to use to create the instance. If not specified, the default is pd- * standard, specified using the full URL. For example: * * https://www.googleapis.com/compute/v1/projects/project/zones/zone/diskTypes/pd-standard * * Other values include pd-ssd and local-ssd. If you define this field, you can provide either the * full or partial URL. For example, the following are valid values: - * https://www.googleapis.com/compute/v1/projects/project/zones/zone/diskTypes/diskType - * projects/project/zones/zone/diskTypes/diskType - zones/zone/diskTypes/diskType * The value may be {@code null}. */ @com.google.api.client.util.Key private java.lang.String diskType; /** * The source image used to create this disk. If the source image is deleted, this field will not * be set. * * To create a disk with one of the public operating system images, specify the image by its * family name. For example, specify family/debian-8 to use the latest Debian 8 image: * * projects/debian-cloud/global/images/family/debian-8 * * Alternatively, use a specific version of a public operating system image: * * projects/debian-cloud/global/images/debian-8-jessie-vYYYYMMDD * * To create a disk with a private image that you created, specify the image name in the following * format: * * global/images/my-private-image * * You can also specify a private image by its image family, which returns the latest version of * the image in that family. Replace the image name with family/family-name: * * global/images/family/my-private-family * The value may be {@code null}. */ @com.google.api.client.util.Key private java.lang.String sourceImage; /** * The customer-supplied encryption key of the source image. Required if the source image is * protected by a customer-supplied encryption key. * * Instance templates do not store customer-supplied encryption keys, so you cannot create disks * for instances in a managed instance group if the source images are encrypted with your own * keys. * The value may be {@code null}. */ @com.google.api.client.util.Key private CustomerEncryptionKey sourceImageEncryptionKey; /** * Specifies the disk name. If not specified, the default is to use the name of the instance. * @return value or {@code null} for none */ public java.lang.String getDiskName() { return diskName; } /** * Specifies the disk name. If not specified, the default is to use the name of the instance. * @param diskName diskName or {@code null} for none */ public AttachedDiskInitializeParams setDiskName(java.lang.String diskName) { this.diskName = diskName; return this; } /** * Specifies the size of the disk in base-2 GB. * @return value or {@code null} for none */ public java.lang.Long getDiskSizeGb() { return diskSizeGb; } /** * Specifies the size of the disk in base-2 GB. * @param diskSizeGb diskSizeGb or {@code null} for none */ public AttachedDiskInitializeParams setDiskSizeGb(java.lang.Long diskSizeGb) { this.diskSizeGb = diskSizeGb; return this; } /** * Specifies the disk type to use to create the instance. If not specified, the default is pd- * standard, specified using the full URL. For example: * * https://www.googleapis.com/compute/v1/projects/project/zones/zone/diskTypes/pd-standard * * Other values include pd-ssd and local-ssd. If you define this field, you can provide either the * full or partial URL. For example, the following are valid values: - * https://www.googleapis.com/compute/v1/projects/project/zones/zone/diskTypes/diskType - * projects/project/zones/zone/diskTypes/diskType - zones/zone/diskTypes/diskType * @return value or {@code null} for none */ public java.lang.String getDiskType() { return diskType; } /** * Specifies the disk type to use to create the instance. If not specified, the default is pd- * standard, specified using the full URL. For example: * * https://www.googleapis.com/compute/v1/projects/project/zones/zone/diskTypes/pd-standard * * Other values include pd-ssd and local-ssd. If you define this field, you can provide either the * full or partial URL. For example, the following are valid values: - * https://www.googleapis.com/compute/v1/projects/project/zones/zone/diskTypes/diskType - * projects/project/zones/zone/diskTypes/diskType - zones/zone/diskTypes/diskType * @param diskType diskType or {@code null} for none */ public AttachedDiskInitializeParams setDiskType(java.lang.String diskType) { this.diskType = diskType; return this; } /** * The source image used to create this disk. If the source image is deleted, this field will not * be set. * * To create a disk with one of the public operating system images, specify the image by its * family name. For example, specify family/debian-8 to use the latest Debian 8 image: * * projects/debian-cloud/global/images/family/debian-8 * * Alternatively, use a specific version of a public operating system image: * * projects/debian-cloud/global/images/debian-8-jessie-vYYYYMMDD * * To create a disk with a private image that you created, specify the image name in the following * format: * * global/images/my-private-image * * You can also specify a private image by its image family, which returns the latest version of * the image in that family. Replace the image name with family/family-name: * * global/images/family/my-private-family * @return value or {@code null} for none */ public java.lang.String getSourceImage() { return sourceImage; } /** * The source image used to create this disk. If the source image is deleted, this field will not * be set. * * To create a disk with one of the public operating system images, specify the image by its * family name. For example, specify family/debian-8 to use the latest Debian 8 image: * * projects/debian-cloud/global/images/family/debian-8 * * Alternatively, use a specific version of a public operating system image: * * projects/debian-cloud/global/images/debian-8-jessie-vYYYYMMDD * * To create a disk with a private image that you created, specify the image name in the following * format: * * global/images/my-private-image * * You can also specify a private image by its image family, which returns the latest version of * the image in that family. Replace the image name with family/family-name: * * global/images/family/my-private-family * @param sourceImage sourceImage or {@code null} for none */ public AttachedDiskInitializeParams setSourceImage(java.lang.String sourceImage) { this.sourceImage = sourceImage; return this; } /** * The customer-supplied encryption key of the source image. Required if the source image is * protected by a customer-supplied encryption key. * * Instance templates do not store customer-supplied encryption keys, so you cannot create disks * for instances in a managed instance group if the source images are encrypted with your own * keys. * @return value or {@code null} for none */ public CustomerEncryptionKey getSourceImageEncryptionKey() { return sourceImageEncryptionKey; } /** * The customer-supplied encryption key of the source image. Required if the source image is * protected by a customer-supplied encryption key. * * Instance templates do not store customer-supplied encryption keys, so you cannot create disks * for instances in a managed instance group if the source images are encrypted with your own * keys. * @param sourceImageEncryptionKey sourceImageEncryptionKey or {@code null} for none */ public AttachedDiskInitializeParams setSourceImageEncryptionKey(CustomerEncryptionKey sourceImageEncryptionKey) { this.sourceImageEncryptionKey = sourceImageEncryptionKey; return this; } @Override public AttachedDiskInitializeParams set(String fieldName, Object value) { return (AttachedDiskInitializeParams) super.set(fieldName, value); } @Override public AttachedDiskInitializeParams clone() { return (AttachedDiskInitializeParams) super.clone(); } }




© 2015 - 2025 Weber Informatics LLC | Privacy Policy