Vendor aws-sdk-go (dep ensure) (#178)

This commit is contained in:
Onur Filiz
2018-04-27 18:18:36 -07:00
committed by Robbie Zhang
parent 228a1f7a5f
commit 8d67098d06
2785 changed files with 1973570 additions and 25 deletions

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,132 @@
// Code generated by private/model/cli/gen-api/main.go. DO NOT EDIT.
// Package cognitosynciface provides an interface to enable mocking the Amazon Cognito Sync service client
// for testing your code.
//
// It is important to note that this interface will have breaking changes
// when the service model is updated and adds new API operations, paginators,
// and waiters.
package cognitosynciface
import (
"github.com/aws/aws-sdk-go/aws"
"github.com/aws/aws-sdk-go/aws/request"
"github.com/aws/aws-sdk-go/service/cognitosync"
)
// CognitoSyncAPI provides an interface to enable mocking the
// cognitosync.CognitoSync service client's API operation,
// paginators, and waiters. This make unit testing your code that calls out
// to the SDK's service client's calls easier.
//
// 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 SDK's request pipeline.
//
// // myFunc uses an SDK service client to make a request to
// // Amazon Cognito Sync.
// func myFunc(svc cognitosynciface.CognitoSyncAPI) bool {
// // Make svc.BulkPublish request
// }
//
// func main() {
// sess := session.New()
// svc := cognitosync.New(sess)
//
// myFunc(svc)
// }
//
// In your _test.go file:
//
// // Define a mock struct to be used in your unit tests of myFunc.
// type mockCognitoSyncClient struct {
// cognitosynciface.CognitoSyncAPI
// }
// func (m *mockCognitoSyncClient) BulkPublish(input *cognitosync.BulkPublishInput) (*cognitosync.BulkPublishOutput, error) {
// // mock response/functionality
// }
//
// func TestMyFunc(t *testing.T) {
// // Setup Test
// mockSvc := &mockCognitoSyncClient{}
//
// myfunc(mockSvc)
//
// // Verify myFunc's functionality
// }
//
// It is important to note that this interface will have breaking changes
// when the service model is updated and adds new API operations, paginators,
// and waiters. Its suggested to use the pattern above for testing, or using
// tooling to generate mocks to satisfy the interfaces.
type CognitoSyncAPI interface {
BulkPublish(*cognitosync.BulkPublishInput) (*cognitosync.BulkPublishOutput, error)
BulkPublishWithContext(aws.Context, *cognitosync.BulkPublishInput, ...request.Option) (*cognitosync.BulkPublishOutput, error)
BulkPublishRequest(*cognitosync.BulkPublishInput) (*request.Request, *cognitosync.BulkPublishOutput)
DeleteDataset(*cognitosync.DeleteDatasetInput) (*cognitosync.DeleteDatasetOutput, error)
DeleteDatasetWithContext(aws.Context, *cognitosync.DeleteDatasetInput, ...request.Option) (*cognitosync.DeleteDatasetOutput, error)
DeleteDatasetRequest(*cognitosync.DeleteDatasetInput) (*request.Request, *cognitosync.DeleteDatasetOutput)
DescribeDataset(*cognitosync.DescribeDatasetInput) (*cognitosync.DescribeDatasetOutput, error)
DescribeDatasetWithContext(aws.Context, *cognitosync.DescribeDatasetInput, ...request.Option) (*cognitosync.DescribeDatasetOutput, error)
DescribeDatasetRequest(*cognitosync.DescribeDatasetInput) (*request.Request, *cognitosync.DescribeDatasetOutput)
DescribeIdentityPoolUsage(*cognitosync.DescribeIdentityPoolUsageInput) (*cognitosync.DescribeIdentityPoolUsageOutput, error)
DescribeIdentityPoolUsageWithContext(aws.Context, *cognitosync.DescribeIdentityPoolUsageInput, ...request.Option) (*cognitosync.DescribeIdentityPoolUsageOutput, error)
DescribeIdentityPoolUsageRequest(*cognitosync.DescribeIdentityPoolUsageInput) (*request.Request, *cognitosync.DescribeIdentityPoolUsageOutput)
DescribeIdentityUsage(*cognitosync.DescribeIdentityUsageInput) (*cognitosync.DescribeIdentityUsageOutput, error)
DescribeIdentityUsageWithContext(aws.Context, *cognitosync.DescribeIdentityUsageInput, ...request.Option) (*cognitosync.DescribeIdentityUsageOutput, error)
DescribeIdentityUsageRequest(*cognitosync.DescribeIdentityUsageInput) (*request.Request, *cognitosync.DescribeIdentityUsageOutput)
GetBulkPublishDetails(*cognitosync.GetBulkPublishDetailsInput) (*cognitosync.GetBulkPublishDetailsOutput, error)
GetBulkPublishDetailsWithContext(aws.Context, *cognitosync.GetBulkPublishDetailsInput, ...request.Option) (*cognitosync.GetBulkPublishDetailsOutput, error)
GetBulkPublishDetailsRequest(*cognitosync.GetBulkPublishDetailsInput) (*request.Request, *cognitosync.GetBulkPublishDetailsOutput)
GetCognitoEvents(*cognitosync.GetCognitoEventsInput) (*cognitosync.GetCognitoEventsOutput, error)
GetCognitoEventsWithContext(aws.Context, *cognitosync.GetCognitoEventsInput, ...request.Option) (*cognitosync.GetCognitoEventsOutput, error)
GetCognitoEventsRequest(*cognitosync.GetCognitoEventsInput) (*request.Request, *cognitosync.GetCognitoEventsOutput)
GetIdentityPoolConfiguration(*cognitosync.GetIdentityPoolConfigurationInput) (*cognitosync.GetIdentityPoolConfigurationOutput, error)
GetIdentityPoolConfigurationWithContext(aws.Context, *cognitosync.GetIdentityPoolConfigurationInput, ...request.Option) (*cognitosync.GetIdentityPoolConfigurationOutput, error)
GetIdentityPoolConfigurationRequest(*cognitosync.GetIdentityPoolConfigurationInput) (*request.Request, *cognitosync.GetIdentityPoolConfigurationOutput)
ListDatasets(*cognitosync.ListDatasetsInput) (*cognitosync.ListDatasetsOutput, error)
ListDatasetsWithContext(aws.Context, *cognitosync.ListDatasetsInput, ...request.Option) (*cognitosync.ListDatasetsOutput, error)
ListDatasetsRequest(*cognitosync.ListDatasetsInput) (*request.Request, *cognitosync.ListDatasetsOutput)
ListIdentityPoolUsage(*cognitosync.ListIdentityPoolUsageInput) (*cognitosync.ListIdentityPoolUsageOutput, error)
ListIdentityPoolUsageWithContext(aws.Context, *cognitosync.ListIdentityPoolUsageInput, ...request.Option) (*cognitosync.ListIdentityPoolUsageOutput, error)
ListIdentityPoolUsageRequest(*cognitosync.ListIdentityPoolUsageInput) (*request.Request, *cognitosync.ListIdentityPoolUsageOutput)
ListRecords(*cognitosync.ListRecordsInput) (*cognitosync.ListRecordsOutput, error)
ListRecordsWithContext(aws.Context, *cognitosync.ListRecordsInput, ...request.Option) (*cognitosync.ListRecordsOutput, error)
ListRecordsRequest(*cognitosync.ListRecordsInput) (*request.Request, *cognitosync.ListRecordsOutput)
RegisterDevice(*cognitosync.RegisterDeviceInput) (*cognitosync.RegisterDeviceOutput, error)
RegisterDeviceWithContext(aws.Context, *cognitosync.RegisterDeviceInput, ...request.Option) (*cognitosync.RegisterDeviceOutput, error)
RegisterDeviceRequest(*cognitosync.RegisterDeviceInput) (*request.Request, *cognitosync.RegisterDeviceOutput)
SetCognitoEvents(*cognitosync.SetCognitoEventsInput) (*cognitosync.SetCognitoEventsOutput, error)
SetCognitoEventsWithContext(aws.Context, *cognitosync.SetCognitoEventsInput, ...request.Option) (*cognitosync.SetCognitoEventsOutput, error)
SetCognitoEventsRequest(*cognitosync.SetCognitoEventsInput) (*request.Request, *cognitosync.SetCognitoEventsOutput)
SetIdentityPoolConfiguration(*cognitosync.SetIdentityPoolConfigurationInput) (*cognitosync.SetIdentityPoolConfigurationOutput, error)
SetIdentityPoolConfigurationWithContext(aws.Context, *cognitosync.SetIdentityPoolConfigurationInput, ...request.Option) (*cognitosync.SetIdentityPoolConfigurationOutput, error)
SetIdentityPoolConfigurationRequest(*cognitosync.SetIdentityPoolConfigurationInput) (*request.Request, *cognitosync.SetIdentityPoolConfigurationOutput)
SubscribeToDataset(*cognitosync.SubscribeToDatasetInput) (*cognitosync.SubscribeToDatasetOutput, error)
SubscribeToDatasetWithContext(aws.Context, *cognitosync.SubscribeToDatasetInput, ...request.Option) (*cognitosync.SubscribeToDatasetOutput, error)
SubscribeToDatasetRequest(*cognitosync.SubscribeToDatasetInput) (*request.Request, *cognitosync.SubscribeToDatasetOutput)
UnsubscribeFromDataset(*cognitosync.UnsubscribeFromDatasetInput) (*cognitosync.UnsubscribeFromDatasetOutput, error)
UnsubscribeFromDatasetWithContext(aws.Context, *cognitosync.UnsubscribeFromDatasetInput, ...request.Option) (*cognitosync.UnsubscribeFromDatasetOutput, error)
UnsubscribeFromDatasetRequest(*cognitosync.UnsubscribeFromDatasetInput) (*request.Request, *cognitosync.UnsubscribeFromDatasetOutput)
UpdateRecords(*cognitosync.UpdateRecordsInput) (*cognitosync.UpdateRecordsOutput, error)
UpdateRecordsWithContext(aws.Context, *cognitosync.UpdateRecordsInput, ...request.Option) (*cognitosync.UpdateRecordsOutput, error)
UpdateRecordsRequest(*cognitosync.UpdateRecordsInput) (*request.Request, *cognitosync.UpdateRecordsOutput)
}
var _ CognitoSyncAPI = (*cognitosync.CognitoSync)(nil)

View File

@@ -0,0 +1,45 @@
// Code generated by private/model/cli/gen-api/main.go. DO NOT EDIT.
// Package cognitosync provides the client and types for making API
// requests to Amazon Cognito Sync.
//
// Amazon Cognito Sync provides an AWS service and client library that enable
// cross-device syncing of application-related user data. High-level client
// libraries are available for both iOS and Android. You can use these libraries
// to persist data locally so that it's available even if the device is offline.
// Developer credentials don't need to be stored on the mobile device to access
// the service. You can use Amazon Cognito to obtain a normalized user ID and
// credentials. User data is persisted in a dataset that can store up to 1 MB
// of key-value pairs, and you can have up to 20 datasets per user identity.
//
// With Amazon Cognito Sync, the data stored for each identity is accessible
// only to credentials assigned to that identity. In order to use the Cognito
// Sync service, you need to make API calls using credentials retrieved with
// Amazon Cognito Identity service (http://docs.aws.amazon.com/cognitoidentity/latest/APIReference/Welcome.html).
//
// If you want to use Cognito Sync in an Android or iOS application, you will
// probably want to make API calls via the AWS Mobile SDK. To learn more, see
// the Developer Guide for Android (http://docs.aws.amazon.com/mobile/sdkforandroid/developerguide/cognito-sync.html)
// and the Developer Guide for iOS (http://docs.aws.amazon.com/mobile/sdkforios/developerguide/cognito-sync.html).
//
// See https://docs.aws.amazon.com/goto/WebAPI/cognito-sync-2014-06-30 for more information on this service.
//
// See cognitosync package documentation for more information.
// https://docs.aws.amazon.com/sdk-for-go/api/service/cognitosync/
//
// Using the Client
//
// To contact Amazon Cognito Sync 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 Amazon Cognito Sync client CognitoSync for more
// information on creating client for this service.
// https://docs.aws.amazon.com/sdk-for-go/api/service/cognitosync/#New
package cognitosync

View File

@@ -0,0 +1,85 @@
// Code generated by private/model/cli/gen-api/main.go. DO NOT EDIT.
package cognitosync
const (
// ErrCodeAlreadyStreamedException for service response error code
// "AlreadyStreamedException".
//
// An exception thrown when a bulk publish operation is requested less than
// 24 hours after a previous bulk publish operation completed successfully.
ErrCodeAlreadyStreamedException = "AlreadyStreamedException"
// ErrCodeConcurrentModificationException for service response error code
// "ConcurrentModificationException".
//
// Thrown if there are parallel requests to modify a resource.
ErrCodeConcurrentModificationException = "ConcurrentModificationException"
// ErrCodeDuplicateRequestException for service response error code
// "DuplicateRequestException".
//
// An exception thrown when there is an IN_PROGRESS bulk publish operation for
// the given identity pool.
ErrCodeDuplicateRequestException = "DuplicateRequestException"
// ErrCodeInternalErrorException for service response error code
// "InternalErrorException".
//
// Indicates an internal service error.
ErrCodeInternalErrorException = "InternalErrorException"
// ErrCodeInvalidConfigurationException for service response error code
// "InvalidConfigurationException".
ErrCodeInvalidConfigurationException = "InvalidConfigurationException"
// ErrCodeInvalidLambdaFunctionOutputException for service response error code
// "InvalidLambdaFunctionOutputException".
//
// The AWS Lambda function returned invalid output or an exception.
ErrCodeInvalidLambdaFunctionOutputException = "InvalidLambdaFunctionOutputException"
// ErrCodeInvalidParameterException for service response error code
// "InvalidParameterException".
//
// Thrown when a request parameter does not comply with the associated constraints.
ErrCodeInvalidParameterException = "InvalidParameterException"
// ErrCodeLambdaThrottledException for service response error code
// "LambdaThrottledException".
//
// AWS Lambda throttled your account, please contact AWS Support
ErrCodeLambdaThrottledException = "LambdaThrottledException"
// ErrCodeLimitExceededException for service response error code
// "LimitExceededException".
//
// Thrown when the limit on the number of objects or operations has been exceeded.
ErrCodeLimitExceededException = "LimitExceededException"
// ErrCodeNotAuthorizedException for service response error code
// "NotAuthorizedException".
//
// Thrown when a user is not authorized to access the requested resource.
ErrCodeNotAuthorizedException = "NotAuthorizedException"
// ErrCodeResourceConflictException for service response error code
// "ResourceConflictException".
//
// Thrown if an update can't be applied because the resource was changed by
// another call and this would result in a conflict.
ErrCodeResourceConflictException = "ResourceConflictException"
// ErrCodeResourceNotFoundException for service response error code
// "ResourceNotFoundException".
//
// Thrown if the resource doesn't exist.
ErrCodeResourceNotFoundException = "ResourceNotFoundException"
// ErrCodeTooManyRequestsException for service response error code
// "TooManyRequestsException".
//
// Thrown if the request is throttled.
ErrCodeTooManyRequestsException = "TooManyRequestsException"
)

View File

@@ -0,0 +1,94 @@
// Code generated by private/model/cli/gen-api/main.go. DO NOT EDIT.
package cognitosync
import (
"github.com/aws/aws-sdk-go/aws"
"github.com/aws/aws-sdk-go/aws/client"
"github.com/aws/aws-sdk-go/aws/client/metadata"
"github.com/aws/aws-sdk-go/aws/request"
"github.com/aws/aws-sdk-go/aws/signer/v4"
"github.com/aws/aws-sdk-go/private/protocol/restjson"
)
// CognitoSync provides the API operation methods for making requests to
// Amazon Cognito Sync. See this package's package overview docs
// for details on the service.
//
// CognitoSync methods are safe to use concurrently. It is not safe to
// modify mutate any of the struct's properties though.
type CognitoSync struct {
*client.Client
}
// Used for custom client initialization logic
var initClient func(*client.Client)
// Used for custom request initialization logic
var initRequest func(*request.Request)
// Service information constants
const (
ServiceName = "cognito-sync" // Service endpoint prefix API calls made to.
EndpointsID = ServiceName // Service ID for Regions and Endpoints metadata.
)
// New creates a new instance of the CognitoSync client with a session.
// If additional configuration is needed for the client instance use the optional
// aws.Config parameter to add your extra config.
//
// Example:
// // Create a CognitoSync client from just a session.
// svc := cognitosync.New(mySession)
//
// // Create a CognitoSync client with additional configuration
// svc := cognitosync.New(mySession, aws.NewConfig().WithRegion("us-west-2"))
func New(p client.ConfigProvider, cfgs ...*aws.Config) *CognitoSync {
c := p.ClientConfig(EndpointsID, cfgs...)
return newClient(*c.Config, c.Handlers, c.Endpoint, c.SigningRegion, c.SigningName)
}
// newClient creates, initializes and returns a new service client instance.
func newClient(cfg aws.Config, handlers request.Handlers, endpoint, signingRegion, signingName string) *CognitoSync {
svc := &CognitoSync{
Client: client.New(
cfg,
metadata.ClientInfo{
ServiceName: ServiceName,
SigningName: signingName,
SigningRegion: signingRegion,
Endpoint: endpoint,
APIVersion: "2014-06-30",
JSONVersion: "1.1",
},
handlers,
),
}
// Handlers
svc.Handlers.Sign.PushBackNamed(v4.SignRequestHandler)
svc.Handlers.Build.PushBackNamed(restjson.BuildHandler)
svc.Handlers.Unmarshal.PushBackNamed(restjson.UnmarshalHandler)
svc.Handlers.UnmarshalMeta.PushBackNamed(restjson.UnmarshalMetaHandler)
svc.Handlers.UnmarshalError.PushBackNamed(restjson.UnmarshalErrorHandler)
// Run custom client initialization if present
if initClient != nil {
initClient(svc.Client)
}
return svc
}
// newRequest creates a new request for a CognitoSync operation and runs any
// custom request initialization.
func (c *CognitoSync) newRequest(op *request.Operation, params, data interface{}) *request.Request {
req := c.NewRequest(op, params, data)
// Run custom request initialization if present
if initRequest != nil {
initRequest(req)
}
return req
}