From 889fac2bdf993dc86f64a8893c0260fdcf848acb Mon Sep 17 00:00:00 2001 From: bculkin2442 Date: Mon, 10 Apr 2017 16:40:33 -0400 Subject: Cleanup --- BJC-Utils2/src/main/java/bjc/utils/cli/GenericCommand.java | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) (limited to 'BJC-Utils2/src/main/java/bjc/utils/cli/GenericCommand.java') diff --git a/BJC-Utils2/src/main/java/bjc/utils/cli/GenericCommand.java b/BJC-Utils2/src/main/java/bjc/utils/cli/GenericCommand.java index c49b4b9..4ae4dea 100644 --- a/BJC-Utils2/src/main/java/bjc/utils/cli/GenericCommand.java +++ b/BJC-Utils2/src/main/java/bjc/utils/cli/GenericCommand.java @@ -10,7 +10,7 @@ public class GenericCommand implements Command { /* * The behavior for invoking the command. */ - private CommandHandler handler; + private final CommandHandler handler; /* * The help for the command. @@ -30,12 +30,12 @@ public class GenericCommand implements Command { * null, in which case the description is repeated for * the detailed help. */ - public GenericCommand(CommandHandler handler, String description, String help) { - if(handler == null) throw new NullPointerException("Command handler must not be null"); + public GenericCommand(final CommandHandler handler, final String description, final String help) { + if (handler == null) throw new NullPointerException("Command handler must not be null"); this.handler = handler; - if(description == null) { + if (description == null) { this.help = new NullHelp(); } else { this.help = new GenericHelp(description, help); @@ -64,15 +64,15 @@ public class GenericCommand implements Command { /* * (non-Javadoc) - * + * * @see java.lang.Object#toString() */ @Override public String toString() { - StringBuilder builder = new StringBuilder(); + final StringBuilder builder = new StringBuilder(); builder.append("GenericCommand ["); - if(help != null) { + if (help != null) { builder.append("help="); builder.append(help); } -- cgit v1.2.3