View Javadoc

1   /*
2    * Copyright 2005-2008 The Kuali Foundation
3    * 
4    * 
5    * Licensed under the Educational Community License, Version 2.0 (the "License");
6    * you may not use this file except in compliance with the License.
7    * You may obtain a copy of the License at
8    * 
9    * http://www.opensource.org/licenses/ecl2.php
10   * 
11   * Unless required by applicable law or agreed to in writing, software
12   * distributed under the License is distributed on an "AS IS" BASIS,
13   * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14   * See the License for the specific language governing permissions and
15   * limitations under the License.
16   */
17  package org.kuali.rice.kew.docsearch.web;
18  
19  import java.io.Serializable;
20  
21  /**
22   *
23   * @author Kuali Rice Team (rice.collab@kuali.org)
24   */
25  public class SearchAttributeFormContainer implements Serializable {
26      private static final long serialVersionUID = 8034659910798901330L;
27      
28      private String key;
29      private String value;
30      private String[] values;
31      private String alternateValue;
32      private boolean valueSet = false;
33  
34      public SearchAttributeFormContainer() {
35      }
36  
37      public SearchAttributeFormContainer(String key, String value) {
38          this.key = key;
39          this.value = value;
40          valueSet = true;
41      }
42  
43      public SearchAttributeFormContainer(String key, String[] values) {
44          this.key = key;
45          this.values = values;
46      }
47  
48      public SearchAttributeFormContainer(String key, String value, String alternateValue) {
49          this.key = key;
50          this.value = value;
51          valueSet = true;
52          this.alternateValue = alternateValue;
53      }
54  
55      
56      public String getAlternateValue() {
57          return alternateValue;
58      }
59  
60      public void setAlternateValue(String alternateValue) {
61          this.alternateValue = alternateValue;
62      }
63  
64      public String getKey() {
65          return key;
66      }
67  
68      public void setKey(String key) {
69          this.key = key;
70      }
71  
72      public String getValue() {
73          return value;
74      }
75      
76      public void setValue(String value) {
77          valueSet = true;
78          this.value = value;
79      }
80  
81      /**
82       * This should only be called for UI editable implementations
83       * @deprecated
84       */
85      public String getValueForUserInterface() {
86          valueSet = false;
87          return value;
88      }
89  
90      /**
91       * This should only be called for UI editable implementations
92       * @deprecated
93       */
94      public void setValueForUserInterface(String value) {
95          valueSet = true;
96          this.value = value;
97      }
98  
99      public String[] getValues() {
100         return values;
101     }
102 
103     public void setValues(String[] values) {
104         this.values = values;
105     }
106 
107     public boolean isValueSet() {
108         return valueSet;
109     }
110 
111 }