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端用户的业务之一,在企业就 ...
随机推荐
- MR案例:分区和排序
现有一学生成绩数据,格式如下:<学号,姓名,学院,成绩> //<id, name, institute, grade>. 需求描述:查询成绩大于等于60分的学生数据,按学院分 ...
- MysQL使用一与Python交互
与python交互 在熟练使用sql语句的基础上,开始使用python语言提供的模块与mysql进行交互 这是我们在工作中大事要做的事 先学会sql是基础,一定要熟练编写sql语句 安装引入模块 安装 ...
- 如何使用JMX监控Kafka
使用kafka做消息队列中间件时,为了实时监控其性能时,免不了要使用jmx调取kafka broker的内部数据,不管是自己重新做一个kafka集群的监控系统,还是使用一些开源的产品,比如yahoo的 ...
- POJ - 3169 差分约束
题意:n头牛,按照编号从左到右排列,两头牛可能在一起,接着有一些关系表示第a头牛与第b头牛相隔最多与最少的距离,最后求出第一头牛与最后一头牛的最大距离是多少,如 果最大距离无限大则输出 ...
- harbor 管理Helm Chart包
官方网站:https://github.com/goharbor/harbor官方用户手册:https://github.com/goharbor/harbor/blob/master/docs/us ...
- Codeforces Round #341 (Div. 2) C. Mike and Chocolate Thieves 二分
C. Mike and Chocolate Thieves time limit per test 2 seconds memory limit per test 256 megabytes inpu ...
- 【Python】模块学习之利用string模块造测试数据
背景 测试过程中需要一些随机数据,使用到了python中的string模块,记录一下 #! /usr/bin/python # coding:utf-8 """ @aut ...
- 【平台中间件】Nginx安装配置,实现版本更新不影响服务访问
为什么要做负载均衡? 当你网站是一个企业站.个人博客的时候,或者访问量比较小的时候,一台服务器完全应付的了,那就完全没必要做负载均衡.但是,如果你的网站是平台级别,用户达到十万百万级别了,一台服务器明 ...
- Angular单元测试系列
Angular单元测试系列 - 大纲Angular单元测试系列 - 简介Angular单元测试系列 - 如何使用Jasmine进行Angular单元测试Angular单元测试系列 - Router.C ...
- JSP XML 数据处理
JSP XML 数据处理 当通过HTTP发送XML数据时,就有必要使用JSP来处理传入和流出的XML文档了,比如RSS文档.作为一个XML文档,它仅仅只是一堆文本而已,使用JSP创建XML文档并不比创 ...