Struct: kms.RevokeGrantInput

import "../ibm-cos-sdk-go/service/kms"

Implemented Interfaces

s3crypto.Cipher, s3manager.ReadSeekerWriteTo, request.Validator, s3manager.WriterReadFrom

Structure Field Summary collapse

Service Operations collapse

Structure Field Details

GrantId *string `min:"1" type:"string" required:"true"`

Identifier of the grant to be revoked.

GrantId is a required field

KeyId *string `min:"1" type:"string" required:"true"`

A unique identifier for the KMS key associated with the grant. To get the key ID and key ARN for a KMS key, use ListKeys or DescribeKey.

Specify the key ID or key ARN of the KMS key. To specify a KMS key in a different Amazon Web Services account, you must use the key ARN.

For example:

  • Key ID: 1234abcd-12ab-34cd-56ef-1234567890ab

  • Key ARN: arn:aws:kms:us-east-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab

To get the key ID and key ARN for a KMS key, use ListKeys or DescribeKey.

KeyId is a required field

_ struct{} `type:"structure"`

Method Details

func (s RevokeGrantInput) GoString() string

GoString returns the string representation.

API parameter values that are decorated as “sensitive” in the API will not be included in the string output. The member name will be present, but the value will be replaced with “sensitive”.



16109
16110
16111
// File 'service/kms/api.go', line 16109

func (s RevokeGrantInput) GoString() string { return s.String() }

func (s *RevokeGrantInput) SetGrantId(v string) *RevokeGrantInput

SetGrantId sets the GrantId field's value.



16136
16137
16138
16139
// File 'service/kms/api.go', line 16136

func (s *RevokeGrantInput) SetGrantId(v string) *RevokeGrantInput { s.GrantId = &v return s }

func (s *RevokeGrantInput) SetKeyId(v string) *RevokeGrantInput

SetKeyId sets the KeyId field's value.



16142
16143
16144
16145
// File 'service/kms/api.go', line 16142

func (s *RevokeGrantInput) SetKeyId(v string) *RevokeGrantInput { s.KeyId = &v return s }

func (s RevokeGrantInput) String() string

String returns the string representation.

API parameter values that are decorated as “sensitive” in the API will not be included in the string output. The member name will be present, but the value will be replaced with “sensitive”.



16100
16101
16102
// File 'service/kms/api.go', line 16100

func (s RevokeGrantInput) String() string { return awsutil.Prettify(s) }

func (s *RevokeGrantInput) Validate() error

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



16114
16115
16116
16117
16118
16119
16120
16121
16122
16123
16124
16125
16126
16127
16128
16129
16130
16131
16132
16133
// File 'service/kms/api.go', line 16114

func (s *RevokeGrantInput) Validate() error { invalidParams := request.ErrInvalidParams{Context: "RevokeGrantInput"} if s.GrantId == nil { invalidParams.Add(request.NewErrParamRequired("GrantId")) } if s.GrantId != nil && len(*s.GrantId) < 1 { invalidParams.Add(request.NewErrParamMinLen("GrantId", 1)) } if s.KeyId == nil { invalidParams.Add(request.NewErrParamRequired("KeyId")) } if s.KeyId != nil && len(*s.KeyId) < 1 { invalidParams.Add(request.NewErrParamMinLen("KeyId", 1)) } if invalidParams.Len() > 0 { return invalidParams } return nil }