info.freelibrary.vertx.s3.Profile Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of vertx-super-s3 Show documentation
Show all versions of vertx-super-s3 Show documentation
An S3 client library for the Vert.x toolkit
package info.freelibrary.vertx.s3;
import com.amazonaws.auth.AWSCredentials;
import com.amazonaws.auth.profile.ProfileCredentialsProvider;
/**
* A AWS profile defined in the system credentials file.
*/
public class Profile {
private final String myProfileName;
/**
* Creates a profile from the supplied profile name.
*
* @param aProfileName A name of a profile from the system credentials file
*/
public Profile(final String aProfileName) {
myProfileName = aProfileName;
}
/**
* Get the credentials for the supplied profile.
*
* @return The AWS credentials for this profile
*/
public AWSCredentials getCredentials() {
return new ProfileCredentialsProvider(myProfileName).getCredentials();
}
}
© 2015 - 2024 Weber Informatics LLC | Privacy Policy