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.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 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 super.completeValidation(); 35 36 if (hasInquiryDefinition()) { 37 inquiryDefinition.completeValidation(getDataObjectClass(), null); 38 } 39 40 if (hasLookupDefinition()) { 41 lookupDefinition.completeValidation(getDataObjectClass(), null); 42 } 43 } 44 45 /** 46 * @return true if this instance has an inquiryDefinition 47 */ 48 public boolean hasInquiryDefinition() { 49 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 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 this.inquiryDefinition = inquiryDefinition; 74 } 75 76 /** 77 * @return true if this instance has a lookupDefinition 78 */ 79 public boolean hasLookupDefinition() { 80 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 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 this.lookupDefinition = lookupDefinition; 112 } 113 }