Main Page
Related Pages
Modules
Namespaces
Namespace List
Namespace Members
All
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Functions
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Variables
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Typedefs
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
r
s
t
u
v
w
y
z
Enumerations
a
b
c
d
e
f
g
h
i
j
l
m
n
o
p
r
s
t
u
v
w
Enumerator
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
r
s
t
u
z
Classes
Class List
Class Hierarchy
Class Members
All
:
[
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
~
Functions
[
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
~
Variables
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Typedefs
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
r
s
t
u
v
w
y
Enumerations
a
b
c
d
e
f
h
i
k
l
m
n
o
p
r
s
t
u
v
w
Enumerator
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
z
Properties
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
r
s
t
u
v
w
Related Functions
:
a
b
c
d
e
f
g
h
i
j
l
m
n
o
p
q
r
s
t
u
v
w
z
Files
File List
File Members
All
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Functions
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
z
Variables
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Typedefs
_
a
b
c
d
e
f
g
h
i
k
l
m
n
o
p
q
r
s
t
u
v
w
x
z
Enumerations
_
a
b
c
d
e
f
g
h
i
k
l
m
n
o
p
r
s
t
u
v
w
x
Enumerator
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
r
s
t
u
v
w
x
Macros
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
grpc
src
php
ext
grpc
php_grpc.h
Go to the documentation of this file.
1
/*
2
*
3
* Copyright 2015 gRPC authors.
4
*
5
* Licensed under the Apache License, Version 2.0 (the "License");
6
* you may not use this file except in compliance with the License.
7
* You may obtain a copy of the License at
8
*
9
* http://www.apache.org/licenses/LICENSE-2.0
10
*
11
* Unless required by applicable law or agreed to in writing, software
12
* distributed under the License is distributed on an "AS IS" BASIS,
13
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14
* See the License for the specific language governing permissions and
15
* limitations under the License.
16
*
17
*/
18
19
20
#ifndef PHP_GRPC_H
21
#define PHP_GRPC_H
22
23
#ifdef HAVE_CONFIG_H
24
#include "config.h"
25
#endif
26
27
#include <stdbool.h>
28
29
#include <php.h>
30
#include <php_ini.h>
31
#include <ext/standard/info.h>
32
33
#include <
grpc/grpc.h
>
34
35
#include "
php7_wrapper.h
"
36
#include "
version.h
"
37
38
extern
zend_module_entry
grpc_module_entry
;
39
#define phpext_grpc_ptr &grpc_module_entry
40
41
#ifdef PHP_WIN32
42
#define PHP_GRPC_API __declspec(dllexport)
43
#elif defined(__GNUC__) && __GNUC__ >= 4
44
#define PHP_GRPC_API __attribute__((visibility("default")))
45
#else
46
#define PHP_GRPC_API
47
#endif
48
49
#if PHP_MAJOR_VERSION >= 8
50
#define TSRMLS_CC
51
#define TSRMLS_C
52
#define TSRMLS_DC
53
#define TSRMLS_D
54
#define TSRMLS_FETCH()
55
#endif
56
57
#ifdef ZTS
58
#include "TSRM.h"
59
#endif
60
61
/* These are all function declarations */
62
/* Code that runs at module initialization */
63
PHP_MINIT_FUNCTION
(
grpc
);
64
/* Code that runs at module shutdown */
65
PHP_MSHUTDOWN_FUNCTION
(
grpc
);
66
/* Displays information about the module */
67
PHP_MINFO_FUNCTION
(
grpc
);
68
/* Code that runs at request start */
69
PHP_RINIT_FUNCTION
(
grpc
);
70
71
/*
72
Declare any global variables you may need between the BEGIN
73
and END macros here:
74
*/
75
ZEND_BEGIN_MODULE_GLOBALS(
grpc
)
76
zend_bool
initialized
;
77
zend_bool
enable_fork_support
;
78
char
*
poll_strategy
;
79
char
*
grpc_verbosity
;
80
char
*
grpc_trace
;
81
char
*
log_filename
;
82
ZEND_END_MODULE_GLOBALS(
grpc
)
83
84
ZEND_EXTERN_MODULE_GLOBALS
(
grpc
);
85
86
/* In every utility function you add that needs to use variables
87
in php_grpc_globals, call TSRMLS_FETCH(); after declaring other
88
variables used by that function, or better yet, pass in TSRMLS_CC
89
after the last function argument and declare your utility function
90
with TSRMLS_DC after the last declared argument. Always refer to
91
the globals in your function as GRPC_G(variable). You are
92
encouraged to rename these macros something shorter, see
93
examples in any other php module directory.
94
*/
95
96
#ifdef ZTS
97
#define GRPC_G(v) TSRMG(grpc_globals_id, zend_grpc_globals *, v)
98
#else
99
#define GRPC_G(v) (grpc_globals.v)
100
#endif
101
102
#define GRPC_STARTUP_FUNCTION(module) ZEND_MINIT_FUNCTION(grpc_##module)
103
#define GRPC_STARTUP(module) \
104
ZEND_MODULE_STARTUP_N(grpc_##module)(INIT_FUNC_ARGS_PASSTHRU)
105
106
#endif
/* PHP_GRPC_H */
poll_strategy
char * poll_strategy
Definition:
php_grpc.h:78
grpc
Definition:
grpcpp/alarm.h:33
ZEND_EXTERN_MODULE_GLOBALS
ZEND_EXTERN_MODULE_GLOBALS(grpc)
php7_wrapper.h
enable_fork_support
zend_bool enable_fork_support
Definition:
php_grpc.h:77
grpc_module_entry
zend_module_entry grpc_module_entry
Definition:
php_grpc.c:60
initialized
zend_bool initialized
Definition:
php_grpc.h:76
grpc.h
PHP_RINIT_FUNCTION
PHP_RINIT_FUNCTION(grpc)
Definition:
php_grpc.c:595
PHP_MINFO_FUNCTION
PHP_MINFO_FUNCTION(grpc)
Definition:
php_grpc.c:584
PHP_MSHUTDOWN_FUNCTION
PHP_MSHUTDOWN_FUNCTION(grpc)
Definition:
php_grpc.c:564
grpc_trace
char * grpc_trace
Definition:
php_grpc.h:80
log_filename
char * log_filename
Definition:
php_grpc.h:81
PHP_MINIT_FUNCTION
PHP_MINIT_FUNCTION(grpc)
Definition:
php_grpc.c:286
grpc_verbosity
char * grpc_verbosity
Definition:
php_grpc.h:79
version.h
grpc
Author(s):
autogenerated on Thu Mar 13 2025 03:00:52