flowable ContentEngine和ContentEngineConfiguration的关系
一、CommandExecutor
ContentEngineConfiguration继承自 AbstractEngineConfiguration。
在 AbstractEngineConfiguration 中包含一个CommandExecutor 属性。
protected CommandExecutor commandExecutor;
二、ContentManagementService和ContentService
ContentEngineConfiguration中包含两个属性:
protected ContentManagementService contentManagementService = new ContentManagementServiceImpl();
protected ContentService contentService = new ContentServiceImpl();
三、创建ContentEngine
ContentEngine是通过调用ContentEngineConfiguration实例的buildContentEngine()完成创建的。
public ContentEngine buildContentEngine() {
init();
return new ContentEngineImpl(this);
}
1、传递CommandExecutor
在调用ContentEngineConfiguration的buildContentEngine()方法时,在 AbstractEngineConfiguration 中包含的CommandExecutor 属性被赋值给ServiceImpl。代码如下:
protected void initServices() {
initService(contentManagementService);
initService(contentService);
}
protected void initService(Object service) {
if (service instanceof ServiceImpl) {
((ServiceImpl) service).setCommandExecutor(commandExecutor);
}
}
ServiceImpl是ContentService和ContentManagementService的父类,包含一个CommandExecutor 属性。(见下图)
至此,ContentEngineConfiguration 初始化了ContentService和ContentManagementService,并把父类中的CommandExecutor传递给了这两个类的实例。
2、构建ContentEngine
ContentEngineConfiguration被当作参数传递给ContentEngineImpl的构造方法。
public ContentEngine buildContentEngine() {
init();
return new ContentEngineImpl(this);
}
ContentEngineImpl通过ContentEngineConfiguration得到ConentService和ContentManagementService,并对外提供。
public ContentEngineImpl(ContentEngineConfiguration engineConfiguration) {
this.engineConfiguration = engineConfiguration;
this.name = engineConfiguration.getEngineName();
this.managementService = engineConfiguration.getContentManagementService();
this.contentService = engineConfiguration.getContentService();
...
}
ContentEngine 提供的服务最终的执行者是ContentService和ContentManagementService的父类 ServiceImpl;
而 ServiceImpl的执行器是由 AbstractEngineConfiguration提供的。
flowable ContentEngine和ContentEngineConfiguration的关系的更多相关文章
- Android 异步框架 RxJava2
观察者模式的概念 RxJava是android的异步框架,官方介绍是可观测的序列,组成异步基于事件程序的库.特点是观察者模式,基于事件流的链式调用,随着异步操作调度过程复杂的情况下,程序逻辑也变得越来 ...
- flowable EngineConfiguration的作用和继承关系(1)
EngineConfiguration 是flowable引擎的核心部件. 在 flowable 中,实现引擎配置的顶层类是 AbstractEngineConfiguration 这是一个抽象类. ...
- flowable 五个引擎和组成引擎的服务
一.flowable的五个引擎 flowable包含五个引擎,分别是: 1.内容引擎 ContentEngine 2.身份识别引擎 IdmEngine 3.表单引擎 FormEngine 4.决策引擎 ...
- flowable EngineConfiguration的实现分析(2)
EngineConfiguration的实现类是一个抽象类:AbstractEngineConfiguration 一.引擎配置的分类 继承 AbsractEngineConfiguration的子类 ...
- flowable表简要说明
1. Flowable数据库表命名规则 ACT_RE_* ’RE’表示repository(存储).RepositoryService接口操作的表.带此前缀的表包含的是静态信息,如,流程定义,流程的资 ...
- 工作流选型专项,Camunda or flowable or?
1. 名词解释 1.1. BPM Business Process Management,业务流程管理,“通过建模.自动化.管理和优化流程,打破跨部门跨系统业务过程依赖,提高业务效率和效果”. 1.2 ...
- Flowable—多实例任务:会签
多实例任务 会签 什么是会签? 举个例子:比如我们有一个任务 可能需要多人审批,审批通过的条件可能比较多样,比如五个人审批.3个人审批过了就算过了,再或者有一个人权限比较高,拥有一票否决权. 即是其余 ...
- Flowable学习入门
一.Flowable简介 1.Flowable是什么 Flowable是一个使用Java编写的轻量级业务流程引擎.Flowable流程引擎可用于部署BPMN 2.0流程定义(用于定义流程的行业XML标 ...
- 【流程】Flowable流程定义总结
背景 近几年,互联网企业从消费互联网向产业互联网转型.在消费互联网时期,企业面对的时C端消费者,而产业互联网面对的是B端用户. 产业互联网涉及方方面面,企业信息化的建设就是B端用户的业务之一,在企业就 ...
随机推荐
- MAC VNC SSH roo用户开通
第一步:ssh: user@xxx.xxx.xxx 第二步:开启VNC 开启VNC共享桌面: sudo /System/Library/CoreServices/RemoteManagement/A ...
- 20144303 《Java程序设计》课程总结
20144303 <Java程序设计>课程总结 每周读书笔记链接汇总 第一周:http://www.cnblogs.com/20144303sys/p/5248979.html 第二周:h ...
- linux 块设备-整理(一)
1. 基本概念: linux设备驱动开发详解(宋宝华): 字符设备与块设备 I/O 操作的不同如下. (1)块设备只能以块为单位接受输入和返回输出,而字符设备则以字节为单位. 大多数设备是字符设备,因 ...
- Job流程:Mapper类分析
此文紧接Job流程:决定map个数的因素,Map任务被提交到Yarn后,被ApplicationMaster启动,任务的形式是YarnChild进程,在其中会执行MapTask的run()方法.无论是 ...
- poj 2187:Beauty Contest(旋转卡壳)
Time Limit: 3000MS Memory Limit: 65536K Total Submissions: 32708 Accepted: 10156 Description Bes ...
- unix_timestamp() 和 from_unixtime()
unix_timestamp() 将时间转换为时间戳.(date 类型数据转换成 timestamp 形式整数) select unix_timestamp('2016-03-23 11:10:10' ...
- spring boot2.1读取 apollo 配置中心3
上篇记录了springboot读取apollo的配置信息,以及如何获取服务端的推送更新配置. 接下来记录一下,如何获取公共namespace的配置. 上文中使用如下代码共聚公共命名空间的配置: @Ap ...
- struts2中<s:checkboxlist/>的用法详解
Html代码 选择角色<br> <s:checkboxlist list="#request.roleuserList" listKey="roleId ...
- Java循环语句之 while
生活中,有些时候为了完成任务,需要重复的进行某些动作.如参加 10000 米长跑,需要绕 400 米的赛道反复的跑 25 圈.在 Java 中实现功能时,也经常需要重复执行某些代码,例如,我们为了表示 ...
- selenium的三种等待时间设置
为了提高脚本的稳定性,我们需要在脚本中增加等待时间 第一种:强制等待 Thread.sleep():固定休眠时间设置,Java的Thread类里提供了休眠方法sleep,导入包后就能使用 sleep( ...