use of com.ibm.cloud.sdk.core.service.model.FileWithMetadata in project java-sdk by watson-developer-cloud.
the class TestUtilities method creatMockListFileWithMetadata.
public static List<FileWithMetadata> creatMockListFileWithMetadata() {
List<FileWithMetadata> list = new ArrayList<FileWithMetadata>();
byte[] fileBytes = { (byte) 0xde, (byte) 0xad, (byte) 0xbe, (byte) 0xef };
InputStream inputStream = new ByteArrayInputStream(fileBytes);
FileWithMetadata.Builder builder = new FileWithMetadata.Builder();
builder.data(inputStream);
FileWithMetadata fileWithMetadata = builder.build();
list.add(fileWithMetadata);
return list;
}
Aggregations