Top Description Fields Constructors Methods
org.jabref.logic.xmp

public Class XmpUtilShared

extends Object
Class Inheritance
Imports
java.io.IOException, .InputStream, java.nio.file.Path, java.util.List, org.jabref.model.entry.BibEntry, org.apache.xmpbox.XMPMetadata, org.apache.xmpbox.xml.DomXmpParser, org.slf4j.Logger, .LoggerFactory

XMPUtilShared provides support for reading XMPUtilReader and writing XMPUtilWriter BibTex data as XMP metadata in PDF-documents.

Field Summary

Modifier and TypeField and Description
private static final Logger

Constructor Summary

AccessConstructor and Description
private

Method Summary

Modifier and TypeMethod and Description
public static boolean

Returns:

whether a BibEntry was found in the given PDF.
hasMetadata
(Path
the path to the PDF.
path
,
XmpPreferences xmpPreferences)

Will try to read XMP metadata from the given file, returning whether metadata was found.

protected static org.apache.xmpbox.XMPMetadata
Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

LOGGERback to summary
private static final Logger LOGGER

Constructor Detail

XmpUtilSharedback to summary
private XmpUtilShared()

Method Detail

hasMetadataback to summary
public static boolean hasMetadata(Path path, XmpPreferences xmpPreferences)

Will try to read XMP metadata from the given file, returning whether metadata was found.

Caution

This method is as expensive as it is reading the actual metadata itself from the PDF.

Parameters
path:Path

the path to the PDF.

Returns:boolean

whether a BibEntry was found in the given PDF.

parseXmpMetadataback to summary
protected static org.apache.xmpbox.XMPMetadata parseXmpMetadata(InputStream is) throws IOException