Package org.camunda.bpm.engine.delegate

Examples of org.camunda.bpm.engine.delegate.CaseVariableListener


    PlanItemDefinition definition = getDefinition(element);

    List<CamundaVariableListener> listeners = queryExtensionElementsByClass(definition, CamundaVariableListener.class);

    for (CamundaVariableListener listener : listeners) {
      CaseVariableListener variableListener = initializeVariableListener(element, activity, context, listener);

      String eventName = listener.getCamundaEvent();
      if(eventName != null) {
        activity.addVariableListener(eventName, variableListener);
View Full Code Here


    String className = listener.getCamundaClass();
    String expression = listener.getCamundaExpression();
    String delegateExpression = listener.getCamundaDelegateExpression();
    CamundaScript scriptElement = listener.getCamundaScript();

    CaseVariableListener variableListener = null;
    if (className != null) {
      variableListener = new ClassDelegateCaseVariableListener(className, fieldDeclarations);

    } else if (expression != null) {
      Expression expressionExp = expressionManager.createExpression(expression);
View Full Code Here

          if (listeners != null) {
            delegateVariable.setScopeExecution(currentExecution);

            for (VariableListener<?> listener : listeners) {
              try {
                CaseVariableListener caseVariableListener = (CaseVariableListener) listener;
                CaseVariableListenerInvocation invocation = new CaseVariableListenerInvocation(caseVariableListener, delegateVariable, currentExecution);
                Context.getProcessEngineConfiguration()
                  .getDelegateInterceptor()
                  .handleInvocation(invocation);
              } catch (Exception e) {
View Full Code Here

  public ClassDelegateCaseVariableListener(Class<?> clazz, List<FieldDeclaration> fieldDeclarations) {
    super(clazz, fieldDeclarations);
  }

  public void notify(DelegateCaseVariableInstance variableInstance) throws Exception {
    CaseVariableListener variableListenerInstance = getVariableListenerInstance();

    Context.getProcessEngineConfiguration()
      .getDelegateInterceptor()
      .handleInvocation(new CaseVariableListenerInvocation(variableListenerInstance, variableInstance));
  }
View Full Code Here

  public void notify(DelegateCaseVariableInstance variableInstance) throws Exception {
    Object delegate = expression.getValue(variableInstance.getSourceExecution());
    applyFieldDeclaration(fieldDeclarations, delegate);

    if (delegate instanceof CaseVariableListener) {
      CaseVariableListener listenerInstance = (CaseVariableListener) delegate;
      Context
        .getProcessEngineConfiguration()
        .getDelegateInterceptor()
        .handleInvocation(new CaseVariableListenerInvocation(listenerInstance, variableInstance));
    } else {
View Full Code Here

TOP

Related Classes of org.camunda.bpm.engine.delegate.CaseVariableListener

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.