Z3
z3_ast_containers.h
Go to the documentation of this file.
1/*++
2Copyright (c) 2015 Microsoft Corporation
3
4Module Name:
5
6 z3_ast_containers.h
7
8Abstract:
9
10 AST Containers
11
12Author:
13
14 Christoph M. Wintersteiger (cwinter) 2015-12-03
15
16Notes:
17
18--*/
19#ifndef Z3_AST_CONTAINERS_H_
20#define Z3_AST_CONTAINERS_H_
21
22#ifdef __cplusplus
23extern "C" {
24#endif // __cplusplus
25
28
38 Z3_ast_vector Z3_API Z3_mk_ast_vector(Z3_context c);
39
44 void Z3_API Z3_ast_vector_inc_ref(Z3_context c, Z3_ast_vector v);
45
50 void Z3_API Z3_ast_vector_dec_ref(Z3_context c, Z3_ast_vector v);
51
56 unsigned Z3_API Z3_ast_vector_size(Z3_context c, Z3_ast_vector v);
57
64 Z3_ast Z3_API Z3_ast_vector_get(Z3_context c, Z3_ast_vector v, unsigned i);
65
72 void Z3_API Z3_ast_vector_set(Z3_context c, Z3_ast_vector v, unsigned i, Z3_ast a);
73
78 void Z3_API Z3_ast_vector_resize(Z3_context c, Z3_ast_vector v, unsigned n);
79
84 void Z3_API Z3_ast_vector_push(Z3_context c, Z3_ast_vector v, Z3_ast a);
85
90 Z3_ast_vector Z3_API Z3_ast_vector_translate(Z3_context s, Z3_ast_vector v, Z3_context t);
91
96 Z3_string Z3_API Z3_ast_vector_to_string(Z3_context c, Z3_ast_vector v);
97
109 Z3_ast_map Z3_API Z3_mk_ast_map(Z3_context c);
110
115 void Z3_API Z3_ast_map_inc_ref(Z3_context c, Z3_ast_map m);
116
121 void Z3_API Z3_ast_map_dec_ref(Z3_context c, Z3_ast_map m);
122
127 bool Z3_API Z3_ast_map_contains(Z3_context c, Z3_ast_map m, Z3_ast k);
128
135 Z3_ast Z3_API Z3_ast_map_find(Z3_context c, Z3_ast_map m, Z3_ast k);
136
141 void Z3_API Z3_ast_map_insert(Z3_context c, Z3_ast_map m, Z3_ast k, Z3_ast v);
142
147 void Z3_API Z3_ast_map_erase(Z3_context c, Z3_ast_map m, Z3_ast k);
148
153 void Z3_API Z3_ast_map_reset(Z3_context c, Z3_ast_map m);
154
159 unsigned Z3_API Z3_ast_map_size(Z3_context c, Z3_ast_map m);
160
165 Z3_ast_vector Z3_API Z3_ast_map_keys(Z3_context c, Z3_ast_map m);
166
171 Z3_string Z3_API Z3_ast_map_to_string(Z3_context c, Z3_ast_map m);
174
175#ifdef __cplusplus
176}
177#endif // __cplusplus
178
179#endif
const char * Z3_string
Z3 string type. It is just an alias for const char *.
Definition: z3_api.h:82
void Z3_API Z3_ast_map_inc_ref(Z3_context c, Z3_ast_map m)
Increment the reference counter of the given AST map.
Z3_ast Z3_API Z3_ast_map_find(Z3_context c, Z3_ast_map m, Z3_ast k)
Return the value associated with the key k.
Z3_string Z3_API Z3_ast_map_to_string(Z3_context c, Z3_ast_map m)
Convert the given map into a string.
void Z3_API Z3_ast_vector_set(Z3_context c, Z3_ast_vector v, unsigned i, Z3_ast a)
Update position i of the AST vector v with the AST a.
bool Z3_API Z3_ast_map_contains(Z3_context c, Z3_ast_map m, Z3_ast k)
Return true if the map m contains the AST key k.
Z3_ast_vector Z3_API Z3_ast_map_keys(Z3_context c, Z3_ast_map m)
Return the keys stored in the given map.
Z3_ast_vector Z3_API Z3_ast_vector_translate(Z3_context s, Z3_ast_vector v, Z3_context t)
Translate the AST vector v from context s into an AST vector in context t.
Z3_string Z3_API Z3_ast_vector_to_string(Z3_context c, Z3_ast_vector v)
Convert AST vector into a string.
void Z3_API Z3_ast_vector_resize(Z3_context c, Z3_ast_vector v, unsigned n)
Resize the AST vector v.
unsigned Z3_API Z3_ast_map_size(Z3_context c, Z3_ast_map m)
Return the size of the given map.
void Z3_API Z3_ast_vector_dec_ref(Z3_context c, Z3_ast_vector v)
Decrement the reference counter of the given AST vector.
void Z3_API Z3_ast_map_dec_ref(Z3_context c, Z3_ast_map m)
Decrement the reference counter of the given AST map.
unsigned Z3_API Z3_ast_vector_size(Z3_context c, Z3_ast_vector v)
Return the size of the given AST vector.
void Z3_API Z3_ast_vector_inc_ref(Z3_context c, Z3_ast_vector v)
Increment the reference counter of the given AST vector.
Z3_ast_vector Z3_API Z3_mk_ast_vector(Z3_context c)
Return an empty AST vector.
void Z3_API Z3_ast_map_erase(Z3_context c, Z3_ast_map m, Z3_ast k)
Erase a key from the map.
void Z3_API Z3_ast_vector_push(Z3_context c, Z3_ast_vector v, Z3_ast a)
Add the AST a in the end of the AST vector v. The size of v is increased by one.
Z3_ast_map Z3_API Z3_mk_ast_map(Z3_context c)
Return an empty mapping from AST to AST.
Z3_ast Z3_API Z3_ast_vector_get(Z3_context c, Z3_ast_vector v, unsigned i)
Return the AST at position i in the AST vector v.
void Z3_API Z3_ast_map_insert(Z3_context c, Z3_ast_map m, Z3_ast k, Z3_ast v)
Store/Replace a new key, value pair in the given map.
void Z3_API Z3_ast_map_reset(Z3_context c, Z3_ast_map m)
Remove all keys from the given map.