Top Fields Constructors Methods
org.jabref.logic.xmp

public Class DocumentInformationExtractor

extends Object
Class Inheritance
Imports
java.util.Map, .Optional, org.jabref.model.entry.BibEntry, org.jabref.model.entry.field.Field, .FieldFactory, .InternalField, .StandardField, org.jabref.model.entry.types.EntryTypeFactory, org.apache.pdfbox.cos.COSBase, org.apache.pdfbox.cos.COSDictionary, org.apache.pdfbox.cos.COSName, org.apache.pdfbox.pdmodel.PDDocumentInformation

Field Summary

Modifier and TypeField and Description
private final BibEntry
private final org.apache.pdfbox.pdmodel.PDDocumentInformation

Constructor Summary

AccessConstructor and Description
public
DocumentInformationExtractor(org.apache.pdfbox.pdmodel.PDDocumentInformation documentInformation)

Method Summary

Modifier and TypeMethod and Description
private void
public Optional<BibEntry>

Returns:

The bibtex entry found in the document information.
extractBibtexEntry
()

Function for retrieving a BibEntry from the PDDocumentInformation in a PDF file.

private void
private void
private void
private void
Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

bibEntryback to summary
private final BibEntry bibEntry
documentInformationback to summary
private final org.apache.pdfbox.pdmodel.PDDocumentInformation documentInformation

Constructor Detail

DocumentInformationExtractorback to summary
public DocumentInformationExtractor(org.apache.pdfbox.pdmodel.PDDocumentInformation documentInformation)

Method Detail

extractAuthorback to summary
private void extractAuthor()
extractBibtexEntryback to summary
public Optional<BibEntry> extractBibtexEntry()

Function for retrieving a BibEntry from the PDDocumentInformation in a PDF file. To understand how to get hold of a PDDocumentInformation have a look in the test cases for XMPUtilTest. The BibEntry is build by mapping individual fields in the document information (like author, title, keywords) to fields in a bibtex entry.

Returns:Optional<BibEntry>

The bibtex entry found in the document information.

extractKeywordsback to summary
private void extractKeywords()
extractOtherFieldsback to summary
private void extractOtherFields()
extractSubjectback to summary
private void extractSubject()
extractTitleback to summary
private void extractTitle()