return text;
}
private static Image newImage(String filename, InputStream inputStream)
throws IOException {
Image image = new Image();
image.setId(Filenames.asId(filename));
image.setTitle(Filenames.asTitle(filename));
image.setLastModified(new Date());
image.setContentType(Filenames.asContentType(filename));
copyStreamToFile(inputStream, image.getFile());
return image;
}