1 | |
|
2 | |
|
3 | |
|
4 | |
|
5 | |
|
6 | |
|
7 | |
|
8 | |
|
9 | |
|
10 | |
|
11 | |
|
12 | |
|
13 | |
|
14 | |
|
15 | |
|
16 | |
package org.kuali.rice.kim.service.impl; |
17 | |
|
18 | |
import org.apache.commons.lang.exception.ExceptionUtils; |
19 | |
import org.apache.log4j.Logger; |
20 | |
import org.kuali.rice.core.api.criteria.QueryByCriteria; |
21 | |
import org.kuali.rice.kim.api.group.Group; |
22 | |
import org.kuali.rice.kim.api.group.GroupService; |
23 | |
import org.kuali.rice.kim.api.group.GroupUpdateService; |
24 | |
import org.kuali.rice.kim.api.identity.Type; |
25 | |
import org.kuali.rice.kim.api.identity.affiliation.EntityAffiliationType; |
26 | |
import org.kuali.rice.kim.api.identity.entity.Entity; |
27 | |
import org.kuali.rice.kim.api.identity.entity.EntityDefault; |
28 | |
import org.kuali.rice.kim.api.identity.entity.EntityDefaultQueryResults; |
29 | |
import org.kuali.rice.kim.api.identity.entity.EntityQueryResults; |
30 | |
import org.kuali.rice.kim.api.identity.external.EntityExternalIdentifierType; |
31 | |
import org.kuali.rice.kim.api.identity.principal.Principal; |
32 | |
import org.kuali.rice.kim.api.permission.Permission; |
33 | |
import org.kuali.rice.kim.api.responsibility.Responsibility; |
34 | |
import org.kuali.rice.kim.api.responsibility.ResponsibilityAction; |
35 | |
import org.kuali.rice.kim.api.responsibility.ResponsibilityService; |
36 | |
import org.kuali.rice.kim.api.services.IdentityManagementService; |
37 | |
import org.kuali.rice.kim.api.services.IdentityService; |
38 | |
import org.kuali.rice.kim.api.services.KimApiServiceLocator; |
39 | |
import org.kuali.rice.kim.bo.role.dto.PermissionAssigneeInfo; |
40 | |
import org.kuali.rice.kim.service.PermissionService; |
41 | |
|
42 | |
import java.util.HashMap; |
43 | |
import java.util.List; |
44 | |
import java.util.Map; |
45 | |
|
46 | 0 | public class IdentityManagementServiceImpl implements IdentityManagementService { |
47 | 0 | private static final Logger LOG = Logger.getLogger( IdentityManagementServiceImpl.class ); |
48 | |
|
49 | |
private PermissionService permissionService; |
50 | |
private ResponsibilityService responsibilityService; |
51 | |
private IdentityService identityService; |
52 | |
private GroupService groupService; |
53 | |
private GroupUpdateService groupUpdateService; |
54 | |
|
55 | |
@Override |
56 | |
public void flushAllCaches() { |
57 | 0 | } |
58 | |
|
59 | |
@Override |
60 | |
public void flushEntityPrincipalCaches() { |
61 | 0 | } |
62 | |
|
63 | |
@Override |
64 | |
public void flushGroupCaches() { |
65 | 0 | } |
66 | |
|
67 | |
@Override |
68 | |
public void flushPermissionCaches() { |
69 | 0 | } |
70 | |
|
71 | |
@Override |
72 | |
public void flushResponsibilityCaches() { |
73 | |
|
74 | 0 | } |
75 | |
|
76 | |
|
77 | |
|
78 | |
@Override |
79 | |
public boolean hasPermission(String principalId, String namespaceCode, String permissionName, Map<String, String> permissionDetails) { |
80 | 0 | if ( LOG.isDebugEnabled() ) { |
81 | 0 | logHasPermissionCheck("Permission", principalId, namespaceCode, permissionName, permissionDetails); |
82 | |
} |
83 | 0 | boolean hasPerm = getPermissionService().hasPermission(principalId, namespaceCode, permissionName, permissionDetails); |
84 | 0 | if ( LOG.isDebugEnabled() ) { |
85 | 0 | LOG.debug( "Result: " + hasPerm ); |
86 | |
} |
87 | 0 | return hasPerm; |
88 | |
} |
89 | |
|
90 | |
@Override |
91 | |
public boolean isAuthorized(String principalId, String namespaceCode, String permissionName, Map<String, String> permissionDetails, Map<String, String> qualification ) { |
92 | 0 | if ( qualification == null || qualification.isEmpty() ) { |
93 | 0 | return hasPermission( principalId, namespaceCode, permissionName, permissionDetails ); |
94 | |
} |
95 | 0 | if ( LOG.isDebugEnabled() ) { |
96 | 0 | logAuthorizationCheck("Permission", principalId, namespaceCode, permissionName, permissionDetails, qualification); |
97 | |
} |
98 | 0 | boolean isAuthorized = getPermissionService().isAuthorized(principalId, namespaceCode, permissionName, permissionDetails, qualification); |
99 | 0 | if ( LOG.isDebugEnabled() ) { |
100 | 0 | LOG.debug( "Result: " + isAuthorized ); |
101 | |
} |
102 | 0 | return isAuthorized; |
103 | |
} |
104 | |
|
105 | |
@Override |
106 | |
public boolean hasPermissionByTemplateName(String principalId, String namespaceCode, String permissionTemplateName, Map<String, String> permissionDetails) { |
107 | 0 | if ( LOG.isDebugEnabled() ) { |
108 | 0 | logHasPermissionCheck("Perm Templ", principalId, namespaceCode, permissionTemplateName, permissionDetails); |
109 | |
} |
110 | |
|
111 | 0 | boolean hasPerm = getPermissionService().hasPermissionByTemplateName(principalId, namespaceCode, permissionTemplateName, permissionDetails); |
112 | |
|
113 | 0 | if ( LOG.isDebugEnabled() ) { |
114 | 0 | LOG.debug( "Result: " + hasPerm ); |
115 | |
} |
116 | 0 | return hasPerm; |
117 | |
} |
118 | |
|
119 | |
@Override |
120 | |
public boolean isAuthorizedByTemplateName(String principalId, String namespaceCode, String permissionTemplateName, Map<String, String> permissionDetails, Map<String, String> qualification ) { |
121 | 0 | if ( qualification == null || qualification.isEmpty() ) { |
122 | 0 | return hasPermissionByTemplateName( principalId, namespaceCode, permissionTemplateName, new HashMap<String, String>(permissionDetails) ); |
123 | |
} |
124 | 0 | if ( LOG.isDebugEnabled() ) { |
125 | 0 | logAuthorizationCheck("Perm Templ", principalId, namespaceCode, permissionTemplateName, new HashMap<String, String>(permissionDetails), new HashMap<String, String>(qualification)); |
126 | |
} |
127 | 0 | boolean isAuthorized = getPermissionService().isAuthorizedByTemplateName( principalId, namespaceCode, permissionTemplateName, new HashMap<String, String>(permissionDetails), new HashMap<String, String>(qualification) ); |
128 | 0 | if ( LOG.isDebugEnabled() ) { |
129 | 0 | LOG.debug( "Result: " + isAuthorized ); |
130 | |
} |
131 | 0 | return isAuthorized; |
132 | |
} |
133 | |
|
134 | |
@Override |
135 | |
public List<Permission> getAuthorizedPermissions(String principalId, |
136 | |
String namespaceCode, String permissionName, Map<String, String> permissionDetails, Map<String, String> qualification) { |
137 | 0 | return getPermissionService().getAuthorizedPermissions(principalId, namespaceCode, permissionName, permissionDetails, qualification); |
138 | |
} |
139 | |
|
140 | |
@Override |
141 | |
public List<Permission> getAuthorizedPermissionsByTemplateName(String principalId, |
142 | |
String namespaceCode, String permissionTemplateName, Map<String, String> permissionDetails, Map<String, String> qualification) { |
143 | 0 | return getPermissionService().getAuthorizedPermissionsByTemplateName(principalId, namespaceCode, permissionTemplateName, permissionDetails, qualification); |
144 | |
} |
145 | |
|
146 | |
@Override |
147 | |
public boolean isPermissionDefinedForTemplateName(String namespaceCode, String permissionTemplateName, Map<String, String> permissionDetails) { |
148 | 0 | return getPermissionService().isPermissionDefinedForTemplateName(namespaceCode, permissionTemplateName, permissionDetails); |
149 | |
} |
150 | |
|
151 | |
@Override |
152 | |
public List<PermissionAssigneeInfo> getPermissionAssignees(String namespaceCode, |
153 | |
String permissionName, Map<String, String> permissionDetails, Map<String, String> qualification) { |
154 | 0 | return this.permissionService.getPermissionAssignees(namespaceCode, permissionName, |
155 | |
permissionDetails, qualification); |
156 | |
} |
157 | |
|
158 | |
@Override |
159 | |
public List<PermissionAssigneeInfo> getPermissionAssigneesForTemplateName(String namespaceCode, |
160 | |
String permissionTemplateName, Map<String, String> permissionDetails, |
161 | |
Map<String, String> qualification) { |
162 | 0 | return this.permissionService.getPermissionAssigneesForTemplateName( namespaceCode, |
163 | |
permissionTemplateName, new HashMap<String, String>(permissionDetails), new HashMap<String, String>(qualification) ); |
164 | |
} |
165 | |
|
166 | |
|
167 | |
@Override |
168 | |
public boolean isMemberOfGroup(String principalId, String groupId) { |
169 | 0 | return getGroupService().isMemberOfGroup(principalId, groupId); |
170 | |
} |
171 | |
@Override |
172 | |
public boolean isMemberOfGroup(String principalId, String namespaceCode, String groupName) { |
173 | 0 | Group group = getGroupByName(namespaceCode, groupName); |
174 | 0 | return group == null ? false : isMemberOfGroup(principalId, group.getId()); |
175 | |
} |
176 | |
@Override |
177 | |
public boolean isGroupMemberOfGroup(String potentialMemberId, String potentialParentId) |
178 | |
{ |
179 | 0 | return getGroupService() |
180 | |
.isGroupMemberOfGroup(potentialMemberId, potentialParentId); |
181 | |
} |
182 | |
@Override |
183 | |
public List<String> getGroupMemberPrincipalIds(String groupId) { |
184 | 0 | return getGroupService().getMemberPrincipalIds(groupId); |
185 | |
} |
186 | |
@Override |
187 | |
public List<String> getDirectGroupMemberPrincipalIds(String groupId) { |
188 | 0 | return getGroupService().getDirectMemberPrincipalIds(groupId); |
189 | |
} |
190 | |
@Override |
191 | |
public List<String> getGroupIdsForPrincipal(String principalId) { |
192 | 0 | return getGroupService().getGroupIdsForPrincipal(principalId); |
193 | |
} |
194 | |
@Override |
195 | |
public List<String> getGroupIdsForPrincipal(String principalId, String namespaceCode ) { |
196 | 0 | return getGroupService().getGroupIdsForPrincipalByNamespace(principalId, namespaceCode ); |
197 | |
} |
198 | |
@Override |
199 | |
public List<Group> getGroupsForPrincipal(String principalId) { |
200 | 0 | return getGroupService().getGroupsForPrincipal(principalId); |
201 | |
} |
202 | |
@Override |
203 | |
public List<Group> getGroupsForPrincipal(String principalId, String namespaceCode ) { |
204 | 0 | return getGroupService().getGroupsForPrincipalByNamespace(principalId, namespaceCode ); |
205 | |
} |
206 | |
@Override |
207 | |
public List<String> getMemberGroupIds(String groupId) { |
208 | 0 | return getGroupService().getMemberGroupIds(groupId); |
209 | |
} |
210 | |
@Override |
211 | |
public List<String> getDirectMemberGroupIds(String groupId) { |
212 | 0 | return getGroupService().getDirectMemberGroupIds(groupId); |
213 | |
} |
214 | |
@Override |
215 | |
public Group getGroup(String groupId) { |
216 | 0 | return getGroupService().getGroup(groupId); |
217 | |
} |
218 | |
@Override |
219 | |
public Group getGroupByName(String namespaceCode, String groupName) { |
220 | 0 | return getGroupService().getGroupByName( namespaceCode, groupName ); |
221 | |
} |
222 | |
@Override |
223 | |
public List<String> getParentGroupIds(String groupId) { |
224 | 0 | return getGroupService().getParentGroupIds(groupId); |
225 | |
} |
226 | |
@Override |
227 | |
public List<String> getDirectParentGroupIds(String groupId) { |
228 | 0 | return getGroupService().getDirectParentGroupIds( groupId ); |
229 | |
} |
230 | |
|
231 | |
@Override |
232 | |
public boolean addGroupToGroup(String childId, String parentId) { |
233 | 0 | return getGroupUpdateService().addGroupToGroup(childId, parentId); |
234 | |
} |
235 | |
|
236 | |
@Override |
237 | |
public boolean addPrincipalToGroup(String principalId, String groupId) { |
238 | 0 | return getGroupUpdateService().addPrincipalToGroup(principalId, groupId); |
239 | |
} |
240 | |
|
241 | |
@Override |
242 | |
public boolean removeGroupFromGroup(String childId, String parentId) { |
243 | 0 | return getGroupUpdateService().removeGroupFromGroup(childId, parentId); |
244 | |
} |
245 | |
|
246 | |
@Override |
247 | |
public boolean removePrincipalFromGroup(String principalId, String groupId) { |
248 | 0 | return getGroupUpdateService().removePrincipalFromGroup(principalId, groupId); |
249 | |
} |
250 | |
|
251 | |
@Override |
252 | |
public Group createGroup(Group group) { |
253 | 0 | return getGroupUpdateService().createGroup(group); |
254 | |
} |
255 | |
|
256 | |
@Override |
257 | |
public void removeAllMembers(String groupId) { |
258 | 0 | getGroupUpdateService().removeAllMembers(groupId); |
259 | 0 | } |
260 | |
|
261 | |
@Override |
262 | |
public Group updateGroup(String groupId, Group group) { |
263 | 0 | return getGroupUpdateService().updateGroup(groupId, group); |
264 | |
} |
265 | |
|
266 | |
|
267 | |
|
268 | |
@Override |
269 | |
public Principal getPrincipal(String principalId) { |
270 | 0 | return getIdentityService().getPrincipal(principalId); |
271 | |
} |
272 | |
|
273 | |
@Override |
274 | |
public Principal getPrincipalByPrincipalName(String principalName) { |
275 | 0 | return getIdentityService().getPrincipalByPrincipalName(principalName); |
276 | |
} |
277 | |
|
278 | |
@Override |
279 | |
public Principal getPrincipalByPrincipalNameAndPassword(String principalName, String password) { |
280 | 0 | return getIdentityService().getPrincipalByPrincipalNameAndPassword(principalName, password); |
281 | |
} |
282 | |
|
283 | |
@Override |
284 | |
public EntityDefault getEntityDefaultInfo(String entityId) { |
285 | 0 | return getIdentityService().getEntityDefault(entityId); |
286 | |
} |
287 | |
|
288 | |
@Override |
289 | |
public EntityDefault getEntityDefaultInfoByPrincipalId( |
290 | |
String principalId) { |
291 | 0 | return getIdentityService().getEntityDefaultByPrincipalId(principalId); |
292 | |
} |
293 | |
|
294 | |
@Override |
295 | |
public EntityDefault getEntityDefaultInfoByPrincipalName( |
296 | |
String principalName) { |
297 | 0 | return getIdentityService().getEntityDefaultByPrincipalName(principalName); |
298 | |
} |
299 | |
|
300 | |
@Override |
301 | |
public EntityDefaultQueryResults findEntityDefaults(QueryByCriteria queryByCriteria) { |
302 | 0 | return getIdentityService().findEntityDefaults(queryByCriteria); |
303 | |
} |
304 | |
|
305 | |
@Override |
306 | |
public Entity getEntity(String entityId) { |
307 | 0 | return getIdentityService().getEntity(entityId); |
308 | |
} |
309 | |
|
310 | |
@Override |
311 | |
public Entity getEntityByPrincipalId(String principalId) { |
312 | 0 | return getIdentityService().getEntityByPrincipalId(principalId); |
313 | |
} |
314 | |
|
315 | |
@Override |
316 | |
public Entity getEntityByPrincipalName(String principalName) { |
317 | 0 | return getIdentityService().getEntityByPrincipalName(principalName); |
318 | |
} |
319 | |
|
320 | |
@Override |
321 | |
public EntityQueryResults findEntities(QueryByCriteria queryByCriteria) { |
322 | 0 | return getIdentityService().findEntities(queryByCriteria); |
323 | |
} |
324 | |
|
325 | |
@Override |
326 | |
public Type getAddressType( String code ) { |
327 | 0 | return getIdentityService().getAddressType(code); |
328 | |
} |
329 | |
|
330 | |
@Override |
331 | |
public Type getEmailType( String code ) { |
332 | 0 | return getIdentityService().getEmailType(code); |
333 | |
} |
334 | |
|
335 | |
@Override |
336 | |
public EntityAffiliationType getAffiliationType( String code ) { |
337 | 0 | return getIdentityService().getAffiliationType(code); |
338 | |
} |
339 | |
|
340 | |
@Override |
341 | |
public Type getCitizenshipStatus( String code ) { |
342 | 0 | return Type.Builder.create(getIdentityService().getCitizenshipStatus(code)).build(); |
343 | |
} |
344 | |
@Override |
345 | |
public Type getEmploymentStatus( String code ) { |
346 | 0 | return getIdentityService().getEmploymentStatus(code); |
347 | |
} |
348 | |
@Override |
349 | |
public Type getEmploymentType( String code ) { |
350 | 0 | return getIdentityService().getEmploymentType(code); |
351 | |
} |
352 | |
@Override |
353 | |
public Type getEntityNameType( String code ) { |
354 | 0 | return getIdentityService().getNameType(code); |
355 | |
} |
356 | |
@Override |
357 | |
public Type getEntityType( String code ) { |
358 | 0 | return getIdentityService().getEntityType(code); |
359 | |
} |
360 | |
@Override |
361 | |
public EntityExternalIdentifierType getExternalIdentifierType( String code ) { |
362 | 0 | return getIdentityService().getExternalIdentifierType(code); |
363 | |
} |
364 | |
@Override |
365 | |
public Type getPhoneType( String code ) { |
366 | 0 | return getIdentityService().getPhoneType(code); |
367 | |
} |
368 | |
|
369 | |
|
370 | |
|
371 | |
|
372 | |
|
373 | |
@Override |
374 | |
public Responsibility getResponsibility(String responsibilityId) { |
375 | 0 | return getResponsibilityService().getResponsibility( responsibilityId ); |
376 | |
} |
377 | |
|
378 | |
@Override |
379 | |
public boolean hasResponsibility(String principalId, String namespaceCode, |
380 | |
String responsibilityName, Map<String, String> qualification, |
381 | |
Map<String, String> responsibilityDetails) { |
382 | 0 | return getResponsibilityService().hasResponsibility( principalId, namespaceCode, responsibilityName, |
383 | |
qualification, responsibilityDetails ); |
384 | |
} |
385 | |
|
386 | |
@Override |
387 | |
public Responsibility getResponsibilityByName( String namespaceCode, String responsibilityName) { |
388 | 0 | return getResponsibilityService().findRespByNamespaceCodeAndName(namespaceCode, responsibilityName); |
389 | |
} |
390 | |
|
391 | |
@Override |
392 | |
public List<ResponsibilityAction> getResponsibilityActions( String namespaceCode, String responsibilityName, |
393 | |
Map<String, String> qualification, Map<String, String> responsibilityDetails) { |
394 | 0 | return getResponsibilityService().getResponsibilityActions( namespaceCode, responsibilityName, qualification, |
395 | |
responsibilityDetails ); |
396 | |
} |
397 | |
|
398 | |
@Override |
399 | |
public List<ResponsibilityAction> getResponsibilityActionsByTemplateName( |
400 | |
String namespaceCode, String responsibilityTemplateName, |
401 | |
Map<String, String> qualification, Map<String, String> responsibilityDetails) { |
402 | 0 | return getResponsibilityService().getResponsibilityActionsByTemplateName(namespaceCode, responsibilityTemplateName, |
403 | |
qualification, responsibilityDetails); |
404 | |
} |
405 | |
|
406 | |
@Override |
407 | |
public boolean hasResponsibilityByTemplateName(String principalId, |
408 | |
String namespaceCode, String responsibilityTemplateName, |
409 | |
Map<String, String> qualification, Map<String, String> responsibilityDetails) { |
410 | 0 | return getResponsibilityService().hasResponsibilityByTemplateName(principalId, namespaceCode, responsibilityTemplateName, |
411 | |
qualification, responsibilityDetails); |
412 | |
} |
413 | |
|
414 | |
protected void logAuthorizationCheck(String checkType, String principalId, String namespaceCode, String permissionName, Map<String, String> permissionDetails, Map<String, String> qualification ) { |
415 | 0 | StringBuilder sb = new StringBuilder(); |
416 | 0 | sb.append( '\n' ); |
417 | 0 | sb.append( "Is AuthZ for " ).append( checkType ).append( ": " ).append( namespaceCode ).append( "/" ).append( permissionName ).append( '\n' ); |
418 | 0 | sb.append( " Principal: " ).append( principalId ); |
419 | 0 | if ( principalId != null ) { |
420 | 0 | Principal principal = getPrincipal( principalId ); |
421 | 0 | if ( principal != null ) { |
422 | 0 | sb.append( " (" ).append( principal.getPrincipalName() ).append( ')' ); |
423 | |
} |
424 | |
} |
425 | 0 | sb.append( '\n' ); |
426 | 0 | sb.append( " Details:\n" ); |
427 | 0 | if ( permissionDetails != null ) { |
428 | 0 | sb.append( permissionDetails); |
429 | |
} else { |
430 | 0 | sb.append( " [null]\n" ); |
431 | |
} |
432 | 0 | sb.append( " Qualifiers:\n" ); |
433 | 0 | if ( qualification != null && !qualification.isEmpty() ) { |
434 | 0 | sb.append( qualification); |
435 | |
} else { |
436 | 0 | sb.append( " [null]\n" ); |
437 | |
} |
438 | 0 | if (LOG.isTraceEnabled()) { |
439 | 0 | LOG.trace( sb.append(ExceptionUtils.getStackTrace(new Throwable()))); |
440 | |
} else { |
441 | 0 | LOG.debug(sb.toString()); |
442 | |
} |
443 | 0 | } |
444 | |
|
445 | |
protected void logHasPermissionCheck(String checkType, String principalId, String namespaceCode, String permissionName, Map<String, String> permissionDetails ) { |
446 | 0 | StringBuilder sb = new StringBuilder(); |
447 | 0 | sb.append( '\n' ); |
448 | 0 | sb.append( "Has Perm for " ).append( checkType ).append( ": " ).append( namespaceCode ).append( "/" ).append( permissionName ).append( '\n' ); |
449 | 0 | sb.append( " Principal: " ).append( principalId ); |
450 | 0 | if ( principalId != null ) { |
451 | 0 | Principal principal = getPrincipal( principalId ); |
452 | 0 | if ( principal != null ) { |
453 | 0 | sb.append( " (" ).append( principal.getPrincipalName() ).append( ')' ); |
454 | |
} |
455 | |
} |
456 | 0 | sb.append( '\n' ); |
457 | 0 | sb.append( " Details:\n" ); |
458 | 0 | if ( permissionDetails != null ) { |
459 | 0 | sb.append( permissionDetails); |
460 | |
} else { |
461 | 0 | sb.append( " [null]\n" ); |
462 | |
} |
463 | 0 | if (LOG.isTraceEnabled()) { |
464 | 0 | LOG.trace( sb.append( ExceptionUtils.getStackTrace(new Throwable())) ); |
465 | |
} else { |
466 | 0 | LOG.debug(sb.toString()); |
467 | |
} |
468 | 0 | } |
469 | |
|
470 | |
|
471 | |
|
472 | |
public IdentityService getIdentityService() { |
473 | 0 | if ( identityService == null ) { |
474 | 0 | identityService = KimApiServiceLocator.getIdentityService(); |
475 | |
} |
476 | 0 | return identityService; |
477 | |
} |
478 | |
|
479 | |
public GroupService getGroupService() { |
480 | 0 | if ( groupService == null ) { |
481 | 0 | groupService = KimApiServiceLocator.getGroupService(); |
482 | |
} |
483 | 0 | return groupService; |
484 | |
} |
485 | |
|
486 | |
public PermissionService getPermissionService() { |
487 | 0 | if ( permissionService == null ) { |
488 | 0 | permissionService = KimApiServiceLocator.getPermissionService(); |
489 | |
} |
490 | 0 | return permissionService; |
491 | |
} |
492 | |
|
493 | |
public ResponsibilityService getResponsibilityService() { |
494 | 0 | if ( responsibilityService == null ) { |
495 | 0 | responsibilityService = KimApiServiceLocator.getResponsibilityService(); |
496 | |
} |
497 | 0 | return responsibilityService; |
498 | |
} |
499 | |
|
500 | |
public GroupUpdateService getGroupUpdateService() { |
501 | |
try { |
502 | 0 | if ( groupUpdateService == null ) { |
503 | 0 | groupUpdateService = KimApiServiceLocator.getGroupUpdateService(); |
504 | 0 | if ( groupUpdateService == null ) { |
505 | 0 | throw new UnsupportedOperationException( "null returned for GroupUpdateService, unable to update group data"); |
506 | |
} |
507 | |
} |
508 | 0 | } catch ( Exception ex ) { |
509 | 0 | throw new UnsupportedOperationException( "unable to obtain a GroupUpdateService, unable to update group data", ex); |
510 | 0 | } |
511 | 0 | return groupUpdateService; |
512 | |
} |
513 | |
} |