try {
// Open the package
Package p = Package.open(docPath, PackageAccess.READ);
// Gets the core properties
PackageProperties props = p.getPackageProperties();
DemoCore.getLogger().info(
"Title: " + props.getTitleProperty().getValue());
DemoCore.getLogger().info(
"Creator: " + props.getCreatorProperty().getValue());
DemoCore.getLogger().info(
"Creation date: " + props.getCreatedProperty().getValue());
DemoCore.getLogger().info(
"Status: " + props.getContentStatusProperty().getValue());
p.revert();
} catch (OpenXML4JException e) {
DemoCore.getLogger().debug(e.getMessage());
}