Skip to main content

pamoja_rule_evaluator_from_json

Function pamoja_rule_evaluator_from_json 

Source
#[unsafe(no_mangle)]
pub unsafe extern "C" fn pamoja_rule_evaluator_from_json( text: *const c_char, ) -> *mut PamojaRuleEvaluator
Expand description

Loads a rule file and arms its rules, every condition starting cleared.

§Arguments

  • text - the rule file, as null-terminated UTF-8.

§Returns

A handle the caller must release with pamoja_rule_evaluator_free, or null if the text is not a rule file or holds a rule no engine could run, with the reason available from pamoja_last_error_message.

§Safety

text must be a valid null-terminated UTF-8 string for the duration of the call, or null.