00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018 #ifndef CUEX_OPRINFO_H
00019 #define CUEX_OPRINFO_H
00020
00021 #include <cuex/fwd.h>
00022 #include <cucon/pmap.h>
00023 #include <stdint.h>
00024
00025 CU_BEGIN_DECLARATIONS
00026
00027 struct cuex_oprinfo
00028 {
00029 struct cucon_umap_node node;
00030 char const *name;
00031 size_t cache_size;
00032 void (*cache_ctor)(cuex_opn_t opn);
00033 uint_least32_t flags;
00034 };
00035
00036 cuex_oprinfo_t cuex_oprinfo(cuex_meta_t opr);
00037
00038 CU_SINLINE cuex_meta_t cuex_oprinfo_opr(cuex_oprinfo_t oi)
00039 { return cucon_umap_node_key(&oi->node); }
00040
00041 CU_SINLINE char const *cuex_oprinfo_name(cuex_oprinfo_t oi)
00042 { return oi->name; }
00043
00044 CU_SINLINE size_t cuex_oprinfo_cache_size(cuex_oprinfo_t oi)
00045 { return oi->cache_size; }
00046
00047 CU_SINLINE void (*cuex_oprinfo_cache_ctor(cuex_oprinfo_t oi))(cuex_opn_t opn)
00048 { return oi->cache_ctor; }
00049
00050
00051
00052
00053 void cuex_oprinfo_register(cuex_oprinfo_t arr);
00054
00055 cu_bool_t cuex_oprinfo_conj(cu_clop(cb, cu_bool_t, cuex_oprinfo_t));
00056
00057 CU_END_DECLARATIONS
00058
00059 #endif