Search in sources :

Example 1 with DateDefinition

use of org.jabref.logic.importer.fileformat.mods.DateDefinition in project jabref by JabRef.

the class ModsExportFormat method addDate.

private void addDate(String dateName, String value, OriginInfoDefinition originInfo) {
    DateDefinition dateIssued = new DateDefinition();
    dateIssued.setKeyDate("yes");
    dateIssued.setValue(value);
    JAXBElement<DateDefinition> element = new JAXBElement<>(new QName(MODS_NAMESPACE_URI, dateName), DateDefinition.class, dateIssued);
    originInfo.getPlaceOrPublisherOrDateIssued().add(element);
}
Also used : DateDefinition(org.jabref.logic.importer.fileformat.mods.DateDefinition) QName(javax.xml.namespace.QName) JAXBElement(javax.xml.bind.JAXBElement)

Aggregations

JAXBElement (javax.xml.bind.JAXBElement)1 QName (javax.xml.namespace.QName)1 DateDefinition (org.jabref.logic.importer.fileformat.mods.DateDefinition)1