Get file info

GroupDocs.Annotation allows to get document information which includes following methods.

The following code sample demonstrates how to get information about document.

Annotator annotator = new Annotator("input.pdf");
IDocumentInfo info = annotator.getDocument().getDocumentInfo();

    "\nFile type: "        + info.getFileType()
    +"\nNumber of pages: " + info.getPageCount()
    +"\nDocument size: "   + info.getSize() + " bytes" 


More resources

Advanced Usage Topics

To learn more about document annotating features, please refer to the advanced usage section.

GitHub Examples

You may easily run the code above and see the feature in action in our GitHub examples:

Free Online App

Along with full-featured Java library we provide simple, but powerful free Apps.
You are welcome to annotate your PDF, DOC or DOCX, XLS or XLSX, PPT or PPTX, PNG and other documents with free to use online GroupDocs Annotation App.