// List all the object versions in the bucket, with no prefix
// or delimiter restrictions. Each result object will be one of
// S3Version or S3DeleteMarker.
BaseVersionOrDeleteMarker[] versions =
s3Service.listVersionedObjects(vBucketName, null, null);
for (int i = 0; i < versions.length; i++) {
System.out.println(versions[i]);
}
// List versions of objects that match a prefix.