/*******************************************************************************
* YORKTOWN ADVANCED SGML PARSER (YASP)                                         *
*         An SGML Parser conforming to International Standard ISO 8879 --      *
*         Standard Generalized Markup Language                                 *
*------------------------------------------------------------------------------*
* Written 1987 - 1993 by                                                       *
*         Pierre G. Richard                                                    *
*         IBM T.J. Watson Research Center                                      *
*         Yorktown Heights, New York                                           *
*         petrus@watson.ibm.com                                                *
*------------------------------------------------------------------------------*
* FUNCTION NAME    = YASP / Header File                                        *
* STATUS           = Version 0, Release 1, Level 24 and up                     *
* COMPONENT NAME   = tag.h                                                     *
* DESCRIPTIVE NAME = tag: block and functions                                  *
* DATE_WR          = 08/04/1988                                                *
* AUTHOR           = Pierre G. Richard - PETRUS at YKTVMX                      *
*                                                                              *
* FUNCTIONAL DESCRIPTION =                                                     *
* IMPLEMENTATION NOTES =                                                       *
* CHANGE HISTORY =                                                             *
*******************************************************************************/

typedef enum {
   DEF_TGF,                     /* Default AVS being parsed (DATA or TAG) */
   TAG_TGF,                     /* Tag Attribute Specification being parsed */
   DATA_TGF                     /* Data Attribute Specification being parsed */
}TGFLAG;

typedef enum {                  /* Return code from tg_stasl */
   NO_CHANGE_ASLRC      = 0x00, /* Nothing changed: can use the default ASL */
   CHANGED_ASLRC        = 0x01, /* At least one AVS was found */
   CONREF_CHANGED_ASLRC = 0x02  /* AVS found for a CONREF */
}ASLRC;

typedef struct t_ASLARG {       /* Argument passed to tg_stasl */
   TGFLAG tgf;                  /* Input: TAG_TGF or DATA_TGF */
   ATD   *D_atd_p;              /* Input: copy of the original atd (or NULL) */
   uint   attval_nln;           /* Output: new normalized length */
}ASLARG;

extern uchar * P_FCT tg_lsfnd  (GA_P, uchar *, uchar *);
extern int     P_FCT tg_gtavs  (GA_P, uchar *, ATD *, ADLEN **, uint *, TGFLAG);
extern ASLRC   P_FCT tg_stasl  (GA_P, ASLARG *);
extern boolean P_FCT tg_parse  (GA_P, ELT *, ATD **);
extern ATD *   P_FCT tg_vldat  (GA_P, ELT *, ATD *);
/******************************************************************************/
