diff options
Diffstat (limited to 'JPratt/src/main/java/com/ashardalon/pratt/commands/MetaInitialCommand.java')
| -rw-r--r-- | JPratt/src/main/java/com/ashardalon/pratt/commands/MetaInitialCommand.java | 27 |
1 files changed, 27 insertions, 0 deletions
diff --git a/JPratt/src/main/java/com/ashardalon/pratt/commands/MetaInitialCommand.java b/JPratt/src/main/java/com/ashardalon/pratt/commands/MetaInitialCommand.java new file mode 100644 index 0000000..7b9aae0 --- /dev/null +++ b/JPratt/src/main/java/com/ashardalon/pratt/commands/MetaInitialCommand.java @@ -0,0 +1,27 @@ +package com.ashardalon.pratt.commands;
+
+import com.ashardalon.pratt.ParserContext;
+
+/**
+ * A 'meta-command' that yields the actual command to use.
+ *
+ * @author bjculkin
+ *
+ * @param <K>
+ * The key type of the context.
+ * @param <V>
+ * The value type of the context.
+ * @param <C>
+ * The storage type of the context.
+ *
+ */
+public interface MetaInitialCommand<K, V, C> {
+ /**
+ * Get the command to use.
+ *
+ * @param ctx
+ * The current parser context.
+ * @return The command to use.
+ */
+ InitialCommand<K, V, C> getCommand(ParserContext<K, V, C> ctx);
+}
|
