Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bump jaxb-xjc from 2.2.4-1 to 2.3.2 #4956

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 4 additions & 3 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,8 @@ plugins {
// use the gradle build scan feature: https://scans.gradle.com/get-started
buildScan { termsOfServiceUrl = 'https://gradle.com/terms-of-service'; termsOfServiceAgree = 'yes' }

// show stacktrace on error
gradle.startParameter.showStacktrace = org.gradle.api.logging.configuration.ShowStacktrace.ALWAYS

apply plugin: 'java'
apply plugin: 'application'
Expand Down Expand Up @@ -225,7 +227,7 @@ dependencies {
testCompile "org.testfx:testfx-junit5:4.0.15-alpha"

checkstyle 'com.puppycrawl.tools:checkstyle:8.24'
xjc 'com.sun.xml.bind:jaxb-xjc:2.2.4-1'
xjc group: 'org.glassfish.jaxb', name: 'jaxb-xjc', version: '2.3.2'
jython 'org.python:jython-standalone:2.7.1'
}

Expand Down Expand Up @@ -351,10 +353,9 @@ task generateEndnoteSource(type: XjcTask) {
group = 'JabRef'
description = "Generates java files for the endnote importer."

schemaFile = "src/main/resources/xjc/endnote/RSXML.dtd"
schemaFile = "src/main/resources/xjc/endnote/endnote.xsd"
outputDirectory = "src/main/gen/"
javaPackage = "org.jabref.logic.importer.fileformat.endnote"
arguments = '-dtd'
}

task generateModsSource(type: XjcTask) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -186,49 +186,49 @@ private BibEntry parseRecord(Record record) {
Optional.ofNullable(record.getTitles())
.map(Titles::getTitle)
.map(Title::getStyle)
.map(Style::getvalue)
.map(Style::getContent)
.ifPresent(value -> entry.setField(StandardField.TITLE, clean(value)));
Optional.ofNullable(record.getTitles())
.map(Titles::getSecondaryTitle)
.map(SecondaryTitle::getStyle)
.map(Style::getvalue)
.map(Style::getContent)
.ifPresent(value -> entry.setField(StandardField.JOURNAL, clean(value)));
Optional.ofNullable(record.getPages())
.map(Pages::getStyle)
.map(Style::getvalue)
.map(Style::getContent)
.ifPresent(value -> entry.setField(StandardField.PAGES, value));
Optional.ofNullable(record.getNumber())
.map(Number::getStyle)
.map(Style::getvalue)
.map(Style::getContent)
.ifPresent(value -> entry.setField(StandardField.NUMBER, value));
Optional.ofNullable(record.getVolume())
.map(Volume::getStyle)
.map(Style::getvalue)
.map(Style::getContent)
.ifPresent(value -> entry.setField(StandardField.VOLUME, value));
Optional.ofNullable(record.getDates())
.map(Dates::getYear)
.map(Year::getStyle)
.map(Style::getvalue)
.map(Style::getContent)
.ifPresent(value -> entry.setField(StandardField.YEAR, value));
Optional.ofNullable(record.getNotes())
.map(Notes::getStyle)
.map(Style::getvalue)
.map(Style::getContent)
.ifPresent(value -> entry.setField(StandardField.NOTE, value.trim()));
getUrl(record)
.ifPresent(value -> entry.setField(StandardField.URL, value));
entry.putKeywords(getKeywords(record), preferences.getKeywordSeparator());
Optional.ofNullable(record.getAbstract())
.map(Abstract::getStyle)
.map(Style::getvalue)
.map(Style::getContent)
.ifPresent(value -> entry.setField(StandardField.ABSTRACT, value.trim()));
entry.setFiles(getLinkedFiles(record));
Optional.ofNullable(record.getIsbn())
.map(Isbn::getStyle)
.map(Style::getvalue)
.map(Style::getContent)
.ifPresent(value -> entry.setField(StandardField.ISBN, clean(value)));
Optional.ofNullable(record.getElectronicResourceNum())
.map(ElectronicResourceNum::getStyle)
.map(Style::getvalue)
.map(Style::getContent)
.ifPresent(doi -> entry.setField(StandardField.DOI, doi.trim()));

return entry;
Expand Down Expand Up @@ -263,7 +263,7 @@ private Optional<String> getUrl(Record record) {
private Optional<String> getUrlValue(Url url) {
return Optional.ofNullable(url)
.map(Url::getStyle)
.map(Style::getvalue)
.map(Style::getContent)
.map(this::clean);
}

Expand All @@ -272,7 +272,7 @@ private List<String> getKeywords(Record record) {
if (keywords != null) {
return keywords.getKeyword()
.stream()
.map(keyword -> keyword.getStyle().getvalue())
.map(keyword -> keyword.getStyle().getContent())
.collect(Collectors.toList());
} else {
return Collections.emptyList();
Expand All @@ -284,7 +284,7 @@ private String getAuthors(Record record) {
.map(Contributors::getAuthors);
return OptionalUtil.toStream(authors)
.flatMap(value -> value.getAuthor().stream())
.map(author -> author.getStyle().getvalue())
.map(author -> author.getStyle().getContent())
.collect(Collectors.joining(" and "));
}

Expand Down
168 changes: 0 additions & 168 deletions src/main/resources/xjc/endnote/RSXML.dtd

This file was deleted.

Loading