Skip to Content.
Sympa Menu

grouper-dev - [grouper-dev] Recursive Stem deletion

Subject: Grouper Developers Forum

List archive

[grouper-dev] Recursive Stem deletion


Chronological Thread 
  • From: Gagné Sébastien <>
  • To: <>
  • Subject: [grouper-dev] Recursive Stem deletion
  • Date: Tue, 24 Jul 2012 13:12:53 -0400

Hi,

I was wondering if there was an easy way to delete a stem with children under it and delete the child objects too ? From what I see in Stem.delete() there’s a validation to prevent deleting a Stem with childs (groups or stem), why is that ? Is it because you couldn’t validate that the session/user had the necessary rights to delete all the child objects?

 

I can create a little bit of code that would do the recursive find and delete using a RootSession for our tests, but I was wondering why it wasn’t included in the Stem class directly ?

 

Our current use case is easy cleaning of tests and temp data, but maybe in the future it could be useful for other tasks.

 

Thanks

 

 

Sébastien Gagné,     | Analyste en informatique

514-343-6111 x33844  | Université de Montréal,

                     | Pavillon Roger-Gaudry, local X-100-11

 




Archive powered by MHonArc 2.6.16.

Top of Page