#include <log_builtins_filter_imp.h>
◆ deinit()
  
  
      
        
          | static void log_builtins_filter_imp::deinit  | 
          ( | 
           | ) | 
           | 
         
       
   | 
  
static   | 
  
 
De-initialize built-in log filter. 
 
 
◆ filter_rule_init()
Initialize a new rule. 
This clears the first unused rule. It does not update the rules count; this is for the caller to do if it succeeds in setting up the rule to its satisfaction. If the caller fails, it should log_builtins_filter_rule_free() the incomplete rule.
- Parameters
 - 
  
    | ruleset | a ruleset (usually allocated with filter_ruleset_new()) | 
  
   
- Returns
 - nullptr could not initialize rule. Do not call rule_free. 
 
- 
!nullptr the address of the rule. fill in. on success, caller must increase rule count. on failure, it must call rule_free. 
 
 
 
◆ filter_ruleset_drop()
Drop an entire filter rule-set. 
Must hold lock.
- Parameters
 - 
  
    | ruleset | a ruleset * (usually allocated with filter_ruleset_new())  | 
  
   
 
 
◆ filter_ruleset_free()
Free an entire filter rule-set. 
Must hold lock. Lock will be destroyed.
- Parameters
 - 
  
    | ruleset | a ruleset * (usually allocated with filter_ruleset_new()) the pointer pointed to will be a nullptr on return.  | 
  
   
 
 
◆ filter_ruleset_lock()
Lock and get the filter rules. 
- Parameters
 - 
  
    | ruleset | a ruleset (usually allocated with filter_ruleset_new())  | 
    | locktype | LOG_BUILTINS_LOCK_SHARED lock for reading LOG_BUILTINS_LOCK_EXCLUSIVE lock for writing | 
  
   
- Returns
 - 0 lock acquired 
 
- 
!0 failed to acquire lock 
 
 
 
◆ filter_ruleset_move()
Move rules from one ruleset to another. 
Origin will be empty afterwards.
- Parameters
 - 
  
    | from | source ruleset  | 
    | to | destination ruleset  | 
  
   
 
 
◆ filter_ruleset_new()
Create a new set of filter rules. 
- Parameters
 - 
  
    | tag | identifying tag of the rule-set creator  | 
    | count | number of rules to allocate | 
  
   
- Returns
 - a pointer to a ruleset structure, or nullptr on failure 
 
 
 
◆ filter_ruleset_unlock()
Release lock on filter rules. 
- Parameters
 - 
  
    | ruleset | a ruleset (usually allocated with filter_ruleset_new())  | 
  
   
 
 
◆ filter_run()
Apply all matching rules from a filter rule set to a given log line. 
- Parameters
 - 
  
    | ruleset | a ruleset (usually allocated with filter_ruleset_new())  | 
    | ll | the current log line | 
  
   
- Returns
 - int number of matched rules 
 
 
 
◆ init()
  
  
      
        
          | static void log_builtins_filter_imp::init  | 
          ( | 
           | ) | 
           | 
         
       
   | 
  
static   | 
  
 
Initialize built-in log filter. 
 
 
The documentation for this class was generated from the following files: