Motr
M0
|
![]() |
Data Structures | |
struct | m0_fdmi_flt_operands |
struct | m0_fdmi_eval_ctx |
struct | m0_fdmi_eval_var_info |
Typedefs | |
typedef int(* | m0_fdmi_flt_op_cb_t) (struct m0_fdmi_flt_operands *opnds, struct m0_fdmi_flt_operand *res) |
Functions | |
M0_INTERNAL void | m0_fdmi_eval_init (struct m0_fdmi_eval_ctx *ctx) |
M0_INTERNAL int | m0_fdmi_eval_add_op_cb (struct m0_fdmi_eval_ctx *ctx, enum m0_fdmi_flt_op_code op, m0_fdmi_flt_op_cb_t cb) |
M0_INTERNAL void | m0_fdmi_eval_del_op_cb (struct m0_fdmi_eval_ctx *ctx, enum m0_fdmi_flt_op_code op) |
M0_INTERNAL int | m0_fdmi_eval_flt (struct m0_fdmi_eval_ctx *ctx, struct m0_conf_fdmi_filter *filter, struct m0_fdmi_eval_var_info *var_info) |
M0_INTERNAL void | m0_fdmi_eval_fini (struct m0_fdmi_eval_ctx *ctx) |
typedef int(* m0_fdmi_flt_op_cb_t) (struct m0_fdmi_flt_operands *opnds, struct m0_fdmi_flt_operand *res) |
Function type, implementing some operation of FDMI filter tree
Definition at line 51 of file flt_eval.h.
M0_INTERNAL int m0_fdmi_eval_add_op_cb | ( | struct m0_fdmi_eval_ctx * | ctx, |
enum m0_fdmi_flt_op_code | op, | ||
m0_fdmi_flt_op_cb_t | cb | ||
) |
Add operation handler to the evaluator context
Can be used by FDMI sources to add operation handlers for data types, specific to these FDMI sources
ctx | FDMI filter evaluator context |
op | operation code |
cb | Handler to be registered |
Definition at line 101 of file flt_eval.c.
M0_INTERNAL void m0_fdmi_eval_del_op_cb | ( | struct m0_fdmi_eval_ctx * | ctx, |
enum m0_fdmi_flt_op_code | op | ||
) |
Delete operation handler from the evaluator context
ctx | FDMI filter evaluator context |
op | operation code |
Definition at line 119 of file flt_eval.c.
M0_INTERNAL void m0_fdmi_eval_fini | ( | struct m0_fdmi_eval_ctx * | ctx | ) |
Finalize FDMI evaluator
ctx | FDMI filter evaluator context |
Definition at line 204 of file flt_eval.c.
M0_INTERNAL int m0_fdmi_eval_flt | ( | struct m0_fdmi_eval_ctx * | ctx, |
struct m0_conf_fdmi_filter * | filter, | ||
struct m0_fdmi_eval_var_info * | var_info | ||
) |
Evaluate filter expression tree value
Result of filter expression is always boolean.
filter | FDMI filter |
ctx | FDMI filter evaluator context |
var_info | Information about how to get value of variable nodes |
Definition at line 184 of file flt_eval.c.
M0_INTERNAL void m0_fdmi_eval_init | ( | struct m0_fdmi_eval_ctx * | ctx | ) |
Initialize FDMI filter evaluator context
ctx | FDMI filter evaluator context |
Definition at line 130 of file flt_eval.c.