This shows you the differences between two versions of the page.
stats:proc:removestudentid [2011/09/27 20:12] Patrick Michel created |
stats:proc:removestudentid [2013/07/10 12:34] |
||
---|---|---|---|
Line 1: | Line 1: | ||
- | ====== Remove Student ID ====== | ||
- | |||
- | <code xcend> | ||
- | # correspondingly, this is the removeStudent procedure | ||
- | removeStudentId(ident username) { | ||
- | assume exists //accounts/account[username]/student; # implies the account exists, which is implicitly true anyway | ||
- | |||
- | assume size(//exercises/exercise/students/student[//accounts/account[username]/student/id]) = 0; | ||
- | assume size(//exams/exam/results/participant[//accounts/account[username]/student/id]) = 0; | ||
- | |||
- | remove //account/account[username]/student; | ||
- | } | ||
- | </code> | ||