Example usage for com.amazonaws.services.cloudfront AmazonCloudFrontClientBuilder standard

List of usage examples for com.amazonaws.services.cloudfront AmazonCloudFrontClientBuilder standard

Introduction

In this page you can find the example usage for com.amazonaws.services.cloudfront AmazonCloudFrontClientBuilder standard.

Prototype

public static AmazonCloudFrontClientBuilder standard() 

Source Link

Usage

From source file:ch.cyberduck.core.cloudfront.CloudFrontDistributionConfiguration.java

License:Open Source License

private AmazonCloudFront client(final Path container) throws BackgroundException {
    return AmazonCloudFrontClientBuilder.standard()
            .withCredentials(new AWSStaticCredentialsProvider(new com.amazonaws.auth.AWSCredentials() {
                @Override//from  w w  w .jav  a  2 s .c o m
                public String getAWSAccessKeyId() {
                    return bookmark.getCredentials().getUsername();
                }

                @Override
                public String getAWSSecretKey() {
                    return bookmark.getCredentials().getPassword();
                }
            })).withClientConfiguration(configuration)
            .withRegion(locationFeature.getLocation(container).getIdentifier()).build();
}