...
- Create IdentityManagementOverrideResourceLoader Class
- Resulting Skeleton Code
Code Block title IdentityManagementOverrideResourceLoader.java package edu.ucdavis.iet.mw.kuali.rice; import org.kuali.rice.resourceloader.BaseResourceLoader; public class IdentityManagementOverrideResourceLoader extends BaseResourceLoader { }
- Add Constructor and Attributes
Code Block title IdentityManagementOverrideResourceLoader.java package edu.ucdavis.iet.mw.kuali.rice; import javax.xml.namespace.QName; import org.apache.xbean.spring.context.ClassPathXmlApplicationContext; import org.kuali.rice.resourceloader.BaseResourceLoader; public class IdentityManagementOverrideResourceLoader extends BaseResourceLoader { public IdentityManagementOverrideResourceLoader(){ super(new QName("IdentityManagementOverrideResourceLoader")); } private static final String SPRING_FILE = "classpath:SpringBeans.xml"; private ClassPathXmlApplicationContext context; }
- Override start(), stop() and getService(QName) Methods
- Implement Methods
Code Block title IdentityManagementOverrideResourceLoader.java package edu.ucdavis.iet.mw.kuali.rice; import javax.xml.namespace.QName; import org.apache.xbean.spring.context.ClassPathXmlApplicationContext; import org.kuali.rice.resourceloader.BaseResourceLoader; import edu.iu.uis.eden.KEWServiceLocator; public class IdentityManagementOverrideResourceLoader extends BaseResourceLoader { public IdentityManagementOverrideResourceLoader(){ super(new QName("IdentityManagementOverrideResourceLoader")); } private static final String SPRING_FILE = "classpath:SpringBeans.xml"; private ClassPathXmlApplicationContext context; public Object getService(QName serviceName) { String springServiceName = serviceName.getLocalPart(); if (KEWServiceLocator.USER_SERVICE.equals(springServiceName)) { return context.getBean(springServiceName); } return super.getService(serviceName); } public void start() throws Exception { context = new ClassPathXmlApplicationContext(SPRING_FILE); super.start(); } public void stop() throws Exception { if (context != null) { context.stop(); context = null; } super.stop(); } }
Implement User Service
- Create LDAPIdentityManagementService Class:
Reference
https://test.kuali.org/confluence/display/KULRICE/Workflow+Plugin+Guide
https://test.kuali.org/confluence/display/KULRICE/JA-SIG+Spring+2008+-+Building+the+Plug-in