Package pl.net.bluesoft.rnd.processtool.model

Examples of pl.net.bluesoft.rnd.processtool.model.ProcessInstanceSimpleAttribute


        a.setValue(value);
        found = true;
      }
    }
    if (!found) {
      ProcessInstanceSimpleAttribute processInstanceSimpleAttribute = new ProcessInstanceSimpleAttribute();
      processInstanceSimpleAttribute.setValue(value);
      processInstanceSimpleAttribute.setKey(key);
      pi.addAttribute(processInstanceSimpleAttribute);
    }
  }
View Full Code Here


    @Override
  public String getSimpleAttributeValue(String key,ProcessInstance processInstance){
     
      long start = System.currentTimeMillis();
      ProcessInstanceSimpleAttribute pisa = getSimpleAttribute(key,processInstance);
       long duration = System.currentTimeMillis() - start;
      logger.severe("getSimpleAttributeValue: " +  duration);
     
    return pisa.getValue();
  }
View Full Code Here

        return list;
     }
 
  @Override
  public ProcessInstanceSimpleAttribute setSimpleAttribute(String key, String newValue, ProcessInstance processInstance){
    ProcessInstanceSimpleAttribute pisa = getSimpleAttribute(key,processInstance);
  if(pisa==null){
    return null
  }
  pisa.setValue(newValue);
  session.update(pisa);
  return pisa;
  }
View Full Code Here

        newProcessInstance.setDescription(description);
        newProcessInstance.setKeyword(keyword);
        newProcessInstance.setStatus(ProcessStatus.NEW);

        {
            ProcessInstanceSimpleAttribute attr = new ProcessInstanceSimpleAttribute();
            attr.setKey("creator");
            attr.setValue(creator.getLogin());
            newProcessInstance.addAttribute(attr);

            attr = new ProcessInstanceSimpleAttribute();
            attr.setKey("creatorName");
            attr.setValue(creator.getRealName());
            newProcessInstance.addAttribute(attr);
        }
        ProcessInstanceSimpleAttribute attr = new ProcessInstanceSimpleAttribute();
        attr.setKey("source");
        attr.setValue(source);
        newProcessInstance.addAttribute(attr);

        ctx.getProcessInstanceDAO().saveProcessInstance(newProcessInstance);

        if(internalId == null)
View Full Code Here

    private static final Logger logger = Logger.getLogger(LogStepTest.class.getName());
   
    @Test
    public void testParse() throws Exception {
        ProcessInstance process = new ProcessInstance();
        process.addAttribute(new ProcessInstanceSimpleAttribute("p1", "my-very-first-param"));
        process.addAttribute(new ProcessInstanceSimpleAttribute("p2", "second_param_123"));

        Map<String, String> properties = new HashMap<String, String>();
        properties.put("message", "${p1} and ${p2} or ${something}");

        String result = processStep(new LogStep(), process, properties);
View Full Code Here

TOP

Related Classes of pl.net.bluesoft.rnd.processtool.model.ProcessInstanceSimpleAttribute

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.