本文整理汇总了C++中overlay_register函数的典型用法代码示例。如果您正苦于以下问题:C++ overlay_register函数的具体用法?C++ overlay_register怎么用?C++ overlay_register使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了overlay_register函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: vernum_initialize
int
vernum_initialize(void)
{
int code, i;
for ( i = 0; as[ i ].desc != NULL; i++ ) {
code = register_at( as[ i ].desc, as[ i ].adp, 0 );
if ( code ) {
Debug( LDAP_DEBUG_ANY,
"vernum_initialize: register_at #%d failed\n",
i, 0, 0 );
return code;
}
/* Allow Manager to set these as needed */
if ( is_at_no_user_mod( (*as[ i ].adp)->ad_type ) ) {
(*as[ i ].adp)->ad_type->sat_flags |=
SLAP_AT_MANAGEABLE;
}
}
vernum.on_bi.bi_type = "vernum";
vernum.on_bi.bi_op_add = vernum_op_add;
vernum.on_bi.bi_op_modify = vernum_op_modify;
vernum.on_bi.bi_db_init = vernum_db_init;
vernum.on_bi.bi_db_open = vernum_db_open;
vernum.on_bi.bi_db_destroy = vernum_db_destroy;
return overlay_register( &vernum );
}
示例2: translucent_initialize
int translucent_initialize() {
int rc;
Debug(LDAP_DEBUG_TRACE, "==> translucent_initialize\n", 0, 0, 0);
translucent.on_bi.bi_type = "translucent";
translucent.on_bi.bi_db_init = translucent_db_init;
translucent.on_bi.bi_db_config = translucent_db_config;
translucent.on_bi.bi_db_open = translucent_db_open;
translucent.on_bi.bi_db_close = translucent_db_close;
translucent.on_bi.bi_db_destroy = translucent_db_destroy;
translucent.on_bi.bi_op_bind = translucent_bind;
translucent.on_bi.bi_op_add = translucent_add;
translucent.on_bi.bi_op_modify = translucent_modify;
translucent.on_bi.bi_op_modrdn = translucent_modrdn;
translucent.on_bi.bi_op_delete = translucent_delete;
translucent.on_bi.bi_op_search = translucent_search;
translucent.on_bi.bi_op_compare = translucent_compare;
translucent.on_bi.bi_connection_destroy = translucent_connection_destroy;
translucent.on_bi.bi_extended = translucent_exop;
translucent.on_bi.bi_cf_ocs = translucentocs;
rc = config_register_schema ( translucentcfg, translucentocs );
if ( rc ) return rc;
return(overlay_register(&translucent));
}
示例3: slapi_over_init
static int
slapi_over_init()
{
memset( &slapi, 0, sizeof(slapi) );
slapi.on_bi.bi_type = SLAPI_OVERLAY_NAME;
slapi.on_bi.bi_op_bind = slapi_op_func;
slapi.on_bi.bi_op_unbind = slapi_op_func;
slapi.on_bi.bi_op_search = slapi_op_func;
slapi.on_bi.bi_op_compare = slapi_op_func;
slapi.on_bi.bi_op_modify = slapi_op_func;
slapi.on_bi.bi_op_modrdn = slapi_op_func;
slapi.on_bi.bi_op_add = slapi_op_func;
slapi.on_bi.bi_op_delete = slapi_op_func;
slapi.on_bi.bi_op_abandon = slapi_op_func;
slapi.on_bi.bi_op_cancel = slapi_op_func;
slapi.on_bi.bi_db_open = slapi_over_db_open;
slapi.on_bi.bi_db_close = slapi_over_db_close;
slapi.on_bi.bi_extended = slapi_over_extended;
slapi.on_bi.bi_access_allowed = slapi_over_access_allowed;
slapi.on_bi.bi_operational = slapi_over_aux_operational;
slapi.on_bi.bi_acl_group = slapi_over_acl_group;
return overlay_register( &slapi );
}
示例4: lastbind_initialize
int lastbind_initialize()
{
int i, code;
/* register operational schema for this overlay (authTimestamp attribute) */
for (i=0; lastBind_OpSchema[i].def; i++) {
code = register_at( lastBind_OpSchema[i].def, lastBind_OpSchema[i].ad, 0 );
if ( code ) {
Debug( LDAP_DEBUG_ANY,
"lastbind_initialize: register_at failed\n" );
return code;
}
}
ad_authTimestamp->ad_type->sat_flags |= SLAP_AT_MANAGEABLE;
lastbind.on_bi.bi_type = "lastbind";
lastbind.on_bi.bi_db_init = lastbind_db_init;
lastbind.on_bi.bi_db_close = lastbind_db_close;
lastbind.on_bi.bi_op_bind = lastbind_bind;
/* register configuration directives */
lastbind.on_bi.bi_cf_ocs = lastbindocs;
code = config_register_schema( lastbindcfg, lastbindocs );
if ( code ) return code;
return overlay_register( &lastbind );
}
示例5: valsort_initialize
int valsort_initialize( void )
{
int rc;
valsort.on_bi.bi_type = "valsort";
valsort.on_bi.bi_db_destroy = valsort_destroy;
valsort.on_bi.bi_db_open = valsort_db_open;
valsort.on_bi.bi_op_add = valsort_add;
valsort.on_bi.bi_op_modify = valsort_modify;
valsort.on_response = valsort_response;
valsort.on_bi.bi_cf_ocs = valsort_cfocs;
rc = register_supported_control( LDAP_CONTROL_VALSORT,
SLAP_CTRL_SEARCH | SLAP_CTRL_HIDE, NULL, valsort_parseCtrl,
&valsort_cid );
if ( rc != LDAP_SUCCESS ) {
Debug( LDAP_DEBUG_ANY, "Failed to register control %d\n", rc, 0, 0 );
return rc;
}
syn_numericString = syn_find( "1.3.6.1.4.1.1466.115.121.1.36" );
rc = config_register_schema( valsort_cfats, valsort_cfocs );
if ( rc ) return rc;
return overlay_register(&valsort);
}
示例6: usn_init
int
usn_init( void )
{
int i, code;
memset( &usn, 0, sizeof( slap_overinst ) );
usn.on_bi.bi_type = "usn";
usn.on_bi.bi_db_init = usn_db_init;
usn.on_bi.bi_db_destroy = usn_db_destroy;
usn.on_bi.bi_db_open = usn_db_open;
usn.on_bi.bi_db_close = usn_db_close;
usn.on_bi.bi_op_modify = usn_func;
usn.on_bi.bi_op_modrdn = usn_func;
usn.on_bi.bi_op_add = usn_func;
usn.on_bi.bi_op_delete = usn_func;
usn.on_bi.bi_operational = usn_operational;
for ( i = 0; as[i].desc; i++ ) {
code = register_at( as[i].desc, as[i].adp, 0 );
if ( code ) {
Debug( LDAP_DEBUG_ANY,
"usn_init: register_at #%d failed\n", i, 0, 0 );
return code;
}
}
return overlay_register( &usn );
}
示例7: pguid_initialize
int
pguid_initialize(void)
{
int code, i;
for ( i = 0; as[ i ].desc != NULL; i++ ) {
code = register_at( as[ i ].desc, as[ i ].adp, 0 );
if ( code ) {
Debug( LDAP_DEBUG_ANY,
"pguid_initialize: register_at #%d failed\n",
i, 0, 0 );
return code;
}
/* Allow Manager to set these as needed */
if ( is_at_no_user_mod( (*as[ i ].adp)->ad_type ) ) {
(*as[ i ].adp)->ad_type->sat_flags |=
SLAP_AT_MANAGEABLE;
}
}
pguid.on_bi.bi_type = "pguid";
pguid.on_bi.bi_op_add = pguid_op_add;
pguid.on_bi.bi_op_modrdn = pguid_op_rename;
pguid.on_bi.bi_db_init = pguid_db_init;
pguid.on_bi.bi_db_open = pguid_db_open;
return overlay_register( &pguid );
}
示例8: autogroup_initialize
static
int
autogroup_initialize(void)
{
int rc = 0;
autogroup.on_bi.bi_type = "autogroup";
autogroup.on_bi.bi_db_open = autogroup_db_open;
autogroup.on_bi.bi_db_close = autogroup_db_close;
autogroup.on_bi.bi_db_destroy = autogroup_db_destroy;
autogroup.on_bi.bi_op_add = autogroup_add_entry;
autogroup.on_bi.bi_op_delete = autogroup_delete_entry;
autogroup.on_bi.bi_op_modify = autogroup_modify_entry;
autogroup.on_response = autogroup_response;
autogroup.on_bi.bi_cf_ocs = agocs;
rc = config_register_schema( agcfg, agocs );
if ( rc ) {
return rc;
}
return overlay_register( &autogroup );
}
示例9: addpartial_init
int addpartial_init()
{
addpartial.on_bi.bi_type = "addpartial";
addpartial.on_bi.bi_op_add = addpartial_add;
return (overlay_register(&addpartial));
}
示例10: dynlist_initialize
static
#endif /* SLAPD_OVER_DYNLIST == SLAPD_MOD_DYNAMIC */
int
dynlist_initialize(void)
{
int rc = 0;
dynlist.on_bi.bi_type = "dynlist";
#ifdef TAKEOVER_DYNGROUP
/* makes dynlist incompatible with dyngroup */
dynlist.on_bi.bi_obsolete_names = obsolete_names;
#endif
dynlist.on_bi.bi_db_config = config_generic_wrapper;
dynlist.on_bi.bi_db_open = dynlist_db_open;
dynlist.on_bi.bi_db_destroy = dynlist_db_destroy;
dynlist.on_response = dynlist_response;
dynlist.on_bi.bi_cf_ocs = dlocs;
rc = config_register_schema( dlcfg, dlocs );
if ( rc ) {
return rc;
}
return overlay_register( &dynlist );
}
示例11: trace_initialize
int
trace_initialize()
{
trace.on_bi.bi_type = "trace";
trace.on_bi.bi_db_init = trace_db_init;
trace.on_bi.bi_db_open = trace_db_open;
trace.on_bi.bi_db_config = trace_db_config;
trace.on_bi.bi_db_close = trace_db_close;
trace.on_bi.bi_db_destroy = trace_db_destroy;
trace.on_bi.bi_op_add = trace_op_func;
trace.on_bi.bi_op_bind = trace_op_func;
trace.on_bi.bi_op_unbind = trace_op_func;
trace.on_bi.bi_op_compare = trace_op_func;
trace.on_bi.bi_op_delete = trace_op_func;
trace.on_bi.bi_op_modify = trace_op_func;
trace.on_bi.bi_op_modrdn = trace_op_func;
trace.on_bi.bi_op_search = trace_op_func;
trace.on_bi.bi_op_abandon = trace_op_func;
trace.on_bi.bi_extended = trace_op_func;
trace.on_response = trace_response;
return overlay_register( &trace );
}
示例12: aa_initialize
static
#endif /* SLAPD_OVER_ALLOWED == SLAPD_MOD_DYNAMIC */
int
aa_initialize( void )
{
int i;
aa.on_bi.bi_type = "allowed";
aa.on_bi.bi_operational = aa_operational;
/* aa schema integration */
for ( i = 0; aa_attrs[i].at; i++ ) {
int code;
code = register_at( aa_attrs[i].at, aa_attrs[i].ad, 0 );
if ( code ) {
Debug( LDAP_DEBUG_ANY,
"aa_initialize: register_at failed\n", 0, 0, 0 );
return -1;
}
}
return overlay_register( &aa );
}
示例13: nops_initialize
static
#endif
int
nops_initialize( void ) {
nops_ovl.on_bi.bi_type = "nops";
nops_ovl.on_bi.bi_op_modify = nops_modify;
return overlay_register( &nops_ovl );
}
示例14: allop_init
int
allop_init()
{
allop.on_bi.bi_type = "allop";
allop.on_bi.bi_db_config = allop_db_config;
allop.on_bi.bi_db_destroy = allop_db_destroy;
allop.on_bi.bi_op_search = allop_op_search;
return overlay_register( &allop );
}
示例15: deref_initialize
int
deref_initialize(void)
{
deref.on_bi.bi_type = "deref";
deref.on_bi.bi_db_init = deref_db_init;
deref.on_bi.bi_db_open = deref_db_open;
#ifdef SLAP_CONFIG_DELETE
deref.on_bi.bi_db_destroy = deref_db_destroy;
#endif /* SLAP_CONFIG_DELETE */
deref.on_bi.bi_op_search = deref_op_search;
return overlay_register( &deref );
}