blob: 2626a315f84d10892fe28364c1c5edfda3bfa906 [file] [log] [blame]
Till Westmann5b431ca2015-10-01 19:16:11 -07001# Licensed to the Apache Software Foundation (ASF) under one
2# or more contributor license agreements. See the NOTICE file
3# distributed with this work for additional information
4# regarding copyright ownership. The ASF licenses this file
5# to you under the Apache License, Version 2.0 (the
6# "License"); you may not use this file except in compliance
7# with the License. You may obtain a copy of the License at
8#
9# http://www.apache.org/licenses/LICENSE-2.0
10#
11# Unless required by applicable law or agreed to in writing,
12# software distributed under the License is distributed on an
13# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
14# KIND, either express or implied. See the License for the
15# specific language governing permissions and limitations
16# under the License.
17
diegogiorgini@gmail.com2de6d342013-02-16 02:41:45 +000018# LEXER GENERATOR configuration file
19# ---------------------------------------
20# Place *first* the generic configuration
21# then list your grammar.
22
Till Westmann9dcba3c2016-02-01 19:42:32 -080023PACKAGE: org.apache.asterix.runtime.operators.file.adm
24LEXER_NAME: AdmLexer
25EXCEPTION_SUPER_CLASS: org.apache.hyracks.api.exceptions.HyracksDataException
diegogiorgini@gmail.com2de6d342013-02-16 02:41:45 +000026
27TOKENS:
28
29BOOLEAN_CONS = string(boolean)
30INT8_CONS = string(int8)
31INT16_CONS = string(int16)
32INT32_CONS = string(int32)
33INT64_CONS = string(int64)
Taewoo Kima12d8cd2015-03-04 13:47:08 -080034INT64_CONS = string(int)
diegogiorgini@gmail.com2de6d342013-02-16 02:41:45 +000035FLOAT_CONS = string(float)
36DOUBLE_CONS = string(double)
37DATE_CONS = string(date)
38DATETIME_CONS = string(datetime)
39DURATION_CONS = string(duration)
40STRING_CONS = string(string)
JavierJia9d3c4a92014-11-20 13:09:58 -080041HEX_CONS = string(hex)
42BASE64_CONS = string(base64)
diegogiorgini@gmail.com2de6d342013-02-16 02:41:45 +000043POINT_CONS = string(point)
44POINT3D_CONS = string(point3d)
45LINE_CONS = string(line)
46POLYGON_CONS = string(polygon)
47RECTANGLE_CONS = string(rectangle)
48CIRCLE_CONS = string(circle)
49TIME_CONS = string(time)
Preston Carmand434b502016-02-02 20:36:22 -080050INTERVAL_CONS = string(interval)
JArodccac1342013-05-15 11:00:44 -070051YEAR_MONTH_DURATION_CONS = string(year-month-duration)
Taewoo Kim83259462014-09-09 18:13:41 -070052DAY_TIME_DURATION_CONS = string(day-time-duration)
53UUID_CONS = string(uuid)
diegogiorgini@gmail.com2de6d342013-02-16 02:41:45 +000054
55NULL_LITERAL = string(null)
56TRUE_LITERAL = string(true)
57FALSE_LITERAL = string(false)
58
59CONSTRUCTOR_OPEN = char(()
60CONSTRUCTOR_CLOSE = char())
61START_RECORD = char({)
62END_RECORD = char(})
63COMMA = char(\,)
64COLON = char(:)
65START_ORDERED_LIST = char([)
66END_ORDERED_LIST = char(])
67START_UNORDERED_LIST = string({{)
ogeidixb9d2cf82013-10-12 22:47:01 +010068# END_UNORDERED_LIST = }} is recognized as a double END_RECORD token
diegogiorgini@gmail.com2de6d342013-02-16 02:41:45 +000069
70STRING_LITERAL = char("), anythingUntil(")
71
72INT_LITERAL = signOrNothing(), digitSequence()
73INT8_LITERAL = token(INT_LITERAL), string(i8)
74INT16_LITERAL = token(INT_LITERAL), string(i16)
75INT32_LITERAL = token(INT_LITERAL), string(i32)
76INT64_LITERAL = token(INT_LITERAL), string(i64)
77
78@EXPONENT = caseInsensitiveChar(e), signOrNothing(), digitSequence()
79
80DOUBLE_LITERAL = signOrNothing(), char(.), digitSequence()
81DOUBLE_LITERAL = signOrNothing(), digitSequence(), char(.), digitSequence()
82DOUBLE_LITERAL = signOrNothing(), digitSequence(), char(.), digitSequence(), token(@EXPONENT)
83DOUBLE_LITERAL = signOrNothing(), digitSequence(), token(@EXPONENT)
84
85FLOAT_LITERAL = token(DOUBLE_LITERAL), caseInsensitiveChar(f)