|
Open SCAP Library
|
00001 /* 00002 * Copyright 2009 Red Hat Inc., Durham, North Carolina. 00003 * All Rights Reserved. 00004 * 00005 * This library is free software; you can redistribute it and/or 00006 * modify it under the terms of the GNU Lesser General Public 00007 * License as published by the Free Software Foundation; either 00008 * version 2.1 of the License, or (at your option) any later version. 00009 * 00010 * This library is distributed in the hope that it will be useful, 00011 * but WITHOUT ANY WARRANTY; without even the implied warranty of 00012 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 00013 * Lesser General Public License for more details. 00014 * 00015 * You should have received a copy of the GNU Lesser General Public 00016 * License along with this library; if not, write to the Free Software 00017 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 00018 * 00019 * Authors: 00020 * "Daniel Kopecek" <dkopecek@redhat.com> 00021 */ 00022 00023 #pragma once 00024 #ifndef SEXP_PARSE_H 00025 #define SEXP_PARSE_H 00026 00027 #ifdef __cplusplus 00028 extern "C" { 00029 #endif 00030 00031 #include <stddef.h> 00032 #include <sexp-types.h> 00033 00034 typedef struct SEXP_psetup SEXP_psetup_t; 00035 00036 SEXP_psetup_t *SEXP_psetup_new (void); 00037 void SEXP_psetup_free (SEXP_psetup_t *); 00038 00039 typedef uint8_t SEXP_pflags_t; 00040 00041 #define SEXP_PFLAG_EOFOK 0x01 00042 #define SEXP_PFLAG_FREEBUF 0x02 00043 #define SEXP_PFLAG_ALL 0x03 00044 00045 int SEXP_psetup_setflags (SEXP_psetup_t *psetup, SEXP_pflags_t flags); 00046 int SEXP_psetup_unsetflags (SEXP_psetup_t *psetup, SEXP_pflags_t flags); 00047 00048 typedef struct SEXP_pstate SEXP_pstate_t; 00049 00050 SEXP_pstate_t *SEXP_pstate_new (void); 00051 void SEXP_pstate_free (SEXP_pstate_t *); 00052 SEXP_pstate_t *SEXP_pstate_init (SEXP_pstate_t *); 00053 00054 SEXP_t *SEXP_parse (const SEXP_psetup_t *psetup, char *buffer, size_t buflen, SEXP_pstate_t **pstate); 00055 00056 bool SEXP_pstate_errorp(SEXP_pstate_t *pstate); 00057 00058 #ifdef __cplusplus 00059 } 00060 #endif 00061 00062 #endif /* SEXP_PARSE_H */
1.7.3