001/** 002 * Copyright 2005-2016 The Kuali Foundation 003 * 004 * Licensed under the Educational Community License, Version 2.0 (the "License"); 005 * you may not use this file except in compliance with the License. 006 * You may obtain a copy of the License at 007 * 008 * http://www.opensource.org/licenses/ecl2.php 009 * 010 * Unless required by applicable law or agreed to in writing, software 011 * distributed under the License is distributed on an "AS IS" BASIS, 012 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 013 * See the License for the specific language governing permissions and 014 * limitations under the License. 015 */ 016package org.kuali.rice.kns.datadictionary; 017 018/** 019 * @author Kuali Rice Team (rice.collab@kuali.org) 020 */ 021@Deprecated 022public class BusinessObjectEntry extends org.kuali.rice.krad.datadictionary.BusinessObjectEntry { 023 024 protected InquiryDefinition inquiryDefinition; 025 protected LookupDefinition lookupDefinition; 026 027 @Override 028 public void completeValidation() { 029 030 super.completeValidation(); 031 032 if (hasInquiryDefinition()) { 033 inquiryDefinition.completeValidation(getDataObjectClass(), null); 034 } 035 036 if (hasLookupDefinition()) { 037 lookupDefinition.completeValidation(getDataObjectClass(), null); 038 } 039 } 040 041 /** 042 * @return true if this instance has an inquiryDefinition 043 */ 044 public boolean hasInquiryDefinition() { 045 return (inquiryDefinition != null); 046 } 047 048 /** 049 * @return current inquiryDefinition for this BusinessObjectEntry, or null if there is none 050 */ 051 public InquiryDefinition getInquiryDefinition() { 052 return inquiryDefinition; 053 } 054 055 /** 056 * The inquiry element is used to specify the fields that will be displayed on the 057 * inquiry screen for this business object and the order in which they will appear. 058 * 059 * DD: See InquiryDefinition.java 060 * 061 * JSTL: The inquiry element is a Map which is accessed using 062 * a key of "inquiry". This map contains the following keys: 063 * title (String) 064 * inquiryFields (Map) 065 * 066 * See InquiryMapBuilder.java 067 */ 068 public void setInquiryDefinition(InquiryDefinition inquiryDefinition) { 069 this.inquiryDefinition = inquiryDefinition; 070 } 071 072 /** 073 * @return true if this instance has a lookupDefinition 074 */ 075 public boolean hasLookupDefinition() { 076 return (lookupDefinition != null); 077 } 078 079 /** 080 * @return current lookupDefinition for this BusinessObjectEntry, or null if there is none 081 */ 082 public LookupDefinition getLookupDefinition() { 083 return lookupDefinition; 084 } 085 086 /** 087 * The lookup element is used to specify the rules for "looking up" 088 * a business object. These specifications define the following: 089 * How to specify the search criteria used to locate a set of business objects 090 * How to display the search results 091 * 092 * DD: See LookupDefinition.java 093 * 094 * JSTL: The lookup element is a Map which is accessed using 095 * a key of "lookup". This map contains the following keys: 096 * lookupableID (String, optional) 097 * title (String) 098 * menubar (String, optional) 099 * defaultSort (Map, optional) 100 * lookupFields (Map) 101 * resultFields (Map) 102 * resultSetLimit (String, optional) 103 * 104 * See LookupMapBuilder.java 105 */ 106 public void setLookupDefinition(LookupDefinition lookupDefinition) { 107 this.lookupDefinition = lookupDefinition; 108 } 109}