Classes | Functions | Variables
names.c File Reference
#include "names.h"
#include <stdlib.h>
#include "protobuf.h"
Include dependency graph for names.c:

Go to the source code of this file.

Classes

struct  stringsink
 

Functions

static void fill_classname (const char *fullname, const char *package, const char *prefix, stringsink *classname)
 
static void fill_namespace (const char *package, const char *php_namespace, stringsink *classname)
 
static void fill_prefix (const char *segment, int length, const char *prefix_given, const char *package_name, stringsink *classname)
 
static void fill_segment (const char *segment, int length, stringsink *classname, bool use_camel)
 
char * GetPhpClassname (const upb_filedef *file, const char *fullname)
 
static bool is_reserved (const char *segment, int length)
 
bool is_reserved_name (const char *name)
 
static char nolocale_tolower (char ch)
 
static char nolocale_toupper (char ch)
 
static void stringsink_init (stringsink *sink)
 
static size_t stringsink_string (stringsink *sink, const char *ptr, size_t len)
 
static void stringsink_uninit (stringsink *sink)
 

Variables

const char *const kReservedNames []
 

Function Documentation

◆ fill_classname()

static void fill_classname ( const char *  fullname,
const char *  package,
const char *  prefix,
stringsink classname 
)
static

Definition at line 184 of file names.c.

◆ fill_namespace()

static void fill_namespace ( const char *  package,
const char *  php_namespace,
stringsink classname 
)
static

Definition at line 161 of file names.c.

◆ fill_prefix()

static void fill_prefix ( const char *  segment,
int  length,
const char *  prefix_given,
const char *  package_name,
stringsink classname 
)
static

Definition at line 132 of file names.c.

◆ fill_segment()

static void fill_segment ( const char *  segment,
int  length,
stringsink classname,
bool  use_camel 
)
static

Definition at line 150 of file names.c.

◆ GetPhpClassname()

char* GetPhpClassname ( const upb_filedef file,
const char *  fullname 
)

Definition at line 210 of file names.c.

◆ is_reserved()

static bool is_reserved ( const char *  segment,
int  length 
)
static

Definition at line 117 of file names.c.

◆ is_reserved_name()

bool is_reserved_name ( const char *  name)

Definition at line 91 of file names.c.

◆ nolocale_tolower()

static char nolocale_tolower ( char  ch)
static

Definition at line 101 of file names.c.

◆ nolocale_toupper()

static char nolocale_toupper ( char  ch)
static

Definition at line 109 of file names.c.

◆ stringsink_init()

static void stringsink_init ( stringsink sink)
static

Definition at line 62 of file names.c.

◆ stringsink_string()

static size_t stringsink_string ( stringsink sink,
const char *  ptr,
size_t  len 
)
static

Definition at line 44 of file names.c.

◆ stringsink_uninit()

static void stringsink_uninit ( stringsink sink)
static

Definition at line 69 of file names.c.

Variable Documentation

◆ kReservedNames

const char* const kReservedNames[]
Initial value:
= {
"abstract", "and", "array", "as", "break",
"callable", "case", "catch", "class", "clone",
"const", "continue", "declare", "default", "die",
"do", "echo", "else", "elseif", "empty",
"enddeclare", "endfor", "endforeach", "endif", "endswitch",
"endwhile", "eval", "exit", "extends", "final",
"finally", "fn", "for", "foreach", "function",
"if", "implements", "include", "include_once", "instanceof",
"global", "goto", "insteadof", "interface", "isset",
"list", "match", "namespace", "new", "object",
"or", "print", "private", "protected", "public",
"require", "require_once", "return", "static", "switch",
"throw", "trait", "try", "unset", "use",
"var", "while", "xor", "yield", "int",
"float", "bool", "string", "true", "false",
"null", "void", "iterable", NULL}

Definition at line 73 of file names.c.



grpc
Author(s):
autogenerated on Fri May 16 2025 03:01:24