// Code generated by go-swagger; DO NOT EDIT.

package models

// This file was generated by the swagger tool.
// Editing this file might prove futile when you re-run the swagger generate command

import (
	"context"
	"encoding/json"

	"github.com/go-openapi/errors"
	"github.com/go-openapi/strfmt"
	"github.com/go-openapi/validate"
)

// HashicorpCloudVault20200420SnapshotState SnapshotState represents the lifecycle of snapshots
//
// swagger:model hashicorp.cloud.vault_20200420.Snapshot.State
type HashicorpCloudVault20200420SnapshotState string

func NewHashicorpCloudVault20200420SnapshotState(value HashicorpCloudVault20200420SnapshotState) *HashicorpCloudVault20200420SnapshotState {
	return &value
}

// Pointer returns a pointer to a freshly-allocated HashicorpCloudVault20200420SnapshotState.
func (m HashicorpCloudVault20200420SnapshotState) Pointer() *HashicorpCloudVault20200420SnapshotState {
	return &m
}

const (

	// HashicorpCloudVault20200420SnapshotStateUNSET captures enum value "UNSET"
	HashicorpCloudVault20200420SnapshotStateUNSET HashicorpCloudVault20200420SnapshotState = "UNSET"

	// HashicorpCloudVault20200420SnapshotStatePENDING captures enum value "PENDING"
	HashicorpCloudVault20200420SnapshotStatePENDING HashicorpCloudVault20200420SnapshotState = "PENDING"

	// HashicorpCloudVault20200420SnapshotStateCREATING captures enum value "CREATING"
	HashicorpCloudVault20200420SnapshotStateCREATING HashicorpCloudVault20200420SnapshotState = "CREATING"

	// HashicorpCloudVault20200420SnapshotStateSTORED captures enum value "STORED"
	HashicorpCloudVault20200420SnapshotStateSTORED HashicorpCloudVault20200420SnapshotState = "STORED"

	// HashicorpCloudVault20200420SnapshotStateFAILED captures enum value "FAILED"
	HashicorpCloudVault20200420SnapshotStateFAILED HashicorpCloudVault20200420SnapshotState = "FAILED"

	// HashicorpCloudVault20200420SnapshotStateDELETING captures enum value "DELETING"
	HashicorpCloudVault20200420SnapshotStateDELETING HashicorpCloudVault20200420SnapshotState = "DELETING"
)

// for schema
var hashicorpCloudVault20200420SnapshotStateEnum []interface{}

func init() {
	var res []HashicorpCloudVault20200420SnapshotState
	if err := json.Unmarshal([]byte(`["UNSET","PENDING","CREATING","STORED","FAILED","DELETING"]`), &res); err != nil {
		panic(err)
	}
	for _, v := range res {
		hashicorpCloudVault20200420SnapshotStateEnum = append(hashicorpCloudVault20200420SnapshotStateEnum, v)
	}
}

func (m HashicorpCloudVault20200420SnapshotState) validateHashicorpCloudVault20200420SnapshotStateEnum(path, location string, value HashicorpCloudVault20200420SnapshotState) error {
	if err := validate.EnumCase(path, location, value, hashicorpCloudVault20200420SnapshotStateEnum, true); err != nil {
		return err
	}
	return nil
}

// Validate validates this hashicorp cloud vault 20200420 snapshot state
func (m HashicorpCloudVault20200420SnapshotState) Validate(formats strfmt.Registry) error {
	var res []error

	// value enum
	if err := m.validateHashicorpCloudVault20200420SnapshotStateEnum("", "body", m); err != nil {
		return err
	}

	if len(res) > 0 {
		return errors.CompositeValidationError(res...)
	}
	return nil
}

// ContextValidate validates this hashicorp cloud vault 20200420 snapshot state based on context it is used
func (m HashicorpCloudVault20200420SnapshotState) ContextValidate(ctx context.Context, formats strfmt.Registry) error {
	return nil
}
