blob: c75c81cf4cd0db7686940e97df7b2e58886f7a56 [file] [log] [blame]
Lev Walkinf15320b2004-06-03 03:38:44 +00001/*
2 * This is the public interface for the processor (fixer) of the ASN.1 tree
3 * produced by the libasn1parser.
4 */
5#ifndef ASN1FIX_H
6#define ASN1FIX_H
7
8#include <asn1parser.h>
9
10/*
11 * Operation flags for the function below.
12 */
13enum asn1f_flags {
14 A1F_NOFLAGS,
Lev Walkin5253da42004-08-20 13:25:56 +000015 A1F_DEBUG = 0x01, /* Print debugging output */
16 A1F_EXTENDED_SizeConstraint = 0x02, /* Enable constraint gen code */
Lev Walkinf15320b2004-06-03 03:38:44 +000017};
18
19/*
20 * Perform a set of semantics checks, transformations and small fixes
21 * on the given tree.
22 * RETURN VALUES:
23 * -1: Some fatal problems were encountered.
24 * 0: No inconsistencies were found.
25 * 1: Some warnings were issued, but no fatal problems encountered.
26 */
27int asn1f_process(asn1p_t *_asn,
28 enum asn1f_flags,
29 void (*error_log_callback)(int _severity, const char *fmt, ...));
30
Lev Walkin97bdee22004-06-28 21:21:24 +000031
32/*
33 * Explicitly mark type as known.
34 */
35int asn1f_make_known_external_type(const char *);
36
Lev Walkinf15320b2004-06-03 03:38:44 +000037#endif /* ASN1FIX_H */