From 15a2b29e48f134bc93cfd0a3d8512001e9242f3d Mon Sep 17 00:00:00 2001 From: Benjamin Culkin Date: Mon, 3 Jun 2024 17:33:53 -0400 Subject: Rename package to new domain Rename the package to the new domain --- .../bjc/pratt/commands/impls/DenestingCommand.java | 49 ---------------------- 1 file changed, 49 deletions(-) delete mode 100644 JPratt/src/main/java/bjc/pratt/commands/impls/DenestingCommand.java (limited to 'JPratt/src/main/java/bjc/pratt/commands/impls/DenestingCommand.java') diff --git a/JPratt/src/main/java/bjc/pratt/commands/impls/DenestingCommand.java b/JPratt/src/main/java/bjc/pratt/commands/impls/DenestingCommand.java deleted file mode 100644 index de39e0b..0000000 --- a/JPratt/src/main/java/bjc/pratt/commands/impls/DenestingCommand.java +++ /dev/null @@ -1,49 +0,0 @@ -package bjc.pratt.commands.impls; - -import bjc.pratt.ParserContext; -import bjc.pratt.commands.AbstractInitialCommand; -import bjc.pratt.commands.CommandResult; -import bjc.pratt.commands.CommandResult.Status; -import bjc.pratt.commands.InitialCommand; -import bjc.pratt.tokens.Token; -import bjc.utils.parserutils.ParserException; - -/** - * A command that denests a input tree. - * - * Useful for processing the result of passing a complex parse group to a - * command. - * - * @author bjculkin - * - * @param - * The key type of the tokens. - * - * @param - * The value type of the tokens. - * - * @param - * The state type of the parser. - * - */ -public class DenestingCommand extends AbstractInitialCommand { - private final InitialCommand wrapped; - - /** - * Create a new transforming initial command. - * - * @param internal - * The initial command to delegate to. - */ - public DenestingCommand(final InitialCommand internal) { - wrapped = internal; - } - - @Override - protected CommandResult intNullDenotation(final Token operator, final ParserContext ctx) - throws ParserException { - CommandResult res = wrapped.denote(operator, ctx); - if (res.status != Status.SUCCESS) return res; - return CommandResult.success(res.success().getChild(0)); - } -} \ No newline at end of file -- cgit v1.2.3