public static final class LibraryItemsTypes.CreateSpec.Builder
extends java.lang.Object
LibraryItemsTypes.CreateSpec
.Constructor and Description |
---|
Builder(java.lang.String sourceVm,
java.lang.String name,
java.lang.String library)
Constructor with parameters for the required properties of
LibraryItemsTypes.CreateSpec . |
Modifier and Type | Method and Description |
---|---|
LibraryItemsTypes.CreateSpec |
build() |
LibraryItemsTypes.CreateSpec.Builder |
setDescription(java.lang.String description)
Description of the library item.
|
LibraryItemsTypes.CreateSpec.Builder |
setDiskStorage(LibraryItemsTypes.CreateSpecDiskStorage diskStorage)
Storage specification for the virtual machine template's disks.
|
LibraryItemsTypes.CreateSpec.Builder |
setDiskStorageOverrides(java.util.Map<java.lang.String,LibraryItemsTypes.CreateSpecDiskStorage> diskStorageOverrides)
Storage specification for individual disks in the virtual machine template.
|
LibraryItemsTypes.CreateSpec.Builder |
setPlacement(LibraryItemsTypes.CreatePlacementSpec placement)
Information used to place the virtual machine template.
|
LibraryItemsTypes.CreateSpec.Builder |
setVmHomeStorage(LibraryItemsTypes.CreateSpecVmHomeStorage vmHomeStorage)
Storage location for the virtual machine template's configuration and log files.
|
public Builder(java.lang.String sourceVm, java.lang.String name, java.lang.String library)
LibraryItemsTypes.CreateSpec
.public LibraryItemsTypes.CreateSpec.Builder setDescription(java.lang.String description)
null
, the newly created library item has the same description as the
source virtual machine.description
- New value for the property.public LibraryItemsTypes.CreateSpec.Builder setVmHomeStorage(LibraryItemsTypes.CreateSpecVmHomeStorage vmHomeStorage)
null
, the virtual machine template's configuration and log files are
placed on the default storage backing associated with the library specified by
getLibrary()
.vmHomeStorage
- New value for the property.public LibraryItemsTypes.CreateSpec.Builder setDiskStorage(LibraryItemsTypes.CreateSpecDiskStorage diskStorage)
getDiskStorageOverrides()
and getDiskStorage()
are
null
, the virtual machine template's disks are placed in the default
storage backing associated with the library specified by getLibrary()
.
If getDiskStorageOverrides()
is null
and getDiskStorage()
is specified, all of the virtual machine template's disks are
created with the storage spec specified by getDiskStorage()
.
If
getDiskStorageOverrides()
is specified and getDiskStorage()
is
null
, disks with identifiers that are not in getDiskStorageOverrides()
are placed in the default storage backing associated
with the library specified by getLibrary()
.
If both getDiskStorageOverrides()
and getDiskStorage()
are specified, disks
with identifiers that are not in getDiskStorageOverrides()
are created
with the storage spec specified by getDiskStorage()
.
diskStorage
- New value for the property.public LibraryItemsTypes.CreateSpec.Builder setDiskStorageOverrides(java.util.Map<java.lang.String,LibraryItemsTypes.CreateSpecDiskStorage> diskStorageOverrides)
getDiskStorageOverrides()
and getDiskStorage()
are
null
, the virtual machine template's disks are placed in the default
storage backing associated with the library specified by getLibrary()
.
If getDiskStorageOverrides()
is null
and getDiskStorage()
is specified, all of the virtual machine template's disks are
created with the storage spec specified by getDiskStorage()
.
If
getDiskStorageOverrides()
is specified and getDiskStorage()
is
null
, disks with identifiers that are not in getDiskStorageOverrides()
are placed in the default storage backing associated
with the library specified by getLibrary()
.
If both getDiskStorageOverrides()
and getDiskStorage()
are specified, disks
with identifiers that are not in getDiskStorageOverrides()
are created
with the storage spec specified by getDiskStorage()
.
diskStorageOverrides
- New value for the property.
When clients pass a value of this class as a parameter, the key in the property
Map
must be an identifier for the resource type: com.vmware.vcenter.vm.hardware.Disk
. When methods return a value of this class
as a return value, the key in the property Map
will be an
identifier for the resource type: com.vmware.vcenter.vm.hardware.Disk
.public LibraryItemsTypes.CreateSpec.Builder setPlacement(LibraryItemsTypes.CreatePlacementSpec placement)
null
, the system will place the virtual machine template on a suitable
resource.
If specified, each property will be used for placement. If the properties result in disjoint placement, the operation will fail. If the properties along with the placement values of the source virtual machine result in disjoint placement, the operation will fail.
placement
- New value for the property.public LibraryItemsTypes.CreateSpec build()