summaryrefslogtreecommitdiff
path: root/java/src/main
diff options
context:
space:
mode:
authorPaul Duncan <pabs@pablotron.org>2018-09-06 18:18:55 -0400
committerPaul Duncan <pabs@pablotron.org>2018-09-06 18:18:55 -0400
commit878e07414367b4cc69843c3e9d91da02bc7c7043 (patch)
treece9ec236aaa5762139d2e94ddc42f7ec01fb4005 /java/src/main
parentc4f3f955179cd217c6e7273561d06468b33e8973 (diff)
downloadluigi-template-878e07414367b4cc69843c3e9d91da02bc7c7043.tar.bz2
luigi-template-878e07414367b4cc69843c3e9d91da02bc7c7043.zip
java: mv src/main/java/org/pablotron/luigi/{,errors/}*Errors.java and update code
Diffstat (limited to 'java/src/main')
-rw-r--r--java/src/main/java/org/pablotron/luigi/Cache.java3
-rw-r--r--java/src/main/java/org/pablotron/luigi/Filter.java2
-rw-r--r--java/src/main/java/org/pablotron/luigi/Parser.java2
-rw-r--r--java/src/main/java/org/pablotron/luigi/Template.java2
-rw-r--r--java/src/main/java/org/pablotron/luigi/Test.java2
-rw-r--r--java/src/main/java/org/pablotron/luigi/actions/Action.java2
-rw-r--r--java/src/main/java/org/pablotron/luigi/actions/FilterAction.java6
-rw-r--r--java/src/main/java/org/pablotron/luigi/actions/TextAction.java6
-rw-r--r--java/src/main/java/org/pablotron/luigi/errors/FilterError.java (renamed from java/src/main/java/org/pablotron/luigi/FilterError.java)2
-rw-r--r--java/src/main/java/org/pablotron/luigi/errors/LuigiError.java (renamed from java/src/main/java/org/pablotron/luigi/LuigiError.java)2
-rw-r--r--java/src/main/java/org/pablotron/luigi/errors/UnknownEntryError.java (renamed from java/src/main/java/org/pablotron/luigi/UnknownEntryError.java)2
-rw-r--r--java/src/main/java/org/pablotron/luigi/errors/UnknownFilterError.java (renamed from java/src/main/java/org/pablotron/luigi/UnknownFilterError.java)2
-rw-r--r--java/src/main/java/org/pablotron/luigi/errors/UnknownKeyError.java (renamed from java/src/main/java/org/pablotron/luigi/UnknownKeyError.java)2
-rw-r--r--java/src/main/java/org/pablotron/luigi/errors/UnknownTemplateError.java (renamed from java/src/main/java/org/pablotron/luigi/UnknownTemplateError.java)2
14 files changed, 20 insertions, 17 deletions
diff --git a/java/src/main/java/org/pablotron/luigi/Cache.java b/java/src/main/java/org/pablotron/luigi/Cache.java
index 4a591bc..7be8f6c 100644
--- a/java/src/main/java/org/pablotron/luigi/Cache.java
+++ b/java/src/main/java/org/pablotron/luigi/Cache.java
@@ -4,7 +4,8 @@ import java.util.Map;
import java.util.HashMap;
import org.pablotron.luigi.Filter;
import org.pablotron.luigi.Template;
-import org.pablotron.luigi.LuigiError;
+import org.pablotron.luigi.errors.LuigiError;
+import org.pablotron.luigi.errors.UnknownTemplateError;
import org.pablotron.luigi.actions.Action;
public final class Cache {
diff --git a/java/src/main/java/org/pablotron/luigi/Filter.java b/java/src/main/java/org/pablotron/luigi/Filter.java
index d2cd432..676c328 100644
--- a/java/src/main/java/org/pablotron/luigi/Filter.java
+++ b/java/src/main/java/org/pablotron/luigi/Filter.java
@@ -4,6 +4,8 @@ import java.util.Map;
import java.util.HashMap;
import java.nio.charset.Charset;
+import org.pablotron.luigi.errors.FilterError;
+
public final class Filter {
public interface Handler {
public String filter(
diff --git a/java/src/main/java/org/pablotron/luigi/Parser.java b/java/src/main/java/org/pablotron/luigi/Parser.java
index 5be4a9c..01e44f8 100644
--- a/java/src/main/java/org/pablotron/luigi/Parser.java
+++ b/java/src/main/java/org/pablotron/luigi/Parser.java
@@ -8,7 +8,7 @@ import org.pablotron.luigi.actions.Action;
import org.pablotron.luigi.actions.FilterAction;
import org.pablotron.luigi.actions.TextAction;
import org.pablotron.luigi.FilterReference;
-import org.pablotron.luigi.LuigiError;
+import org.pablotron.luigi.errors.LuigiError;
public final class Parser {
private static final Pattern RE_ACTION = Pattern.compile(
diff --git a/java/src/main/java/org/pablotron/luigi/Template.java b/java/src/main/java/org/pablotron/luigi/Template.java
index e5f25a9..91c6f9f 100644
--- a/java/src/main/java/org/pablotron/luigi/Template.java
+++ b/java/src/main/java/org/pablotron/luigi/Template.java
@@ -3,7 +3,7 @@ package org.pablotron.luigi;
import java.util.Map;
import org.pablotron.luigi.Parser;
import org.pablotron.luigi.Filter;
-import org.pablotron.luigi.LuigiError;
+import org.pablotron.luigi.errors.LuigiError;
import org.pablotron.luigi.actions.Action;
public final class Template {
diff --git a/java/src/main/java/org/pablotron/luigi/Test.java b/java/src/main/java/org/pablotron/luigi/Test.java
index 2a560e2..3d25c13 100644
--- a/java/src/main/java/org/pablotron/luigi/Test.java
+++ b/java/src/main/java/org/pablotron/luigi/Test.java
@@ -3,7 +3,7 @@ package org.pablotron.luigi;
import java.util.Map;
import java.util.HashMap;
-import org.pablotron.luigi.LuigiError;
+import org.pablotron.luigi.errors.LuigiError;
import org.pablotron.luigi.Filter;
import org.pablotron.luigi.Template;
import org.pablotron.luigi.Cache;
diff --git a/java/src/main/java/org/pablotron/luigi/actions/Action.java b/java/src/main/java/org/pablotron/luigi/actions/Action.java
index 9708199..a473f62 100644
--- a/java/src/main/java/org/pablotron/luigi/actions/Action.java
+++ b/java/src/main/java/org/pablotron/luigi/actions/Action.java
@@ -2,7 +2,7 @@ package org.pablotron.luigi.actions;
import java.util.Map;
import org.pablotron.luigi.Filter;
-import org.pablotron.luigi.LuigiError;
+import org.pablotron.luigi.errors.LuigiError;
public interface Action {
public String run(
diff --git a/java/src/main/java/org/pablotron/luigi/actions/FilterAction.java b/java/src/main/java/org/pablotron/luigi/actions/FilterAction.java
index 19565dc..091a285 100644
--- a/java/src/main/java/org/pablotron/luigi/actions/FilterAction.java
+++ b/java/src/main/java/org/pablotron/luigi/actions/FilterAction.java
@@ -4,9 +4,9 @@ import java.util.Map;
import org.pablotron.luigi.actions.Action;
import org.pablotron.luigi.FilterReference;
import org.pablotron.luigi.Filter;
-import org.pablotron.luigi.LuigiError;
-import org.pablotron.luigi.UnknownFilterError;
-import org.pablotron.luigi.UnknownKeyError;
+import org.pablotron.luigi.errors.LuigiError;
+import org.pablotron.luigi.errors.UnknownFilterError;
+import org.pablotron.luigi.errors.UnknownKeyError;
public final class FilterAction implements Action {
private final String key;
diff --git a/java/src/main/java/org/pablotron/luigi/actions/TextAction.java b/java/src/main/java/org/pablotron/luigi/actions/TextAction.java
index 0ad4382..32487be 100644
--- a/java/src/main/java/org/pablotron/luigi/actions/TextAction.java
+++ b/java/src/main/java/org/pablotron/luigi/actions/TextAction.java
@@ -3,7 +3,7 @@ package org.pablotron.luigi.actions;
import java.util.Map;
import org.pablotron.luigi.actions.Action;
import org.pablotron.luigi.Filter;
-import org.pablotron.luigi.LuigiError;
+import org.pablotron.luigi.errors.LuigiError;
public final class TextAction implements Action {
private final String text;
@@ -13,8 +13,8 @@ public final class TextAction implements Action {
}
public String run(
- Map<String, Filter.Handler> filters,
- Map<String, String> args
+ final Map<String, Filter.Handler> filters,
+ final Map<String, String> args
) throws LuigiError {
return this.text;
}
diff --git a/java/src/main/java/org/pablotron/luigi/FilterError.java b/java/src/main/java/org/pablotron/luigi/errors/FilterError.java
index cb631a7..f2ff7fb 100644
--- a/java/src/main/java/org/pablotron/luigi/FilterError.java
+++ b/java/src/main/java/org/pablotron/luigi/errors/FilterError.java
@@ -1,4 +1,4 @@
-package org.pablotron.luigi;
+package org.pablotron.luigi.errors;
public class FilterError extends LuigiError {
public FilterError(final String message) {
diff --git a/java/src/main/java/org/pablotron/luigi/LuigiError.java b/java/src/main/java/org/pablotron/luigi/errors/LuigiError.java
index edeb7c7..abf9280 100644
--- a/java/src/main/java/org/pablotron/luigi/LuigiError.java
+++ b/java/src/main/java/org/pablotron/luigi/errors/LuigiError.java
@@ -1,4 +1,4 @@
-package org.pablotron.luigi;
+package org.pablotron.luigi.errors;
public class LuigiError extends Exception {
public LuigiError(final String message) {
diff --git a/java/src/main/java/org/pablotron/luigi/UnknownEntryError.java b/java/src/main/java/org/pablotron/luigi/errors/UnknownEntryError.java
index 8b8a0fd..7710838 100644
--- a/java/src/main/java/org/pablotron/luigi/UnknownEntryError.java
+++ b/java/src/main/java/org/pablotron/luigi/errors/UnknownEntryError.java
@@ -1,4 +1,4 @@
-package org.pablotron.luigi;
+package org.pablotron.luigi.errors;
public class UnknownEntryError extends LuigiError {
public final String type;
diff --git a/java/src/main/java/org/pablotron/luigi/UnknownFilterError.java b/java/src/main/java/org/pablotron/luigi/errors/UnknownFilterError.java
index a56a6c1..7396da6 100644
--- a/java/src/main/java/org/pablotron/luigi/UnknownFilterError.java
+++ b/java/src/main/java/org/pablotron/luigi/errors/UnknownFilterError.java
@@ -1,4 +1,4 @@
-package org.pablotron.luigi;
+package org.pablotron.luigi.errors;
public class UnknownFilterError extends UnknownEntryError {
public UnknownFilterError(final String name) {
diff --git a/java/src/main/java/org/pablotron/luigi/UnknownKeyError.java b/java/src/main/java/org/pablotron/luigi/errors/UnknownKeyError.java
index 88da21a..7b0ae4c 100644
--- a/java/src/main/java/org/pablotron/luigi/UnknownKeyError.java
+++ b/java/src/main/java/org/pablotron/luigi/errors/UnknownKeyError.java
@@ -1,4 +1,4 @@
-package org.pablotron.luigi;
+package org.pablotron.luigi.errors;
public class UnknownKeyError extends UnknownEntryError {
public UnknownKeyError(final String name) {
diff --git a/java/src/main/java/org/pablotron/luigi/UnknownTemplateError.java b/java/src/main/java/org/pablotron/luigi/errors/UnknownTemplateError.java
index 15dae97..e6b4682 100644
--- a/java/src/main/java/org/pablotron/luigi/UnknownTemplateError.java
+++ b/java/src/main/java/org/pablotron/luigi/errors/UnknownTemplateError.java
@@ -1,4 +1,4 @@
-package org.pablotron.luigi;
+package org.pablotron.luigi.errors;
public class UnknownTemplateError extends UnknownEntryError {
public UnknownTemplateError(final String name) {