tin  2.4.5
About: TIN is a threaded NNTP and spool based UseNet newsreader.
  Fossies Dox: tin-2.4.5.tar.xz  ("unofficial" and yet experimental doxygen-generated source code documentation)  

pcre_get.c File Reference
#include "pcre_internal.h"
Include dependency graph for pcre_get.c:

Go to the source code of this file.

Functions

int pcre_get_stringnumber (const pcre *code, const char *stringname)
 
int pcre_get_stringtable_entries (const pcre *code, const char *stringname, char **firstptr, char **lastptr)
 
static int get_first_set (const pcre *code, const char *stringname, int *ovector)
 
int pcre_copy_substring (const char *subject, int *ovector, int stringcount, int stringnumber, char *buffer, int size)
 
int pcre_copy_named_substring (const pcre *code, const char *subject, int *ovector, int stringcount, const char *stringname, char *buffer, int size)
 
int pcre_get_substring_list (const char *subject, int *ovector, int stringcount, const char ***listptr)
 
void pcre_free_substring_list (const char **pointer)
 
int pcre_get_substring (const char *subject, int *ovector, int stringcount, int stringnumber, const char **stringptr)
 
int pcre_get_named_substring (const pcre *code, const char *subject, int *ovector, int stringcount, const char *stringname, const char **stringptr)
 
void pcre_free_substring (const char *pointer)
 

Function Documentation

◆ get_first_set()

static int get_first_set ( const pcre code,
const char *  stringname,
int *  ovector 
)
static

Find first set of multiple named strings *

Definition at line 182 of file pcre_get.c.

References code, real_pcre::options, PCRE_DUPNAMES, pcre_get_stringnumber(), pcre_get_stringtable_entries(), and PCRE_JCHANGED.

Referenced by pcre_copy_named_substring(), and pcre_get_named_substring().

◆ pcre_copy_named_substring()

int pcre_copy_named_substring ( const pcre code,
const char *  subject,
int *  ovector,
int  stringcount,
const char *  stringname,
char *  buffer,
int  size 
)

Copy named captured string to given buffer *

Definition at line 276 of file pcre_get.c.

References buffer, code, get_first_set(), and pcre_copy_substring().

Referenced by main().

◆ pcre_copy_substring()

int pcre_copy_substring ( const char *  subject,
int *  ovector,
int  stringcount,
int  stringnumber,
char *  buffer,
int  size 
)

Copy captured string to given buffer *

Definition at line 231 of file pcre_get.c.

References buffer, PCRE_ERROR_NOMEMORY, and PCRE_ERROR_NOSUBSTRING.

Referenced by main(), and pcre_copy_named_substring().

◆ pcre_free_substring()

void pcre_free_substring ( const char *  pointer)

Free store obtained by get_substring *

Definition at line 456 of file pcre_get.c.

References pcre_free.

Referenced by main().

◆ pcre_free_substring_list()

void pcre_free_substring_list ( const char **  pointer)

Free store obtained by get_substring_list *

Definition at line 353 of file pcre_get.c.

References pcre_free.

Referenced by main().

◆ pcre_get_named_substring()

int pcre_get_named_substring ( const pcre code,
const char *  subject,
int *  ovector,
int  stringcount,
const char *  stringname,
const char **  stringptr 
)

Copy named captured string to new store *

Definition at line 433 of file pcre_get.c.

References code, get_first_set(), and pcre_get_substring().

Referenced by main().

◆ pcre_get_stringnumber()

int pcre_get_stringnumber ( const pcre code,
const char *  stringname 
)

Perl-Compatible Regular Expressions * Find number for named string *

Definition at line 65 of file pcre_get.c.

References code, PCRE_ERROR_NOSUBSTRING, pcre_fullinfo(), PCRE_INFO_NAMECOUNT, PCRE_INFO_NAMEENTRYSIZE, and PCRE_INFO_NAMETABLE.

Referenced by get_first_set(), and main().

◆ pcre_get_stringtable_entries()

int pcre_get_stringtable_entries ( const pcre code,
const char *  stringname,
char **  firstptr,
char **  lastptr 
)

Find (multiple) entries for named string *

Definition at line 114 of file pcre_get.c.

References code, PCRE_ERROR_NOSUBSTRING, pcre_fullinfo(), PCRE_INFO_NAMECOUNT, PCRE_INFO_NAMEENTRYSIZE, and PCRE_INFO_NAMETABLE.

Referenced by get_first_set().

◆ pcre_get_substring()

int pcre_get_substring ( const char *  subject,
int *  ovector,
int  stringcount,
int  stringnumber,
const char **  stringptr 
)

Copy captured string to new store *

Definition at line 386 of file pcre_get.c.

References PCRE_ERROR_NOMEMORY, PCRE_ERROR_NOSUBSTRING, and pcre_malloc.

Referenced by main(), and pcre_get_named_substring().

◆ pcre_get_substring_list()

int pcre_get_substring_list ( const char *  subject,
int *  ovector,
int  stringcount,
const char ***  listptr 
)

Copy all captured strings to new store *

Definition at line 308 of file pcre_get.c.

References PCRE_ERROR_NOMEMORY, and pcre_malloc.

Referenced by main().