Classes in this File | Line Coverage | Branch Coverage | Complexity | ||||
ParameterContract |
|
| 1.0;1 |
1 | /* | |
2 | * Copyright 2006-2011 The Kuali Foundation | |
3 | * | |
4 | * Licensed under the Educational Community License, Version 2.0 (the "License"); | |
5 | * you may not use this file except in compliance with the License. | |
6 | * You may obtain a copy of the License at | |
7 | * | |
8 | * http://www.opensource.org/licenses/ecl2.php | |
9 | * | |
10 | * Unless required by applicable law or agreed to in writing, software | |
11 | * distributed under the License is distributed on an "AS IS" BASIS, | |
12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | |
13 | * See the License for the specific language governing permissions and | |
14 | * limitations under the License. | |
15 | */ | |
16 | ||
17 | package org.kuali.rice.core.api.parameter; | |
18 | ||
19 | import org.kuali.rice.core.api.mo.common.GloballyUnique; | |
20 | import org.kuali.rice.core.api.mo.common.Versioned; | |
21 | ||
22 | /** | |
23 | * This is the contract for a Parameter. The concept of a parameter is a key=value pair that is associated | |
24 | * with a rice enabled application. | |
25 | * | |
26 | * <p> | |
27 | * When thinking of a parameter in terms of a key=value pair, the following defines the key and value parts: | |
28 | * | |
29 | * the key of a parameter consists of the following pieces: | |
30 | * | |
31 | * <ol> | |
32 | * <li>{@link #getApplicationId() applicationId}</li> | |
33 | * <li>{@link #getNamespaceCode() namespaceCode}</li> | |
34 | * <li>{@link #getComponentCode() componentCode}</li> | |
35 | * <li>{@link #getName() name}</li> | |
36 | * </ol> | |
37 | * | |
38 | * the value consists of the {@link #getValue() value} | |
39 | * </p> | |
40 | */ | |
41 | public interface ParameterContract extends Versioned, GloballyUnique { | |
42 | ||
43 | /** | |
44 | * This is the application id for the Parameter. This cannot be null or a blank string. | |
45 | * | |
46 | * <p> | |
47 | * It is a way of assigning the Parameter to a specific rice application or rice ecosystem. | |
48 | * </p> | |
49 | * | |
50 | * @return application id | |
51 | */ | |
52 | String getApplicationId(); | |
53 | ||
54 | /** | |
55 | * This is the namespace for the parameter. This cannot be null or a blank string. | |
56 | * | |
57 | * <p> | |
58 | * It is a way of assigning the parameter to a logical grouping within a rice application or rice ecosystem. | |
59 | * </p> | |
60 | * | |
61 | * @return namespace code | |
62 | */ | |
63 | String getNamespaceCode(); | |
64 | ||
65 | /** | |
66 | * This is the component code for the parameter. This cannot be null. | |
67 | * | |
68 | * <p> | |
69 | * It is a way of assigning a parameter to a functional component within a rice application or rice ecosystem. | |
70 | * </p> | |
71 | * | |
72 | * @return component | |
73 | */ | |
74 | String getComponentCode(); | |
75 | ||
76 | /** | |
77 | * The name of the parameter. This cannot be null or a blank string. | |
78 | * @return name | |
79 | */ | |
80 | String getName(); | |
81 | ||
82 | /** | |
83 | * The value of the parameter. This can be null or a blank string. | |
84 | * @return value | |
85 | */ | |
86 | String getValue(); | |
87 | ||
88 | /** | |
89 | * This is the description for what the parameter is used for. This can be null or a blank string. | |
90 | * @return description | |
91 | */ | |
92 | String getDescription(); | |
93 | ||
94 | /** | |
95 | * This is the evaluation operator for the parameter. This can be null. | |
96 | * | |
97 | * <p> | |
98 | * This allows parameters to be used as primitive business rules. | |
99 | * </p> | |
100 | * | |
101 | * @return evaluation operator | |
102 | */ | |
103 | EvaluationOperator getEvaluationOperator(); | |
104 | ||
105 | /** | |
106 | * This is the type for the parameter. This cannot be null. | |
107 | * | |
108 | * <p> | |
109 | * Some parameters have special types in rice which may have special meaning | |
110 | * and is related to the {@link #getEvaluationOperator()} | |
111 | * </p> | |
112 | * | |
113 | * @return type | |
114 | */ | |
115 | ParameterTypeContract getParameterType(); | |
116 | ||
117 | } |