1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16 package org.kuali.rice.kew.actionrequest;
17
18 import org.kuali.rice.kim.api.identity.principal.PrincipalContract;
19
20
21
22
23
24
25
26
27 public class KimPrincipalRecipient implements Recipient {
28
29 private static final long serialVersionUID = 1L;
30 private PrincipalContract principal;
31
32 public KimPrincipalRecipient(String principalId) {
33 this(ActionRequestFactory.getIdentityService().getPrincipal(principalId));
34 }
35
36 public KimPrincipalRecipient(PrincipalContract principal) {
37 if (principal == null) {
38 throw new IllegalArgumentException("Attempted to create a KimPrincipalRecipient with a null KimPrincipal!");
39 }
40 this.principal = principal;
41 }
42
43 public PrincipalContract getPrincipal() {
44 return this.principal;
45 }
46
47 public String getPrincipalId() {
48 return getPrincipal().getPrincipalId();
49 }
50
51
52 }