Samba4/LDB/API: Difference between revisions
From SambaWiki
Line 24: | Line 24: | ||
* dn: The DN to linearize |
* dn: The DN to linearize |
||
* mode: Style of extended DN to return (0 is HEX representation of binary form, 1 is a string form) |
* mode: Style of extended DN to return (0 is HEX representation of binary form, 1 is a string form) |
||
== const struct ldb_val *ldb_dn_get_extended_component(struct ldb_dn *dn, const char *name) == |
|||
== int ldb_dn_set_extended_component(struct ldb_dn *dn, const char *name, const struct ldb_val *val) == |
|||
== void ldb_dn_remove_extended_components(struct ldb_dn *dn) == |
|||
== bool ldb_dn_has_extended(struct ldb_dn *dn) == |
|||
== int ldb_dn_extended_add_syntax(struct ldb_context *ldb, unsigned flags, const struct ldb_dn_extended_syntax *syntax) == |
|||
== struct ldb_dn *ldb_dn_new(TALLOC_CTX *mem_ctx, struct ldb_context *ldb, const char *dn) == |
|||
Allocate a new DN from a string |
|||
Parameters: |
|||
* mem_ctx: TALLOC context to return resulting ldb_dn structure on |
|||
* dn: The new DN |
|||
The DN will not be parsed at this time. Use ldb_dn_validate to tell if the DN is syntacticly correct |
Revision as of 23:08, 23 September 2009
DN
const char *ldb_dn_get_linearized(struct ldb_dn *dn)
Get the linear form of a DN (without any extended components)
Parameters:
- dn: The DN to linearize
char *ldb_dn_alloc_linearized(TALLOC_CTX *mem_ctx, struct ldb_dn *dn)
Allocate a copy of the linear form of a DN (without any extended components) onto the supplied memory context
Parameters:
- dn: The DN to linearize
- mem_ctx: TALLOC context to return result on
char *ldb_dn_get_extended_linearized(void *mem_ctx, struct ldb_dn *dn, int mode)
Get the linear form of a DN (with any extended components)
Parameters:
- mem_ctx: TALLOC context to return result on
- dn: The DN to linearize
- mode: Style of extended DN to return (0 is HEX representation of binary form, 1 is a string form)
const struct ldb_val *ldb_dn_get_extended_component(struct ldb_dn *dn, const char *name)
int ldb_dn_set_extended_component(struct ldb_dn *dn, const char *name, const struct ldb_val *val)
void ldb_dn_remove_extended_components(struct ldb_dn *dn)
bool ldb_dn_has_extended(struct ldb_dn *dn)
int ldb_dn_extended_add_syntax(struct ldb_context *ldb, unsigned flags, const struct ldb_dn_extended_syntax *syntax)
struct ldb_dn *ldb_dn_new(TALLOC_CTX *mem_ctx, struct ldb_context *ldb, const char *dn)
Allocate a new DN from a string
Parameters:
- mem_ctx: TALLOC context to return resulting ldb_dn structure on
- dn: The new DN
The DN will not be parsed at this time. Use ldb_dn_validate to tell if the DN is syntacticly correct