/***********************************************************************/
/*                                                                     */
/*                                 GALAX                               */
/*                            XML Query Engine                         */
/*                                                                     */
/*  Copyright 2000, Lucent Technologies.                               */
/*  Distributed only by permission.                                    */
/*                                                                     */
/***********************************************************************/

/* $Id: glx_CPP.h,v 1.1 2002/10/12 00:33:30 simeon Exp $ */

/* Functions callable directly from C++ */

/* Type for XML values in Vortex */

typedef char *xml;

/* Types and operations on lists of parameters */

typedef struct paramlist_elem {
  xml param;
  struct paramlist_elem *next;
} *paramlist;

extern "C" {
  extern paramlist create_empty();
  
  extern paramlist create_cons(char *param,paramlist cdr);
  extern int is_empty(paramlist p);
  
  extern xml params_first(paramlist p);
  extern paramlist params_next(paramlist p);
  
  extern void params_print(paramlist p);
  
  /* actually calls to the XML Algebra engine */
  
  extern void glx_init(char **argv);
  
  extern char *glx_eval_xquery_from_string(char *xquery_string);
  extern char *glx_eval_xquery_from_file(char *xquery_file);
  
  extern char *glx_eval_xquery_fun_from_string(char *xquery_string, char *funname, paramlist params);
  extern char *glx_eval_xquery_fun_from_file(char *xquery_file, char *funname, paramlist params);
  
}

