1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16 package org.kuali.rice.krms.dto;
17
18 import org.kuali.rice.krms.api.repository.proposition.PropositionParameterContract;
19
20 import java.io.Serializable;
21 import org.kuali.rice.krms.api.repository.term.TermDefinition;
22
23
24
25
26 public class PropositionParameterEditor implements PropositionParameterContract, Serializable {
27
28 private String id;
29 private String propId;
30 private String value;
31 private TermDefinition termValue;
32 private String parameterType;
33 private Integer sequenceNumber;
34 private Long versionNumber;
35
36 public PropositionParameterEditor(){
37 super();
38 }
39
40 public PropositionParameterEditor(String parameterType, Integer sequenceNumber){
41 super();
42 this.setParameterType(parameterType);
43 this.setSequenceNumber(sequenceNumber);
44 this.setVersionNumber(Long.valueOf(1));
45 this.setValue(null);
46 this.setTermValue(null);
47 }
48
49
50
51
52
53
54 public PropositionParameterEditor(PropositionParameterContract definition) {
55 this.id = definition.getId();
56 this.propId = definition.getPropId();
57 this.value = definition.getValue();
58 this.termValue = definition.getTermValue();
59 this.parameterType = definition.getParameterType();
60 this.sequenceNumber = definition.getSequenceNumber();
61 this.versionNumber = definition.getVersionNumber();
62 }
63
64 public void clear() {
65 this.value = null;
66 }
67
68 public void setId(String id) {
69 this.id = id;
70 }
71
72 @Override
73 public String getId() {
74 return id;
75 }
76
77 public void setPropId(String propId) {
78 this.propId = propId;
79 }
80
81 @Override
82 public String getPropId() {
83 return propId;
84 }
85
86 public void setValue(String value) {
87 this.value = value;
88 }
89
90 @Override
91 public String getValue() {
92 return value;
93 }
94
95 public void setTermValue(TermDefinition termValue) {
96 this.termValue = termValue;
97 }
98
99 @Override
100 public TermDefinition getTermValue() {
101 return termValue;
102 }
103
104
105
106 public void setParameterType(String parameterType) {
107 this.parameterType = parameterType;
108 }
109
110 @Override
111 public String getParameterType() {
112 return parameterType;
113 }
114
115 public void setSequenceNumber(Integer sequenceNumber) {
116 this.sequenceNumber = sequenceNumber;
117 }
118
119 @Override
120 public Integer getSequenceNumber() {
121 return sequenceNumber;
122 }
123
124 @Override
125 public Long getVersionNumber() {
126 return versionNumber;
127 }
128
129 public void setVersionNumber(Long versionNumber) {
130 this.versionNumber = versionNumber;
131 }
132
133 }