// 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 StorageAccountsFileServicesShare_Spec struct {
	Name string `json:"name,omitempty"`

	// Properties: Properties of the file share.
	Properties *FileShareProperties `json:"properties,omitempty"`
}

var _ genruntime.ARMResourceSpec = &StorageAccountsFileServicesShare_Spec{}

// GetAPIVersion returns the ARM API version of the resource. This is always "2022-09-01"
func (share StorageAccountsFileServicesShare_Spec) GetAPIVersion() string {
	return "2022-09-01"
}

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

// GetType returns the ARM Type of the resource. This is always "Microsoft.Storage/storageAccounts/fileServices/shares"
func (share *StorageAccountsFileServicesShare_Spec) GetType() string {
	return "Microsoft.Storage/storageAccounts/fileServices/shares"
}

// The properties of the file share.
type FileShareProperties struct {
	// AccessTier: Access tier for specific share. GpV2 account can choose between TransactionOptimized (default), Hot, and
	// Cool. FileStorage account can choose Premium.
	AccessTier *FileShareProperties_AccessTier `json:"accessTier,omitempty"`

	// EnabledProtocols: The authentication protocol that is used for the file share. Can only be specified when creating a
	// share.
	EnabledProtocols *FileShareProperties_EnabledProtocols `json:"enabledProtocols,omitempty"`

	// Metadata: A name-value pair to associate with the share as metadata.
	Metadata map[string]string `json:"metadata"`

	// RootSquash: The property is for NFS share only. The default is NoRootSquash.
	RootSquash *FileShareProperties_RootSquash `json:"rootSquash,omitempty"`

	// ShareQuota: The maximum size of the share, in gigabytes. Must be greater than 0, and less than or equal to 5TB (5120).
	// For Large File Shares, the maximum size is 102400.
	ShareQuota *int `json:"shareQuota,omitempty"`

	// SignedIdentifiers: List of stored access policies specified on the share.
	SignedIdentifiers []SignedIdentifier `json:"signedIdentifiers"`
}

// +kubebuilder:validation:Enum={"Cool","Hot","Premium","TransactionOptimized"}
type FileShareProperties_AccessTier string

const (
	FileShareProperties_AccessTier_Cool                 = FileShareProperties_AccessTier("Cool")
	FileShareProperties_AccessTier_Hot                  = FileShareProperties_AccessTier("Hot")
	FileShareProperties_AccessTier_Premium              = FileShareProperties_AccessTier("Premium")
	FileShareProperties_AccessTier_TransactionOptimized = FileShareProperties_AccessTier("TransactionOptimized")
)

// Mapping from string to FileShareProperties_AccessTier
var fileShareProperties_AccessTier_Values = map[string]FileShareProperties_AccessTier{
	"cool":                 FileShareProperties_AccessTier_Cool,
	"hot":                  FileShareProperties_AccessTier_Hot,
	"premium":              FileShareProperties_AccessTier_Premium,
	"transactionoptimized": FileShareProperties_AccessTier_TransactionOptimized,
}

// +kubebuilder:validation:Enum={"NFS","SMB"}
type FileShareProperties_EnabledProtocols string

const (
	FileShareProperties_EnabledProtocols_NFS = FileShareProperties_EnabledProtocols("NFS")
	FileShareProperties_EnabledProtocols_SMB = FileShareProperties_EnabledProtocols("SMB")
)

// Mapping from string to FileShareProperties_EnabledProtocols
var fileShareProperties_EnabledProtocols_Values = map[string]FileShareProperties_EnabledProtocols{
	"nfs": FileShareProperties_EnabledProtocols_NFS,
	"smb": FileShareProperties_EnabledProtocols_SMB,
}

// +kubebuilder:validation:Enum={"AllSquash","NoRootSquash","RootSquash"}
type FileShareProperties_RootSquash string

const (
	FileShareProperties_RootSquash_AllSquash    = FileShareProperties_RootSquash("AllSquash")
	FileShareProperties_RootSquash_NoRootSquash = FileShareProperties_RootSquash("NoRootSquash")
	FileShareProperties_RootSquash_RootSquash   = FileShareProperties_RootSquash("RootSquash")
)

// Mapping from string to FileShareProperties_RootSquash
var fileShareProperties_RootSquash_Values = map[string]FileShareProperties_RootSquash{
	"allsquash":    FileShareProperties_RootSquash_AllSquash,
	"norootsquash": FileShareProperties_RootSquash_NoRootSquash,
	"rootsquash":   FileShareProperties_RootSquash_RootSquash,
}

type SignedIdentifier struct {
	// AccessPolicy: Access policy
	AccessPolicy *AccessPolicy `json:"accessPolicy,omitempty"`

	// Id: An unique identifier of the stored access policy.
	Id *string `json:"id,omitempty"`
}

type AccessPolicy struct {
	// ExpiryTime: Expiry time of the access policy
	ExpiryTime *string `json:"expiryTime,omitempty"`

	// Permission: List of abbreviated permissions.
	Permission *string `json:"permission,omitempty"`

	// StartTime: Start time of the access policy
	StartTime *string `json:"startTime,omitempty"`
}
