From 4e1a13330028b57818ece6741e029ebdbc9c7572 Mon Sep 17 00:00:00 2001 From: bculkin2442 Date: Sat, 7 Apr 2018 15:20:50 -0400 Subject: Documentation --- base/src/main/java/bjc/utils/cli/objects/BlockReaderCLI.java | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 'base/src/main/java/bjc/utils/cli/objects/BlockReaderCLI.java') diff --git a/base/src/main/java/bjc/utils/cli/objects/BlockReaderCLI.java b/base/src/main/java/bjc/utils/cli/objects/BlockReaderCLI.java index 8c29d8c..64b56fc 100644 --- a/base/src/main/java/bjc/utils/cli/objects/BlockReaderCLI.java +++ b/base/src/main/java/bjc/utils/cli/objects/BlockReaderCLI.java @@ -87,6 +87,7 @@ public class BlockReaderCLI { if(interactive) { System.out.printf("reader-conf(%d)>", lno); } + while(input.hasNextLine()) { /* Read a line. */ String ln = input.nextLine(); @@ -123,6 +124,7 @@ public class BlockReaderCLI { * @return The status of the executed command. */ public CommandStatus handleCommand(Command com, boolean interactive) { + /* Handle each command. */ switch(com.nameCommand) { case "def-filtered": return defFiltered(com); @@ -155,6 +157,11 @@ public class BlockReaderCLI { /* * Get the block name. */ + /* + * @TODO 02/17/18 Ben Culkin :StringHandling + * This slicing up strings by indexed characters should be abstracted into some + * sort of class. + */ int idx = remn.indexOf(' '); if(idx == -1) { LOGGER.severe(com.error("No name argument for def-filtered.\n")); @@ -173,6 +180,7 @@ public class BlockReaderCLI { /* * Get the reader name. */ + /* :StringHandling */ idx = remn.indexOf(' '); if(idx == -1) { LOGGER.severe(com.error("No reader-name argument for def-filtered.\n")); @@ -370,6 +378,7 @@ public class BlockReaderCLI { /* * Get the block name. */ + /* :StringHandling */ int idx = remn.indexOf(' '); if(idx == -1) { LOGGER.severe(com.error("No name argument for def-simple.\n")); @@ -388,6 +397,7 @@ public class BlockReaderCLI { /* * Get the source name. */ + /* :StringHandling */ idx = remn.indexOf(' '); if(idx == -1) { LOGGER.severe(com.error("No source-name argument for def-simple.\n")); @@ -414,6 +424,7 @@ public class BlockReaderCLI { String delim = remn; + /* Get the delimiter, and create the reader. */ try { BlockReader reader = new SimpleBlockReader(delim, stat.sources.get(sourceName)); -- cgit v1.2.3