// 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"
)

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

func NewHashicorpCloudVault20201125SnapshotState(value HashicorpCloudVault20201125SnapshotState) *HashicorpCloudVault20201125SnapshotState {
	return &value
}

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

const (

	// HashicorpCloudVault20201125SnapshotStateSNAPSHOTSTATEINVALID captures enum value "SNAPSHOT_STATE_INVALID"
	HashicorpCloudVault20201125SnapshotStateSNAPSHOTSTATEINVALID HashicorpCloudVault20201125SnapshotState = "SNAPSHOT_STATE_INVALID"

	// HashicorpCloudVault20201125SnapshotStatePENDING captures enum value "PENDING"
	HashicorpCloudVault20201125SnapshotStatePENDING HashicorpCloudVault20201125SnapshotState = "PENDING"

	// HashicorpCloudVault20201125SnapshotStateCREATING captures enum value "CREATING"
	HashicorpCloudVault20201125SnapshotStateCREATING HashicorpCloudVault20201125SnapshotState = "CREATING"

	// HashicorpCloudVault20201125SnapshotStateSTORED captures enum value "STORED"
	HashicorpCloudVault20201125SnapshotStateSTORED HashicorpCloudVault20201125SnapshotState = "STORED"

	// HashicorpCloudVault20201125SnapshotStateFAILED captures enum value "FAILED"
	HashicorpCloudVault20201125SnapshotStateFAILED HashicorpCloudVault20201125SnapshotState = "FAILED"

	// HashicorpCloudVault20201125SnapshotStateDELETING captures enum value "DELETING"
	HashicorpCloudVault20201125SnapshotStateDELETING HashicorpCloudVault20201125SnapshotState = "DELETING"
)

// for schema
var hashicorpCloudVault20201125SnapshotStateEnum []interface{}

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

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

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

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

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

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