mirror of
https://github.com/aptly-dev/aptly.git
synced 2026-06-01 04:40:38 +00:00
Upgrade AWS SDK to the latest version
This commit is contained in:
+34
-34
@@ -1,6 +1,5 @@
|
||||
// THIS FILE IS AUTOMATICALLY GENERATED. DO NOT EDIT.
|
||||
// Code generated by private/model/cli/gen-api/main.go. DO NOT EDIT.
|
||||
|
||||
// Package costandusagereportservice provides a client for AWS Cost and Usage Report Service.
|
||||
package costandusagereportservice
|
||||
|
||||
import (
|
||||
@@ -13,19 +12,18 @@ const opDeleteReportDefinition = "DeleteReportDefinition"
|
||||
|
||||
// DeleteReportDefinitionRequest generates a "aws/request.Request" representing the
|
||||
// client's request for the DeleteReportDefinition operation. The "output" return
|
||||
// value can be used to capture response data after the request's "Send" method
|
||||
// is called.
|
||||
// value will be populated with the request's response once the request complets
|
||||
// successfuly.
|
||||
//
|
||||
// See DeleteReportDefinition for usage and error information.
|
||||
// Use "Send" method on the returned Request to send the API call to the service.
|
||||
// the "output" return value is not valid until after Send returns without error.
|
||||
//
|
||||
// Creating a request object using this method should be used when you want to inject
|
||||
// custom logic into the request's lifecycle using a custom handler, or if you want to
|
||||
// access properties on the request object before or after sending the request. If
|
||||
// you just want the service response, call the DeleteReportDefinition method directly
|
||||
// instead.
|
||||
// See DeleteReportDefinition for more information on using the DeleteReportDefinition
|
||||
// API call, and error handling.
|
||||
//
|
||||
// This method is useful when you want to inject custom logic or configuration
|
||||
// into the SDK's request lifecycle. Such as custom headers, or retry logic.
|
||||
//
|
||||
// Note: You must call the "Send" method on the returned request object in order
|
||||
// to execute the request.
|
||||
//
|
||||
// // Example sending a request using the DeleteReportDefinitionRequest method.
|
||||
// req, resp := client.DeleteReportDefinitionRequest(params)
|
||||
@@ -98,19 +96,18 @@ const opDescribeReportDefinitions = "DescribeReportDefinitions"
|
||||
|
||||
// DescribeReportDefinitionsRequest generates a "aws/request.Request" representing the
|
||||
// client's request for the DescribeReportDefinitions operation. The "output" return
|
||||
// value can be used to capture response data after the request's "Send" method
|
||||
// is called.
|
||||
// value will be populated with the request's response once the request complets
|
||||
// successfuly.
|
||||
//
|
||||
// See DescribeReportDefinitions for usage and error information.
|
||||
// Use "Send" method on the returned Request to send the API call to the service.
|
||||
// the "output" return value is not valid until after Send returns without error.
|
||||
//
|
||||
// Creating a request object using this method should be used when you want to inject
|
||||
// custom logic into the request's lifecycle using a custom handler, or if you want to
|
||||
// access properties on the request object before or after sending the request. If
|
||||
// you just want the service response, call the DescribeReportDefinitions method directly
|
||||
// instead.
|
||||
// See DescribeReportDefinitions for more information on using the DescribeReportDefinitions
|
||||
// API call, and error handling.
|
||||
//
|
||||
// This method is useful when you want to inject custom logic or configuration
|
||||
// into the SDK's request lifecycle. Such as custom headers, or retry logic.
|
||||
//
|
||||
// Note: You must call the "Send" method on the returned request object in order
|
||||
// to execute the request.
|
||||
//
|
||||
// // Example sending a request using the DescribeReportDefinitionsRequest method.
|
||||
// req, resp := client.DescribeReportDefinitionsRequest(params)
|
||||
@@ -211,8 +208,12 @@ func (c *CostandUsageReportService) DescribeReportDefinitionsPages(input *Descri
|
||||
func (c *CostandUsageReportService) DescribeReportDefinitionsPagesWithContext(ctx aws.Context, input *DescribeReportDefinitionsInput, fn func(*DescribeReportDefinitionsOutput, bool) bool, opts ...request.Option) error {
|
||||
p := request.Pagination{
|
||||
NewRequest: func() (*request.Request, error) {
|
||||
inCpy := *input
|
||||
req, _ := c.DescribeReportDefinitionsRequest(&inCpy)
|
||||
var inCpy *DescribeReportDefinitionsInput
|
||||
if input != nil {
|
||||
tmp := *input
|
||||
inCpy = &tmp
|
||||
}
|
||||
req, _ := c.DescribeReportDefinitionsRequest(inCpy)
|
||||
req.SetContext(ctx)
|
||||
req.ApplyOptions(opts...)
|
||||
return req, nil
|
||||
@@ -230,19 +231,18 @@ const opPutReportDefinition = "PutReportDefinition"
|
||||
|
||||
// PutReportDefinitionRequest generates a "aws/request.Request" representing the
|
||||
// client's request for the PutReportDefinition operation. The "output" return
|
||||
// value can be used to capture response data after the request's "Send" method
|
||||
// is called.
|
||||
// value will be populated with the request's response once the request complets
|
||||
// successfuly.
|
||||
//
|
||||
// See PutReportDefinition for usage and error information.
|
||||
// Use "Send" method on the returned Request to send the API call to the service.
|
||||
// the "output" return value is not valid until after Send returns without error.
|
||||
//
|
||||
// Creating a request object using this method should be used when you want to inject
|
||||
// custom logic into the request's lifecycle using a custom handler, or if you want to
|
||||
// access properties on the request object before or after sending the request. If
|
||||
// you just want the service response, call the PutReportDefinition method directly
|
||||
// instead.
|
||||
// See PutReportDefinition for more information on using the PutReportDefinition
|
||||
// API call, and error handling.
|
||||
//
|
||||
// This method is useful when you want to inject custom logic or configuration
|
||||
// into the SDK's request lifecycle. Such as custom headers, or retry logic.
|
||||
//
|
||||
// Note: You must call the "Send" method on the returned request object in order
|
||||
// to execute the request.
|
||||
//
|
||||
// // Example sending a request using the PutReportDefinitionRequest method.
|
||||
// req, resp := client.PutReportDefinitionRequest(params)
|
||||
|
||||
Generated
Vendored
+2
-2
@@ -1,4 +1,4 @@
|
||||
// THIS FILE IS AUTOMATICALLY GENERATED. DO NOT EDIT.
|
||||
// Code generated by private/model/cli/gen-api/main.go. DO NOT EDIT.
|
||||
|
||||
// Package costandusagereportserviceiface provides an interface to enable mocking the AWS Cost and Usage Report Service service client
|
||||
// for testing your code.
|
||||
@@ -21,7 +21,7 @@ import (
|
||||
//
|
||||
// The best way to use this interface is so the SDK's service client's calls
|
||||
// can be stubbed out for unit testing your code with the SDK without needing
|
||||
// to inject custom request handlers into the the SDK's request pipeline.
|
||||
// to inject custom request handlers into the SDK's request pipeline.
|
||||
//
|
||||
// // myFunc uses an SDK service client to make a request to
|
||||
// // AWS Cost and Usage Report Service.
|
||||
|
||||
+28
@@ -0,0 +1,28 @@
|
||||
// Code generated by private/model/cli/gen-api/main.go. DO NOT EDIT.
|
||||
|
||||
// Package costandusagereportservice provides the client and types for making API
|
||||
// requests to AWS Cost and Usage Report Service.
|
||||
//
|
||||
// All public APIs for AWS Cost and Usage Report service
|
||||
//
|
||||
// See https://docs.aws.amazon.com/goto/WebAPI/cur-2017-01-06 for more information on this service.
|
||||
//
|
||||
// See costandusagereportservice package documentation for more information.
|
||||
// https://docs.aws.amazon.com/sdk-for-go/api/service/costandusagereportservice/
|
||||
//
|
||||
// Using the Client
|
||||
//
|
||||
// To AWS Cost and Usage Report Service with the SDK use the New function to create
|
||||
// a new service client. With that client you can make API requests to the service.
|
||||
// These clients are safe to use concurrently.
|
||||
//
|
||||
// See the SDK's documentation for more information on how to use the SDK.
|
||||
// https://docs.aws.amazon.com/sdk-for-go/api/
|
||||
//
|
||||
// See aws.Config documentation for more information on configuring SDK clients.
|
||||
// https://docs.aws.amazon.com/sdk-for-go/api/aws/#Config
|
||||
//
|
||||
// See the AWS Cost and Usage Report Service client CostandUsageReportService for more
|
||||
// information on creating client for this service.
|
||||
// https://docs.aws.amazon.com/sdk-for-go/api/service/costandusagereportservice/#New
|
||||
package costandusagereportservice
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// THIS FILE IS AUTOMATICALLY GENERATED. DO NOT EDIT.
|
||||
// Code generated by private/model/cli/gen-api/main.go. DO NOT EDIT.
|
||||
|
||||
package costandusagereportservice
|
||||
|
||||
|
||||
Generated
Vendored
-96
@@ -1,96 +0,0 @@
|
||||
// THIS FILE IS AUTOMATICALLY GENERATED. DO NOT EDIT.
|
||||
|
||||
package costandusagereportservice_test
|
||||
|
||||
import (
|
||||
"bytes"
|
||||
"fmt"
|
||||
"time"
|
||||
|
||||
"github.com/aws/aws-sdk-go/aws"
|
||||
"github.com/aws/aws-sdk-go/aws/session"
|
||||
"github.com/aws/aws-sdk-go/service/costandusagereportservice"
|
||||
)
|
||||
|
||||
var _ time.Duration
|
||||
var _ bytes.Buffer
|
||||
|
||||
func ExampleCostandUsageReportService_DeleteReportDefinition() {
|
||||
sess := session.Must(session.NewSession())
|
||||
|
||||
svc := costandusagereportservice.New(sess)
|
||||
|
||||
params := &costandusagereportservice.DeleteReportDefinitionInput{
|
||||
ReportName: aws.String("ReportName"),
|
||||
}
|
||||
resp, err := svc.DeleteReportDefinition(params)
|
||||
|
||||
if err != nil {
|
||||
// Print the error, cast err to awserr.Error to get the Code and
|
||||
// Message from an error.
|
||||
fmt.Println(err.Error())
|
||||
return
|
||||
}
|
||||
|
||||
// Pretty-print the response data.
|
||||
fmt.Println(resp)
|
||||
}
|
||||
|
||||
func ExampleCostandUsageReportService_DescribeReportDefinitions() {
|
||||
sess := session.Must(session.NewSession())
|
||||
|
||||
svc := costandusagereportservice.New(sess)
|
||||
|
||||
params := &costandusagereportservice.DescribeReportDefinitionsInput{
|
||||
MaxResults: aws.Int64(1),
|
||||
NextToken: aws.String("GenericString"),
|
||||
}
|
||||
resp, err := svc.DescribeReportDefinitions(params)
|
||||
|
||||
if err != nil {
|
||||
// Print the error, cast err to awserr.Error to get the Code and
|
||||
// Message from an error.
|
||||
fmt.Println(err.Error())
|
||||
return
|
||||
}
|
||||
|
||||
// Pretty-print the response data.
|
||||
fmt.Println(resp)
|
||||
}
|
||||
|
||||
func ExampleCostandUsageReportService_PutReportDefinition() {
|
||||
sess := session.Must(session.NewSession())
|
||||
|
||||
svc := costandusagereportservice.New(sess)
|
||||
|
||||
params := &costandusagereportservice.PutReportDefinitionInput{
|
||||
ReportDefinition: &costandusagereportservice.ReportDefinition{ // Required
|
||||
AdditionalSchemaElements: []*string{ // Required
|
||||
aws.String("SchemaElement"), // Required
|
||||
// More values...
|
||||
},
|
||||
Compression: aws.String("CompressionFormat"), // Required
|
||||
Format: aws.String("ReportFormat"), // Required
|
||||
ReportName: aws.String("ReportName"), // Required
|
||||
S3Bucket: aws.String("S3Bucket"), // Required
|
||||
S3Prefix: aws.String("S3Prefix"), // Required
|
||||
S3Region: aws.String("AWSRegion"), // Required
|
||||
TimeUnit: aws.String("TimeUnit"), // Required
|
||||
AdditionalArtifacts: []*string{
|
||||
aws.String("AdditionalArtifact"), // Required
|
||||
// More values...
|
||||
},
|
||||
},
|
||||
}
|
||||
resp, err := svc.PutReportDefinition(params)
|
||||
|
||||
if err != nil {
|
||||
// Print the error, cast err to awserr.Error to get the Code and
|
||||
// Message from an error.
|
||||
fmt.Println(err.Error())
|
||||
return
|
||||
}
|
||||
|
||||
// Pretty-print the response data.
|
||||
fmt.Println(resp)
|
||||
}
|
||||
+7
-5
@@ -1,4 +1,4 @@
|
||||
// THIS FILE IS AUTOMATICALLY GENERATED. DO NOT EDIT.
|
||||
// Code generated by private/model/cli/gen-api/main.go. DO NOT EDIT.
|
||||
|
||||
package costandusagereportservice
|
||||
|
||||
@@ -11,10 +11,12 @@ import (
|
||||
"github.com/aws/aws-sdk-go/private/protocol/jsonrpc"
|
||||
)
|
||||
|
||||
// All public APIs for AWS Cost and Usage Report service
|
||||
// The service client's operations are safe to be used concurrently.
|
||||
// It is not safe to mutate any of the client's properties though.
|
||||
// Please also see https://docs.aws.amazon.com/goto/WebAPI/cur-2017-01-06
|
||||
// CostandUsageReportService provides the API operation methods for making requests to
|
||||
// AWS Cost and Usage Report Service. See this package's package overview docs
|
||||
// for details on the service.
|
||||
//
|
||||
// CostandUsageReportService methods are safe to use concurrently. It is not safe to
|
||||
// modify mutate any of the struct's properties though.
|
||||
type CostandUsageReportService struct {
|
||||
*client.Client
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user