public class NamedProcessEngineServicesProducer {
@Produces @ProcessEngineName("")
public ProcessEngine processEngine(InjectionPoint ip) {
ProcessEngineName annotation = ip.getAnnotated().getAnnotation(ProcessEngineName.class);
String processEngineName = annotation.value();
if(processEngineName == null || processEngineName.length() == 0) {
throw new ProcessEngineException("Cannot determine which process engine to inject: @ProcessEngineName must specify the name of a process engine.");
}
try {
ProcessEngineService processEngineService = BpmPlatform.getProcessEngineService();