libidav/davqlparser.h

changeset 130
80d273229f24
parent 127
7072a2b4ae35
child 131
32e7b3e6b482
equal deleted inserted replaced
129:7532963bd15b 130:80d273229f24
155 * Contains the binary information about the parsed query. 155 * Contains the binary information about the parsed query.
156 * 156 *
157 * The grammar for a DavQLStatement is: 157 * The grammar for a DavQLStatement is:
158 * 158 *
159 * <pre> 159 * <pre>
160 * Keyword = "select" | "set" | "from" | "at" | "as" | "where" | "with"
161 * | "order" | "by" | "asc" | "desc";
162 *
160 * Expression = AddExpression; 163 * Expression = AddExpression;
161 * AddExpression = MultExpression, [AddOperator, AddExpression]; 164 * AddExpression = MultExpression, [AddOperator, AddExpression];
162 * MultExpression = BitwiseExpression, [MultOperator, MultExpression]; 165 * MultExpression = BitwiseExpression, [MultOperator, MultExpression];
163 * BitwiseExpression = UnaryExpression, [BitwiseOperator, BitwiseExpression]; 166 * BitwiseExpression = UnaryExpression, [BitwiseOperator, BitwiseExpression];
164 * UnaryExpression = [UnaryOperator], (ParExpression | AtomicExpression); 167 * UnaryExpression = [UnaryOperator], (ParExpression | AtomicExpression);
198 * NamedField = Expression, " as ", Identifier; 201 * NamedField = Expression, " as ", Identifier;
199 * 202 *
200 * SetExpressions = SetExpression, {",", SetExpression}; 203 * SetExpressions = SetExpression, {",", SetExpression};
201 * SetExpression = Identifier, "=", Expression; 204 * SetExpression = Identifier, "=", Expression;
202 * 205 *
203 * Path = "%s" 206 * Path = String
204 * | "/", {?Character? - " "} 207 * | "/", [PathNode, {"/", PathNode}], ["/"];
205 * | "'/", {?Character?}, "'"; 208 * PathNode = {{?Character? - "/"} - Keyword};
206 * 209 *
207 * WithClause = "depth", "=", (Number | "infinity"); 210 * WithClause = "depth", "=", (Number | "infinity");
208 * 211 *
209 * OrderByClause = OrderByCriterion, {",", OrderByCriterion}; 212 * OrderByClause = OrderByCriterion, {",", OrderByCriterion};
210 * OrderByCriterion = (Identifier | Number), [" asc"|" desc"]; 213 * OrderByCriterion = (Identifier | Number), [" asc"|" desc"];
211 * 214 *
212 * </pre> 215 * </pre>
213 * 216 *
214 * Note: mandatory spaces are part of the grammar. But you may also insert an 217 * Note: mandatory spaces are part of the grammar. But you may also insert an
215 * arbitrary amount of optional spaces between two symbols if they are not part 218 * arbitrary amount of optional spaces between two symbols if they are not part
216 * of an literal or identifier. 219 * of an literal, identifier or the path.
217 * 220 *
218 * <b>SELECT:</b> 221 * <b>SELECT:</b>
219 * <pre> 222 * <pre>
220 * SelectStatement = "select ", FieldExpressions, 223 * SelectStatement = "select ", FieldExpressions,
221 * " from ", Path, 224 * " from ", Path,

mercurial