git-svn-id: http://jclouds.googlecode.com/svn/trunk@419 3d8758e0-26b5-11de-8745-db77d3ebf521
This commit is contained in:
adrian.f.cole 2009-05-06 22:11:04 +00:00
parent 186504b7e8
commit e32ed04b13
7 changed files with 8 additions and 8 deletions

View File

@ -110,13 +110,13 @@ public class JCloudsS3Service extends S3Service {
/**
* {@inheritDoc}
*
* @see S3Connection#deleteBucketIfNotEmpty(org.jclouds.aws.s3.domain.S3Bucket)
* @see S3Connection#deleteBucketIfEmpty(org.jclouds.aws.s3.domain.S3Bucket)
*/
@Override
protected void deleteBucketImpl(String bucketName)
throws S3ServiceException {
try {
connection.deleteBucketIfNotEmpty(bucketName).get(
connection.deleteBucketIfEmpty(bucketName).get(
requestTimeoutMilliseconds, TimeUnit.MILLISECONDS);
} catch (Exception e) {
Utils.<S3ServiceException> rethrowIfRuntimeOrSameType(e);

View File

@ -202,7 +202,7 @@ public class JCloudsS3ServiceTest extends S3IntegrationTest {
jcBucket.getCanonicalUser().getDisplayName());
}
client.deleteBucketIfNotEmpty(bucketName);
client.deleteBucketIfEmpty(bucketName);
}
@Test

View File

@ -112,7 +112,7 @@ public interface S3Connection {
* what to delete
* @return false, if the bucket was not empty and therefore not deleted
*/
Future<Boolean> deleteBucketIfNotEmpty(String s3Bucket);
Future<Boolean> deleteBucketIfEmpty(String s3Bucket);
/**
* Copies one object to another bucket

View File

@ -141,7 +141,7 @@ public class LiveS3Connection implements S3Connection {
*
* @see DeleteBucket
*/
public Future<Boolean> deleteBucketIfNotEmpty(String s3Bucket) {
public Future<Boolean> deleteBucketIfEmpty(String s3Bucket) {
DeleteBucket deleteBucket = factory.createDeleteBucket(s3Bucket);
client.submit(deleteBucket);
return deleteBucket;

View File

@ -148,7 +148,7 @@ public class AmazonS3Test extends S3IntegrationTest {
Boolean deleteBucket() throws Exception {
String s3Bucket = bucketPrefix + "adrianjbosstest";
return client.deleteBucketIfNotEmpty(s3Bucket)
return client.deleteBucketIfEmpty(s3Bucket)
.get(10, TimeUnit.SECONDS);
}

View File

@ -152,7 +152,7 @@ public class S3IntegrationTest {
iterator.next().get(10, TimeUnit.SECONDS);
iterator.remove();
}
client.deleteBucketIfNotEmpty(metaDatum.getName()).get(10,
client.deleteBucketIfEmpty(metaDatum.getName()).get(10,
TimeUnit.SECONDS);
}

View File

@ -120,7 +120,7 @@ public class StubS3Connection implements S3Connection {
};
}
public Future<Boolean> deleteBucketIfNotEmpty(final String s3Bucket) {
public Future<Boolean> deleteBucketIfEmpty(final String s3Bucket) {
return new FutureBase<Boolean>() {
public Boolean get() throws InterruptedException,
ExecutionException {