From b3bccd2512821653904372e5f995e9bb8f591ed5 Mon Sep 17 00:00:00 2001 From: "pabs@pablotron.org" Date: Thu, 18 Dec 2014 16:45:35 -0500 Subject: add comments --- java/pablotron/luigi/Test.java | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'java') diff --git a/java/pablotron/luigi/Test.java b/java/pablotron/luigi/Test.java index 1814a95..7163c52 100644 --- a/java/pablotron/luigi/Test.java +++ b/java/pablotron/luigi/Test.java @@ -2,6 +2,7 @@ package pablotron.luigi; import java.util.Map; import java.util.HashMap; + import pablotron.luigi.LuigiError; import pablotron.luigi.Filter; import pablotron.luigi.Template; @@ -27,12 +28,14 @@ public final class Test { // custom filters private static final Map filters = new HashMap() {{ + // add custom filter put("custom", new Filter.Handler() { public String filter(String val, String args[], Map row) { return "custom"; } }); + // add custom filter with argument put("custom_with_arg", new Filter.Handler() { public String filter(String val, String args[], Map row) { return (args.length > 0) ? args[0] : "custom"; @@ -40,7 +43,7 @@ public final class Test { }); }}; - public static void main(String cli_args[]) throws Exception { + public static void main(String params[]) throws Exception { // add custom filters Filter.FILTERS.putAll(filters); -- cgit v1.2.3