This shows you the differences between two versions of the page.
stats:proc:creategroup [2011/09/29 16:22] Patrick Michel |
stats:proc:creategroup [2013/07/10 12:42] |
||
---|---|---|---|
Line 1: | Line 1: | ||
- | ====== Create Group ====== | ||
- | |||
- | <code xcend> | ||
- | createGroup(ident id, ident groupId, string day, string time, string location, integer maxSize) { | ||
- | assume exists //exercises/exercise[id]; | ||
- | assume not exists //exercises/exercise[id]/groups/group[groupId]; | ||
- | | ||
- | assume maxSize >= 0; | ||
- | assume day = "Monday" || day = "Tuesday" || ...; | ||
- | | ||
- | insert //exercises/exercise[id]/groups <group id=[groupId] day=[day] time=[time] location=[location] curSize=[0] maxSize=[maxSize] />; | ||
- | } # roles: assistant[id] | ||
- | </code> | ||
- | |||