From f2745aadc7d0eb02002f667cd72d8536e4f1daf1 Mon Sep 17 00:00:00 2001 From: "David A. Madore" Date: Thu, 22 Apr 2010 02:16:29 +0200 Subject: Various "stylistic" improvements suggested by Joshua Bloch's book. Use @Override annotation. Limit accessibility of fields. Make final what can be. Use complex enums. Don't ignore exceptions. Some more changes on exceptions thrown. --- org/madore/damlengine/DamlEngine.java | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'org/madore/damlengine/DamlEngine.java') diff --git a/org/madore/damlengine/DamlEngine.java b/org/madore/damlengine/DamlEngine.java index c9bd477..2cde6ec 100644 --- a/org/madore/damlengine/DamlEngine.java +++ b/org/madore/damlengine/DamlEngine.java @@ -13,7 +13,9 @@ public final class DamlEngine { public static final String XHTML_NS = "http://www.w3.org/1999/xhtml"; public static final String DAML_NS = "http://www.madore.org/~david/NS/daml/"; - private DamlEngine() { } // Forbid instantiation + private DamlEngine() { // Forbid instantiation + throw new AssertionError("DamlEngine cannot be instantiated"); + } public static class RootTodo extends TodoItem { public RootTodo(Context ctx) { -- cgit v1.2.3