// Code generated by volcengine with private/model/cli/gen-api/main.go. DO NOT EDIT.

package autoscaling

import (
	"k8s.io/autoscaler/cluster-autoscaler/cloudprovider/volcengine/volcengine-go-sdk/volcengine"
	"k8s.io/autoscaler/cluster-autoscaler/cloudprovider/volcengine/volcengine-go-sdk/volcengine/request"
	"k8s.io/autoscaler/cluster-autoscaler/cloudprovider/volcengine/volcengine-go-sdk/volcengine/response"
	"k8s.io/autoscaler/cluster-autoscaler/cloudprovider/volcengine/volcengine-go-sdk/volcengine/volcengineutil"
)

const opEnableScalingGroupCommon = "EnableScalingGroup"

// EnableScalingGroupCommonRequest generates a "volcengine/request.Request" representing the
// client's request for the EnableScalingGroupCommon operation. The "output" return
// value will be populated with the EnableScalingGroupCommon request's response once the request completes
// successfully.
//
// Use "Send" method on the returned EnableScalingGroupCommon Request to send the API call to the service.
// the "output" return value is not valid until after EnableScalingGroupCommon Send returns without error.
//
// See EnableScalingGroupCommon for more information on using the EnableScalingGroupCommon
// API call, and error handling.
//
//	// Example sending a request using the EnableScalingGroupCommonRequest method.
//	req, resp := client.EnableScalingGroupCommonRequest(params)
//
//	err := req.Send()
//	if err == nil { // resp is now filled
//	    fmt.Println(resp)
//	}
func (c *AUTOSCALING) EnableScalingGroupCommonRequest(input *map[string]interface{}) (req *request.Request, output *map[string]interface{}) {
	op := &request.Operation{
		Name:       opEnableScalingGroupCommon,
		HTTPMethod: "GET",
		HTTPPath:   "/",
	}

	if input == nil {
		input = &map[string]interface{}{}
	}

	output = &map[string]interface{}{}
	req = c.newRequest(op, input, output)

	return
}

// EnableScalingGroupCommon API operation for AUTO_SCALING.
//
// Returns volcengineerr.Error for service API and SDK errors. Use runtime type assertions
// with volcengineerr.Error's Code and Message methods to get detailed information about
// the error.
//
// See the VOLCENGINE API reference guide for AUTO_SCALING's
// API operation EnableScalingGroupCommon for usage and error information.
func (c *AUTOSCALING) EnableScalingGroupCommon(input *map[string]interface{}) (*map[string]interface{}, error) {
	req, out := c.EnableScalingGroupCommonRequest(input)
	return out, req.Send()
}

// EnableScalingGroupCommonWithContext is the same as EnableScalingGroupCommon with the addition of
// the ability to pass a context and additional request options.
//
// See EnableScalingGroupCommon for details on how to use this API operation.
//
// The context must be non-nil and will be used for request cancellation. If the context is nil a panic will occur.
// In the future the SDK may create sub-contexts for http.Requests. See https://golang.org/pkg/context/
// for more information on using Contexts.
func (c *AUTOSCALING) EnableScalingGroupCommonWithContext(ctx volcengine.Context, input *map[string]interface{}, opts ...request.Option) (*map[string]interface{}, error) {
	req, out := c.EnableScalingGroupCommonRequest(input)
	req.SetContext(ctx)
	req.ApplyOptions(opts...)
	return out, req.Send()
}

const opEnableScalingGroup = "EnableScalingGroup"

// EnableScalingGroupRequest generates a "volcengine/request.Request" representing the
// client's request for the EnableScalingGroup operation. The "output" return
// value will be populated with the EnableScalingGroupCommon request's response once the request completes
// successfully.
//
// Use "Send" method on the returned EnableScalingGroupCommon Request to send the API call to the service.
// the "output" return value is not valid until after EnableScalingGroupCommon Send returns without error.
//
// See EnableScalingGroup for more information on using the EnableScalingGroup
// API call, and error handling.
//
//	// Example sending a request using the EnableScalingGroupRequest method.
//	req, resp := client.EnableScalingGroupRequest(params)
//
//	err := req.Send()
//	if err == nil { // resp is now filled
//	    fmt.Println(resp)
//	}
func (c *AUTOSCALING) EnableScalingGroupRequest(input *EnableScalingGroupInput) (req *request.Request, output *EnableScalingGroupOutput) {
	op := &request.Operation{
		Name:       opEnableScalingGroup,
		HTTPMethod: "GET",
		HTTPPath:   "/",
	}

	if input == nil {
		input = &EnableScalingGroupInput{}
	}

	output = &EnableScalingGroupOutput{}
	req = c.newRequest(op, input, output)

	return
}

// EnableScalingGroup API operation for AUTO_SCALING.
//
// Returns volcengineerr.Error for service API and SDK errors. Use runtime type assertions
// with volcengineerr.Error's Code and Message methods to get detailed information about
// the error.
//
// See the VOLCENGINE API reference guide for AUTO_SCALING's
// API operation EnableScalingGroup for usage and error information.
func (c *AUTOSCALING) EnableScalingGroup(input *EnableScalingGroupInput) (*EnableScalingGroupOutput, error) {
	req, out := c.EnableScalingGroupRequest(input)
	return out, req.Send()
}

// EnableScalingGroupWithContext is the same as EnableScalingGroup with the addition of
// the ability to pass a context and additional request options.
//
// See EnableScalingGroup for details on how to use this API operation.
//
// The context must be non-nil and will be used for request cancellation. Ifthe context is nil a panic will occur.
// In the future the SDK may create sub-contexts for http.Requests. See https://golang.org/pkg/context/
// for more information on using Contexts.
func (c *AUTOSCALING) EnableScalingGroupWithContext(ctx volcengine.Context, input *EnableScalingGroupInput, opts ...request.Option) (*EnableScalingGroupOutput, error) {
	req, out := c.EnableScalingGroupRequest(input)
	req.SetContext(ctx)
	req.ApplyOptions(opts...)
	return out, req.Send()
}

type EnableScalingGroupInput struct {
	_ struct{} `type:"structure"`

	ScalingGroupId *string `type:"string"`
}

// String returns the string representation
func (s EnableScalingGroupInput) String() string {
	return volcengineutil.Prettify(s)
}

// GoString returns the string representation
func (s EnableScalingGroupInput) GoString() string {
	return s.String()
}

// SetScalingGroupId sets the ScalingGroupId field's value.
func (s *EnableScalingGroupInput) SetScalingGroupId(v string) *EnableScalingGroupInput {
	s.ScalingGroupId = &v
	return s
}

type EnableScalingGroupOutput struct {
	_ struct{} `type:"structure"`

	Metadata *response.ResponseMetadata

	ScalingGroupId *string `type:"string"`
}

// String returns the string representation
func (s EnableScalingGroupOutput) String() string {
	return volcengineutil.Prettify(s)
}

// GoString returns the string representation
func (s EnableScalingGroupOutput) GoString() string {
	return s.String()
}

// SetScalingGroupId sets the ScalingGroupId field's value.
func (s *EnableScalingGroupOutput) SetScalingGroupId(v string) *EnableScalingGroupOutput {
	s.ScalingGroupId = &v
	return s
}
