diff options
| author | student <student@69.161.224.78> | 2018-02-12 16:20:10 -0500 |
|---|---|---|
| committer | student <student@69.161.224.78> | 2018-02-12 16:20:10 -0500 |
| commit | 654a69ca0a0c1ab86aea2f6be63fe60eac61105a (patch) | |
| tree | 53bd2cb7f54577e9220780cc4270ea525e423c0f /base/src/bjc | |
| parent | 5115f1d2a7eab41436debc696870953e18a1b236 (diff) | |
Formatting pass
Diffstat (limited to 'base/src/bjc')
22 files changed, 67 insertions, 70 deletions
diff --git a/base/src/bjc/dicelang/CLIArgsParser.java b/base/src/bjc/dicelang/CLIArgsParser.java index 1cec55d..553692b 100644 --- a/base/src/bjc/dicelang/CLIArgsParser.java +++ b/base/src/bjc/dicelang/CLIArgsParser.java @@ -21,9 +21,9 @@ public class CLIArgsParser { * Parse the provided set of CLI arguments. * * @param args - * The CLI arguments to parse. + * The CLI arguments to parse. * @param eng - * The engine to affect with parsing. + * The engine to affect with parsing. * * @return Whether or not to continue to the DiceLang repl. */ diff --git a/base/src/bjc/dicelang/CompilerTweaker.java b/base/src/bjc/dicelang/CompilerTweaker.java index 95926f0..b11caa9 100644 --- a/base/src/bjc/dicelang/CompilerTweaker.java +++ b/base/src/bjc/dicelang/CompilerTweaker.java @@ -5,7 +5,7 @@ import bjc.utils.parserutils.splitter.ConfigurableTokenSplitter; /* * @TODO 10/09/17 Ben Culkin :CompilerTweaking * - * Expand this to allow tweaking more things about the compiler. + * Expand this to allow tweaking more things about the compiler. */ /** * Contains methods for customizing the DiceLang and SCL compilers. @@ -21,7 +21,7 @@ public class CompilerTweaker { * Create a new compiler tweaker. * * @param engine - * The engine to tweak. + * The engine to tweak. */ public CompilerTweaker(final DiceLangEngine engine) { eng = engine; @@ -33,7 +33,7 @@ public class CompilerTweaker { * Add a string literal to the compiler's internal banks. * * @param val - * The string literal to add. + * The string literal to add. * * @return The key into the string literal table for this string. */ @@ -48,7 +48,7 @@ public class CompilerTweaker { * Add a line defn to the compiler. * * @param dfn - * The defn to add. + * The defn to add. */ public void addLineDefine(final Define dfn) { eng.addLineDefine(dfn); @@ -58,7 +58,7 @@ public class CompilerTweaker { * Add a token defn to the compiler. * * @param dfn - * The defn to add. + * The defn to add. */ public void addTokenDefine(final Define dfn) { eng.addTokenDefine(dfn); @@ -68,7 +68,7 @@ public class CompilerTweaker { * Adds delimiters that are expanded from tokens. * * @param delims - * The delimiters to expand on. + * The delimiters to expand on. */ public void addDelimiter(final String... delims) { opExpander.addSimpleDelimiters(delims); @@ -78,7 +78,7 @@ public class CompilerTweaker { * Adds multi-character delimiters that are expanded from tokens. * * @param delims - * The multi-character delimiters to expand on. + * The multi-character delimiters to expand on. */ public void addMultiDelimiter(final String... delims) { opExpander.addMultiDelimiters(delims); @@ -95,7 +95,7 @@ public class CompilerTweaker { * Change the max no. of times defines are allowed to recur. * * @param times - * The number of times to allow defines to recur. + * The number of times to allow defines to recur. */ public static void setDefineRecurLimit(final int times) { Define.MAX_RECURS = times; diff --git a/base/src/bjc/dicelang/Define.java b/base/src/bjc/dicelang/Define.java index 1051957..b11e10b 100644 --- a/base/src/bjc/dicelang/Define.java +++ b/base/src/bjc/dicelang/Define.java @@ -13,7 +13,7 @@ import static bjc.dicelang.Errors.ErrorKey.*; /* * @TODO 10/09/17 Ben Culkin :DefineRefactor * - * Consider replacing this with the defines package from BJC-Utils. + * Consider replacing this with the defines package from BJC-Utils. */ /** * A regular expression based pre-processor define. @@ -63,25 +63,25 @@ public class Define implements UnaryOperator<String>, Comparable<Define> { * Create a new define. * * @param priorty - * The priority of the define. + * The priority of the define. * * @param isSub - * Whether or not this is a 'sub-define' + * Whether or not this is a 'sub-define' * * @param recur - * Whether this define is recursive or not. + * Whether this define is recursive or not. * * @param isCircular - * Whether this define is circular or not. + * Whether this define is circular or not. * * @param predicte - * The string to use as a predicate. + * The string to use as a predicate. * * @param searchr - * The string to use as a search. + * The string to use as a search. * * @param replacrs - * The source for replacement strings. + * The source for replacement strings. */ public Define(final int priorty, final boolean isSub, final boolean recur, final boolean isCircular, final String predicte, final String searchr, final Iterable<String> replacrs) { diff --git a/base/src/bjc/dicelang/DiceLangConsole.java b/base/src/bjc/dicelang/DiceLangConsole.java index d2c214d..a43c1da 100644 --- a/base/src/bjc/dicelang/DiceLangConsole.java +++ b/base/src/bjc/dicelang/DiceLangConsole.java @@ -29,7 +29,7 @@ public class DiceLangConsole { * Create a new console. * * @param args - * The CLI args for the console. + * The CLI args for the console. */ public DiceLangConsole(final String[] args) { commandNumber = 0; @@ -303,7 +303,7 @@ public class DiceLangConsole { * Main method. * * @param args - * CLI arguments. + * CLI arguments. */ public static void main(final String[] args) { final DiceLangConsole console = new DiceLangConsole(args); diff --git a/base/src/bjc/dicelang/DiceLangEngine.java b/base/src/bjc/dicelang/DiceLangEngine.java index 128e2a6..ebdb07f 100644 --- a/base/src/bjc/dicelang/DiceLangEngine.java +++ b/base/src/bjc/dicelang/DiceLangEngine.java @@ -140,7 +140,7 @@ public class DiceLangEngine { * Add a defn that's applied to lines. * * @param dfn - * The defn to add. + * The defn to add. */ public void addLineDefine(final Define dfn) { lineDefns.add(dfn); @@ -152,7 +152,7 @@ public class DiceLangEngine { * Add a defn that's applied to tokens. * * @param dfn - * The defn to add. + * The defn to add. */ public void addTokenDefine(final Define dfn) { tokenDefns.add(dfn); @@ -211,7 +211,7 @@ public class DiceLangEngine { * Run a command to completion. * * @param command - * The command to run + * The command to run * * @return Whether or not the command ran successfully */ diff --git a/base/src/bjc/dicelang/Errors.java b/base/src/bjc/dicelang/Errors.java index 2263532..2577a32 100644 --- a/base/src/bjc/dicelang/Errors.java +++ b/base/src/bjc/dicelang/Errors.java @@ -273,10 +273,10 @@ public class Errors { * Print an error. * * @param key - * The key of the error. + * The key of the error. * * @param args - * The arguments for the error. + * The arguments for the error. */ public void printError(final ErrorKey key, final String... args) { switch (mode) { diff --git a/base/src/bjc/dicelang/Evaluator.java b/base/src/bjc/dicelang/Evaluator.java index e959355..677aef4 100644 --- a/base/src/bjc/dicelang/Evaluator.java +++ b/base/src/bjc/dicelang/Evaluator.java @@ -62,7 +62,7 @@ public class Evaluator { * Create a new evaluator. * * @param en - * The engine. + * The engine. */ public Evaluator(final DiceLangEngine en) { eng = en; @@ -72,7 +72,7 @@ public class Evaluator { * Evaluate a AST. * * @param comm - * The AST to evaluate. + * The AST to evaluate. * * @return The result of the tree. */ diff --git a/base/src/bjc/dicelang/EvaluatorResult.java b/base/src/bjc/dicelang/EvaluatorResult.java index f23fc71..0d0706a 100644 --- a/base/src/bjc/dicelang/EvaluatorResult.java +++ b/base/src/bjc/dicelang/EvaluatorResult.java @@ -82,7 +82,7 @@ public class EvaluatorResult { * Create a new result. * * @param typ - * The type of the result. + * The type of the result. */ public EvaluatorResult(final EvaluatorResult.Type typ) { type = typ; @@ -92,10 +92,10 @@ public class EvaluatorResult { * Create a new result. * * @param typ - * The type of the result. + * The type of the result. * * @param orig - * The original value of the result. + * The original value of the result. */ public EvaluatorResult(final EvaluatorResult.Type typ, final ITree<Node> orig) { this(typ); @@ -107,10 +107,10 @@ public class EvaluatorResult { * Create a new result. * * @param typ - * The type of the result. + * The type of the result. * * @param orig - * The original value of the result. + * The original value of the result. */ public EvaluatorResult(final EvaluatorResult.Type typ, final Node orig) { this(typ, new Tree<>(orig)); diff --git a/base/src/bjc/dicelang/Node.java b/base/src/bjc/dicelang/Node.java index 55273e8..ff0c83d 100644 --- a/base/src/bjc/dicelang/Node.java +++ b/base/src/bjc/dicelang/Node.java @@ -5,9 +5,8 @@ import static bjc.dicelang.EvaluatorResult.Type.FAILURE; import bjc.utils.data.ITree; /* - * @TODO 10/09/17 Ben Culkin :NodeReorg - * Same thing, different class. Split into subclasses based off of the type - * values. + * @TODO 10/09/17 Ben Culkin :NodeReorg Same thing, different class. Split into + * subclasses based off of the type values. */ /** * Represents a node in the AST. diff --git a/base/src/bjc/dicelang/Parser.java b/base/src/bjc/dicelang/Parser.java index 25d23c8..76730b9 100644 --- a/base/src/bjc/dicelang/Parser.java +++ b/base/src/bjc/dicelang/Parser.java @@ -36,10 +36,10 @@ public class Parser { * Parse a series of tokens to a forest of ASTs. * * @param tokens - * The list of tokens to parse. + * The list of tokens to parse. * * @param results - * The place to set results. + * The place to set results. * * @return Whether or not the parse was successful. */ diff --git a/base/src/bjc/dicelang/Shunter.java b/base/src/bjc/dicelang/Shunter.java index ca0f6e1..01029cd 100644 --- a/base/src/bjc/dicelang/Shunter.java +++ b/base/src/bjc/dicelang/Shunter.java @@ -108,10 +108,10 @@ public class Shunter { * Shunt a set of tokens from infix to postfix. * * @param tks - * The tokens to input. + * The tokens to input. * * @param returned - * The postfix tokens. + * The postfix tokens. * * @return Whether or not the shunt succeeded. */ diff --git a/base/src/bjc/dicelang/Token.java b/base/src/bjc/dicelang/Token.java index 50e5b31..b152185 100644 --- a/base/src/bjc/dicelang/Token.java +++ b/base/src/bjc/dicelang/Token.java @@ -6,7 +6,7 @@ import bjc.utils.funcdata.IList; /* * @TODO 10/09/17 Ben Culkin :TokenReorg * - * Split the class into subclasses based off of type. + * Split the class into subclasses based off of type. */ /** * Lexer token. diff --git a/base/src/bjc/dicelang/expr/ExprREPL.java b/base/src/bjc/dicelang/expr/ExprREPL.java index 84149a0..49b9575 100644 --- a/base/src/bjc/dicelang/expr/ExprREPL.java +++ b/base/src/bjc/dicelang/expr/ExprREPL.java @@ -17,7 +17,7 @@ public class ExprREPL { * Main method. * * @param args - * Unused CLI args. + * Unused CLI args. */ public static void main(final String[] args) { /* Create our objects. */ diff --git a/base/src/bjc/dicelang/expr/Ezpr.java b/base/src/bjc/dicelang/expr/Ezpr.java index b852fd1..4919c81 100644 --- a/base/src/bjc/dicelang/expr/Ezpr.java +++ b/base/src/bjc/dicelang/expr/Ezpr.java @@ -1,6 +1,6 @@ /* - * @TODO 10/08/17 Ben Culkin :EzprFixing - * Implement these, and make sure they work correctly. + * @TODO 10/08/17 Ben Culkin :EzprFixing Implement these, and make sure they + * work correctly. */ package bjc.dicelang.expr; diff --git a/base/src/bjc/dicelang/expr/Lexer.java b/base/src/bjc/dicelang/expr/Lexer.java index 7530ba5..c7dd92f 100644 --- a/base/src/bjc/dicelang/expr/Lexer.java +++ b/base/src/bjc/dicelang/expr/Lexer.java @@ -7,10 +7,9 @@ import bjc.utils.funcdata.IList; import bjc.utils.parserutils.splitter.ConfigurableTokenSplitter; /* - * @TODO 10/08/18 :IntExpressions - * Add support for integer constants, and maybe floating-point ones as well - * if you feel like. Heck, you could even go for ratio constants and things - * as well. + * @TODO 10/08/18 :IntExpressions Add support for integer constants, and maybe + * floating-point ones as well if you feel like. Heck, you could even go for + * ratio constants and things as well. */ /** * Implements the lexer for simple expression operations. @@ -35,10 +34,10 @@ public class Lexer { * Convert a string from a input command to a series of infix tokens. * * @param inp - * The input command. + * The input command. * * @param tks - * The token state. + * The token state. * * @return A series of infix tokens representing the command. */ @@ -52,7 +51,7 @@ public class Lexer { for (final String spacedToken : spacedTokens) { /* Split on operators. */ final IList<String> splitTokens = split.split(spacedToken); - + /* Convert strings to tokens. */ final IList<Token> rawTokens = splitTokens.map(tok -> { return tks.lexToken(tok, spacedToken); diff --git a/base/src/bjc/dicelang/expr/Shunter.java b/base/src/bjc/dicelang/expr/Shunter.java index a1b24cb..53c2298 100644 --- a/base/src/bjc/dicelang/expr/Shunter.java +++ b/base/src/bjc/dicelang/expr/Shunter.java @@ -16,7 +16,7 @@ public class Shunter { * Convert a infix series of tokens to a postfix series of tokens. * * @param infixTokens - * The tokens in infix order. + * The tokens in infix order. * * @return The tokens in postfix order. */ diff --git a/base/src/bjc/dicelang/expr/Token.java b/base/src/bjc/dicelang/expr/Token.java index 3c6b1da..750362d 100644 --- a/base/src/bjc/dicelang/expr/Token.java +++ b/base/src/bjc/dicelang/expr/Token.java @@ -3,9 +3,9 @@ package bjc.dicelang.expr; /* * @TODO 10/08/17 :TokenReorg * - * I am not a fan of this 'having a bunch of subclasses' in one thing I - * seem to have been doing around this project. This should be multiple - * subclasses, one for each value for TokenType. + * I am not a fan of this 'having a bunch of subclasses' in one thing I seem to + * have been doing around this project. This should be multiple subclasses, one + * for each value for TokenType. */ /** * Represents a lexical token. @@ -33,13 +33,13 @@ public class Token { * Create a new token. * * @param type - * The type of this token. + * The type of this token. * * @param raw - * The string this token came from. + * The string this token came from. * * @param toks - * The state for this token + * The state for this token */ public Token(final TokenType type, final String raw, final Tokens toks) { this.typ = type; diff --git a/base/src/bjc/dicelang/expr/Tokens.java b/base/src/bjc/dicelang/expr/Tokens.java index 92416d1..687a414 100644 --- a/base/src/bjc/dicelang/expr/Tokens.java +++ b/base/src/bjc/dicelang/expr/Tokens.java @@ -58,9 +58,9 @@ public class Tokens { * Convert the string representation of a token into a token. * * @param tok - * The string representation of the token. + * The string representation of the token. * @param raw - * The original string the token came from. + * The original string the token came from. * * @return The token the string represents. */ diff --git a/base/src/bjc/dicelang/scl/StreamControlConsole.java b/base/src/bjc/dicelang/scl/StreamControlConsole.java index cc0fac8..ca61244 100644 --- a/base/src/bjc/dicelang/scl/StreamControlConsole.java +++ b/base/src/bjc/dicelang/scl/StreamControlConsole.java @@ -19,7 +19,7 @@ public class StreamControlConsole { * Main method * * @param args - * Unused CLI args. + * Unused CLI args. */ public static void main(String[] args) { /* diff --git a/base/src/bjc/dicelang/scl/StreamControlEngine.java b/base/src/bjc/dicelang/scl/StreamControlEngine.java index e05c983..32ae8ba 100644 --- a/base/src/bjc/dicelang/scl/StreamControlEngine.java +++ b/base/src/bjc/dicelang/scl/StreamControlEngine.java @@ -17,8 +17,7 @@ import static bjc.dicelang.scl.WordSCLToken.Word.*; /* * @TODO 10/08/17 Ben Culkin :SCLReorg * - * This is a large enough class that it should maybe be split into - * subclasses. + * This is a large enough class that it should maybe be split into subclasses. */ /** * Runs a Stream Control Language (SCL) program. @@ -42,7 +41,7 @@ public class StreamControlEngine { * Create a new stream control engine. * * @param engine - * The engine to control. + * The engine to control. */ public StreamControlEngine(final StreamEngine engine) { eng = engine; @@ -55,7 +54,7 @@ public class StreamControlEngine { * Run a SCL program. * * @param tokens - * The program to run. + * The program to run. * * @return Whether the program executed successfully. */ diff --git a/base/src/bjc/dicelang/scl/StreamEngine.java b/base/src/bjc/dicelang/scl/StreamEngine.java index 8a5df09..2d931b9 100644 --- a/base/src/bjc/dicelang/scl/StreamEngine.java +++ b/base/src/bjc/dicelang/scl/StreamEngine.java @@ -43,7 +43,7 @@ public class StreamEngine { * Create a new stream engine. * * @param engine - * The dice engine we're attached to. + * The dice engine we're attached to. */ public StreamEngine(final DiceLangEngine engine) { eng = engine; @@ -66,10 +66,10 @@ public class StreamEngine { * Process a possibly interleaved set of streams. * * @param toks - * The raw token to read streams from. + * The raw token to read streams from. * * @param dest - * The list to write the final stream to. + * The list to write the final stream to. * * @return Whether or not the streams were successfully processed. */ @@ -81,10 +81,10 @@ public class StreamEngine { * Process a possibly interleaved set of streams. * * @param toks - * The raw token to read streams from. + * The raw token to read streams from. * * @param dest - * The list to write the final stream to. + * The list to write the final stream to. * * @return Whether or not the streams were successfully processed. */ diff --git a/base/src/bjc/dicelang/util/ResourceLoader.java b/base/src/bjc/dicelang/util/ResourceLoader.java index 581f4cb..085081f 100644 --- a/base/src/bjc/dicelang/util/ResourceLoader.java +++ b/base/src/bjc/dicelang/util/ResourceLoader.java @@ -22,7 +22,7 @@ public class ResourceLoader { * Loads a .help file from the data/help directory. * * @param name - * The name of the help file to load. + * The name of the help file to load. * * @return The contents of the help file, or null if it could not be opened. */ |
