本文整理汇总了C++中zend_object_std_init函数的典型用法代码示例。如果您正苦于以下问题:C++ zend_object_std_init函数的具体用法?C++ zend_object_std_init怎么用?C++ zend_object_std_init使用的例子?那么, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了zend_object_std_init函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: php_com_saproxy_create
int php_com_saproxy_create(zend_object *com_object, zval *proxy_out, zval *index)
{
php_com_saproxy *proxy, *rel = NULL;
proxy = ecalloc(1, sizeof(*proxy));
proxy->dimensions = 1;
if (com_object->ce == php_com_saproxy_class_entry) {
rel = (php_com_saproxy*) com_object;
proxy->obj = rel->obj;
proxy->dimensions += rel->dimensions;
} else {
proxy->obj = (php_com_dotnet_object*) com_object;
}
GC_ADDREF(&proxy->obj->zo);
proxy->indices = safe_emalloc(proxy->dimensions, sizeof(zval *), 0);
if (rel) {
clone_indices(proxy, rel, rel->dimensions);
}
ZVAL_DUP(&proxy->indices[proxy->dimensions-1], index);
zend_object_std_init(&proxy->std, php_com_saproxy_class_entry);
proxy->std.handlers = &php_com_saproxy_handlers;
ZVAL_OBJ(proxy_out, &proxy->std);
return 1;
}
示例2: ecalloc
static Set *set_init_ex(HTable *table)
{
Set *set = ecalloc(1, sizeof(Set));
zend_object_std_init(&set->std, set_ce);
set->std.handlers = &set_handlers;
set->table = table;
return set;
}
示例3: ecalloc
zend_object *php_ds_pair_create_object_ex(ds_pair_t *pair)
{
php_ds_pair_t *obj = ecalloc(1, sizeof(php_ds_pair_t));
zend_object_std_init(&obj->std, php_ds_pair_ce);
obj->std.handlers = &php_pair_handlers;
obj->pair = pair;
return &obj->std;
}
示例4: ecalloc
zend_object *php_lua_closure_create_object(zend_class_entry *ce) /* {{{ */
{
lua_closure_object *objval = ecalloc(1, sizeof(lua_closure_object) + zend_object_properties_size(ce));
zend_object *zobj = &(objval->std);
zend_object_std_init(zobj, ce);
zobj->handlers = &lua_closure_handlers;
return zobj;
} /* }}} */
示例5: php_zwlog_create
static inline zend_object* php_zwlog_create(zend_class_entry *ce) {
php_zwlog_t *pz = (php_zwlog_t*) ecalloc(1, sizeof(php_zwlog_t) + zend_object_properties_size(ce));
zend_object_std_init(&pz->std, ce);
object_properties_init(&pz->std, ce);
pz->std.handlers = &ZWLog_handlers;
return &pz->std;
}
示例6: ecalloc
/* Initializes an instace of wrapped_grpc_server_credentials to be associated
* with an object of a class specified by class_type */
zend_object *create_wrapped_grpc_server_credentials(zend_class_entry
*class_type) {
wrapped_grpc_server_credentials *intern;
intern = ecalloc(1, sizeof(wrapped_grpc_server_credentials) +
zend_object_properties_size(class_type));
zend_object_std_init(&intern->std, class_type);
object_properties_init(&intern->std, class_type);
intern->std.handlers = &server_credentials_ce_handlers;
return &intern->std;
}
示例7: yrmcds_client_new
static zend_object* yrmcds_client_new(zend_class_entry *ce) {
yrmcds_client_object* o;
o = ecalloc(1, sizeof(yrmcds_client_object) + zend_object_properties_size(ce));
zend_object_std_init(&o->std, ce); // upcall the default
object_properties_init(&o->std, ce);
o->std.handlers = &oh_yrmcds_client;
return &o->std;
}
示例8: krisp_object_new
static zend_object * krisp_object_new (zend_class_entry *class_type) {
KROBJ * intern;
PRINT_CALL_API_NAME;
intern = ecalloc (1, sizeof (KROBJ) + zend_object_properties_size (class_type));
zend_object_std_init (&intern->std,class_type TSRMLS_CC);
intern->std.handlers = &krisp_object_handlers;
return &intern->std;
}
示例9: php_float32x4_create
static inline zend_object* php_float32x4_create(zend_class_entry *ce) {
php_float32x4_t *p =
(php_float32x4_t*) ecalloc(1, sizeof(php_float32x4_t) + zend_object_properties_size(ce));
zend_object_std_init(&p->std, ce);
object_properties_init(&p->std, ce);
p->std.handlers = &php_float32x4_handlers;
return &p->std;
}
示例10: ecalloc
zend_object *gearman_job_obj_new(zend_class_entry *ce) {
gearman_job_obj *intern = ecalloc(1,
sizeof(gearman_job_obj) +
zend_object_properties_size(ce));
zend_object_std_init(&(intern->std), ce);
object_properties_init(&intern->std, ce);
intern->std.handlers = &gearman_job_obj_handlers;
return &intern->std;
}
示例11: skyray_promise_object_init
void skyray_promise_object_init(skyray_promise_t *self, zend_class_entry *ce)
{
zend_object_std_init(&self->std, ce);
object_properties_init(&self->std, ce);
ZVAL_UNDEF(&self->result);
zend_hash_init(&self->on_fulfilled, 8, NULL, promise_resolve_context_free, 0);
zend_hash_init(&self->on_rejcted, 8, NULL, promise_resolve_context_free, 0);
zend_hash_init(&self->on_notify, 8, NULL, promise_resolve_context_free, 0);
}
示例12: skyray_stream_client_object_new
zend_object * skyray_stream_client_object_new(zend_class_entry *ce)
{
skyray_stream_client_t *intern;
intern = ecalloc(1, sizeof(skyray_stream_client_t) + zend_object_properties_size(ce));
zend_object_std_init(&intern->std, ce);
object_properties_init(&intern->std, ce);
intern->std.handlers = &skyray_handler_StreamClient;
return &intern->std;
}
示例13: php_jit_struct_create
static inline zend_object* php_jit_struct_create(zend_class_entry *ce) {
php_jit_struct_t *pstruct =
(php_jit_struct_t*) ecalloc(1, sizeof(php_jit_struct_t) + zend_object_properties_size(ce));
zend_object_std_init(&pstruct->std, ce);
object_properties_init(&pstruct->std, ce);
pstruct->std.handlers = &php_jit_struct_handlers;
return &pstruct->std;
}
示例14: skyray_process_watcher_object_new
static zend_object * skyray_process_watcher_object_new(zend_class_entry *ce)
{
skyray_process_watcher_t *intern;
intern = ecalloc(1, sizeof(skyray_process_watcher_t) + zend_object_properties_size(ce));
zend_object_std_init(&intern->std, ce);
object_properties_init(&intern->std, ce);
intern->std.handlers = &skyray_handler_ProcessWatcher;
return &intern->std;
}
示例15: ecalloc
static zend_object *pimple_closure_object_create(zend_class_entry *ce)
{
pimple_closure_object *pimple_closure_obj = NULL;
pimple_closure_obj = ecalloc(1, sizeof(pimple_closure_object) + zend_object_properties_size(ce));
zend_object_std_init(&pimple_closure_obj->zobj, ce);
object_properties_init(&pimple_closure_obj->zobj, ce);
pimple_closure_obj->zobj.handlers = &pimple_closure_object_handlers;
return &pimple_closure_obj->zobj;
}