- public static @bind.as("++") El plusmax(final El e) { return new Rep(e, null, false, true, true); }
- public static @bind.as("+") El plus(final El e) { return new Rep(e, null, false, true, false); }
- public static @bind.as("++/") El plusmaxfollow(final El e, final El sep) { return new Rep(e, sep, false, true, true); }
- public static @bind.as("+/") El plusfollow(final El e, final El sep) { return new Rep(e, sep, false, true, false); }
- public static @bind.as("**") El starmax(final El e) { return new Rep(e, null, true, true, true); }
- public static @bind.as("*") El star(final El e) { return new Rep(e, null, true, true, false); }
- public static @bind.as("**/") El starmaxfollow(final El e, final El sep) { return new Rep(e, sep, true, true, true); }
- public static @bind.as("*/") El starfollow(final El e, final El sep) { return new Rep(e, sep, true, true, false); }
- public static @bind.as("?") El question(final El e) { return new Rep(e, null, true, true, false); }
-
- public static @bind.as("!") El bang(final El e) { return new Drop(e); }
-
- public static @bind.as("^") El caret(final String s) {
- return new Drop(new Constant(CharRange.string(s)) {
- public String getOwnerTag() { return s; }
- });
+ public static @bind.as("++") ElementNode plusmax(final ElementNode e)
+ { return new Rep(e, null, false, true, true); }
+ public static @bind.as("+") ElementNode plus(final ElementNode e)
+ { return new Rep(e, null, false, true, false); }
+ public static @bind.as("++/") ElementNode plusmaxfollow(final ElementNode e, final ElementNode sep)
+ { return new Rep(e, sep, false, true, true); }
+ public static @bind.as("+/") ElementNode plusfollow(final ElementNode e, final ElementNode sep)
+ { return new Rep(e, sep, false, true, false); }
+ public static @bind.as("**") ElementNode starmax(final ElementNode e)
+ { return new Rep(e, null, true, true, true); }
+ public static @bind.as("*") ElementNode star(final ElementNode e)
+ { return new Rep(e, null, true, true, false); }
+ public static @bind.as("**/") ElementNode starmaxfollow(final ElementNode e, final ElementNode sep)
+ { return new Rep(e, sep, true, true, true); }
+ public static @bind.as("*/") ElementNode starfollow(final ElementNode e, final ElementNode sep)
+ { return new Rep(e, sep, true, true, false); }
+ public static @bind.as("?") ElementNode question(final ElementNode e)
+ { return new Rep(e, null, true, true, false); }
+ public static @bind.as("!") ElementNode bang(final ElementNode e)
+ { return new Drop(e); }
+
+ public static @bind.as("^") ElementNode caret(final String s) {
+ final String thePrefix = prefix;
+ return new Constant(CharAtom.string(s)) {
+ public String getOwnerTag() { return thePrefix+s; }
+ public boolean drop() { return true; }
+ };