当前位置: 首页>>代码示例>>C++>>正文


C++ zend_object_std_init函数代码示例

本文整理汇总了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;
}
开发者ID:KonstantinKuklin,项目名称:php-src,代码行数:30,代码来源:com_saproxy.c

示例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;
}
开发者ID:Driky,项目名称:ds,代码行数:8,代码来源:php_set.c

示例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;
}
开发者ID:dlundgren,项目名称:extension,代码行数:9,代码来源:php_pair.c

示例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;
} /* }}} */
开发者ID:laruence,项目名称:php-lua,代码行数:10,代码来源:lua_closure.c

示例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;
}
开发者ID:krakjoe,项目名称:zway,代码行数:10,代码来源:zwlog.c

示例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;
}
开发者ID:thinkerou,项目名称:grpc-php7,代码行数:12,代码来源:server_credentials.c

示例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;
}
开发者ID:cybozu,项目名称:php-yrmcds,代码行数:10,代码来源:yrmcds.c

示例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;
}
开发者ID:OOPS-ORG-PHP,项目名称:mod_krisp,代码行数:11,代码来源:php_krisp_class.c

示例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;
}
开发者ID:krakjoe,项目名称:SIMD,代码行数:11,代码来源:simd.c

示例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;
}
开发者ID:wcgallego,项目名称:pecl-gearman,代码行数:11,代码来源:php_gearman_job.c

示例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);
}
开发者ID:Lucups,项目名称:Skyray,代码行数:11,代码来源:promise.c

示例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;
}
开发者ID:Lucups,项目名称:Skyray,代码行数:11,代码来源:client.c

示例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;
}
开发者ID:krakjoe,项目名称:jitfu,代码行数:11,代码来源:struct.c

示例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;
}
开发者ID:Lucups,项目名称:Skyray,代码行数:11,代码来源:process_watcher.c

示例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;
}
开发者ID:ruolinn,项目名称:yaf,代码行数:12,代码来源:yaf_closure.c


注:本文中的zend_object_std_init函数示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。