source: trunk/grails-app/domain/dbnp/studycapturing/ProtocolParameterType.groovy @ 84

Last change on this file since 84 was 84, checked in by keesvb, 10 years ago

updated domain classes: added comments, carried out some normalization

File size: 685 bytes
RevLine 
[80]1package dbnp.studycapturing
2
[84]3/**
4 * Enum describing the type of a protocol parameter.
5 */
[80]6public enum ProtocolParameterType {
7    STRING('String'),
8    NUMBER('Number'),
9    STRINGLIST('List')
10
11    String name
12
13    ProtocolParameterType(String name) {
14     this.name = name
15    }
16
17    static list() {
18     [STRING, NUMBER, STRINGLIST]
19    }
20
[84]21
22    // It would be nice to see the description string in the scaffolding,
23    // and the following works, but then the item cannot be saved properly.
24    // TODO: find a way to display the enum description but save the enum value in the scaffolding
[80]25    /*def String toString() {
26        return this.name
27    }*/
28
29}
Note: See TracBrowser for help on using the repository browser.