Classes in this File | Line Coverage | Branch Coverage | Complexity | ||||
DataDictionaryEntry |
|
| 1.0;1 |
1 | /* | |
2 | * Copyright 2005-2007 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.kns.datadictionary; | |
18 | ||
19 | import java.util.List; | |
20 | ||
21 | ||
22 | /** | |
23 | * Defines methods common to all DataDictionaryDefinition types. | |
24 | * | |
25 | * DD: The highest level objects in the data dictionary are of | |
26 | the following types: | |
27 | * BusinessObjectEntry | |
28 | * MaintenanceDocumentEntry | |
29 | * TransactionalDocumentEntry | |
30 | ||
31 | JSTL: The data dictionary is exposed as a Map which is accessed | |
32 | by referring to the "DataDictionary" global constant. This Map contains | |
33 | the following kinds of entries keyed as indicated: | |
34 | * Business Object Entries - | |
35 | Key = businessObjectClass name | |
36 | Value = Map created by BusinessObjectEntryMapper | |
37 | * Maintenance Document entries - | |
38 | Key = DocumentType name | |
39 | Value = Map created by MaintenanceObjectEntryMapper | |
40 | * Transactional Document entries - | |
41 | Key = DocumentType name | |
42 | Value = Map created by TransactionalDocumentEntryMapper | |
43 | ||
44 | All elements are exposed to JSTL as Maps (where the element has a | |
45 | unique key by which they can be retrieved), or Strings. For collections | |
46 | of elements having no unique key, the entry's position in the list | |
47 | (0, 1, etc.) is used as its index. | |
48 | ||
49 | All Maps (except the top-level DataDictionary one) are guaranteed to | |
50 | present their entries with an iteration order identical to the order | |
51 | in which the elements were defined in XML. | |
52 | ||
53 | */ | |
54 | public interface DataDictionaryEntry { | |
55 | /** | |
56 | * @return String used as a globally-unique key for this entry's jstl-exported version | |
57 | */ | |
58 | public String getJstlKey(); | |
59 | ||
60 | /** | |
61 | * Kicks off complete entry-wide validation which couldn't be done earlier. | |
62 | * | |
63 | * @throws org.kuali.rice.kns.datadictionary.exception.CompletionException if a problem arises during validation-completion | |
64 | */ | |
65 | public void completeValidation(); | |
66 | ||
67 | /** | |
68 | * @param attributeName | |
69 | * @return AttributeDefinition with the given name, or null if none with that name exists | |
70 | */ | |
71 | public AttributeDefinition getAttributeDefinition(String attributeName); | |
72 | ||
73 | /** | |
74 | * Returns the full class name of the underlying object. | |
75 | */ | |
76 | public String getFullClassName(); | |
77 | ||
78 | /** | |
79 | * @return a Map containing all RelationshipDefinitions associated with this BusinessObjectEntry, indexed by relationshipName | |
80 | */ | |
81 | public List<RelationshipDefinition> getRelationships(); | |
82 | } |