2 * Copyright (C) 1995-2005, Index Data ApS
3 * See the file LICENSE for details.
5 * $Id: cclp.h,v 1.2 2007-04-27 09:50:35 adam Exp $
10 * \brief CCL header with private definitions
15 #define CCL_TOK_TERM 1
18 #define CCL_TOK_PROX 4
21 #define CCL_TOK_COMMA 7
24 #define CCL_TOK_NOT 10
25 #define CCL_TOK_SET 11
31 size_t len; /* length of name below */
32 const char *name; /* string / name of token */
33 struct ccl_token *next;
34 struct ccl_token *prev;
35 const char *ws_prefix_buf; /* leading white space buf */
36 size_t ws_prefix_len; /* leading white space len */
39 /** CCL parser structure */
41 /** current lookahead token */
42 struct ccl_token *look_token;
44 /** holds error code if error occur */
46 /** start of CCL string buffer */
47 const char *start_pos;
48 /** if error occurs, this holds position (starting from 0). */
49 const char *error_pos;
54 /** names of and operator */
56 /** names of or operator */
58 /** names of not operator */
60 /** names of set operator */
62 /** 1=CCL parser is case sensitive, 0=case insensitive */
63 int ccl_case_sensitive;
67 * Splits CCL command string into individual tokens using
71 struct ccl_token *ccl_parser_tokenize (CCL_parser cclp, const char *command);
77 void ccl_token_del (struct ccl_token *list);
80 * Add single token after a given onde.
83 struct ccl_token *ccl_token_add (struct ccl_token *at);
87 struct ccl_rpn_node *ccl_parser_find_token(CCL_parser cclp,
88 struct ccl_token *list);
95 * indent-tabs-mode: nil
97 * vim: shiftwidth=4 tabstop=8 expandtab