From 694bed833470393ee00eae0a85bff0c6c90e692a Mon Sep 17 00:00:00 2001 From: bjculkin Date: Wed, 12 Apr 2017 10:45:46 -0400 Subject: Add support for meta-commands Meta-commands allow you to implement meta-operators, whose behavior changes based off of tokens that follow. --- .../main/java/bjc/pratt/MetaNonInitialCommand.java | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 JPratt/src/main/java/bjc/pratt/MetaNonInitialCommand.java (limited to 'JPratt/src/main/java/bjc/pratt/MetaNonInitialCommand.java') diff --git a/JPratt/src/main/java/bjc/pratt/MetaNonInitialCommand.java b/JPratt/src/main/java/bjc/pratt/MetaNonInitialCommand.java new file mode 100644 index 0000000..444c0e4 --- /dev/null +++ b/JPratt/src/main/java/bjc/pratt/MetaNonInitialCommand.java @@ -0,0 +1,19 @@ +package bjc.pratt; + +/** + * A 'meta-command' for non-initial commands. + * + * @author bjculkin + * + * @param + * The token key type. + * + * @param + * The token value type. + * + * @param + * The parser state type. + */ +public interface MetaNonInitialCommand { + NonInitialCommand getCommand(ParserContext ctx); +} -- cgit v1.2.3