mirror of
https://github.com/php/php-src.git
synced 2025-08-19 17:04:47 +02:00
rpc apstraction module
does only work with ZendEngine2
This commit is contained in:
parent
7935e73749
commit
ff62e746d2
7 changed files with 502 additions and 0 deletions
25
ext/rpc/handler.h
Normal file
25
ext/rpc/handler.h
Normal file
|
@ -0,0 +1,25 @@
|
|||
#ifndef HANDLER_H
|
||||
#define HANDLER_H
|
||||
|
||||
#include "php.h"
|
||||
|
||||
#define RPC_HANDLER(layer) {#layer, layer##_handler_init, &layer##_object_handlers, &layer##_class_entry}
|
||||
#define RPC_DECLARE_HANDLER(layer) void layer##_handler_init(); \
|
||||
rpc_object_handlers layer##_object_handlers; \
|
||||
zend_class_entry layer##_class_entry;
|
||||
#define RPC_INIT_FUNCTION(layer) void layer##_handler_init()
|
||||
#define RPC_REGISTER_HANDLERS(layer) zend_class_entry layer##_class_entry; \
|
||||
rpc_object_handlers layer##object_handlers;
|
||||
|
||||
typedef struct _rpc_object_handlers {
|
||||
int i;
|
||||
} rpc_object_handlers;
|
||||
|
||||
typedef struct _rpc_handler_entry {
|
||||
char *name;
|
||||
void (*rpc_handler_init)();
|
||||
rpc_object_handlers *handlers;
|
||||
zend_class_entry *ce;
|
||||
} rpc_handler_entry;
|
||||
|
||||
#endif /* HANDLER_H */
|
Loading…
Add table
Add a link
Reference in a new issue