Via Document
Document doc = database.fetchDocument("docId"); Attachment a = doc.getAttachment("logo.png"); a.retrieve(new StreamContext() { public void withInputStream(InputStream is) throws IOException { // Use the InputStream // InputStream will be closed automatically. } });
Add Comment