calabash-android 0.4.0.pre6 → 0.4.0.pre7
Sign up to get free protection for your applications and to get access to all the features.
- data/bin/calabash-android +7 -0
- data/bin/calabash-android-build.rb +1 -1
- data/bin/calabash-android-console.rb +1 -1
- data/bin/calabash-android-run.rb +1 -1
- data/calabash-android.gemspec +1 -0
- data/irbrc +2 -0
- data/lib/calabash-android/helpers.rb +4 -2
- data/lib/calabash-android/lib/TestServer.apk +0 -0
- data/lib/calabash-android/operations.rb +31 -22
- data/lib/calabash-android/version.rb +1 -1
- data/test-server/instrumentation-backend/.classpath +0 -1
- data/test-server/instrumentation-backend/antlr/UIQuery.g +11 -2
- data/test-server/instrumentation-backend/src/sh/calaba/instrumentationbackend/Command.java +4 -3
- data/test-server/instrumentation-backend/src/sh/calaba/instrumentationbackend/FranklyResult.java +95 -0
- data/test-server/instrumentation-backend/src/sh/calaba/instrumentationbackend/Result.java +7 -1
- data/test-server/instrumentation-backend/src/sh/calaba/instrumentationbackend/actions/HttpServer.java +15 -23
- data/test-server/instrumentation-backend/src/sh/calaba/instrumentationbackend/actions/location/FakeGPSLocation.java +13 -10
- data/test-server/instrumentation-backend/src/sh/calaba/instrumentationbackend/actions/webview/CalabashChromeClient.java +136 -36
- data/test-server/instrumentation-backend/src/sh/calaba/instrumentationbackend/actions/webview/DumpBodyHtml.java +38 -18
- data/test-server/instrumentation-backend/src/sh/calaba/instrumentationbackend/actions/webview/DumpHtml.java +38 -16
- data/test-server/instrumentation-backend/src/sh/calaba/instrumentationbackend/actions/webview/EnterTextByCssSelector.java +94 -66
- data/test-server/instrumentation-backend/src/sh/calaba/instrumentationbackend/actions/webview/ExecuteAsyncJavascript.java +55 -33
- data/test-server/instrumentation-backend/src/sh/calaba/instrumentationbackend/actions/webview/ExecuteJavascript.java +54 -31
- data/test-server/instrumentation-backend/src/sh/calaba/instrumentationbackend/actions/webview/JavaScriptOperation.java +44 -0
- data/test-server/instrumentation-backend/src/sh/calaba/instrumentationbackend/actions/webview/PressByCssSelector.java +52 -27
- data/test-server/instrumentation-backend/src/sh/calaba/instrumentationbackend/actions/webview/QueryHelper.java +39 -32
- data/test-server/instrumentation-backend/src/sh/calaba/instrumentationbackend/actions/webview/ScrollTo.java +56 -41
- data/test-server/instrumentation-backend/src/sh/calaba/instrumentationbackend/actions/webview/SetPropertyByCssSelector.java +50 -25
- data/test-server/instrumentation-backend/src/sh/calaba/instrumentationbackend/actions/webview/SetText.java +19 -22
- data/test-server/instrumentation-backend/src/sh/calaba/instrumentationbackend/query/CompletedFuture.java +40 -0
- data/test-server/instrumentation-backend/src/sh/calaba/instrumentationbackend/query/InvocationOperation.java +201 -0
- data/test-server/instrumentation-backend/src/sh/calaba/instrumentationbackend/query/Operation.java +7 -0
- data/test-server/instrumentation-backend/src/sh/calaba/instrumentationbackend/query/PropertyOperation.java +56 -0
- data/test-server/instrumentation-backend/src/sh/calaba/instrumentationbackend/query/Query.java +144 -72
- data/test-server/instrumentation-backend/src/sh/calaba/instrumentationbackend/query/UIQuery.tokens +15 -12
- data/test-server/instrumentation-backend/src/sh/calaba/instrumentationbackend/query/UIQueryResultVoid.java +22 -0
- data/test-server/instrumentation-backend/src/sh/calaba/instrumentationbackend/query/ViewMapper.java +38 -11
- data/test-server/instrumentation-backend/src/sh/calaba/instrumentationbackend/query/antlr/UIQueryLexer.java +226 -109
- data/test-server/instrumentation-backend/src/sh/calaba/instrumentationbackend/query/antlr/UIQueryParser.java +237 -84
- data/test-server/instrumentation-backend/src/sh/calaba/instrumentationbackend/query/ast/PartialFutureList.java +100 -0
- data/test-server/instrumentation-backend/src/sh/calaba/instrumentationbackend/query/ast/UIQueryAST.java +1 -1
- data/test-server/instrumentation-backend/src/sh/calaba/instrumentationbackend/query/ast/UIQueryASTClassName.java +26 -22
- data/test-server/instrumentation-backend/src/sh/calaba/instrumentationbackend/query/ast/UIQueryASTWith.java +170 -102
- data/test-server/instrumentation-backend/src/sh/calaba/instrumentationbackend/query/ast/UIQueryEvaluator.java +54 -155
- data/test-server/instrumentation-backend/src/sh/calaba/instrumentationbackend/query/ast/UIQueryUtils.java +97 -2
- data/test-server/instrumentation-backend/src/sh/calaba/instrumentationbackend/query/ast/UIQueryVisibility.java +32 -0
- metadata +27 -5
- data/test-server/instrumentation-backend/src/sh/calaba/instrumentationbackend/actions/webview/Query.java +0 -24
- data/test-server/instrumentation-backend/src/sh/calaba/instrumentationbackend/actions/webview/Touch.java +0 -44
- data/test-server/instrumentation-backend/tests/sh/calaba/instrumentationbackend/query/tests/UIQueryTest.java +0 -134
@@ -0,0 +1,56 @@
|
|
1
|
+
package sh.calaba.instrumentationbackend.query;
|
2
|
+
|
3
|
+
import java.lang.reflect.Method;
|
4
|
+
import java.util.Map;
|
5
|
+
|
6
|
+
import sh.calaba.instrumentationbackend.query.ast.UIQueryUtils;
|
7
|
+
import android.view.View;
|
8
|
+
|
9
|
+
public class PropertyOperation implements Operation {
|
10
|
+
|
11
|
+
public final String propertyName;
|
12
|
+
|
13
|
+
public PropertyOperation(String propertyName) {
|
14
|
+
super();
|
15
|
+
this.propertyName = propertyName;
|
16
|
+
}
|
17
|
+
|
18
|
+
|
19
|
+
@SuppressWarnings({ "rawtypes" })
|
20
|
+
@Override
|
21
|
+
public Object apply(Object o) throws Exception {
|
22
|
+
if (o instanceof Map) {
|
23
|
+
Map objAsMap = (Map) o;
|
24
|
+
if (objAsMap.containsKey(propertyName)) {
|
25
|
+
return objAsMap.get(propertyName);
|
26
|
+
} else {
|
27
|
+
return UIQueryResultVoid.instance.asMap(
|
28
|
+
propertyName, o, "No key for "
|
29
|
+
+ propertyName + ". Keys: "
|
30
|
+
+ (objAsMap.keySet().toString()));
|
31
|
+
}
|
32
|
+
} else {
|
33
|
+
if (o instanceof View && "id".equals(propertyName)) {
|
34
|
+
return UIQueryUtils.getId((View) o);
|
35
|
+
} else {
|
36
|
+
Method m = UIQueryUtils
|
37
|
+
.hasProperty(o, propertyName);
|
38
|
+
if (m != null) {
|
39
|
+
return m.invoke(o);
|
40
|
+
} else {
|
41
|
+
return UIQueryResultVoid.instance
|
42
|
+
.asMap(propertyName, o,
|
43
|
+
"NO accessor for "
|
44
|
+
+ propertyName);
|
45
|
+
}
|
46
|
+
}
|
47
|
+
}
|
48
|
+
|
49
|
+
}
|
50
|
+
|
51
|
+
@Override
|
52
|
+
public String getName() {
|
53
|
+
return "Property["+this.propertyName+"]";
|
54
|
+
}
|
55
|
+
|
56
|
+
}
|
data/test-server/instrumentation-backend/src/sh/calaba/instrumentationbackend/query/Query.java
CHANGED
@@ -6,96 +6,168 @@ import java.util.ArrayList;
|
|
6
6
|
import java.util.Collections;
|
7
7
|
import java.util.HashSet;
|
8
8
|
import java.util.List;
|
9
|
+
import java.util.Map;
|
9
10
|
import java.util.Set;
|
10
|
-
import java.util.concurrent.atomic.AtomicReference;
|
11
11
|
|
12
|
-
import
|
12
|
+
import org.antlr.runtime.ANTLRStringStream;
|
13
|
+
import org.antlr.runtime.CommonTokenStream;
|
14
|
+
import org.antlr.runtime.RecognitionException;
|
15
|
+
import org.antlr.runtime.tree.CommonTree;
|
16
|
+
|
17
|
+
import sh.calaba.instrumentationbackend.query.antlr.UIQueryLexer;
|
18
|
+
import sh.calaba.instrumentationbackend.query.antlr.UIQueryParser;
|
19
|
+
import sh.calaba.instrumentationbackend.query.ast.InvalidUIQueryException;
|
20
|
+
import sh.calaba.instrumentationbackend.query.ast.UIQueryAST;
|
21
|
+
import sh.calaba.instrumentationbackend.query.ast.UIQueryASTClassName;
|
22
|
+
import sh.calaba.instrumentationbackend.query.ast.UIQueryASTWith;
|
13
23
|
import sh.calaba.instrumentationbackend.query.ast.UIQueryEvaluator;
|
14
|
-
import sh.calaba.instrumentationbackend.query.ast.
|
15
|
-
import android.os.Looper;
|
24
|
+
import sh.calaba.instrumentationbackend.query.ast.UIQueryVisibility;
|
16
25
|
import android.view.View;
|
17
26
|
|
18
27
|
public class Query {
|
19
28
|
|
20
|
-
|
29
|
+
private String queryString;
|
21
30
|
@SuppressWarnings("rawtypes")
|
22
|
-
private List
|
31
|
+
private List operations;
|
23
32
|
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
33
|
+
public Query(String queryString) {
|
34
|
+
this.queryString = queryString;
|
35
|
+
this.operations = Collections.EMPTY_LIST;
|
36
|
+
if (this.queryString == null || this.queryString.trim().equals("")) {
|
37
|
+
throw new IllegalArgumentException("Illegal query: "
|
38
|
+
+ this.queryString);
|
39
|
+
}
|
40
|
+
}
|
32
41
|
|
33
|
-
|
34
|
-
public Query(String queryString,List args) {
|
35
|
-
|
36
|
-
|
37
|
-
|
42
|
+
@SuppressWarnings("rawtypes")
|
43
|
+
public Query(String queryString, List args) {
|
44
|
+
this(queryString);
|
45
|
+
this.operations = args;
|
46
|
+
}
|
38
47
|
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
48
|
+
@SuppressWarnings("rawtypes")
|
49
|
+
public List executeQuery() {
|
50
|
+
return UIQueryEvaluator.evaluateQueryWithOptions(parseQuery(this.queryString), rootViews(), parseOperations(this.operations));
|
51
|
+
}
|
52
|
+
|
53
|
+
@SuppressWarnings("rawtypes")
|
54
|
+
public static List<Operation> parseOperations(List ops) {
|
55
|
+
List<Operation> result = new ArrayList<Operation>(ops.size());
|
56
|
+
for (Object o : ops) {
|
57
|
+
Operation op = null;
|
58
|
+
if (o instanceof Operation) {
|
59
|
+
op = (Operation) o;
|
60
|
+
}
|
61
|
+
else if (o instanceof String) {
|
62
|
+
op = new PropertyOperation((String) o);
|
63
|
+
}
|
64
|
+
else if (o instanceof Map) {
|
65
|
+
Map mapOp = (Map) o;
|
66
|
+
String methodName = (String) mapOp.get("method_name");
|
67
|
+
if (methodName == null) {
|
68
|
+
throw new IllegalArgumentException("Trying to convert a Map without method_name to an operation. " + mapOp.toString());
|
69
|
+
}
|
70
|
+
List arguments = (List) mapOp.get("arguments");
|
71
|
+
if (arguments == null) {
|
72
|
+
throw new IllegalArgumentException("Trying to convert a Map without arguments to an operation. " + mapOp.toString());
|
73
|
+
}
|
74
|
+
op = new InvocationOperation(methodName, arguments);
|
75
|
+
}
|
76
|
+
result.add(op);
|
77
|
+
}
|
78
|
+
return result;
|
79
|
+
}
|
44
80
|
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
result.set(execute());
|
50
|
-
}
|
51
|
-
});
|
52
|
-
return result.get();
|
81
|
+
@SuppressWarnings("unchecked")
|
82
|
+
public static List<UIQueryAST> parseQuery(String query) {
|
83
|
+
UIQueryLexer lexer = new UIQueryLexer(new ANTLRStringStream(query));
|
84
|
+
UIQueryParser parser = new UIQueryParser(new CommonTokenStream(lexer));
|
53
85
|
|
54
|
-
|
86
|
+
UIQueryParser.query_return q;
|
87
|
+
try {
|
88
|
+
q = parser.query();
|
89
|
+
} catch (RecognitionException e) {
|
90
|
+
throw new InvalidUIQueryException(e.getMessage());
|
91
|
+
}
|
92
|
+
if (q == null) {
|
93
|
+
throw new InvalidUIQueryException(query);
|
94
|
+
}
|
95
|
+
CommonTree rootNode = (CommonTree) q.getTree();
|
96
|
+
List<CommonTree> queryPath = rootNode.getChildren();
|
97
|
+
|
98
|
+
if (queryPath == null || queryPath.isEmpty()) {
|
99
|
+
queryPath = Collections.singletonList(rootNode);
|
100
|
+
}
|
55
101
|
|
56
|
-
|
57
|
-
|
58
|
-
|
59
|
-
|
60
|
-
|
61
|
-
|
62
|
-
|
63
|
-
|
64
|
-
|
102
|
+
return mapUIQueryFromAstNodes(queryPath);
|
103
|
+
}
|
104
|
+
|
105
|
+
|
106
|
+
public static List<UIQueryAST> mapUIQueryFromAstNodes(List<CommonTree> nodes) {
|
107
|
+
List<UIQueryAST> mapped = new ArrayList<UIQueryAST>(nodes.size());
|
108
|
+
for (CommonTree t : nodes) {
|
109
|
+
mapped.add(uiQueryFromAst(t));
|
110
|
+
}
|
111
|
+
return mapped;
|
112
|
+
}
|
113
|
+
|
114
|
+
public static UIQueryAST uiQueryFromAst(CommonTree step) {
|
115
|
+
String stepType = UIQueryParser.tokenNames[step.getType()];
|
116
|
+
switch (step.getType()) {
|
117
|
+
case UIQueryParser.QUALIFIED_NAME:
|
118
|
+
try {
|
119
|
+
return new UIQueryASTClassName(Class.forName(step.getText()));
|
120
|
+
} catch (ClassNotFoundException e) {
|
121
|
+
// TODO Auto-generated catch block
|
122
|
+
throw new InvalidUIQueryException("Qualified class name: "
|
123
|
+
+ step.getText() + " not found. (" + e.getMessage()
|
124
|
+
+ ")");
|
125
|
+
}
|
126
|
+
case UIQueryParser.NAME:
|
127
|
+
return new UIQueryASTClassName(step.getText());
|
65
128
|
|
66
|
-
|
67
|
-
|
68
|
-
|
69
|
-
|
70
|
-
|
71
|
-
|
72
|
-
|
73
|
-
for (Object v : queryResults) {
|
74
|
-
if (UIQueryUtils.isVisible(v)) {
|
75
|
-
System.out.println("Query result: "+v);
|
76
|
-
result.add(ViewMapper.extractDataFromView(v));
|
77
|
-
}
|
78
|
-
|
79
|
-
}
|
80
|
-
|
81
|
-
return new QueryResult(result);
|
82
|
-
}
|
129
|
+
case UIQueryParser.WILDCARD:
|
130
|
+
try {
|
131
|
+
return new UIQueryASTClassName(Class.forName("android.view.View"));
|
132
|
+
} catch (ClassNotFoundException e) {
|
133
|
+
//Cannot happen
|
134
|
+
throw new IllegalStateException(e);
|
135
|
+
}
|
83
136
|
|
137
|
+
|
138
|
+
case UIQueryParser.FILTER_COLON:
|
139
|
+
return UIQueryASTWith.fromAST(step);
|
140
|
+
|
141
|
+
case UIQueryParser.ALL:
|
142
|
+
return UIQueryVisibility.ALL;
|
143
|
+
|
144
|
+
case UIQueryParser.VISIBLE:
|
145
|
+
return UIQueryVisibility.VISIBLE;
|
146
|
+
|
147
|
+
default:
|
148
|
+
throw new InvalidUIQueryException("Unknown query: " + stepType
|
149
|
+
+ " with text: " + step.getText());
|
84
150
|
|
85
|
-
|
86
|
-
|
87
|
-
|
151
|
+
}
|
152
|
+
|
153
|
+
}
|
154
|
+
|
155
|
+
public List<View> allVisibleViews() {
|
156
|
+
return viewFetcher.getAllViews(false);
|
157
|
+
}
|
88
158
|
|
89
159
|
public List<View> rootViews() {
|
90
|
-
|
91
|
-
|
92
|
-
|
93
|
-
|
94
|
-
|
95
|
-
|
96
|
-
|
97
|
-
|
98
|
-
|
99
|
-
|
160
|
+
Set<View> parents = new HashSet<View>();
|
161
|
+
for (View v : allVisibleViews())
|
162
|
+
{
|
163
|
+
View parent = viewFetcher.getTopParent(v);
|
164
|
+
System.out.println(parent);
|
165
|
+
parents.add(parent);
|
166
|
+
}
|
167
|
+
List<View> results = new ArrayList<View>();
|
168
|
+
results.addAll(parents);
|
169
|
+
return results;
|
100
170
|
}
|
171
|
+
|
172
|
+
|
101
173
|
}
|
data/test-server/instrumentation-backend/src/sh/calaba/instrumentationbackend/query/UIQuery.tokens
CHANGED
@@ -1,12 +1,15 @@
|
|
1
|
-
|
2
|
-
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
1
|
+
ALL=4
|
2
|
+
BOOL=5
|
3
|
+
ESC_SEQ=6
|
4
|
+
FILTER_COLON=7
|
5
|
+
HEX_DIGIT=8
|
6
|
+
INT=9
|
7
|
+
NAME=10
|
8
|
+
NIL=11
|
9
|
+
OCTAL_ESC=12
|
10
|
+
QUALIFIED_NAME=13
|
11
|
+
STRING=14
|
12
|
+
UNICODE_ESC=15
|
13
|
+
VISIBLE=16
|
14
|
+
WHITE=17
|
15
|
+
WILDCARD=18
|
@@ -0,0 +1,22 @@
|
|
1
|
+
package sh.calaba.instrumentationbackend.query;
|
2
|
+
|
3
|
+
import java.util.HashMap;
|
4
|
+
import java.util.Map;
|
5
|
+
|
6
|
+
|
7
|
+
public class UIQueryResultVoid {
|
8
|
+
public static final UIQueryResultVoid instance = new UIQueryResultVoid();
|
9
|
+
|
10
|
+
private UIQueryResultVoid() {}
|
11
|
+
|
12
|
+
@SuppressWarnings({ "rawtypes", "unchecked" })
|
13
|
+
public Object asMap(String methodName, Object receiver,
|
14
|
+
String errorMessage) {
|
15
|
+
Map map = new HashMap();
|
16
|
+
map.put("error", errorMessage);
|
17
|
+
map.put("methodName", methodName);
|
18
|
+
map.put("receiverClass", receiver.getClass().getName());
|
19
|
+
map.put("receiverString", receiver.toString());
|
20
|
+
return map;
|
21
|
+
}
|
22
|
+
}
|
data/test-server/instrumentation-backend/src/sh/calaba/instrumentationbackend/query/ViewMapper.java
CHANGED
@@ -2,8 +2,10 @@ package sh.calaba.instrumentationbackend.query;
|
|
2
2
|
|
3
3
|
import java.util.HashMap;
|
4
4
|
import java.util.Map;
|
5
|
+
import java.util.Map.Entry;
|
5
6
|
|
6
7
|
import sh.calaba.instrumentationbackend.InstrumentationBackend;
|
8
|
+
import sh.calaba.instrumentationbackend.query.ast.UIQueryUtils;
|
7
9
|
import android.content.res.Resources;
|
8
10
|
import android.view.View;
|
9
11
|
import android.widget.Button;
|
@@ -13,12 +15,10 @@ import android.widget.TextView;
|
|
13
15
|
public class ViewMapper {
|
14
16
|
|
15
17
|
@SuppressWarnings({ "rawtypes", "unchecked" })
|
16
|
-
public static Object extractDataFromView(
|
17
|
-
|
18
|
-
View v = (View) obj;
|
18
|
+
public static Object extractDataFromView(View v) {
|
19
|
+
|
19
20
|
Map data = new HashMap();
|
20
|
-
data.put("class", v.getClass().
|
21
|
-
data.put("qualified_class", v.getClass().getName());
|
21
|
+
data.put("class", v.getClass().getName());
|
22
22
|
data.put("description", v.toString());
|
23
23
|
CharSequence description = v.getContentDescription();
|
24
24
|
data.put("contentDescription", description != null ? description.toString() : null);
|
@@ -33,16 +33,20 @@ public class ViewMapper {
|
|
33
33
|
}
|
34
34
|
data.put("id", id);
|
35
35
|
|
36
|
-
Map
|
36
|
+
Map rect = new HashMap();
|
37
37
|
int[] location = new int[2];
|
38
38
|
v.getLocationOnScreen(location);
|
39
39
|
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
40
|
+
rect.put("x", location[0]);
|
41
|
+
rect.put("y", location[1]);
|
42
|
+
|
43
|
+
rect.put("center_x", location[0] + v.getWidth()/2.0);
|
44
|
+
rect.put("center_y", location[1] + v.getHeight()/2.0);
|
45
|
+
|
46
|
+
rect.put("width", v.getWidth());
|
47
|
+
rect.put("height", v.getHeight());
|
44
48
|
|
45
|
-
data.put("
|
49
|
+
data.put("rect", rect);
|
46
50
|
|
47
51
|
if (v instanceof Button) {
|
48
52
|
Button b = (Button) v;
|
@@ -60,4 +64,27 @@ public class ViewMapper {
|
|
60
64
|
|
61
65
|
}
|
62
66
|
|
67
|
+
@SuppressWarnings({ "unchecked", "rawtypes" })
|
68
|
+
public static Object mapView(Object o) {
|
69
|
+
if (o instanceof View) {
|
70
|
+
return extractDataFromView((View) o);
|
71
|
+
}
|
72
|
+
else if (o instanceof Map) {
|
73
|
+
Map copy = new HashMap();
|
74
|
+
for (Object e : ((Map) o).entrySet()) {
|
75
|
+
Map.Entry entry = (Entry) e;
|
76
|
+
Object value = entry.getValue();
|
77
|
+
if (value instanceof View) {
|
78
|
+
copy.put(entry.getKey(), UIQueryUtils.getId((View) value));
|
79
|
+
}
|
80
|
+
else {
|
81
|
+
copy.put(entry.getKey(),entry.getValue());
|
82
|
+
}
|
83
|
+
}
|
84
|
+
|
85
|
+
return copy;
|
86
|
+
}
|
87
|
+
return o;
|
88
|
+
}
|
89
|
+
|
63
90
|
}
|
@@ -1,4 +1,4 @@
|
|
1
|
-
// $ANTLR 3.4 antlr/UIQuery.g
|
1
|
+
// $ANTLR 3.4 antlr/UIQuery.g 2013-01-07 13:26:07
|
2
2
|
|
3
3
|
package sh.calaba.instrumentationbackend.query.antlr;
|
4
4
|
|
@@ -11,18 +11,21 @@ import java.util.ArrayList;
|
|
11
11
|
@SuppressWarnings({"all", "warnings", "unchecked"})
|
12
12
|
public class UIQueryLexer extends Lexer {
|
13
13
|
public static final int EOF=-1;
|
14
|
-
public static final int
|
15
|
-
public static final int
|
16
|
-
public static final int
|
17
|
-
public static final int
|
18
|
-
public static final int
|
19
|
-
public static final int
|
20
|
-
public static final int
|
21
|
-
public static final int
|
22
|
-
public static final int
|
23
|
-
public static final int
|
24
|
-
public static final int
|
25
|
-
public static final int
|
14
|
+
public static final int ALL=4;
|
15
|
+
public static final int BOOL=5;
|
16
|
+
public static final int ESC_SEQ=6;
|
17
|
+
public static final int FILTER_COLON=7;
|
18
|
+
public static final int HEX_DIGIT=8;
|
19
|
+
public static final int INT=9;
|
20
|
+
public static final int NAME=10;
|
21
|
+
public static final int NIL=11;
|
22
|
+
public static final int OCTAL_ESC=12;
|
23
|
+
public static final int QUALIFIED_NAME=13;
|
24
|
+
public static final int STRING=14;
|
25
|
+
public static final int UNICODE_ESC=15;
|
26
|
+
public static final int VISIBLE=16;
|
27
|
+
public static final int WHITE=17;
|
28
|
+
public static final int WILDCARD=18;
|
26
29
|
|
27
30
|
// delegates
|
28
31
|
// delegators
|
@@ -39,18 +42,39 @@ public class UIQueryLexer extends Lexer {
|
|
39
42
|
}
|
40
43
|
public String getGrammarFileName() { return "antlr/UIQuery.g"; }
|
41
44
|
|
45
|
+
// $ANTLR start "WILDCARD"
|
46
|
+
public final void mWILDCARD() throws RecognitionException {
|
47
|
+
try {
|
48
|
+
int _type = WILDCARD;
|
49
|
+
int _channel = DEFAULT_TOKEN_CHANNEL;
|
50
|
+
// antlr/UIQuery.g:43:10: ( '*' )
|
51
|
+
// antlr/UIQuery.g:43:12: '*'
|
52
|
+
{
|
53
|
+
match('*');
|
54
|
+
|
55
|
+
}
|
56
|
+
|
57
|
+
state.type = _type;
|
58
|
+
state.channel = _channel;
|
59
|
+
}
|
60
|
+
finally {
|
61
|
+
// do for sure before leaving
|
62
|
+
}
|
63
|
+
}
|
64
|
+
// $ANTLR end "WILDCARD"
|
65
|
+
|
42
66
|
// $ANTLR start "QUALIFIED_NAME"
|
43
67
|
public final void mQUALIFIED_NAME() throws RecognitionException {
|
44
68
|
try {
|
45
69
|
int _type = QUALIFIED_NAME;
|
46
70
|
int _channel = DEFAULT_TOKEN_CHANNEL;
|
47
|
-
// antlr/UIQuery.g:
|
48
|
-
// antlr/UIQuery.g:
|
71
|
+
// antlr/UIQuery.g:45:16: ( NAME ( '.' NAME )+ )
|
72
|
+
// antlr/UIQuery.g:45:18: NAME ( '.' NAME )+
|
49
73
|
{
|
50
74
|
mNAME();
|
51
75
|
|
52
76
|
|
53
|
-
// antlr/UIQuery.g:
|
77
|
+
// antlr/UIQuery.g:45:23: ( '.' NAME )+
|
54
78
|
int cnt1=0;
|
55
79
|
loop1:
|
56
80
|
do {
|
@@ -64,7 +88,7 @@ public class UIQueryLexer extends Lexer {
|
|
64
88
|
|
65
89
|
switch (alt1) {
|
66
90
|
case 1 :
|
67
|
-
// antlr/UIQuery.g:
|
91
|
+
// antlr/UIQuery.g:45:24: '.' NAME
|
68
92
|
{
|
69
93
|
match('.');
|
70
94
|
|
@@ -95,13 +119,59 @@ public class UIQueryLexer extends Lexer {
|
|
95
119
|
}
|
96
120
|
// $ANTLR end "QUALIFIED_NAME"
|
97
121
|
|
122
|
+
// $ANTLR start "ALL"
|
123
|
+
public final void mALL() throws RecognitionException {
|
124
|
+
try {
|
125
|
+
int _type = ALL;
|
126
|
+
int _channel = DEFAULT_TOKEN_CHANNEL;
|
127
|
+
// antlr/UIQuery.g:49:5: ( 'all' )
|
128
|
+
// antlr/UIQuery.g:49:7: 'all'
|
129
|
+
{
|
130
|
+
match("all");
|
131
|
+
|
132
|
+
|
133
|
+
|
134
|
+
}
|
135
|
+
|
136
|
+
state.type = _type;
|
137
|
+
state.channel = _channel;
|
138
|
+
}
|
139
|
+
finally {
|
140
|
+
// do for sure before leaving
|
141
|
+
}
|
142
|
+
}
|
143
|
+
// $ANTLR end "ALL"
|
144
|
+
|
145
|
+
// $ANTLR start "VISIBLE"
|
146
|
+
public final void mVISIBLE() throws RecognitionException {
|
147
|
+
try {
|
148
|
+
int _type = VISIBLE;
|
149
|
+
int _channel = DEFAULT_TOKEN_CHANNEL;
|
150
|
+
// antlr/UIQuery.g:51:9: ( 'visible' )
|
151
|
+
// antlr/UIQuery.g:51:11: 'visible'
|
152
|
+
{
|
153
|
+
match("visible");
|
154
|
+
|
155
|
+
|
156
|
+
|
157
|
+
}
|
158
|
+
|
159
|
+
state.type = _type;
|
160
|
+
state.channel = _channel;
|
161
|
+
}
|
162
|
+
finally {
|
163
|
+
// do for sure before leaving
|
164
|
+
}
|
165
|
+
}
|
166
|
+
// $ANTLR end "VISIBLE"
|
167
|
+
|
98
168
|
// $ANTLR start "FILTER_COLON"
|
99
169
|
public final void mFILTER_COLON() throws RecognitionException {
|
100
170
|
try {
|
101
171
|
int _type = FILTER_COLON;
|
102
172
|
int _channel = DEFAULT_TOKEN_CHANNEL;
|
103
|
-
// antlr/UIQuery.g:
|
104
|
-
// antlr/UIQuery.g:
|
173
|
+
// antlr/UIQuery.g:56:15: ( ':' )
|
174
|
+
// antlr/UIQuery.g:56:17: ':'
|
105
175
|
{
|
106
176
|
match(':');
|
107
177
|
|
@@ -121,10 +191,10 @@ public class UIQueryLexer extends Lexer {
|
|
121
191
|
try {
|
122
192
|
int _type = INT;
|
123
193
|
int _channel = DEFAULT_TOKEN_CHANNEL;
|
124
|
-
// antlr/UIQuery.g:
|
125
|
-
// antlr/UIQuery.g:
|
194
|
+
// antlr/UIQuery.g:60:5: ( ( '0' .. '9' )+ )
|
195
|
+
// antlr/UIQuery.g:60:7: ( '0' .. '9' )+
|
126
196
|
{
|
127
|
-
// antlr/UIQuery.g:
|
197
|
+
// antlr/UIQuery.g:60:7: ( '0' .. '9' )+
|
128
198
|
int cnt2=0;
|
129
199
|
loop2:
|
130
200
|
do {
|
@@ -179,7 +249,7 @@ public class UIQueryLexer extends Lexer {
|
|
179
249
|
try {
|
180
250
|
int _type = BOOL;
|
181
251
|
int _channel = DEFAULT_TOKEN_CHANNEL;
|
182
|
-
// antlr/UIQuery.g:
|
252
|
+
// antlr/UIQuery.g:63:6: ( 'true' | 'false' )
|
183
253
|
int alt3=2;
|
184
254
|
int LA3_0 = input.LA(1);
|
185
255
|
|
@@ -198,7 +268,7 @@ public class UIQueryLexer extends Lexer {
|
|
198
268
|
}
|
199
269
|
switch (alt3) {
|
200
270
|
case 1 :
|
201
|
-
// antlr/UIQuery.g:
|
271
|
+
// antlr/UIQuery.g:63:8: 'true'
|
202
272
|
{
|
203
273
|
match("true");
|
204
274
|
|
@@ -207,7 +277,7 @@ public class UIQueryLexer extends Lexer {
|
|
207
277
|
}
|
208
278
|
break;
|
209
279
|
case 2 :
|
210
|
-
// antlr/UIQuery.g:
|
280
|
+
// antlr/UIQuery.g:63:17: 'false'
|
211
281
|
{
|
212
282
|
match("false");
|
213
283
|
|
@@ -231,7 +301,7 @@ public class UIQueryLexer extends Lexer {
|
|
231
301
|
try {
|
232
302
|
int _type = NIL;
|
233
303
|
int _channel = DEFAULT_TOKEN_CHANNEL;
|
234
|
-
// antlr/UIQuery.g:
|
304
|
+
// antlr/UIQuery.g:66:5: ( 'nil' | 'null' )
|
235
305
|
int alt4=2;
|
236
306
|
int LA4_0 = input.LA(1);
|
237
307
|
|
@@ -261,7 +331,7 @@ public class UIQueryLexer extends Lexer {
|
|
261
331
|
}
|
262
332
|
switch (alt4) {
|
263
333
|
case 1 :
|
264
|
-
// antlr/UIQuery.g:
|
334
|
+
// antlr/UIQuery.g:66:7: 'nil'
|
265
335
|
{
|
266
336
|
match("nil");
|
267
337
|
|
@@ -270,7 +340,7 @@ public class UIQueryLexer extends Lexer {
|
|
270
340
|
}
|
271
341
|
break;
|
272
342
|
case 2 :
|
273
|
-
// antlr/UIQuery.g:
|
343
|
+
// antlr/UIQuery.g:66:15: 'null'
|
274
344
|
{
|
275
345
|
match("null");
|
276
346
|
|
@@ -294,8 +364,8 @@ public class UIQueryLexer extends Lexer {
|
|
294
364
|
try {
|
295
365
|
int _type = NAME;
|
296
366
|
int _channel = DEFAULT_TOKEN_CHANNEL;
|
297
|
-
// antlr/UIQuery.g:
|
298
|
-
// antlr/UIQuery.g:
|
367
|
+
// antlr/UIQuery.g:69:7: ( ( 'a' .. 'z' | 'A' .. 'Z' | '_' ) ( 'a' .. 'z' | 'A' .. 'Z' | '0' .. '9' | '_' )* )
|
368
|
+
// antlr/UIQuery.g:69:9: ( 'a' .. 'z' | 'A' .. 'Z' | '_' ) ( 'a' .. 'z' | 'A' .. 'Z' | '0' .. '9' | '_' )*
|
299
369
|
{
|
300
370
|
if ( (input.LA(1) >= 'A' && input.LA(1) <= 'Z')||input.LA(1)=='_'||(input.LA(1) >= 'a' && input.LA(1) <= 'z') ) {
|
301
371
|
input.consume();
|
@@ -307,7 +377,7 @@ public class UIQueryLexer extends Lexer {
|
|
307
377
|
}
|
308
378
|
|
309
379
|
|
310
|
-
// antlr/UIQuery.g:
|
380
|
+
// antlr/UIQuery.g:69:33: ( 'a' .. 'z' | 'A' .. 'Z' | '0' .. '9' | '_' )*
|
311
381
|
loop5:
|
312
382
|
do {
|
313
383
|
int alt5=2;
|
@@ -357,12 +427,12 @@ public class UIQueryLexer extends Lexer {
|
|
357
427
|
try {
|
358
428
|
int _type = STRING;
|
359
429
|
int _channel = DEFAULT_TOKEN_CHANNEL;
|
360
|
-
// antlr/UIQuery.g:
|
361
|
-
// antlr/UIQuery.g:
|
430
|
+
// antlr/UIQuery.g:73:5: ( '\\'' ( ESC_SEQ |~ ( '\\\\' | '\\'' ) )* '\\'' )
|
431
|
+
// antlr/UIQuery.g:73:8: '\\'' ( ESC_SEQ |~ ( '\\\\' | '\\'' ) )* '\\''
|
362
432
|
{
|
363
433
|
match('\'');
|
364
434
|
|
365
|
-
// antlr/UIQuery.g:
|
435
|
+
// antlr/UIQuery.g:73:13: ( ESC_SEQ |~ ( '\\\\' | '\\'' ) )*
|
366
436
|
loop6:
|
367
437
|
do {
|
368
438
|
int alt6=3;
|
@@ -378,7 +448,7 @@ public class UIQueryLexer extends Lexer {
|
|
378
448
|
|
379
449
|
switch (alt6) {
|
380
450
|
case 1 :
|
381
|
-
// antlr/UIQuery.g:
|
451
|
+
// antlr/UIQuery.g:73:15: ESC_SEQ
|
382
452
|
{
|
383
453
|
mESC_SEQ();
|
384
454
|
|
@@ -386,7 +456,7 @@ public class UIQueryLexer extends Lexer {
|
|
386
456
|
}
|
387
457
|
break;
|
388
458
|
case 2 :
|
389
|
-
// antlr/UIQuery.g:
|
459
|
+
// antlr/UIQuery.g:73:25: ~ ( '\\\\' | '\\'' )
|
390
460
|
{
|
391
461
|
if ( (input.LA(1) >= '\u0000' && input.LA(1) <= '&')||(input.LA(1) >= '(' && input.LA(1) <= '[')||(input.LA(1) >= ']' && input.LA(1) <= '\uFFFF') ) {
|
392
462
|
input.consume();
|
@@ -425,10 +495,10 @@ public class UIQueryLexer extends Lexer {
|
|
425
495
|
try {
|
426
496
|
int _type = WHITE;
|
427
497
|
int _channel = DEFAULT_TOKEN_CHANNEL;
|
428
|
-
// antlr/UIQuery.g:
|
429
|
-
// antlr/UIQuery.g:
|
498
|
+
// antlr/UIQuery.g:76:9: ( ( ' ' )+ )
|
499
|
+
// antlr/UIQuery.g:76:11: ( ' ' )+
|
430
500
|
{
|
431
|
-
// antlr/UIQuery.g:
|
501
|
+
// antlr/UIQuery.g:76:11: ( ' ' )+
|
432
502
|
int cnt7=0;
|
433
503
|
loop7:
|
434
504
|
do {
|
@@ -442,7 +512,7 @@ public class UIQueryLexer extends Lexer {
|
|
442
512
|
|
443
513
|
switch (alt7) {
|
444
514
|
case 1 :
|
445
|
-
// antlr/UIQuery.g:
|
515
|
+
// antlr/UIQuery.g:76:11: ' '
|
446
516
|
{
|
447
517
|
match(' ');
|
448
518
|
|
@@ -473,7 +543,7 @@ public class UIQueryLexer extends Lexer {
|
|
473
543
|
// $ANTLR start "HEX_DIGIT"
|
474
544
|
public final void mHEX_DIGIT() throws RecognitionException {
|
475
545
|
try {
|
476
|
-
// antlr/UIQuery.g:
|
546
|
+
// antlr/UIQuery.g:79:11: ( ( '0' .. '9' | 'a' .. 'f' | 'A' .. 'F' ) )
|
477
547
|
// antlr/UIQuery.g:
|
478
548
|
{
|
479
549
|
if ( (input.LA(1) >= '0' && input.LA(1) <= '9')||(input.LA(1) >= 'A' && input.LA(1) <= 'F')||(input.LA(1) >= 'a' && input.LA(1) <= 'f') ) {
|
@@ -499,7 +569,7 @@ public class UIQueryLexer extends Lexer {
|
|
499
569
|
// $ANTLR start "ESC_SEQ"
|
500
570
|
public final void mESC_SEQ() throws RecognitionException {
|
501
571
|
try {
|
502
|
-
// antlr/UIQuery.g:
|
572
|
+
// antlr/UIQuery.g:83:5: ( '\\\\' ( 'b' | 't' | 'n' | 'f' | 'r' | '\\'' | '\\\\' ) | UNICODE_ESC | OCTAL_ESC )
|
503
573
|
int alt8=3;
|
504
574
|
int LA8_0 = input.LA(1);
|
505
575
|
|
@@ -551,7 +621,7 @@ public class UIQueryLexer extends Lexer {
|
|
551
621
|
}
|
552
622
|
switch (alt8) {
|
553
623
|
case 1 :
|
554
|
-
// antlr/UIQuery.g:
|
624
|
+
// antlr/UIQuery.g:83:9: '\\\\' ( 'b' | 't' | 'n' | 'f' | 'r' | '\\'' | '\\\\' )
|
555
625
|
{
|
556
626
|
match('\\');
|
557
627
|
|
@@ -568,7 +638,7 @@ public class UIQueryLexer extends Lexer {
|
|
568
638
|
}
|
569
639
|
break;
|
570
640
|
case 2 :
|
571
|
-
// antlr/UIQuery.g:
|
641
|
+
// antlr/UIQuery.g:84:9: UNICODE_ESC
|
572
642
|
{
|
573
643
|
mUNICODE_ESC();
|
574
644
|
|
@@ -576,7 +646,7 @@ public class UIQueryLexer extends Lexer {
|
|
576
646
|
}
|
577
647
|
break;
|
578
648
|
case 3 :
|
579
|
-
// antlr/UIQuery.g:
|
649
|
+
// antlr/UIQuery.g:85:9: OCTAL_ESC
|
580
650
|
{
|
581
651
|
mOCTAL_ESC();
|
582
652
|
|
@@ -596,7 +666,7 @@ public class UIQueryLexer extends Lexer {
|
|
596
666
|
// $ANTLR start "OCTAL_ESC"
|
597
667
|
public final void mOCTAL_ESC() throws RecognitionException {
|
598
668
|
try {
|
599
|
-
// antlr/UIQuery.g:
|
669
|
+
// antlr/UIQuery.g:90:5: ( '\\\\' ( '0' .. '3' ) ( '0' .. '7' ) ( '0' .. '7' ) | '\\\\' ( '0' .. '7' ) ( '0' .. '7' ) | '\\\\' ( '0' .. '7' ) )
|
600
670
|
int alt9=3;
|
601
671
|
int LA9_0 = input.LA(1);
|
602
672
|
|
@@ -647,7 +717,7 @@ public class UIQueryLexer extends Lexer {
|
|
647
717
|
}
|
648
718
|
switch (alt9) {
|
649
719
|
case 1 :
|
650
|
-
// antlr/UIQuery.g:
|
720
|
+
// antlr/UIQuery.g:90:9: '\\\\' ( '0' .. '3' ) ( '0' .. '7' ) ( '0' .. '7' )
|
651
721
|
{
|
652
722
|
match('\\');
|
653
723
|
|
@@ -684,7 +754,7 @@ public class UIQueryLexer extends Lexer {
|
|
684
754
|
}
|
685
755
|
break;
|
686
756
|
case 2 :
|
687
|
-
// antlr/UIQuery.g:
|
757
|
+
// antlr/UIQuery.g:91:9: '\\\\' ( '0' .. '7' ) ( '0' .. '7' )
|
688
758
|
{
|
689
759
|
match('\\');
|
690
760
|
|
@@ -711,7 +781,7 @@ public class UIQueryLexer extends Lexer {
|
|
711
781
|
}
|
712
782
|
break;
|
713
783
|
case 3 :
|
714
|
-
// antlr/UIQuery.g:
|
784
|
+
// antlr/UIQuery.g:92:9: '\\\\' ( '0' .. '7' )
|
715
785
|
{
|
716
786
|
match('\\');
|
717
787
|
|
@@ -740,8 +810,8 @@ public class UIQueryLexer extends Lexer {
|
|
740
810
|
// $ANTLR start "UNICODE_ESC"
|
741
811
|
public final void mUNICODE_ESC() throws RecognitionException {
|
742
812
|
try {
|
743
|
-
// antlr/UIQuery.g:
|
744
|
-
// antlr/UIQuery.g:
|
813
|
+
// antlr/UIQuery.g:97:5: ( '\\\\' 'u' HEX_DIGIT HEX_DIGIT HEX_DIGIT HEX_DIGIT )
|
814
|
+
// antlr/UIQuery.g:97:9: '\\\\' 'u' HEX_DIGIT HEX_DIGIT HEX_DIGIT HEX_DIGIT
|
745
815
|
{
|
746
816
|
match('\\');
|
747
817
|
|
@@ -770,68 +840,92 @@ public class UIQueryLexer extends Lexer {
|
|
770
840
|
// $ANTLR end "UNICODE_ESC"
|
771
841
|
|
772
842
|
public void mTokens() throws RecognitionException {
|
773
|
-
// antlr/UIQuery.g:1:8: ( QUALIFIED_NAME | FILTER_COLON | INT | BOOL | NIL | NAME | STRING | WHITE )
|
774
|
-
int alt10=
|
843
|
+
// antlr/UIQuery.g:1:8: ( WILDCARD | QUALIFIED_NAME | ALL | VISIBLE | FILTER_COLON | INT | BOOL | NIL | NAME | STRING | WHITE )
|
844
|
+
int alt10=11;
|
775
845
|
alt10 = dfa10.predict(input);
|
776
846
|
switch (alt10) {
|
777
847
|
case 1 :
|
778
|
-
// antlr/UIQuery.g:1:10:
|
848
|
+
// antlr/UIQuery.g:1:10: WILDCARD
|
779
849
|
{
|
780
|
-
|
850
|
+
mWILDCARD();
|
781
851
|
|
782
852
|
|
783
853
|
}
|
784
854
|
break;
|
785
855
|
case 2 :
|
786
|
-
// antlr/UIQuery.g:1:
|
856
|
+
// antlr/UIQuery.g:1:19: QUALIFIED_NAME
|
787
857
|
{
|
788
|
-
|
858
|
+
mQUALIFIED_NAME();
|
789
859
|
|
790
860
|
|
791
861
|
}
|
792
862
|
break;
|
793
863
|
case 3 :
|
794
|
-
// antlr/UIQuery.g:1:
|
864
|
+
// antlr/UIQuery.g:1:34: ALL
|
795
865
|
{
|
796
|
-
|
866
|
+
mALL();
|
797
867
|
|
798
868
|
|
799
869
|
}
|
800
870
|
break;
|
801
871
|
case 4 :
|
802
|
-
// antlr/UIQuery.g:1:
|
872
|
+
// antlr/UIQuery.g:1:38: VISIBLE
|
803
873
|
{
|
804
|
-
|
874
|
+
mVISIBLE();
|
805
875
|
|
806
876
|
|
807
877
|
}
|
808
878
|
break;
|
809
879
|
case 5 :
|
810
|
-
// antlr/UIQuery.g:1:
|
880
|
+
// antlr/UIQuery.g:1:46: FILTER_COLON
|
811
881
|
{
|
812
|
-
|
882
|
+
mFILTER_COLON();
|
813
883
|
|
814
884
|
|
815
885
|
}
|
816
886
|
break;
|
817
887
|
case 6 :
|
818
|
-
// antlr/UIQuery.g:1:
|
888
|
+
// antlr/UIQuery.g:1:59: INT
|
819
889
|
{
|
820
|
-
|
890
|
+
mINT();
|
821
891
|
|
822
892
|
|
823
893
|
}
|
824
894
|
break;
|
825
895
|
case 7 :
|
826
|
-
// antlr/UIQuery.g:1:
|
896
|
+
// antlr/UIQuery.g:1:63: BOOL
|
827
897
|
{
|
828
|
-
|
898
|
+
mBOOL();
|
829
899
|
|
830
900
|
|
831
901
|
}
|
832
902
|
break;
|
833
903
|
case 8 :
|
834
|
-
// antlr/UIQuery.g:1:
|
904
|
+
// antlr/UIQuery.g:1:68: NIL
|
905
|
+
{
|
906
|
+
mNIL();
|
907
|
+
|
908
|
+
|
909
|
+
}
|
910
|
+
break;
|
911
|
+
case 9 :
|
912
|
+
// antlr/UIQuery.g:1:72: NAME
|
913
|
+
{
|
914
|
+
mNAME();
|
915
|
+
|
916
|
+
|
917
|
+
}
|
918
|
+
break;
|
919
|
+
case 10 :
|
920
|
+
// antlr/UIQuery.g:1:77: STRING
|
921
|
+
{
|
922
|
+
mSTRING();
|
923
|
+
|
924
|
+
|
925
|
+
}
|
926
|
+
break;
|
927
|
+
case 11 :
|
928
|
+
// antlr/UIQuery.g:1:84: WHITE
|
835
929
|
{
|
836
930
|
mWHITE();
|
837
931
|
|
@@ -846,60 +940,83 @@ public class UIQueryLexer extends Lexer {
|
|
846
940
|
|
847
941
|
protected DFA10 dfa10 = new DFA10(this);
|
848
942
|
static final String DFA10_eotS =
|
849
|
-
"\
|
850
|
-
"\
|
943
|
+
"\2\uffff\3\16\2\uffff\3\16\2\uffff\2\16\2\uffff\5\16\1\33\3\16\1"+
|
944
|
+
"\37\1\16\1\uffff\1\16\1\42\1\16\1\uffff\1\37\1\16\1\uffff\1\42\1"+
|
945
|
+
"\16\1\46\1\uffff";
|
851
946
|
static final String DFA10_eofS =
|
852
|
-
"\
|
947
|
+
"\47\uffff";
|
853
948
|
static final String DFA10_minS =
|
854
|
-
"\1\40\1\56\2\uffff\3\56\2\uffff\2\56\2\uffff\
|
855
|
-
"\1\uffff\1\56";
|
949
|
+
"\1\40\1\uffff\3\56\2\uffff\3\56\2\uffff\2\56\2\uffff\13\56\1\uffff"+
|
950
|
+
"\3\56\1\uffff\2\56\1\uffff\3\56\1\uffff";
|
856
951
|
static final String DFA10_maxS =
|
857
|
-
"\
|
858
|
-
"\1\uffff\1\172";
|
952
|
+
"\1\172\1\uffff\3\172\2\uffff\3\172\2\uffff\2\172\2\uffff\13\172"+
|
953
|
+
"\1\uffff\3\172\1\uffff\2\172\1\uffff\3\172\1\uffff";
|
859
954
|
static final String DFA10_acceptS =
|
860
|
-
"\
|
861
|
-
"\uffff\1\
|
955
|
+
"\1\uffff\1\1\3\uffff\1\5\1\6\3\uffff\1\12\1\13\2\uffff\1\11\1\2"+
|
956
|
+
"\13\uffff\1\3\3\uffff\1\10\2\uffff\1\7\3\uffff\1\4";
|
862
957
|
static final String DFA10_specialS =
|
863
|
-
"\
|
958
|
+
"\47\uffff}>";
|
864
959
|
static final String[] DFA10_transitionS = {
|
865
|
-
"\1\
|
866
|
-
"\
|
867
|
-
"\
|
868
|
-
"
|
960
|
+
"\1\13\6\uffff\1\12\2\uffff\1\1\5\uffff\12\6\1\5\6\uffff\32\11"+
|
961
|
+
"\4\uffff\1\11\1\uffff\1\2\4\11\1\7\7\11\1\10\5\11\1\4\1\11\1"+
|
962
|
+
"\3\4\11",
|
963
|
+
"",
|
964
|
+
"\1\17\1\uffff\12\15\7\uffff\32\15\4\uffff\1\15\1\uffff\13\15"+
|
965
|
+
"\1\14\16\15",
|
966
|
+
"\1\17\1\uffff\12\15\7\uffff\32\15\4\uffff\1\15\1\uffff\10\15"+
|
967
|
+
"\1\20\21\15",
|
968
|
+
"\1\17\1\uffff\12\15\7\uffff\32\15\4\uffff\1\15\1\uffff\21\15"+
|
969
|
+
"\1\21\10\15",
|
970
|
+
"",
|
869
971
|
"",
|
972
|
+
"\1\17\1\uffff\12\15\7\uffff\32\15\4\uffff\1\15\1\uffff\1\22"+
|
973
|
+
"\31\15",
|
974
|
+
"\1\17\1\uffff\12\15\7\uffff\32\15\4\uffff\1\15\1\uffff\10\15"+
|
975
|
+
"\1\23\13\15\1\24\5\15",
|
976
|
+
"\1\17\1\uffff\12\15\7\uffff\32\15\4\uffff\1\15\1\uffff\32\15",
|
870
977
|
"",
|
871
|
-
"\1\14\1\uffff\12\12\7\uffff\32\12\4\uffff\1\12\1\uffff\1\15"+
|
872
|
-
"\31\12",
|
873
|
-
"\1\14\1\uffff\12\12\7\uffff\32\12\4\uffff\1\12\1\uffff\10\12"+
|
874
|
-
"\1\16\13\12\1\17\5\12",
|
875
|
-
"\1\14\1\uffff\12\12\7\uffff\32\12\4\uffff\1\12\1\uffff\32\12",
|
876
978
|
"",
|
979
|
+
"\1\17\1\uffff\12\15\7\uffff\32\15\4\uffff\1\15\1\uffff\13\15"+
|
980
|
+
"\1\25\16\15",
|
981
|
+
"\1\17\1\uffff\12\15\7\uffff\32\15\4\uffff\1\15\1\uffff\32\15",
|
877
982
|
"",
|
878
|
-
"\1\14\1\uffff\12\12\7\uffff\32\12\4\uffff\1\12\1\uffff\24\12"+
|
879
|
-
"\1\20\5\12",
|
880
|
-
"\1\14\1\uffff\12\12\7\uffff\32\12\4\uffff\1\12\1\uffff\32\12",
|
881
983
|
"",
|
984
|
+
"\1\17\1\uffff\12\15\7\uffff\32\15\4\uffff\1\15\1\uffff\22\15"+
|
985
|
+
"\1\26\7\15",
|
986
|
+
"\1\17\1\uffff\12\15\7\uffff\32\15\4\uffff\1\15\1\uffff\24\15"+
|
987
|
+
"\1\27\5\15",
|
988
|
+
"\1\17\1\uffff\12\15\7\uffff\32\15\4\uffff\1\15\1\uffff\13\15"+
|
989
|
+
"\1\30\16\15",
|
990
|
+
"\1\17\1\uffff\12\15\7\uffff\32\15\4\uffff\1\15\1\uffff\13\15"+
|
991
|
+
"\1\31\16\15",
|
992
|
+
"\1\17\1\uffff\12\15\7\uffff\32\15\4\uffff\1\15\1\uffff\13\15"+
|
993
|
+
"\1\32\16\15",
|
994
|
+
"\1\17\1\uffff\12\15\7\uffff\32\15\4\uffff\1\15\1\uffff\32\15",
|
995
|
+
"\1\17\1\uffff\12\15\7\uffff\32\15\4\uffff\1\15\1\uffff\10\15"+
|
996
|
+
"\1\34\21\15",
|
997
|
+
"\1\17\1\uffff\12\15\7\uffff\32\15\4\uffff\1\15\1\uffff\4\15"+
|
998
|
+
"\1\35\25\15",
|
999
|
+
"\1\17\1\uffff\12\15\7\uffff\32\15\4\uffff\1\15\1\uffff\22\15"+
|
1000
|
+
"\1\36\7\15",
|
1001
|
+
"\1\17\1\uffff\12\15\7\uffff\32\15\4\uffff\1\15\1\uffff\32\15",
|
1002
|
+
"\1\17\1\uffff\12\15\7\uffff\32\15\4\uffff\1\15\1\uffff\13\15"+
|
1003
|
+
"\1\40\16\15",
|
882
1004
|
"",
|
883
|
-
"\1\
|
884
|
-
"\1\
|
885
|
-
"\1\
|
886
|
-
"\1\
|
887
|
-
"\1\
|
888
|
-
"\1\23\16\12",
|
889
|
-
"\1\14\1\uffff\12\12\7\uffff\32\12\4\uffff\1\12\1\uffff\4\12"+
|
890
|
-
"\1\24\25\12",
|
891
|
-
"\1\14\1\uffff\12\12\7\uffff\32\12\4\uffff\1\12\1\uffff\22\12"+
|
892
|
-
"\1\25\7\12",
|
893
|
-
"\1\14\1\uffff\12\12\7\uffff\32\12\4\uffff\1\12\1\uffff\32\12",
|
894
|
-
"\1\14\1\uffff\12\12\7\uffff\32\12\4\uffff\1\12\1\uffff\13\12"+
|
895
|
-
"\1\27\16\12",
|
896
|
-
"\1\14\1\uffff\12\12\7\uffff\32\12\4\uffff\1\12\1\uffff\32\12",
|
897
|
-
"\1\14\1\uffff\12\12\7\uffff\32\12\4\uffff\1\12\1\uffff\4\12"+
|
898
|
-
"\1\31\25\12",
|
1005
|
+
"\1\17\1\uffff\12\15\7\uffff\32\15\4\uffff\1\15\1\uffff\1\15"+
|
1006
|
+
"\1\41\30\15",
|
1007
|
+
"\1\17\1\uffff\12\15\7\uffff\32\15\4\uffff\1\15\1\uffff\32\15",
|
1008
|
+
"\1\17\1\uffff\12\15\7\uffff\32\15\4\uffff\1\15\1\uffff\4\15"+
|
1009
|
+
"\1\43\25\15",
|
899
1010
|
"",
|
900
|
-
"\1\
|
1011
|
+
"\1\17\1\uffff\12\15\7\uffff\32\15\4\uffff\1\15\1\uffff\32\15",
|
1012
|
+
"\1\17\1\uffff\12\15\7\uffff\32\15\4\uffff\1\15\1\uffff\13\15"+
|
1013
|
+
"\1\44\16\15",
|
901
1014
|
"",
|
902
|
-
"\1\
|
1015
|
+
"\1\17\1\uffff\12\15\7\uffff\32\15\4\uffff\1\15\1\uffff\32\15",
|
1016
|
+
"\1\17\1\uffff\12\15\7\uffff\32\15\4\uffff\1\15\1\uffff\4\15"+
|
1017
|
+
"\1\45\25\15",
|
1018
|
+
"\1\17\1\uffff\12\15\7\uffff\32\15\4\uffff\1\15\1\uffff\32\15",
|
1019
|
+
""
|
903
1020
|
};
|
904
1021
|
|
905
1022
|
static final short[] DFA10_eot = DFA.unpackEncodedString(DFA10_eotS);
|
@@ -932,7 +1049,7 @@ public class UIQueryLexer extends Lexer {
|
|
932
1049
|
this.transition = DFA10_transition;
|
933
1050
|
}
|
934
1051
|
public String getDescription() {
|
935
|
-
return "1:1: Tokens : ( QUALIFIED_NAME | FILTER_COLON | INT | BOOL | NIL | NAME | STRING | WHITE );";
|
1052
|
+
return "1:1: Tokens : ( WILDCARD | QUALIFIED_NAME | ALL | VISIBLE | FILTER_COLON | INT | BOOL | NIL | NAME | STRING | WHITE );";
|
936
1053
|
}
|
937
1054
|
}
|
938
1055
|
|