View Javadoc

1   /**
2    * Copyright 2005-2012 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.term;
17  
18  import org.kuali.rice.core.api.mo.common.Identifiable;
19  import org.kuali.rice.core.api.mo.common.Versioned;
20  import org.kuali.rice.core.api.mo.common.active.Inactivatable;
21  import org.kuali.rice.krms.api.repository.category.CategoryDefinitionContract;
22  
23  import java.util.List;
24  
25  /**
26   * <p>The contract for a {@link TermSpecificationDefinition} which defines important information about a term (see
27   * {@link org.kuali.rice.krms.api.repository.term.TermDefinitionContract}).  A term specification should be uniquely
28   * identifiable by its name and namespace. This key is important for determining how the fact value for a term can be
29   * resolved.
30   * </p>
31   *
32   * @author Kuali Rice Team (rice.collab@kuali.org)
33   *
34   */
35  public interface TermSpecificationDefinitionContract extends Identifiable, Inactivatable, Versioned {
36  
37      /**
38       * Gets the name for this {@link TermSpecificationDefinitionContract}.  This is an important key
39       * that must be unique within a namespace, and is used to determine how to resolve any terms
40       * having this specification. Will not be null or empty.
41       *
42       * @return the name
43       */
44  	String getName();
45  
46      /**
47  	 * Gets the namespace of this {@link TermSpecificationDefinitionContract}.  Will not be null or empty.
48  	 *
49  	 * @return the namespace of the TermSpecificationDefinitionContract
50  	 */
51  	public String getNamespace();
52  
53      /**
54       * Gets the fully qualified class name for the values of any term having this specification.  E.g. if the
55       * type of the fact values for the "total dollar amount of a grant" term was {@link java.math.BigDecimal},
56       * then the term specification's type would be the String "java.math.BigDecimal".  Will never return null or
57       * the empty string.
58       *
59       * @return the fully qualified name of the java type of values for this term.
60       */
61  	String getType();
62  
63      /**
64       * Gets the description for this term specification, which will typically be a suitable description for
65       * any term having this specification as well.  May return null if no description is specified for the term
66       * specification.
67       *
68       * @return the description for this term specification.
69       */
70      String getDescription();
71  
72      /**
73       * Gets an ordered list of the categories which this term specification
74       * definition belongs to.  This list can be empty but will never be null.
75       *
76       * @return the list of categories for this term specification definition.
77       */
78      List<? extends CategoryDefinitionContract> getCategories();
79  
80  }