1 /**
2 * Copyright 2005-2013 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 package org.kuali.rice.krms.api.repository.proposition;
17
18
19 import org.kuali.rice.core.api.mo.common.Identifiable;
20 import org.kuali.rice.core.api.mo.common.Versioned;
21 import org.kuali.rice.krms.api.repository.term.TermDefinition;
22
23 /**
24 * The contract for {@link PropositionParameter}
25 * @author Kuali Rice Team (rice.collab@kuali.org)
26 */
27 public interface PropositionParameterContract extends Identifiable, Versioned {
28 /**
29 * Returns the Id for the parent proposition.
30 *
31 * <p>
32 * It is the Id of the parent proposition.
33 * </p>
34 * @return Id for parent parameter.
35 */
36 public String getPropId();
37
38
39 /**
40 * Returns the value of the proposition parameter
41 *
42 * <p>
43 * It is the value of the parameter
44 * </p>
45 * @return value of the parameter
46 */
47 public String getValue();
48
49
50 /**
51 * Returns the term value of the proposition parameter if the
52 * proposition parameter is a term.
53 *
54 * <p>
55 * It is the term value of the parameter
56 * </p>
57 * @return value of the term parameter
58 */
59 public TermDefinition getTermValue();
60
61 /**
62 * Returns the type of the parameter.
63 * Proposition parameters are one of the following types:
64 * Constant Values: numbers, strings, dates, etc.
65 * Terms: data available in the execution environment or provided by a term resolver
66 * Functions: custom functions that resolve to a value,
67 * or standard operators (equals, greater than, less than, ...)
68 *
69 * <p>
70 * It identified the type of the parameter.
71 * </p>
72 * @return the parameter type code. Valid values are C, T, and F.
73 */
74 public String getParameterType();
75
76 /**
77 * Returns the sequence number of the proposition parameter.
78 * Proposition parameters are listed in Reverse Polish Notation.
79 * The sequence number (starting with 1) identifies the position of the
80 * parameter in the list.
81 *
82 * @return the sequence number of the proposition parameter
83 */
84 public Integer getSequenceNumber();
85 }