diff --git a/AutoComplete/src/main/java/org/fife/ui/autocomplete/DefaultCompletionProvider.java b/AutoComplete/src/main/java/org/fife/ui/autocomplete/DefaultCompletionProvider.java
index a91b420..24c7634 100644
--- a/AutoComplete/src/main/java/org/fife/ui/autocomplete/DefaultCompletionProvider.java
+++ b/AutoComplete/src/main/java/org/fife/ui/autocomplete/DefaultCompletionProvider.java
@@ -293,6 +293,31 @@ public void loadFromXML(InputStream in) throws IOException {
}
+ /**
+ * Loads completions from an XML file. The XML should validate against
+ * CompletionXml.dtd.
+ *
+ * @param resource A resource the current ClassLoader can get to.
+ * @throws IOException If an IO error occurs.
+ */
+ public void loadFromXML(String resource) throws IOException {
+ ClassLoader cl = getClass().getClassLoader();
+ InputStream in = cl.getResourceAsStream(resource);
+ if (in==null) {
+ File file = new File(resource);
+ if (file.isFile()) {
+ in = Files.newInputStream(file.toPath());
+ }
+ else {
+ throw new IOException("No such resource: " + resource);
+ }
+ }
+ try (BufferedInputStream bin = new BufferedInputStream(in)) {
+ loadFromXML(bin);
+ }
+ }
+
+
/**
* Loads completions from an XML input stream. The XML should validate
* against CompletionXml.dtd.
@@ -330,29 +355,4 @@ public void loadFromXML(InputStream in, ClassLoader cl) throws IOException {
}
- /**
- * Loads completions from an XML file. The XML should validate against
- * CompletionXml.dtd.
- *
- * @param resource A resource the current ClassLoader can get to.
- * @throws IOException If an IO error occurs.
- */
- public void loadFromXML(String resource) throws IOException {
- ClassLoader cl = getClass().getClassLoader();
- InputStream in = cl.getResourceAsStream(resource);
- if (in==null) {
- File file = new File(resource);
- if (file.isFile()) {
- in = Files.newInputStream(file.toPath());
- }
- else {
- throw new IOException("No such resource: " + resource);
- }
- }
- try (BufferedInputStream bin = new BufferedInputStream(in)) {
- loadFromXML(bin);
- }
- }
-
-
}
diff --git a/build.gradle b/build.gradle
index 2d988dc..1379d9c 100644
--- a/build.gradle
+++ b/build.gradle
@@ -3,12 +3,12 @@ buildscript {
mavenCentral()
}
dependencies {
- classpath 'biz.aQute.bnd:biz.aQute.bnd.gradle:7.2.0'
+ classpath 'biz.aQute.bnd:biz.aQute.bnd.gradle:7.3.0'
}
}
plugins {
- id 'com.github.spotbugs' version '6.4.8'
+ id 'com.github.spotbugs' version '6.5.9'
id 'io.github.gradle-nexus.publish-plugin' version '2.0.0'
}
@@ -50,7 +50,7 @@ subprojects {
}
checkstyle {
- toolVersion = '12.3.0'
+ toolVersion = '13.8.0'
configDirectory = file("$rootProject.projectDir/config/checkstyle")
}
diff --git a/config/checkstyle/checkstyle.xml b/config/checkstyle/checkstyle.xml
index 725373b..b5fbb99 100644
--- a/config/checkstyle/checkstyle.xml
+++ b/config/checkstyle/checkstyle.xml
@@ -83,6 +83,12 @@
+
+
+
+
+
+
@@ -183,7 +189,15 @@
LITERAL_FINALLY, LITERAL_CATCH, DO_WHILE, LITERAL_SWITCH, LITERAL_SYNCHRONIZED, LITERAL_TRY,
LITERAL_CASE, LAMBDA, LITERAL_WHEN"/>
-
+
+
+
+
+
+
+
@@ -221,22 +235,28 @@
-->
+
+
+
+
-
+
+
+
@@ -256,6 +276,7 @@
+