urp.h 1.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445
  1. /** BEGIN COPYRIGHT BLOCK
  2. * Copyright (C) 2001 Sun Microsystems, Inc. Used by permission.
  3. * Copyright (C) 2005 Red Hat, Inc.
  4. * All rights reserved.
  5. * END COPYRIGHT BLOCK **/
  6. /*
  7. */
  8. #define REASON_ANNOTATE_DN "namingConflict"
  9. #define REASON_RESURRECT_ENTRY "deletedEntryHasChildren"
  10. /*
  11. * urp.c
  12. */
  13. int urp_modify_operation( Slapi_PBlock *pb );
  14. int urp_add_operation( Slapi_PBlock *pb );
  15. int urp_delete_operation( Slapi_PBlock *pb );
  16. int urp_post_delete_operation( Slapi_PBlock *pb );
  17. int urp_modrdn_operation( Slapi_PBlock *pb );
  18. int urp_post_modrdn_operation( Slapi_PBlock *pb );
  19. /* urp internal ops */
  20. int urp_fixup_add_entry (Slapi_Entry *e, const char *target_uniqueid, const char *parentuniqueid, CSN *opcsn, int opflags);
  21. int urp_fixup_delete_entry (const char *uniqueid, const char *dn, CSN *opcsn, int opflags);
  22. int urp_fixup_rename_entry (Slapi_Entry *entry, const char *newrdn, int opflags);
  23. int urp_fixup_modify_entry (const char *uniqueid, const char *dn, CSN *opcsn, Slapi_Mods *smods, int opflags);
  24. int is_suffix_dn (Slapi_PBlock *pb, const Slapi_DN *dn, Slapi_DN **parenddn);
  25. /*
  26. * urp_glue.c
  27. */
  28. int is_glue_entry(const Slapi_Entry* entry);
  29. int create_glue_entry ( Slapi_PBlock *pb, char *sessionid, Slapi_DN *dn, const char *uniqueid, CSN *opcsn );
  30. int entry_to_glue(char *sessionid, const Slapi_Entry* entry, const char *reason, CSN *opcsn);
  31. int glue_to_entry (Slapi_PBlock *pb, Slapi_Entry *entry );
  32. PRBool get_glue_csn(const Slapi_Entry *entry, const CSN **gluecsn);
  33. /*
  34. * urp_tombstone.c
  35. */
  36. int is_tombstone_entry(const Slapi_Entry* entry);
  37. int tombstone_to_glue(Slapi_PBlock *pb, const char *sessionid, Slapi_Entry *entry, const Slapi_DN *parentdn, const char *reason, CSN *opcsn);
  38. int entry_to_tombstone ( Slapi_PBlock *pb, Slapi_Entry *entry );
  39. PRBool get_tombstone_csn(const Slapi_Entry *entry, const CSN **delcsn);