当前位置: 首页>>代码示例>>Java>>正文


Java ProcessVariable类代码示例

本文整理汇总了Java中org.activiti.spring.annotations.ProcessVariable的典型用法代码示例。如果您正苦于以下问题:Java ProcessVariable类的具体用法?Java ProcessVariable怎么用?Java ProcessVariable使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。


ProcessVariable类属于org.activiti.spring.annotations包,在下文中一共展示了ProcessVariable类的10个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: processVariablesFromAnnotations

import org.activiti.spring.annotations.ProcessVariable; //导入依赖的package包/类
/**
 * if there any arguments with the {@link org.activiti.engine.annotations.ProcessVariable} annotation,
 * then we feed those parameters into the business process
 *
 * @param invocation the invocation of the method as passed to the {@link org.aopalliance.intercept.MethodInterceptor#invoke(org.aopalliance.intercept.MethodInvocation)} method
 * @return returns the map of process variables extracted from the parameters
 * @throws Throwable thrown anything goes wrong
 */
protected Map<String, Object> processVariablesFromAnnotations(MethodInvocation invocation) throws Throwable {

	Map<ProcessVariable, Object> vars = this.mapOfAnnotationValues(ProcessVariable.class, invocation);

	Map<String, Object> varNameToValueMap = new HashMap<String, Object>();
	for (ProcessVariable processVariable : vars.keySet()) {
		varNameToValueMap.put(processVariable.value(), vars.get(processVariable));
	}
	return varNameToValueMap;

}
 
开发者ID:logicalhacking,项目名称:SecureBPMN,代码行数:20,代码来源:ProcessStartingMethodInterceptor.java

示例2: processVariablesFromAnnotations

import org.activiti.spring.annotations.ProcessVariable; //导入依赖的package包/类
/**
 * if there any arguments with the {@link org.activiti.spring.annotations.ProcessVariable} annotation,
 * then we feed those parameters into the business process
 *
 * @param invocation the invocation of the method as passed to the {@link org.aopalliance.intercept.MethodInterceptor#invoke(org.aopalliance.intercept.MethodInvocation)} method
 * @return returns the map of process variables extracted from the parameters
 * @throws Throwable thrown anything goes wrong
 */
protected Map<String, Object> processVariablesFromAnnotations(MethodInvocation invocation) throws Throwable {

	Map<ProcessVariable, Object> vars = this.mapOfAnnotationValues(ProcessVariable.class, invocation);

	Map<String, Object> varNameToValueMap = new HashMap<String, Object>();
	for (ProcessVariable processVariable : vars.keySet()) {
		varNameToValueMap.put(processVariable.value(), vars.get(processVariable));
	}
	return varNameToValueMap;

}
 
开发者ID:joshlong,项目名称:javaconfig-ftw,代码行数:20,代码来源:ProcessStartingMethodInterceptor.java

示例3: startProcess

import org.activiti.spring.annotations.ProcessVariable; //导入依赖的package包/类
@StartProcess(processKey = "b")
public void startProcess(@ProcessVariable("customerId") long customerId) {
	log.info("starting 'b' with customerId # " + customerId);
	this.methodState += 1;
	log.info("up'd the method state");
}
 
开发者ID:logicalhacking,项目名称:SecureBPMN,代码行数:7,代码来源:ProcessInitiatingPojo.java

示例4: startProcessA

import org.activiti.spring.annotations.ProcessVariable; //导入依赖的package包/类
@StartProcess(processKey = "waiter", returnProcessInstanceId = true)
public String startProcessA(@ProcessVariable("customerId") long cId) {
	return null;
}
 
开发者ID:logicalhacking,项目名称:SecureBPMN,代码行数:5,代码来源:ProcessInitiatingPojo.java

示例5: enrollCustomer

import org.activiti.spring.annotations.ProcessVariable; //导入依赖的package包/类
@StartProcess(processKey = "waiter")
public ProcessInstance enrollCustomer(@BusinessKey String key, @ProcessVariable("customerId") long customerId) {
	return null;
}
 
开发者ID:logicalhacking,项目名称:SecureBPMN,代码行数:5,代码来源:ProcessInitiatingPojo.java

示例6: startScopedProcess

import org.activiti.spring.annotations.ProcessVariable; //导入依赖的package包/类
@StartProcess(processKey = "component-waiter")
public void startScopedProcess( @ProcessVariable("customerId") long customerId){
	log.info(" start scoped 'component-waiter' process.") ;
}
 
开发者ID:logicalhacking,项目名称:SecureBPMN,代码行数:5,代码来源:ProcessInitiatingPojo.java

示例7: startProcess

import org.activiti.spring.annotations.ProcessVariable; //导入依赖的package包/类
@StartProcess(processKey = "b")
public void startProcess(@ProcessVariable("customerId") long customerId) {
	log.info("starting 'b' with customerId # {}", customerId);
	this.methodState += 1;
	log.info("up'd the method state");
}
 
开发者ID:joshlong,项目名称:javaconfig-ftw,代码行数:7,代码来源:ProcessInitiatingPojo.java

示例8: startScopedProcess

import org.activiti.spring.annotations.ProcessVariable; //导入依赖的package包/类
@StartProcess(processKey = "component-waiter")
public void startScopedProcess( @ProcessVariable("customerId") long customerId){
	log.info("start scoped 'component-waiter' process.") ;
}
 
开发者ID:joshlong,项目名称:javaconfig-ftw,代码行数:5,代码来源:ProcessInitiatingPojo.java

示例9: startFulfillment

import org.activiti.spring.annotations.ProcessVariable; //导入依赖的package包/类
@StartProcess(processKey = "crm-order-fulfillment", returnProcessInstanceId = true)
public String startFulfillment(@ProcessVariable("customerId") long customerId) {
    cart.amountDue = cart.amountDue + 10;
    System.out.println("start scoped 'waiter' process with customerId = " + customerId);
    return null;
}
 
开发者ID:joshlong,项目名称:javaconfig-ftw,代码行数:7,代码来源:Main.java

示例10: customerOrderReview

import org.activiti.spring.annotations.ProcessVariable; //导入依赖的package包/类
@State("customer-order-review")
public void customerOrderReview(@ProcessVariable("customerId") long customerId, DelegateExecution delegateExecution) {
    System.out.println(this.cart.toString());
    System.out.println("the current customerId is " + customerId + ".");
    // System.out.println( delegateExecution);
}
 
开发者ID:joshlong,项目名称:javaconfig-ftw,代码行数:7,代码来源:Main.java


注:本文中的org.activiti.spring.annotations.ProcessVariable类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。