@Test void getDescription_withoutObjectMetaData_returnsDescriptiveDescription() throws Exception { AmazonS3 amazonS3 = mock(AmazonS3.class); SimpleStorageResource simpleStorageResource = new SimpleStorageResource(amazonS3, "1", "2", new SyncTaskExecutor()); String description = simpleStorageResource.getDescription(); assertThat(description.contains("bucket")).isTrue(); assertThat(description.contains("object")).isTrue(); assertThat(description.contains("1")).isTrue(); assertThat(description.contains("2")).isTrue(); }
@Override public String getDescription() { StringBuilder builder = new StringBuilder("Amazon s3 resource [bucket='"); builder.append(this.bucketName); builder.append("' and object='"); builder.append(this.objectName); if (this.versionId != null) { builder.append("' and versionId='"); builder.append(this.versionId); } builder.append("']"); return builder.toString(); }
SimpleStorageResource extends AbstractResource implements WritableResource { @Override public String getDescription() { StringBuilder builder = new StringBuilder("Amazon s3 resource [bucket='"); builder.append(this.bucketName); builder.append("' and object='"); builder.append(this.objectName); if (this.versionId != null) { builder.append("' and versionId='"); builder.append(this.versionId); } builder.append("']"); return builder.toString(); } }
SimpleStorageResource extends AbstractResource implements WritableResource { @Override public String getDescription() { StringBuilder builder = new StringBuilder("Amazon s3 resource [bucket='"); builder.append(this.bucketName); builder.append("' and object='"); builder.append(this.objectName); if (this.versionId != null) { builder.append("' and versionId='"); builder.append(this.versionId); } builder.append("']"); return builder.toString(); } SimpleStorageResource(AmazonS3 amazonS3, String bucketName, String objectName,
			TaskExecutor taskExecutor);  SimpleStorageResource(AmazonS3 amazonS3, String bucketName, String objectName,
			TaskExecutor taskExecutor, String versionId); }
SimpleStorageResource extends AbstractResource implements WritableResource { @Override public String getDescription() { StringBuilder builder = new StringBuilder("Amazon s3 resource [bucket='"); builder.append(this.bucketName); builder.append("' and object='"); builder.append(this.objectName); if (this.versionId != null) { builder.append("' and versionId='"); builder.append(this.versionId); } builder.append("']"); return builder.toString(); } SimpleStorageResource(AmazonS3 amazonS3, String bucketName, String objectName,
			TaskExecutor taskExecutor);  SimpleStorageResource(AmazonS3 amazonS3, String bucketName, String objectName,
			TaskExecutor taskExecutor, String versionId); @Override String getDescription(); @Override InputStream getInputStream(); @Override boolean exists(); @Override long contentLength(); @Override long lastModified(); @Override String getFilename(); @Override URL getURL(); URI getS3Uri(); @Override File getFile(); @Override boolean isWritable(); @Override OutputStream getOutputStream(); @Override SimpleStorageResource createRelative(String relativePath); AmazonS3 getAmazonS3(); }
SimpleStorageResource extends AbstractResource implements WritableResource { @Override public String getDescription() { StringBuilder builder = new StringBuilder("Amazon s3 resource [bucket='"); builder.append(this.bucketName); builder.append("' and object='"); builder.append(this.objectName); if (this.versionId != null) { builder.append("' and versionId='"); builder.append(this.versionId); } builder.append("']"); return builder.toString(); } SimpleStorageResource(AmazonS3 amazonS3, String bucketName, String objectName,
			TaskExecutor taskExecutor);  SimpleStorageResource(AmazonS3 amazonS3, String bucketName, String objectName,
			TaskExecutor taskExecutor, String versionId); @Override String getDescription(); @Override InputStream getInputStream(); @Override boolean exists(); @Override long contentLength(); @Override long lastModified(); @Override String getFilename(); @Override URL getURL(); URI getS3Uri(); @Override File getFile(); @Override boolean isWritable(); @Override OutputStream getOutputStream(); @Override SimpleStorageResource createRelative(String relativePath); AmazonS3 getAmazonS3();  }