Package org.activiti.bpmn.model

Examples of org.activiti.bpmn.model.ScriptTask


    return scriptTask;
  }

  @Override
  protected void writeAdditionalAttributes(BaseElement element, XMLStreamWriter xtw) throws Exception {
    ScriptTask scriptTask = (ScriptTask) element;
    writeDefaultAttribute(ATTRIBUTE_TASK_SCRIPT_FORMAT, scriptTask.getScriptFormat(), xtw);
  }
View Full Code Here


    writeDefaultAttribute(ATTRIBUTE_TASK_SCRIPT_FORMAT, scriptTask.getScriptFormat(), xtw);
  }

  @Override
  protected void writeAdditionalChildElements(BaseElement element, XMLStreamWriter xtw) throws Exception {
    ScriptTask scriptTask = (ScriptTask) element;
    if (StringUtils.isNotEmpty(scriptTask.getScript())) {
      xtw.writeStartElement(ATTRIBUTE_TASK_SCRIPT_TEXT);
      xtw.writeCharacters(scriptTask.getScript());
      xtw.writeEndElement();
    }
  }
View Full Code Here

   * @param original
   *          the object to clone
   * @return a clone of the original object
   */
  private static final ScriptTask clone(final ScriptTask original, final Diagram diagram) {
    ScriptTask result = new ScriptTask();

    result.setId(ActivitiUiUtil.getNextId(result.getClass(), CreateScriptTaskFeature.FEATURE_ID_KEY, diagram));
    result.setScript(original.getScript());
    result.setScriptFormat(original.getScriptFormat());

    return result;

  }
View Full Code Here

  protected String getStencilId(FlowElement flowElement) {
    return STENCIL_TASK_SCRIPT;
  }
 
  protected void convertElementToJson(ObjectNode propertiesNode, FlowElement flowElement) {
    ScriptTask scriptTask = (ScriptTask) flowElement;
    propertiesNode.put(PROPERTY_SCRIPT_FORMAT, scriptTask.getScriptFormat());
    propertiesNode.put(PROPERTY_SCRIPT_TEXT, scriptTask.getScript());
  }
View Full Code Here

    propertiesNode.put(PROPERTY_SCRIPT_FORMAT, scriptTask.getScriptFormat());
    propertiesNode.put(PROPERTY_SCRIPT_TEXT, scriptTask.getScript());
  }
 
  protected FlowElement convertJsonToElement(JsonNode elementNode, JsonNode modelNode, Map<String, JsonNode> shapeMap) {
    ScriptTask task = new ScriptTask();
    task.setScriptFormat(getPropertyValueAsString(PROPERTY_SCRIPT_FORMAT, elementNode));
    task.setScript(getPropertyValueAsString(PROPERTY_SCRIPT_TEXT, elementNode));
    return task;
  }
View Full Code Here

TOP

Related Classes of org.activiti.bpmn.model.ScriptTask

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.