英文:
Problems with findBeans Spring
问题
以下是翻译好的内容:
- 我正在尝试从使用Spring开发的Java应用程序中检查Active Directory中的密码更改,以便与身份管理应用程序(OPENIAM)集成。我必须使用一个名为AuditDataService的服务,通过调用findBeans并填充"AuditLogSearchBean"过滤器,至少使用以下参数:
- setUserId(String userId):用户的ID
- setTargetUsers(Set<String> targetUsers):执行操作的目标用户
- setActions(Set<String> actions):包含操作的集合
- setTargetManagedSystems(Set<String> targetManagedSystems):受管理系统标识符集合,仅限于AD
- setFrom:日期,将是更改的日期(今天)
我的问题是AuditLogSearchBean类没有setTargetUsers、setActions和setTargetManagedSystems方法,它只包含setUserId和setFrom方法,在API中我看到了这个:
public class AuditLogSearchBean
extends AbstractSearchBean<IdmAuditLogDoc,String>;
IdmAuditLogDoc具有我需要的方法,但我无法访问它们。
在控制器中的服务调用:
AuditDataService auditDataService = (AuditDataService)context.getBean("auditDataService");
AuditLogSearchBean alsb = new AuditLogSearchBean();
alsb.setUserId(user.getId());
auditDataService.findBeans(alsb, 0, Integer.MAX_VALUE);
AuditLogSearchBean的Java类代码:
(图片参见原文链接)
IdmAuditLogDoc的Java类代码:
(图片参见原文链接)
英文:
- I'm trying to check a password change in Active Directory from a Java
application developed with Spring to an identity management
application (OPENIAM). I have to use a service called
AuditDataService by calling findBeans and filling the
"AuditLogSearchBean" filter with at least the following parameters:
- setUserId(String userId) : Id of the user
- setTargetUsers(Set<String> targetUsers): User on which the action is executed
- setActions(Set<String> actions) : A collection with the action
- setTargetManagedSystems(Set<String> targetManagedSystems) : Managed system identifier collection, in this case AD only
- setFrom : Date, which would be the day of the change (today)
My problem is that the AuditLogSearchBean class does not have a setTargetUsers, setActions and setTargetManagedSystems, it only contains setUserId and setFrom, in the API I see this:
public class AuditLogSearchBean
extends AbstractSearchBean<IdmAuditLogDoc,String>
IdmAuditLogDoc has the sets I need but I can't get to them.
service call in the Controller:
AuditDataService auditDataService = (AuditDataService)context.getBean("auditDataService");
AuditLogSearchBean alsb = new AuditLogSearchBean();
alsb.setUserId(user.getId());
auditDataService.findBeans(alsb, 0, Integer.MAX_VALUE);
AuditLogSearchBean java class code:
IdmAuditLogDoc java class code:
专注分享java语言的经验与见解,让所有开发者获益!
评论