1 |
|
package org.kuali.student.lum.common.client.widgets; |
2 |
|
|
3 |
|
import org.kuali.student.common.assembly.data.Data; |
4 |
|
import org.kuali.student.common.assembly.helper.PropertyEnum; |
5 |
|
|
|
|
| 0% |
Uncovered Elements: 28 (28) |
Complexity: 11 |
Complexity Density: 0.73 |
|
6 |
|
public class QueryParamHelper { |
7 |
|
|
|
|
| 0% |
Uncovered Elements: 4 (4) |
Complexity: 2 |
Complexity Density: 1 |
|
8 |
|
public enum Properties implements PropertyEnum |
9 |
|
{ |
10 |
|
VALUE ("value"), |
11 |
|
LIST_VALUE ("listValue"), |
12 |
|
KEY ("key"); |
13 |
|
|
14 |
|
private final String key; |
15 |
|
|
|
|
| 0% |
Uncovered Elements: 1 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
16 |
0
|
private Properties (final String key) {... |
17 |
0
|
this.key = key; |
18 |
|
} |
19 |
|
|
|
|
| 0% |
Uncovered Elements: 1 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
20 |
0
|
@Override... |
21 |
|
public String getKey() { |
22 |
0
|
return this.key; |
23 |
|
} |
24 |
|
} |
25 |
|
|
26 |
|
private Data data; |
27 |
|
|
|
|
| 0% |
Uncovered Elements: 1 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
28 |
0
|
public QueryParamHelper(Data data) {... |
29 |
0
|
this.data = data; |
30 |
|
} |
31 |
|
|
|
|
| 0% |
Uncovered Elements: 5 (5) |
Complexity: 2 |
Complexity Density: 0.67 |
|
32 |
0
|
public static QueryParamHelper wrap(Data data) {... |
33 |
0
|
if (data == null) { |
34 |
0
|
return null; |
35 |
|
} |
36 |
0
|
return new QueryParamHelper(data); |
37 |
|
} |
38 |
|
|
|
|
| 0% |
Uncovered Elements: 1 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
39 |
0
|
public void setValue(String value) {... |
40 |
0
|
data.set(Properties.VALUE.getKey(), value); |
41 |
|
} |
42 |
|
|
|
|
| 0% |
Uncovered Elements: 1 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
43 |
0
|
public String getValue() {... |
44 |
0
|
return (String) data.get(Properties.VALUE.getKey()); |
45 |
|
} |
46 |
|
|
|
|
| 0% |
Uncovered Elements: 1 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
47 |
0
|
public void setListValue(Data value) {... |
48 |
0
|
data.set(Properties.LIST_VALUE.getKey(), value); |
49 |
|
} |
50 |
|
|
|
|
| 0% |
Uncovered Elements: 7 (7) |
Complexity: 2 |
Complexity Density: 0.4 |
|
51 |
0
|
public Data getListValue() {... |
52 |
0
|
Data listValue = data.get(Properties.LIST_VALUE.getKey()); |
53 |
0
|
if (listValue == null) { |
54 |
0
|
listValue = new Data(); |
55 |
0
|
setListValue(listValue); |
56 |
|
} |
57 |
0
|
return listValue; |
58 |
|
} |
59 |
|
|
|
|
| 0% |
Uncovered Elements: 1 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
60 |
0
|
public void setKey(String value) {... |
61 |
0
|
data.set(Properties.KEY.getKey(), value); |
62 |
|
} |
63 |
|
|
|
|
| 0% |
Uncovered Elements: 1 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
64 |
0
|
public String getKey() {... |
65 |
0
|
return (String) data.get(Properties.KEY.getKey()); |
66 |
|
} |
67 |
|
|
|
|
| 0% |
Uncovered Elements: 1 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
68 |
0
|
public Data getData() {... |
69 |
0
|
return data; |
70 |
|
} |
71 |
|
|
72 |
|
} |