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

// HashicorpCloudWaypointV20241122VariableType - STRING: Defaults to treat type as a string
//
// swagger:model hashicorp.cloud.waypoint.v20241122.Variable.Type
type HashicorpCloudWaypointV20241122VariableType string

func NewHashicorpCloudWaypointV20241122VariableType(value HashicorpCloudWaypointV20241122VariableType) *HashicorpCloudWaypointV20241122VariableType {
	return &value
}

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

const (

	// HashicorpCloudWaypointV20241122VariableTypeSTRING captures enum value "STRING"
	HashicorpCloudWaypointV20241122VariableTypeSTRING HashicorpCloudWaypointV20241122VariableType = "STRING"

	// HashicorpCloudWaypointV20241122VariableTypeBOOL captures enum value "BOOL"
	HashicorpCloudWaypointV20241122VariableTypeBOOL HashicorpCloudWaypointV20241122VariableType = "BOOL"

	// HashicorpCloudWaypointV20241122VariableTypeINT captures enum value "INT"
	HashicorpCloudWaypointV20241122VariableTypeINT HashicorpCloudWaypointV20241122VariableType = "INT"
)

// for schema
var hashicorpCloudWaypointV20241122VariableTypeEnum []interface{}

func init() {
	var res []HashicorpCloudWaypointV20241122VariableType
	if err := json.Unmarshal([]byte(`["STRING","BOOL","INT"]`), &res); err != nil {
		panic(err)
	}
	for _, v := range res {
		hashicorpCloudWaypointV20241122VariableTypeEnum = append(hashicorpCloudWaypointV20241122VariableTypeEnum, v)
	}
}

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

// Validate validates this hashicorp cloud waypoint v20241122 variable type
func (m HashicorpCloudWaypointV20241122VariableType) Validate(formats strfmt.Registry) error {
	var res []error

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

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

// ContextValidate validates this hashicorp cloud waypoint v20241122 variable type based on context it is used
func (m HashicorpCloudWaypointV20241122VariableType) ContextValidate(ctx context.Context, formats strfmt.Registry) error {
	return nil
}
