github.com/aavshr/aws-sdk-go@v1.41.3/service/codeguruprofiler/codeguruprofileriface/interface.go (about) 1 // Code generated by private/model/cli/gen-api/main.go. DO NOT EDIT. 2 3 // Package codeguruprofileriface provides an interface to enable mocking the Amazon CodeGuru Profiler 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 codeguruprofileriface 10 11 import ( 12 "github.com/aavshr/aws-sdk-go/aws" 13 "github.com/aavshr/aws-sdk-go/aws/request" 14 "github.com/aavshr/aws-sdk-go/service/codeguruprofiler" 15 ) 16 17 // CodeGuruProfilerAPI provides an interface to enable mocking the 18 // codeguruprofiler.CodeGuruProfiler 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 // // Amazon CodeGuru Profiler. 28 // func myFunc(svc codeguruprofileriface.CodeGuruProfilerAPI) bool { 29 // // Make svc.AddNotificationChannels request 30 // } 31 // 32 // func main() { 33 // sess := session.New() 34 // svc := codeguruprofiler.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 mockCodeGuruProfilerClient struct { 43 // codeguruprofileriface.CodeGuruProfilerAPI 44 // } 45 // func (m *mockCodeGuruProfilerClient) AddNotificationChannels(input *codeguruprofiler.AddNotificationChannelsInput) (*codeguruprofiler.AddNotificationChannelsOutput, error) { 46 // // mock response/functionality 47 // } 48 // 49 // func TestMyFunc(t *testing.T) { 50 // // Setup Test 51 // mockSvc := &mockCodeGuruProfilerClient{} 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 CodeGuruProfilerAPI interface { 63 AddNotificationChannels(*codeguruprofiler.AddNotificationChannelsInput) (*codeguruprofiler.AddNotificationChannelsOutput, error) 64 AddNotificationChannelsWithContext(aws.Context, *codeguruprofiler.AddNotificationChannelsInput, ...request.Option) (*codeguruprofiler.AddNotificationChannelsOutput, error) 65 AddNotificationChannelsRequest(*codeguruprofiler.AddNotificationChannelsInput) (*request.Request, *codeguruprofiler.AddNotificationChannelsOutput) 66 67 BatchGetFrameMetricData(*codeguruprofiler.BatchGetFrameMetricDataInput) (*codeguruprofiler.BatchGetFrameMetricDataOutput, error) 68 BatchGetFrameMetricDataWithContext(aws.Context, *codeguruprofiler.BatchGetFrameMetricDataInput, ...request.Option) (*codeguruprofiler.BatchGetFrameMetricDataOutput, error) 69 BatchGetFrameMetricDataRequest(*codeguruprofiler.BatchGetFrameMetricDataInput) (*request.Request, *codeguruprofiler.BatchGetFrameMetricDataOutput) 70 71 ConfigureAgent(*codeguruprofiler.ConfigureAgentInput) (*codeguruprofiler.ConfigureAgentOutput, error) 72 ConfigureAgentWithContext(aws.Context, *codeguruprofiler.ConfigureAgentInput, ...request.Option) (*codeguruprofiler.ConfigureAgentOutput, error) 73 ConfigureAgentRequest(*codeguruprofiler.ConfigureAgentInput) (*request.Request, *codeguruprofiler.ConfigureAgentOutput) 74 75 CreateProfilingGroup(*codeguruprofiler.CreateProfilingGroupInput) (*codeguruprofiler.CreateProfilingGroupOutput, error) 76 CreateProfilingGroupWithContext(aws.Context, *codeguruprofiler.CreateProfilingGroupInput, ...request.Option) (*codeguruprofiler.CreateProfilingGroupOutput, error) 77 CreateProfilingGroupRequest(*codeguruprofiler.CreateProfilingGroupInput) (*request.Request, *codeguruprofiler.CreateProfilingGroupOutput) 78 79 DeleteProfilingGroup(*codeguruprofiler.DeleteProfilingGroupInput) (*codeguruprofiler.DeleteProfilingGroupOutput, error) 80 DeleteProfilingGroupWithContext(aws.Context, *codeguruprofiler.DeleteProfilingGroupInput, ...request.Option) (*codeguruprofiler.DeleteProfilingGroupOutput, error) 81 DeleteProfilingGroupRequest(*codeguruprofiler.DeleteProfilingGroupInput) (*request.Request, *codeguruprofiler.DeleteProfilingGroupOutput) 82 83 DescribeProfilingGroup(*codeguruprofiler.DescribeProfilingGroupInput) (*codeguruprofiler.DescribeProfilingGroupOutput, error) 84 DescribeProfilingGroupWithContext(aws.Context, *codeguruprofiler.DescribeProfilingGroupInput, ...request.Option) (*codeguruprofiler.DescribeProfilingGroupOutput, error) 85 DescribeProfilingGroupRequest(*codeguruprofiler.DescribeProfilingGroupInput) (*request.Request, *codeguruprofiler.DescribeProfilingGroupOutput) 86 87 GetFindingsReportAccountSummary(*codeguruprofiler.GetFindingsReportAccountSummaryInput) (*codeguruprofiler.GetFindingsReportAccountSummaryOutput, error) 88 GetFindingsReportAccountSummaryWithContext(aws.Context, *codeguruprofiler.GetFindingsReportAccountSummaryInput, ...request.Option) (*codeguruprofiler.GetFindingsReportAccountSummaryOutput, error) 89 GetFindingsReportAccountSummaryRequest(*codeguruprofiler.GetFindingsReportAccountSummaryInput) (*request.Request, *codeguruprofiler.GetFindingsReportAccountSummaryOutput) 90 91 GetFindingsReportAccountSummaryPages(*codeguruprofiler.GetFindingsReportAccountSummaryInput, func(*codeguruprofiler.GetFindingsReportAccountSummaryOutput, bool) bool) error 92 GetFindingsReportAccountSummaryPagesWithContext(aws.Context, *codeguruprofiler.GetFindingsReportAccountSummaryInput, func(*codeguruprofiler.GetFindingsReportAccountSummaryOutput, bool) bool, ...request.Option) error 93 94 GetNotificationConfiguration(*codeguruprofiler.GetNotificationConfigurationInput) (*codeguruprofiler.GetNotificationConfigurationOutput, error) 95 GetNotificationConfigurationWithContext(aws.Context, *codeguruprofiler.GetNotificationConfigurationInput, ...request.Option) (*codeguruprofiler.GetNotificationConfigurationOutput, error) 96 GetNotificationConfigurationRequest(*codeguruprofiler.GetNotificationConfigurationInput) (*request.Request, *codeguruprofiler.GetNotificationConfigurationOutput) 97 98 GetPolicy(*codeguruprofiler.GetPolicyInput) (*codeguruprofiler.GetPolicyOutput, error) 99 GetPolicyWithContext(aws.Context, *codeguruprofiler.GetPolicyInput, ...request.Option) (*codeguruprofiler.GetPolicyOutput, error) 100 GetPolicyRequest(*codeguruprofiler.GetPolicyInput) (*request.Request, *codeguruprofiler.GetPolicyOutput) 101 102 GetProfile(*codeguruprofiler.GetProfileInput) (*codeguruprofiler.GetProfileOutput, error) 103 GetProfileWithContext(aws.Context, *codeguruprofiler.GetProfileInput, ...request.Option) (*codeguruprofiler.GetProfileOutput, error) 104 GetProfileRequest(*codeguruprofiler.GetProfileInput) (*request.Request, *codeguruprofiler.GetProfileOutput) 105 106 GetRecommendations(*codeguruprofiler.GetRecommendationsInput) (*codeguruprofiler.GetRecommendationsOutput, error) 107 GetRecommendationsWithContext(aws.Context, *codeguruprofiler.GetRecommendationsInput, ...request.Option) (*codeguruprofiler.GetRecommendationsOutput, error) 108 GetRecommendationsRequest(*codeguruprofiler.GetRecommendationsInput) (*request.Request, *codeguruprofiler.GetRecommendationsOutput) 109 110 ListFindingsReports(*codeguruprofiler.ListFindingsReportsInput) (*codeguruprofiler.ListFindingsReportsOutput, error) 111 ListFindingsReportsWithContext(aws.Context, *codeguruprofiler.ListFindingsReportsInput, ...request.Option) (*codeguruprofiler.ListFindingsReportsOutput, error) 112 ListFindingsReportsRequest(*codeguruprofiler.ListFindingsReportsInput) (*request.Request, *codeguruprofiler.ListFindingsReportsOutput) 113 114 ListFindingsReportsPages(*codeguruprofiler.ListFindingsReportsInput, func(*codeguruprofiler.ListFindingsReportsOutput, bool) bool) error 115 ListFindingsReportsPagesWithContext(aws.Context, *codeguruprofiler.ListFindingsReportsInput, func(*codeguruprofiler.ListFindingsReportsOutput, bool) bool, ...request.Option) error 116 117 ListProfileTimes(*codeguruprofiler.ListProfileTimesInput) (*codeguruprofiler.ListProfileTimesOutput, error) 118 ListProfileTimesWithContext(aws.Context, *codeguruprofiler.ListProfileTimesInput, ...request.Option) (*codeguruprofiler.ListProfileTimesOutput, error) 119 ListProfileTimesRequest(*codeguruprofiler.ListProfileTimesInput) (*request.Request, *codeguruprofiler.ListProfileTimesOutput) 120 121 ListProfileTimesPages(*codeguruprofiler.ListProfileTimesInput, func(*codeguruprofiler.ListProfileTimesOutput, bool) bool) error 122 ListProfileTimesPagesWithContext(aws.Context, *codeguruprofiler.ListProfileTimesInput, func(*codeguruprofiler.ListProfileTimesOutput, bool) bool, ...request.Option) error 123 124 ListProfilingGroups(*codeguruprofiler.ListProfilingGroupsInput) (*codeguruprofiler.ListProfilingGroupsOutput, error) 125 ListProfilingGroupsWithContext(aws.Context, *codeguruprofiler.ListProfilingGroupsInput, ...request.Option) (*codeguruprofiler.ListProfilingGroupsOutput, error) 126 ListProfilingGroupsRequest(*codeguruprofiler.ListProfilingGroupsInput) (*request.Request, *codeguruprofiler.ListProfilingGroupsOutput) 127 128 ListProfilingGroupsPages(*codeguruprofiler.ListProfilingGroupsInput, func(*codeguruprofiler.ListProfilingGroupsOutput, bool) bool) error 129 ListProfilingGroupsPagesWithContext(aws.Context, *codeguruprofiler.ListProfilingGroupsInput, func(*codeguruprofiler.ListProfilingGroupsOutput, bool) bool, ...request.Option) error 130 131 ListTagsForResource(*codeguruprofiler.ListTagsForResourceInput) (*codeguruprofiler.ListTagsForResourceOutput, error) 132 ListTagsForResourceWithContext(aws.Context, *codeguruprofiler.ListTagsForResourceInput, ...request.Option) (*codeguruprofiler.ListTagsForResourceOutput, error) 133 ListTagsForResourceRequest(*codeguruprofiler.ListTagsForResourceInput) (*request.Request, *codeguruprofiler.ListTagsForResourceOutput) 134 135 PostAgentProfile(*codeguruprofiler.PostAgentProfileInput) (*codeguruprofiler.PostAgentProfileOutput, error) 136 PostAgentProfileWithContext(aws.Context, *codeguruprofiler.PostAgentProfileInput, ...request.Option) (*codeguruprofiler.PostAgentProfileOutput, error) 137 PostAgentProfileRequest(*codeguruprofiler.PostAgentProfileInput) (*request.Request, *codeguruprofiler.PostAgentProfileOutput) 138 139 PutPermission(*codeguruprofiler.PutPermissionInput) (*codeguruprofiler.PutPermissionOutput, error) 140 PutPermissionWithContext(aws.Context, *codeguruprofiler.PutPermissionInput, ...request.Option) (*codeguruprofiler.PutPermissionOutput, error) 141 PutPermissionRequest(*codeguruprofiler.PutPermissionInput) (*request.Request, *codeguruprofiler.PutPermissionOutput) 142 143 RemoveNotificationChannel(*codeguruprofiler.RemoveNotificationChannelInput) (*codeguruprofiler.RemoveNotificationChannelOutput, error) 144 RemoveNotificationChannelWithContext(aws.Context, *codeguruprofiler.RemoveNotificationChannelInput, ...request.Option) (*codeguruprofiler.RemoveNotificationChannelOutput, error) 145 RemoveNotificationChannelRequest(*codeguruprofiler.RemoveNotificationChannelInput) (*request.Request, *codeguruprofiler.RemoveNotificationChannelOutput) 146 147 RemovePermission(*codeguruprofiler.RemovePermissionInput) (*codeguruprofiler.RemovePermissionOutput, error) 148 RemovePermissionWithContext(aws.Context, *codeguruprofiler.RemovePermissionInput, ...request.Option) (*codeguruprofiler.RemovePermissionOutput, error) 149 RemovePermissionRequest(*codeguruprofiler.RemovePermissionInput) (*request.Request, *codeguruprofiler.RemovePermissionOutput) 150 151 SubmitFeedback(*codeguruprofiler.SubmitFeedbackInput) (*codeguruprofiler.SubmitFeedbackOutput, error) 152 SubmitFeedbackWithContext(aws.Context, *codeguruprofiler.SubmitFeedbackInput, ...request.Option) (*codeguruprofiler.SubmitFeedbackOutput, error) 153 SubmitFeedbackRequest(*codeguruprofiler.SubmitFeedbackInput) (*request.Request, *codeguruprofiler.SubmitFeedbackOutput) 154 155 TagResource(*codeguruprofiler.TagResourceInput) (*codeguruprofiler.TagResourceOutput, error) 156 TagResourceWithContext(aws.Context, *codeguruprofiler.TagResourceInput, ...request.Option) (*codeguruprofiler.TagResourceOutput, error) 157 TagResourceRequest(*codeguruprofiler.TagResourceInput) (*request.Request, *codeguruprofiler.TagResourceOutput) 158 159 UntagResource(*codeguruprofiler.UntagResourceInput) (*codeguruprofiler.UntagResourceOutput, error) 160 UntagResourceWithContext(aws.Context, *codeguruprofiler.UntagResourceInput, ...request.Option) (*codeguruprofiler.UntagResourceOutput, error) 161 UntagResourceRequest(*codeguruprofiler.UntagResourceInput) (*request.Request, *codeguruprofiler.UntagResourceOutput) 162 163 UpdateProfilingGroup(*codeguruprofiler.UpdateProfilingGroupInput) (*codeguruprofiler.UpdateProfilingGroupOutput, error) 164 UpdateProfilingGroupWithContext(aws.Context, *codeguruprofiler.UpdateProfilingGroupInput, ...request.Option) (*codeguruprofiler.UpdateProfilingGroupOutput, error) 165 UpdateProfilingGroupRequest(*codeguruprofiler.UpdateProfilingGroupInput) (*request.Request, *codeguruprofiler.UpdateProfilingGroupOutput) 166 } 167 168 var _ CodeGuruProfilerAPI = (*codeguruprofiler.CodeGuruProfiler)(nil)