Nilorea Library
C utilities for networking, threading, graphics
Loading...
Searching...
No Matches
n_pcre.c File Reference

PCRE helpers for regex matching. More...

#include "nilorea/n_pcre.h"
#include "nilorea/n_log.h"
#include <string.h>
+ Include dependency graph for n_pcre.c:

Go to the source code of this file.

Functions

int _npcre_print_error (int LOG_LEVEL, const char *file, const char *func, int line, int rc)
 print error associated to pcre error code
 
int npcre_clean_match (N_PCRE *pcre)
 clean the match list of the last capture, if any
 
int npcre_delete (N_PCRE **pcre)
 Free a N_PCRE pointer.
 
int npcre_match (char *str, N_PCRE *pcre)
 Thread-safe match: returns TRUE/FALSE without modifying the N_PCRE struct.
 
int npcre_match_capture (char *str, N_PCRE *pcre)
 Return TRUE if str matches regexp, and make captures.
 
N_PCREnpcre_new (char *str, int flags)
 From pcre doc, the flag bits are: PCRE_ANCHORED Force pattern anchoring PCRE_AUTO_CALLOUT Compile automatic callouts PCRE_BSR_ANYCRLF \R matches only CR, LF, or CRLF PCRE_BSR_UNICODE \R matches all Unicode line endings PCRE_CASELESS Do caseless matching PCRE_DOLLAR_ENDONLY $ not to match newline at end PCRE_DOTALL .
 

Detailed Description

PCRE helpers for regex matching.

Author
Castagnier Mickael
Version
2.0
Date
04/12/2019

Definition in file n_pcre.c.