// Code generated by azure-service-operator-codegen. DO NOT EDIT.
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT license.
package arm

import "github.com/Azure/azure-service-operator/v2/pkg/genruntime"

type Snapshot_Spec struct {
	// ExtendedLocation: The extended location where the snapshot will be created. Extended location cannot be changed.
	ExtendedLocation *ExtendedLocation `json:"extendedLocation,omitempty"`

	// Location: Resource location
	Location *string `json:"location,omitempty"`
	Name     string  `json:"name,omitempty"`

	// Properties: Snapshot resource properties.
	Properties *SnapshotProperties `json:"properties,omitempty"`

	// Sku: The snapshots sku name. Can be Standard_LRS, Premium_LRS, or Standard_ZRS. This is an optional parameter for
	// incremental  snapshot and the default behavior is the SKU will be set to the same sku as the previous snapshot
	Sku *SnapshotSku `json:"sku,omitempty"`

	// Tags: Resource tags
	Tags map[string]string `json:"tags,omitempty"`
}

var _ genruntime.ARMResourceSpec = &Snapshot_Spec{}

// GetAPIVersion returns the ARM API version of the resource. This is always "2020-09-30"
func (snapshot Snapshot_Spec) GetAPIVersion() string {
	return "2020-09-30"
}

// GetName returns the Name of the resource
func (snapshot *Snapshot_Spec) GetName() string {
	return snapshot.Name
}

// GetType returns the ARM Type of the resource. This is always "Microsoft.Compute/snapshots"
func (snapshot *Snapshot_Spec) GetType() string {
	return "Microsoft.Compute/snapshots"
}

// Snapshot resource properties.
type SnapshotProperties struct {
	// CreationData: Disk source information. CreationData information cannot be changed after the disk has been created.
	CreationData *CreationData `json:"creationData,omitempty"`

	// DiskAccessId: ARM id of the DiskAccess resource for using private endpoints on disks.
	DiskAccessId *string `json:"diskAccessId,omitempty"`

	// DiskSizeGB: If creationData.createOption is Empty, this field is mandatory and it indicates the size of the disk to
	// create. If this field is present for updates or creation with other options, it indicates a resize. Resizes are only
	// allowed if the disk is not attached to a running VM, and can only increase the disk's size.
	DiskSizeGB *int `json:"diskSizeGB,omitempty"`

	// Encryption: Encryption property can be used to encrypt data at rest with customer managed keys or platform managed keys.
	Encryption *Encryption `json:"encryption,omitempty"`

	// EncryptionSettingsCollection: Encryption settings collection used be Azure Disk Encryption, can contain multiple
	// encryption settings per disk or snapshot.
	EncryptionSettingsCollection *EncryptionSettingsCollection `json:"encryptionSettingsCollection,omitempty"`

	// HyperVGeneration: The hypervisor generation of the Virtual Machine. Applicable to OS disks only.
	HyperVGeneration *SnapshotProperties_HyperVGeneration `json:"hyperVGeneration,omitempty"`

	// Incremental: Whether a snapshot is incremental. Incremental snapshots on the same disk occupy less space than full
	// snapshots and can be diffed.
	Incremental *bool `json:"incremental,omitempty"`

	// NetworkAccessPolicy: Policy for accessing the disk via network.
	NetworkAccessPolicy *NetworkAccessPolicy `json:"networkAccessPolicy,omitempty"`

	// OsType: The Operating System type.
	OsType *SnapshotProperties_OsType `json:"osType,omitempty"`

	// PurchasePlan: Purchase plan information for the image from which the source disk for the snapshot was originally created.
	PurchasePlan *PurchasePlan `json:"purchasePlan,omitempty"`
}

// The snapshots sku name. Can be Standard_LRS, Premium_LRS, or Standard_ZRS. This is an optional parameter for incremental
// snapshot and the default behavior is the SKU will be set to the same sku as the previous snapshot
type SnapshotSku struct {
	// Name: The sku name.
	Name *SnapshotSku_Name `json:"name,omitempty"`
}

// +kubebuilder:validation:Enum={"V1","V2"}
type SnapshotProperties_HyperVGeneration string

const (
	SnapshotProperties_HyperVGeneration_V1 = SnapshotProperties_HyperVGeneration("V1")
	SnapshotProperties_HyperVGeneration_V2 = SnapshotProperties_HyperVGeneration("V2")
)

// Mapping from string to SnapshotProperties_HyperVGeneration
var snapshotProperties_HyperVGeneration_Values = map[string]SnapshotProperties_HyperVGeneration{
	"v1": SnapshotProperties_HyperVGeneration_V1,
	"v2": SnapshotProperties_HyperVGeneration_V2,
}

// +kubebuilder:validation:Enum={"Linux","Windows"}
type SnapshotProperties_OsType string

const (
	SnapshotProperties_OsType_Linux   = SnapshotProperties_OsType("Linux")
	SnapshotProperties_OsType_Windows = SnapshotProperties_OsType("Windows")
)

// Mapping from string to SnapshotProperties_OsType
var snapshotProperties_OsType_Values = map[string]SnapshotProperties_OsType{
	"linux":   SnapshotProperties_OsType_Linux,
	"windows": SnapshotProperties_OsType_Windows,
}

// +kubebuilder:validation:Enum={"Premium_LRS","Standard_LRS","Standard_ZRS"}
type SnapshotSku_Name string

const (
	SnapshotSku_Name_Premium_LRS  = SnapshotSku_Name("Premium_LRS")
	SnapshotSku_Name_Standard_LRS = SnapshotSku_Name("Standard_LRS")
	SnapshotSku_Name_Standard_ZRS = SnapshotSku_Name("Standard_ZRS")
)

// Mapping from string to SnapshotSku_Name
var snapshotSku_Name_Values = map[string]SnapshotSku_Name{
	"premium_lrs":  SnapshotSku_Name_Premium_LRS,
	"standard_lrs": SnapshotSku_Name_Standard_LRS,
	"standard_zrs": SnapshotSku_Name_Standard_ZRS,
}
