User Tools

Site Tools


stats:proc:deleteaccount

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

stats:proc:deleteaccount [2011/09/28 21:17]
Patrick Michel
stats:proc:deleteaccount [2013/07/10 12:34]
Line 1: Line 1:
-====== Remove Account ====== 
  
-<code xcend> 
-removeAccount(ident username) { 
-  assume exists //​accounts/​account[username];​ 
-  ​ 
-  assume size(//​accounts/​account[username]/​examiner) = 0; 
-  assume size(//​accounts/​account[username]/​assistant) = 0; 
-  assume size(//​accounts/​account[username]/​tutor) = 0; 
- 
-  # not yet a constraint of the implementation,​ but is seems practically relevant :-) 
-  if exists //​accounts/​account[username]/​admin then 
-    assume size(//​accounts/​account/​admin) > 1; 
-  fi 
- 
-  if exists //​accounts/​account[username]/​student then 
-    assume size(//​exercises/​exercise/​students/​student[//​accounts/​account[username]/​student/​id]) = 0; 
-    assume size(//​exams/​exam/​results/​participant[//​accounts/​account[username]/​student/​id]) = 0; 
-  fi 
-  ​ 
-  remove //​accounts/​account[username];​ 
-} 
-</​code>​ 
stats/proc/deleteaccount.txt ยท Last modified: 2013/07/10 12:34 (external edit)