Last change
on this file since 193 was
193,
checked in by Maciej Komosinski, 10 years ago
|
Set svn:eol-style native for all textual files
|
-
Property svn:eol-style set to
native
|
File size:
598 bytes
|
Line | |
---|
1 | package com.framsticks.params.types; |
---|
2 | |
---|
3 | import java.util.List; |
---|
4 | |
---|
5 | import com.framsticks.params.ParamBuilder; |
---|
6 | |
---|
7 | import javax.annotation.concurrent.Immutable; |
---|
8 | |
---|
9 | /** |
---|
10 | * @author Piotr Sniegowski |
---|
11 | */ |
---|
12 | @Immutable |
---|
13 | public class EnumParam extends DecimalParam { |
---|
14 | |
---|
15 | |
---|
16 | protected final List<String> enums; |
---|
17 | |
---|
18 | /** |
---|
19 | * This constructor exists because EnumParam is different package than ParamBuilder. |
---|
20 | * |
---|
21 | * @param enums |
---|
22 | */ |
---|
23 | public EnumParam(ParamBuilder builder) { |
---|
24 | super(builder); |
---|
25 | this.enums = builder.getEnumValues(); |
---|
26 | assert(this.enums != null); |
---|
27 | } |
---|
28 | |
---|
29 | public List<String> getElements() { |
---|
30 | return enums; |
---|
31 | } |
---|
32 | |
---|
33 | |
---|
34 | |
---|
35 | } |
---|
Note: See
TracBrowser
for help on using the repository browser.