1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16 package org.kuali.rice.kim.inquiry;
17
18 import java.util.Map;
19
20 import org.kuali.rice.kim.bo.Person;
21 import org.kuali.rice.kim.service.KIMServiceLocator;
22 import org.kuali.rice.kim.service.PersonService;
23 import org.kuali.rice.kns.bo.BusinessObject;
24 import org.kuali.rice.kns.inquiry.KualiInquirableImpl;
25
26
27
28
29
30
31
32 public class PersonInquirableImpl extends KualiInquirableImpl {
33
34 PersonService<Person> personService;
35
36
37
38
39
40
41 @SuppressWarnings("unchecked")
42 @Override
43 public BusinessObject getBusinessObject(Map fieldValues) {
44 return getPersonService().getPerson( fieldValues.get( "principalId" ).toString() );
45 }
46
47 public PersonService<Person> getPersonService() {
48 if ( personService == null ) {
49 personService = KIMServiceLocator.getPersonService();
50 }
51 return personService;
52 }
53 }