| Classes in this File | Line Coverage | Branch Coverage | Complexity | ||||
| BusinessObjectEntry |
|
| 1.2857142857142858;1.286 |
| 1 | /** | |
| 2 | * Copyright 2005-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 | package org.kuali.rice.kns.datadictionary; | |
| 17 | ||
| 18 | import org.kuali.rice.krad.datadictionary.DataDictionaryException; | |
| 19 | import org.kuali.rice.krad.datadictionary.InactivationBlockingDefinition; | |
| 20 | import org.kuali.rice.krad.datadictionary.exception.ClassValidationException; | |
| 21 | ||
| 22 | /** | |
| 23 | * @author Kuali Rice Team (rice.collab@kuali.org) | |
| 24 | */ | |
| 25 | @Deprecated | |
| 26 | 0 | public class BusinessObjectEntry extends org.kuali.rice.krad.datadictionary.BusinessObjectEntry { |
| 27 | ||
| 28 | protected InquiryDefinition inquiryDefinition; | |
| 29 | protected LookupDefinition lookupDefinition; | |
| 30 | ||
| 31 | @Override | |
| 32 | public void completeValidation() { | |
| 33 | ||
| 34 | 0 | super.completeValidation(); |
| 35 | ||
| 36 | 0 | if (hasInquiryDefinition()) { |
| 37 | 0 | inquiryDefinition.completeValidation(getDataObjectClass(), null); |
| 38 | } | |
| 39 | ||
| 40 | 0 | if (hasLookupDefinition()) { |
| 41 | 0 | lookupDefinition.completeValidation(getDataObjectClass(), null); |
| 42 | } | |
| 43 | 0 | } |
| 44 | ||
| 45 | /** | |
| 46 | * @return true if this instance has an inquiryDefinition | |
| 47 | */ | |
| 48 | public boolean hasInquiryDefinition() { | |
| 49 | 0 | return (inquiryDefinition != null); |
| 50 | } | |
| 51 | ||
| 52 | /** | |
| 53 | * @return current inquiryDefinition for this BusinessObjectEntry, or null if there is none | |
| 54 | */ | |
| 55 | public InquiryDefinition getInquiryDefinition() { | |
| 56 | 0 | return inquiryDefinition; |
| 57 | } | |
| 58 | ||
| 59 | /** | |
| 60 | * The inquiry element is used to specify the fields that will be displayed on the | |
| 61 | * inquiry screen for this business object and the order in which they will appear. | |
| 62 | * | |
| 63 | * DD: See InquiryDefinition.java | |
| 64 | * | |
| 65 | * JSTL: The inquiry element is a Map which is accessed using | |
| 66 | * a key of "inquiry". This map contains the following keys: | |
| 67 | * title (String) | |
| 68 | * inquiryFields (Map) | |
| 69 | * | |
| 70 | * See InquiryMapBuilder.java | |
| 71 | */ | |
| 72 | public void setInquiryDefinition(InquiryDefinition inquiryDefinition) { | |
| 73 | 0 | this.inquiryDefinition = inquiryDefinition; |
| 74 | 0 | } |
| 75 | ||
| 76 | /** | |
| 77 | * @return true if this instance has a lookupDefinition | |
| 78 | */ | |
| 79 | public boolean hasLookupDefinition() { | |
| 80 | 0 | return (lookupDefinition != null); |
| 81 | } | |
| 82 | ||
| 83 | /** | |
| 84 | * @return current lookupDefinition for this BusinessObjectEntry, or null if there is none | |
| 85 | */ | |
| 86 | public LookupDefinition getLookupDefinition() { | |
| 87 | 0 | return lookupDefinition; |
| 88 | } | |
| 89 | ||
| 90 | /** | |
| 91 | * The lookup element is used to specify the rules for "looking up" | |
| 92 | * a business object. These specifications define the following: | |
| 93 | * How to specify the search criteria used to locate a set of business objects | |
| 94 | * How to display the search results | |
| 95 | * | |
| 96 | * DD: See LookupDefinition.java | |
| 97 | * | |
| 98 | * JSTL: The lookup element is a Map which is accessed using | |
| 99 | * a key of "lookup". This map contains the following keys: | |
| 100 | * lookupableID (String, optional) | |
| 101 | * title (String) | |
| 102 | * menubar (String, optional) | |
| 103 | * defaultSort (Map, optional) | |
| 104 | * lookupFields (Map) | |
| 105 | * resultFields (Map) | |
| 106 | * resultSetLimit (String, optional) | |
| 107 | * | |
| 108 | * See LookupMapBuilder.java | |
| 109 | */ | |
| 110 | public void setLookupDefinition(LookupDefinition lookupDefinition) { | |
| 111 | 0 | this.lookupDefinition = lookupDefinition; |
| 112 | 0 | } |
| 113 | } |