View Javadoc

1   /*
2    * Copyright 2007 The Kuali Foundation Licensed under the Educational Community
3    * License, Version 1.0 (the "License"); you may not use this file except in
4    * compliance with the License. You may obtain a copy of the License at
5    * http://www.opensource.org/licenses/ecl1.php Unless required by applicable law
6    * or agreed to in writing, software distributed under the License is
7    * distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
8    * KIND, either express or implied. See the License for the specific language
9    * governing permissions and limitations under the License.
10   */
11  package org.kuali.student.enrollment.lpr.dto;
12  
13  import java.util.List;
14  
15  import javax.xml.bind.annotation.XmlAccessType;
16  import javax.xml.bind.annotation.XmlAccessorType;
17  import javax.xml.bind.annotation.XmlAnyElement;
18  import javax.xml.bind.annotation.XmlElement;
19  import javax.xml.bind.annotation.XmlType;
20  
21  import org.kuali.student.enrollment.lpr.infc.LprTransactionItemRequestOption;
22  import org.w3c.dom.Element;
23  
24  /**
25   * @author Kuali Student Team (sambitpatnaik)
26   */
27  @XmlAccessorType(XmlAccessType.FIELD)
28  @XmlType(name = "RequestOptionInfo", propOrder = {"id", "optionKey", "optionValue", "_futureElements"})
29  public class LprTransactionItemRequestOptionInfo implements LprTransactionItemRequestOption {
30  
31      @XmlElement
32      private String id;
33      @XmlElement
34      private String optionKey;
35      @XmlElement
36      private String optionValue;
37      @XmlAnyElement
38      private List<Element> _futureElements;
39  
40      public LprTransactionItemRequestOptionInfo() {
41      }
42  
43      public LprTransactionItemRequestOptionInfo(LprTransactionItemRequestOption reqOp) {
44          if (null == reqOp) {
45              return;
46          }
47          this.optionValue = reqOp.getOptionValue();
48          this.optionKey = reqOp.getOptionKey();
49      }
50  
51      public void setOptionValue(String optionValue) {
52          this.optionValue = optionValue;
53      }
54  
55      @Override
56      public String getId() {
57          return id;
58      }
59  
60      @Override
61      public String getOptionKey() {
62          return optionKey;
63      }
64  
65      @Override
66      public String getOptionValue() {
67          return optionValue;
68      }
69  
70      public void setId(String id) {
71          this.id = id;
72      }
73  
74      public void setOptionKey(String optionKey) {
75          this.optionKey = optionKey;
76      }
77  
78  	@Override
79  	public String toString() {
80  		StringBuilder builder = new StringBuilder();
81  		builder.append("LprTransactionItemRequestOptionInfo [id=");
82  		builder.append(id);
83  		builder.append(", optionKey=");
84  		builder.append(optionKey);
85  		builder.append(", optionValue=");
86  		builder.append(optionValue);
87  		builder.append("]");
88  		return builder.toString();
89  	}
90      
91      
92  }