| 1 |
// Code generated by private/model/cli/gen-api/main.go. DO NOT EDIT. |
| 2 |
|
| 3 |
// Package greengrassv2iface provides an interface to enable mocking the AWS IoT Greengrass V2 service client |
| 4 |
// for testing your code. |
| 5 |
// |
| 6 |
// It is important to note that this interface will have breaking changes |
| 7 |
// when the service model is updated and adds new API operations, paginators, |
| 8 |
// and waiters. |
| 9 |
package greengrassv2iface |
| 10 |
|
| 11 |
import ( |
| 12 |
"github.com/aws/aws-sdk-go/aws" |
| 13 |
"github.com/aws/aws-sdk-go/aws/request" |
| 14 |
"github.com/aws/aws-sdk-go/service/greengrassv2" |
| 15 |
) |
| 16 |
|
| 17 |
// GreengrassV2API provides an interface to enable mocking the |
| 18 |
// greengrassv2.GreengrassV2 service client's API operation, |
| 19 |
// paginators, and waiters. This make unit testing your code that calls out |
| 20 |
// to the SDK's service client's calls easier. |
| 21 |
// |
| 22 |
// The best way to use this interface is so the SDK's service client's calls |
| 23 |
// can be stubbed out for unit testing your code with the SDK without needing |
| 24 |
// to inject custom request handlers into the SDK's request pipeline. |
| 25 |
// |
| 26 |
// // myFunc uses an SDK service client to make a request to |
| 27 |
// // AWS IoT Greengrass V2. |
| 28 |
// func myFunc(svc greengrassv2iface.GreengrassV2API) bool { |
| 29 |
// // Make svc.AssociateServiceRoleToAccount request |
| 30 |
// } |
| 31 |
// |
| 32 |
// func main() { |
| 33 |
// sess := session.New() |
| 34 |
// svc := greengrassv2.New(sess) |
| 35 |
// |
| 36 |
// myFunc(svc) |
| 37 |
// } |
| 38 |
// |
| 39 |
// In your _test.go file: |
| 40 |
// |
| 41 |
// // Define a mock struct to be used in your unit tests of myFunc. |
| 42 |
// type mockGreengrassV2Client struct { |
| 43 |
// greengrassv2iface.GreengrassV2API |
| 44 |
// } |
| 45 |
// func (m *mockGreengrassV2Client) AssociateServiceRoleToAccount(input *greengrassv2.AssociateServiceRoleToAccountInput) (*greengrassv2.AssociateServiceRoleToAccountOutput, error) { |
| 46 |
// // mock response/functionality |
| 47 |
// } |
| 48 |
// |
| 49 |
// func TestMyFunc(t *testing.T) { |
| 50 |
// // Setup Test |
| 51 |
// mockSvc := &mockGreengrassV2Client{} |
| 52 |
// |
| 53 |
// myfunc(mockSvc) |
| 54 |
// |
| 55 |
// // Verify myFunc's functionality |
| 56 |
// } |
| 57 |
// |
| 58 |
// It is important to note that this interface will have breaking changes |
| 59 |
// when the service model is updated and adds new API operations, paginators, |
| 60 |
// and waiters. Its suggested to use the pattern above for testing, or using |
| 61 |
// tooling to generate mocks to satisfy the interfaces. |
| 62 |
type GreengrassV2API interface { |
| 63 |
AssociateServiceRoleToAccount(*greengrassv2.AssociateServiceRoleToAccountInput) (*greengrassv2.AssociateServiceRoleToAccountOutput, error) |
| 64 |
AssociateServiceRoleToAccountWithContext(aws.Context, *greengrassv2.AssociateServiceRoleToAccountInput, ...request.Option) (*greengrassv2.AssociateServiceRoleToAccountOutput, error) |
| 65 |
AssociateServiceRoleToAccountRequest(*greengrassv2.AssociateServiceRoleToAccountInput) (*request.Request, *greengrassv2.AssociateServiceRoleToAccountOutput) |
| 66 |
|
| 67 |
BatchAssociateClientDeviceWithCoreDevice(*greengrassv2.BatchAssociateClientDeviceWithCoreDeviceInput) (*greengrassv2.BatchAssociateClientDeviceWithCoreDeviceOutput, error) |
| 68 |
BatchAssociateClientDeviceWithCoreDeviceWithContext(aws.Context, *greengrassv2.BatchAssociateClientDeviceWithCoreDeviceInput, ...request.Option) (*greengrassv2.BatchAssociateClientDeviceWithCoreDeviceOutput, error) |
| 69 |
BatchAssociateClientDeviceWithCoreDeviceRequest(*greengrassv2.BatchAssociateClientDeviceWithCoreDeviceInput) (*request.Request, *greengrassv2.BatchAssociateClientDeviceWithCoreDeviceOutput) |
| 70 |
|
| 71 |
BatchDisassociateClientDeviceFromCoreDevice(*greengrassv2.BatchDisassociateClientDeviceFromCoreDeviceInput) (*greengrassv2.BatchDisassociateClientDeviceFromCoreDeviceOutput, error) |
| 72 |
BatchDisassociateClientDeviceFromCoreDeviceWithContext(aws.Context, *greengrassv2.BatchDisassociateClientDeviceFromCoreDeviceInput, ...request.Option) (*greengrassv2.BatchDisassociateClientDeviceFromCoreDeviceOutput, error) |
| 73 |
BatchDisassociateClientDeviceFromCoreDeviceRequest(*greengrassv2.BatchDisassociateClientDeviceFromCoreDeviceInput) (*request.Request, *greengrassv2.BatchDisassociateClientDeviceFromCoreDeviceOutput) |
| 74 |
|
| 75 |
CancelDeployment(*greengrassv2.CancelDeploymentInput) (*greengrassv2.CancelDeploymentOutput, error) |
| 76 |
CancelDeploymentWithContext(aws.Context, *greengrassv2.CancelDeploymentInput, ...request.Option) (*greengrassv2.CancelDeploymentOutput, error) |
| 77 |
CancelDeploymentRequest(*greengrassv2.CancelDeploymentInput) (*request.Request, *greengrassv2.CancelDeploymentOutput) |
| 78 |
|
| 79 |
CreateComponentVersion(*greengrassv2.CreateComponentVersionInput) (*greengrassv2.CreateComponentVersionOutput, error) |
| 80 |
CreateComponentVersionWithContext(aws.Context, *greengrassv2.CreateComponentVersionInput, ...request.Option) (*greengrassv2.CreateComponentVersionOutput, error) |
| 81 |
CreateComponentVersionRequest(*greengrassv2.CreateComponentVersionInput) (*request.Request, *greengrassv2.CreateComponentVersionOutput) |
| 82 |
|
| 83 |
CreateDeployment(*greengrassv2.CreateDeploymentInput) (*greengrassv2.CreateDeploymentOutput, error) |
| 84 |
CreateDeploymentWithContext(aws.Context, *greengrassv2.CreateDeploymentInput, ...request.Option) (*greengrassv2.CreateDeploymentOutput, error) |
| 85 |
CreateDeploymentRequest(*greengrassv2.CreateDeploymentInput) (*request.Request, *greengrassv2.CreateDeploymentOutput) |
| 86 |
|
| 87 |
DeleteComponent(*greengrassv2.DeleteComponentInput) (*greengrassv2.DeleteComponentOutput, error) |
| 88 |
DeleteComponentWithContext(aws.Context, *greengrassv2.DeleteComponentInput, ...request.Option) (*greengrassv2.DeleteComponentOutput, error) |
| 89 |
DeleteComponentRequest(*greengrassv2.DeleteComponentInput) (*request.Request, *greengrassv2.DeleteComponentOutput) |
| 90 |
|
| 91 |
DeleteCoreDevice(*greengrassv2.DeleteCoreDeviceInput) (*greengrassv2.DeleteCoreDeviceOutput, error) |
| 92 |
DeleteCoreDeviceWithContext(aws.Context, *greengrassv2.DeleteCoreDeviceInput, ...request.Option) (*greengrassv2.DeleteCoreDeviceOutput, error) |
| 93 |
DeleteCoreDeviceRequest(*greengrassv2.DeleteCoreDeviceInput) (*request.Request, *greengrassv2.DeleteCoreDeviceOutput) |
| 94 |
|
| 95 |
DeleteDeployment(*greengrassv2.DeleteDeploymentInput) (*greengrassv2.DeleteDeploymentOutput, error) |
| 96 |
DeleteDeploymentWithContext(aws.Context, *greengrassv2.DeleteDeploymentInput, ...request.Option) (*greengrassv2.DeleteDeploymentOutput, error) |
| 97 |
DeleteDeploymentRequest(*greengrassv2.DeleteDeploymentInput) (*request.Request, *greengrassv2.DeleteDeploymentOutput) |
| 98 |
|
| 99 |
DescribeComponent(*greengrassv2.DescribeComponentInput) (*greengrassv2.DescribeComponentOutput, error) |
| 100 |
DescribeComponentWithContext(aws.Context, *greengrassv2.DescribeComponentInput, ...request.Option) (*greengrassv2.DescribeComponentOutput, error) |
| 101 |
DescribeComponentRequest(*greengrassv2.DescribeComponentInput) (*request.Request, *greengrassv2.DescribeComponentOutput) |
| 102 |
|
| 103 |
DisassociateServiceRoleFromAccount(*greengrassv2.DisassociateServiceRoleFromAccountInput) (*greengrassv2.DisassociateServiceRoleFromAccountOutput, error) |
| 104 |
DisassociateServiceRoleFromAccountWithContext(aws.Context, *greengrassv2.DisassociateServiceRoleFromAccountInput, ...request.Option) (*greengrassv2.DisassociateServiceRoleFromAccountOutput, error) |
| 105 |
DisassociateServiceRoleFromAccountRequest(*greengrassv2.DisassociateServiceRoleFromAccountInput) (*request.Request, *greengrassv2.DisassociateServiceRoleFromAccountOutput) |
| 106 |
|
| 107 |
GetComponent(*greengrassv2.GetComponentInput) (*greengrassv2.GetComponentOutput, error) |
| 108 |
GetComponentWithContext(aws.Context, *greengrassv2.GetComponentInput, ...request.Option) (*greengrassv2.GetComponentOutput, error) |
| 109 |
GetComponentRequest(*greengrassv2.GetComponentInput) (*request.Request, *greengrassv2.GetComponentOutput) |
| 110 |
|
| 111 |
GetComponentVersionArtifact(*greengrassv2.GetComponentVersionArtifactInput) (*greengrassv2.GetComponentVersionArtifactOutput, error) |
| 112 |
GetComponentVersionArtifactWithContext(aws.Context, *greengrassv2.GetComponentVersionArtifactInput, ...request.Option) (*greengrassv2.GetComponentVersionArtifactOutput, error) |
| 113 |
GetComponentVersionArtifactRequest(*greengrassv2.GetComponentVersionArtifactInput) (*request.Request, *greengrassv2.GetComponentVersionArtifactOutput) |
| 114 |
|
| 115 |
GetConnectivityInfo(*greengrassv2.GetConnectivityInfoInput) (*greengrassv2.GetConnectivityInfoOutput, error) |
| 116 |
GetConnectivityInfoWithContext(aws.Context, *greengrassv2.GetConnectivityInfoInput, ...request.Option) (*greengrassv2.GetConnectivityInfoOutput, error) |
| 117 |
GetConnectivityInfoRequest(*greengrassv2.GetConnectivityInfoInput) (*request.Request, *greengrassv2.GetConnectivityInfoOutput) |
| 118 |
|
| 119 |
GetCoreDevice(*greengrassv2.GetCoreDeviceInput) (*greengrassv2.GetCoreDeviceOutput, error) |
| 120 |
GetCoreDeviceWithContext(aws.Context, *greengrassv2.GetCoreDeviceInput, ...request.Option) (*greengrassv2.GetCoreDeviceOutput, error) |
| 121 |
GetCoreDeviceRequest(*greengrassv2.GetCoreDeviceInput) (*request.Request, *greengrassv2.GetCoreDeviceOutput) |
| 122 |
|
| 123 |
GetDeployment(*greengrassv2.GetDeploymentInput) (*greengrassv2.GetDeploymentOutput, error) |
| 124 |
GetDeploymentWithContext(aws.Context, *greengrassv2.GetDeploymentInput, ...request.Option) (*greengrassv2.GetDeploymentOutput, error) |
| 125 |
GetDeploymentRequest(*greengrassv2.GetDeploymentInput) (*request.Request, *greengrassv2.GetDeploymentOutput) |
| 126 |
|
| 127 |
GetServiceRoleForAccount(*greengrassv2.GetServiceRoleForAccountInput) (*greengrassv2.GetServiceRoleForAccountOutput, error) |
| 128 |
GetServiceRoleForAccountWithContext(aws.Context, *greengrassv2.GetServiceRoleForAccountInput, ...request.Option) (*greengrassv2.GetServiceRoleForAccountOutput, error) |
| 129 |
GetServiceRoleForAccountRequest(*greengrassv2.GetServiceRoleForAccountInput) (*request.Request, *greengrassv2.GetServiceRoleForAccountOutput) |
| 130 |
|
| 131 |
ListClientDevicesAssociatedWithCoreDevice(*greengrassv2.ListClientDevicesAssociatedWithCoreDeviceInput) (*greengrassv2.ListClientDevicesAssociatedWithCoreDeviceOutput, error) |
| 132 |
ListClientDevicesAssociatedWithCoreDeviceWithContext(aws.Context, *greengrassv2.ListClientDevicesAssociatedWithCoreDeviceInput, ...request.Option) (*greengrassv2.ListClientDevicesAssociatedWithCoreDeviceOutput, error) |
| 133 |
ListClientDevicesAssociatedWithCoreDeviceRequest(*greengrassv2.ListClientDevicesAssociatedWithCoreDeviceInput) (*request.Request, *greengrassv2.ListClientDevicesAssociatedWithCoreDeviceOutput) |
| 134 |
|
| 135 |
ListClientDevicesAssociatedWithCoreDevicePages(*greengrassv2.ListClientDevicesAssociatedWithCoreDeviceInput, func(*greengrassv2.ListClientDevicesAssociatedWithCoreDeviceOutput, bool) bool) error |
| 136 |
ListClientDevicesAssociatedWithCoreDevicePagesWithContext(aws.Context, *greengrassv2.ListClientDevicesAssociatedWithCoreDeviceInput, func(*greengrassv2.ListClientDevicesAssociatedWithCoreDeviceOutput, bool) bool, ...request.Option) error |
| 137 |
|
| 138 |
ListComponentVersions(*greengrassv2.ListComponentVersionsInput) (*greengrassv2.ListComponentVersionsOutput, error) |
| 139 |
ListComponentVersionsWithContext(aws.Context, *greengrassv2.ListComponentVersionsInput, ...request.Option) (*greengrassv2.ListComponentVersionsOutput, error) |
| 140 |
ListComponentVersionsRequest(*greengrassv2.ListComponentVersionsInput) (*request.Request, *greengrassv2.ListComponentVersionsOutput) |
| 141 |
|
| 142 |
ListComponentVersionsPages(*greengrassv2.ListComponentVersionsInput, func(*greengrassv2.ListComponentVersionsOutput, bool) bool) error |
| 143 |
ListComponentVersionsPagesWithContext(aws.Context, *greengrassv2.ListComponentVersionsInput, func(*greengrassv2.ListComponentVersionsOutput, bool) bool, ...request.Option) error |
| 144 |
|
| 145 |
ListComponents(*greengrassv2.ListComponentsInput) (*greengrassv2.ListComponentsOutput, error) |
| 146 |
ListComponentsWithContext(aws.Context, *greengrassv2.ListComponentsInput, ...request.Option) (*greengrassv2.ListComponentsOutput, error) |
| 147 |
ListComponentsRequest(*greengrassv2.ListComponentsInput) (*request.Request, *greengrassv2.ListComponentsOutput) |
| 148 |
|
| 149 |
ListComponentsPages(*greengrassv2.ListComponentsInput, func(*greengrassv2.ListComponentsOutput, bool) bool) error |
| 150 |
ListComponentsPagesWithContext(aws.Context, *greengrassv2.ListComponentsInput, func(*greengrassv2.ListComponentsOutput, bool) bool, ...request.Option) error |
| 151 |
|
| 152 |
ListCoreDevices(*greengrassv2.ListCoreDevicesInput) (*greengrassv2.ListCoreDevicesOutput, error) |
| 153 |
ListCoreDevicesWithContext(aws.Context, *greengrassv2.ListCoreDevicesInput, ...request.Option) (*greengrassv2.ListCoreDevicesOutput, error) |
| 154 |
ListCoreDevicesRequest(*greengrassv2.ListCoreDevicesInput) (*request.Request, *greengrassv2.ListCoreDevicesOutput) |
| 155 |
|
| 156 |
ListCoreDevicesPages(*greengrassv2.ListCoreDevicesInput, func(*greengrassv2.ListCoreDevicesOutput, bool) bool) error |
| 157 |
ListCoreDevicesPagesWithContext(aws.Context, *greengrassv2.ListCoreDevicesInput, func(*greengrassv2.ListCoreDevicesOutput, bool) bool, ...request.Option) error |
| 158 |
|
| 159 |
ListDeployments(*greengrassv2.ListDeploymentsInput) (*greengrassv2.ListDeploymentsOutput, error) |
| 160 |
ListDeploymentsWithContext(aws.Context, *greengrassv2.ListDeploymentsInput, ...request.Option) (*greengrassv2.ListDeploymentsOutput, error) |
| 161 |
ListDeploymentsRequest(*greengrassv2.ListDeploymentsInput) (*request.Request, *greengrassv2.ListDeploymentsOutput) |
| 162 |
|
| 163 |
ListDeploymentsPages(*greengrassv2.ListDeploymentsInput, func(*greengrassv2.ListDeploymentsOutput, bool) bool) error |
| 164 |
ListDeploymentsPagesWithContext(aws.Context, *greengrassv2.ListDeploymentsInput, func(*greengrassv2.ListDeploymentsOutput, bool) bool, ...request.Option) error |
| 165 |
|
| 166 |
ListEffectiveDeployments(*greengrassv2.ListEffectiveDeploymentsInput) (*greengrassv2.ListEffectiveDeploymentsOutput, error) |
| 167 |
ListEffectiveDeploymentsWithContext(aws.Context, *greengrassv2.ListEffectiveDeploymentsInput, ...request.Option) (*greengrassv2.ListEffectiveDeploymentsOutput, error) |
| 168 |
ListEffectiveDeploymentsRequest(*greengrassv2.ListEffectiveDeploymentsInput) (*request.Request, *greengrassv2.ListEffectiveDeploymentsOutput) |
| 169 |
|
| 170 |
ListEffectiveDeploymentsPages(*greengrassv2.ListEffectiveDeploymentsInput, func(*greengrassv2.ListEffectiveDeploymentsOutput, bool) bool) error |
| 171 |
ListEffectiveDeploymentsPagesWithContext(aws.Context, *greengrassv2.ListEffectiveDeploymentsInput, func(*greengrassv2.ListEffectiveDeploymentsOutput, bool) bool, ...request.Option) error |
| 172 |
|
| 173 |
ListInstalledComponents(*greengrassv2.ListInstalledComponentsInput) (*greengrassv2.ListInstalledComponentsOutput, error) |
| 174 |
ListInstalledComponentsWithContext(aws.Context, *greengrassv2.ListInstalledComponentsInput, ...request.Option) (*greengrassv2.ListInstalledComponentsOutput, error) |
| 175 |
ListInstalledComponentsRequest(*greengrassv2.ListInstalledComponentsInput) (*request.Request, *greengrassv2.ListInstalledComponentsOutput) |
| 176 |
|
| 177 |
ListInstalledComponentsPages(*greengrassv2.ListInstalledComponentsInput, func(*greengrassv2.ListInstalledComponentsOutput, bool) bool) error |
| 178 |
ListInstalledComponentsPagesWithContext(aws.Context, *greengrassv2.ListInstalledComponentsInput, func(*greengrassv2.ListInstalledComponentsOutput, bool) bool, ...request.Option) error |
| 179 |
|
| 180 |
ListTagsForResource(*greengrassv2.ListTagsForResourceInput) (*greengrassv2.ListTagsForResourceOutput, error) |
| 181 |
ListTagsForResourceWithContext(aws.Context, *greengrassv2.ListTagsForResourceInput, ...request.Option) (*greengrassv2.ListTagsForResourceOutput, error) |
| 182 |
ListTagsForResourceRequest(*greengrassv2.ListTagsForResourceInput) (*request.Request, *greengrassv2.ListTagsForResourceOutput) |
| 183 |
|
| 184 |
ResolveComponentCandidates(*greengrassv2.ResolveComponentCandidatesInput) (*greengrassv2.ResolveComponentCandidatesOutput, error) |
| 185 |
ResolveComponentCandidatesWithContext(aws.Context, *greengrassv2.ResolveComponentCandidatesInput, ...request.Option) (*greengrassv2.ResolveComponentCandidatesOutput, error) |
| 186 |
ResolveComponentCandidatesRequest(*greengrassv2.ResolveComponentCandidatesInput) (*request.Request, *greengrassv2.ResolveComponentCandidatesOutput) |
| 187 |
|
| 188 |
TagResource(*greengrassv2.TagResourceInput) (*greengrassv2.TagResourceOutput, error) |
| 189 |
TagResourceWithContext(aws.Context, *greengrassv2.TagResourceInput, ...request.Option) (*greengrassv2.TagResourceOutput, error) |
| 190 |
TagResourceRequest(*greengrassv2.TagResourceInput) (*request.Request, *greengrassv2.TagResourceOutput) |
| 191 |
|
| 192 |
UntagResource(*greengrassv2.UntagResourceInput) (*greengrassv2.UntagResourceOutput, error) |
| 193 |
UntagResourceWithContext(aws.Context, *greengrassv2.UntagResourceInput, ...request.Option) (*greengrassv2.UntagResourceOutput, error) |
| 194 |
UntagResourceRequest(*greengrassv2.UntagResourceInput) (*request.Request, *greengrassv2.UntagResourceOutput) |
| 195 |
|
| 196 |
UpdateConnectivityInfo(*greengrassv2.UpdateConnectivityInfoInput) (*greengrassv2.UpdateConnectivityInfoOutput, error) |
| 197 |
UpdateConnectivityInfoWithContext(aws.Context, *greengrassv2.UpdateConnectivityInfoInput, ...request.Option) (*greengrassv2.UpdateConnectivityInfoOutput, error) |
| 198 |
UpdateConnectivityInfoRequest(*greengrassv2.UpdateConnectivityInfoInput) (*request.Request, *greengrassv2.UpdateConnectivityInfoOutput) |
| 199 |
} |
| 200 |
|
| 201 |
var _ GreengrassV2API = (*greengrassv2.GreengrassV2)(nil) |