From 42f7d379a430aaf2fad169f0170de04072b08b10 Mon Sep 17 00:00:00 2001 From: bculkin2442 Date: Fri, 22 Apr 2016 14:48:04 -0400 Subject: Formatting changes --- .../src/main/java/bjc/utils/cli/ICommandMode.java | 54 +++++++++++----------- 1 file changed, 27 insertions(+), 27 deletions(-) (limited to 'BJC-Utils2/src/main/java/bjc/utils/cli/ICommandMode.java') diff --git a/BJC-Utils2/src/main/java/bjc/utils/cli/ICommandMode.java b/BJC-Utils2/src/main/java/bjc/utils/cli/ICommandMode.java index 5208657..f6313af 100644 --- a/BJC-Utils2/src/main/java/bjc/utils/cli/ICommandMode.java +++ b/BJC-Utils2/src/main/java/bjc/utils/cli/ICommandMode.java @@ -8,21 +8,6 @@ package bjc.utils.cli; * */ public interface ICommandMode { - /** - * Process a command in this mode - * - * @param command - * The command to process - * @param args - * A list of arguments to the command - * @return The command mode to use for the next command. Defaults to - * returning this, and doing nothing else - */ - public default ICommandMode processCommand(String command, - String[] args) { - return this; - }; - /** * Check to see if this mode can handle the specified command * @@ -33,6 +18,19 @@ public interface ICommandMode { */ public default boolean canHandleCommand(String command) { return false; + }; + + /** + * Get the custom prompt for this mode + * + * @return the custom prompt for this mode + * + * @throws UnsupportedOperationException + * if this mode doesn't support a custom prompt + */ + public default String getCustomPrompt() { + throw new UnsupportedOperationException( + "This mode doesn't support a custom prompt"); } /** @@ -45,24 +43,26 @@ public interface ICommandMode { } /** - * Check if this mode uses a custom prompt + * Process a command in this mode * - * @return Whether or not this mode uses a custom prompt + * @param command + * The command to process + * @param args + * A list of arguments to the command + * @return The command mode to use for the next command. Defaults to + * returning this, and doing nothing else */ - public default boolean useCustomPrompt() { - return false; + public default ICommandMode processCommand(String command, + String[] args) { + return this; } /** - * Get the custom prompt for this mode - * - * @return the custom prompt for this mode + * Check if this mode uses a custom prompt * - * @throws UnsupportedOperationException - * if this mode doesn't support a custom prompt + * @return Whether or not this mode uses a custom prompt */ - public default String getCustomPrompt() { - throw new UnsupportedOperationException( - "This mode doesn't support a custom prompt"); + public default boolean useCustomPrompt() { + return false; } } -- cgit v1.2.3