AWS SDK for Go (PILOT)
API Reference

PREVIEW DOCUMENTATION - This is a preview of a new format for the AWS SDK for Go API Reference documentation. For the current AWS SDK for Go API Reference, see https://docs.aws.amazon.com/sdk-for-go/api/.

We welcome your feedback on this new version of the documentation. Send your comments to aws-sdkdocs-feedback@amazon.com.

StopInstancesInput

import "github.com/aws/aws-sdk-go/service/ec2"

type StopInstancesInput struct { DryRun *bool `locationName:"dryRun" type:"boolean"` Force *bool `locationName:"force" type:"boolean"` Hibernate *bool `type:"boolean"` InstanceIds []*string `locationName:"InstanceId" locationNameList:"InstanceId" type:"list" required:"true"` }

DryRun

Type: *bool

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

Force

Type: *bool

Forces the instances to stop. The instances do not have an opportunity to flush file system caches or file system metadata. If you use this option, you must perform file system check and repair procedures. This option is not recommended for Windows instances.

Default: false

Hibernate

Type: *bool

Hibernates the instance if the instance was enabled for hibernation at launch. If the instance cannot hibernate successfully, a normal shutdown occurs. For more information, see Hibernate Your Instance (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/Hibernate.html) in the Amazon Elastic Compute Cloud User Guide.

Default: false

InstanceIds

Type: []*string

One or more instance IDs.

InstanceIds is a required field

Method

GoString

func (s StopInstancesInput) GoString() string

GoString returns the string representation

SetDryRun

func (s *StopInstancesInput) SetDryRun(v bool) *StopInstancesInput

SetDryRun sets the DryRun field's value.

SetForce

func (s *StopInstancesInput) SetForce(v bool) *StopInstancesInput

SetForce sets the Force field's value.

SetHibernate

func (s *StopInstancesInput) SetHibernate(v bool) *StopInstancesInput

SetHibernate sets the Hibernate field's value.

SetInstanceIds

func (s *StopInstancesInput) SetInstanceIds(v []*string) *StopInstancesInput

SetInstanceIds sets the InstanceIds field's value.

String

func (s StopInstancesInput) String() string

String returns the string representation

Validate

func (s *StopInstancesInput) Validate() error

Validate inspects the fields of the type to determine if they are valid.

On this page: