在配置Hibernat的事务传播特性比较常用就是REQUIRED,read-only,REQUIRES_NEW,示例代码如下:
<tx:advice id="txAdvice" transaction-manager="transactionManager"> <tx:attributes> <tx:method name="get*" read-only="true" /> <tx:method name="query*" read-only="true" /> <tx:method name="find*" read-only="true" /> <tx:method name="load*" read-only="true" /> <tx:method name="*REQUIRES_NEW" propagation="REQUIRES_NEW"/> <tx:method name="*" propagation="REQUIRED" /> </tx:attributes> </tx:advice>
1、假设有UserService中有代码如下:
public void save(User user){ String code =null; try { code=codeGenerateService.generateUserCode_REQUIRES_NEW(); } catch (Exception e) { LOG.error(e.getMessage(),e); } user.setUserCode(code); baseDao.save(user); }
在执行过程中后台打印的日志如下:
2015-11-11 10:17:03:DEBUG main org.hibernate.impl.SessionImpl - opened session at timestamp: 5927941831421952
org.springframework.orm.hibernate3.HibernateTransactionManager - Opened new Session [org.hibernate.impl.SessionImpl@86d1da] for Hibernate transaction
org.springframework.orm.hibernate3.HibernateTransactionManager - Preparing JDBC Connection of Hibernate Session [org.hibernate.impl.SessionImpl@86d1da]
org.springframework.orm.hibernate3.HibernateTransactionManager - Found thread-bound Session [org.hibernate.impl.SessionImpl@86d1da] for Hibernate transaction
org.springframework.orm.hibernate3.HibernateTransactionManager - Suspending current transaction, creating new transaction with name [com.lyl.system.service.CodeGenerateService.generateUserCode_REQUIRES_NEW]
org.hibernate.impl.SessionImpl - opened session at timestamp: 5927941831806976
org.springframework.orm.hibernate3.HibernateTransactionManager - Opened new Session [org.hibernate.impl.SessionImpl@19977bd] for Hibernate transaction
org.springframework.orm.hibernate3.HibernateTransactionManager - Preparing JDBC Connection of Hibernate Session [org.hibernate.impl.SessionImpl@19977bd]
org.hibernate.transaction.JDBCTransaction - begin
org.hibernate.jdbc.ConnectionManager - opening JDBC connection
net.sf.ehcache.CacheManager@6691da net.sf.ehcache.util.UpdateChecker - Checking for update...
org.hibernate.transaction.JDBCTransaction - current autocommit status: true
org.hibernate.transaction.JDBCTransaction - disabling autocommit
Hibernate:
select
codegenera0_.codeType as codeType0_,
codegenera0_.value as value0_
from
demo1_code_generate codegenera0_
where
codegenera0_.codeType=?
org.hibernate.jdbc.AbstractBatcher - about to open ResultSet (open ResultSets: 0, globally: 0)
org.hibernate.loader.Loader - result row: EntityKey[com.lyl.system.entity.CodeGenerate#USER_CODE]
org.hibernate.jdbc.AbstractBatcher - about to close ResultSet (open ResultSets: 1, globally: 1)
org.hibernate.jdbc.AbstractBatcher - about to close PreparedStatement (open PreparedStatements: 1, globally: 1)
org.hibernate.engine.TwoPhaseLoad - resolving associations for [com.lyl.system.entity.CodeGenerate#USER_CODE]
org.hibernate.engine.TwoPhaseLoad - done materializing entity [com.lyl.system.entity.CodeGenerate#USER_CODE]
org.hibernate.engine.StatefulPersistenceContext - initializing non-lazy collections
org.springframework.orm.hibernate3.HibernateTemplate - Not closing pre-bound Hibernate Session after HibernateTemplate
org.springframework.orm.hibernate3.HibernateTemplate - Found thread-bound Session for HibernateTemplate
org.springframework.orm.hibernate3.HibernateTemplate - Not closing pre-bound Hibernate Session after HibernateTemplate
org.springframework.orm.hibernate3.HibernateTransactionManager - Initiating transaction commit
org.springframework.orm.hibernate3.HibernateTransactionManager - Committing Hibernate transaction on Session [org.hibernate.impl.SessionImpl@19977bd]
org.hibernate.transaction.JDBCTransaction - commit
org.hibernate.event.def.AbstractFlushingEventListener - processing flush-time cascades
org.hibernate.event.def.AbstractFlushingEventListener - dirty checking collections
org.hibernate.event.def.AbstractFlushingEventListener - Flushed: 0 insertions, 1 updates, 0 deletions to 1 objects
org.hibernate.event.def.AbstractFlushingEventListener - Flushed: 0 (re)creations, 0 updates, 0 removals to 0 collections
org.hibernate.pretty.Printer - listing entities:
org.hibernate.pretty.Printer - com.lyl.system.entity.CodeGenerate{value=8, codeType=USER_CODE}
org.hibernate.jdbc.AbstractBatcher - about to open PreparedStatement (open PreparedStatements: 0, globally: 0)
org.hibernate.SQL -
update
demo1_code_generate
set
value=?
where
codeType=?
Hibernate:
update
demo1_code_generate
set
value=?
where
codeType=?
org.hibernate.cache.UpdateTimestampsCache - Pre-invalidating space [demo1_code_generate]
org.hibernate.jdbc.AbstractBatcher - Executing batch size: 1
org.hibernate.jdbc.AbstractBatcher - about to close PreparedStatement (open PreparedStatements: 1, globally: 1)
org.hibernate.transaction.JDBCTransaction - re-enabling autocommit
org.hibernate.transaction.JDBCTransaction - committed JDBC Connection
org.hibernate.jdbc.ConnectionManager - transaction completed on session with on_close connection release mode; be sure to close the session to release JDBC resources!
org.hibernate.cache.UpdateTimestampsCache - Invalidating space [demo1_code_generate], timestamp: 5927941833535488
org.springframework.orm.hibernate3.HibernateTransactionManager - Closing Hibernate Session [org.hibernate.impl.SessionImpl@19977bd] after transaction
org.springframework.orm.hibernate3.SessionFactoryUtils - Closing Hibernate Session
org.hibernate.jdbc.ConnectionManager - releasing JDBC connection [ (open PreparedStatements: 0, globally: 0) (open ResultSets: 0, globally: 0)]
org.hibernate.jdbc.ConnectionManager - transaction completed on session with on_close connection release mode; be sure to close the session to release JDBC resources!
org.springframework.orm.hibernate3.HibernateTransactionManager - Resuming suspended transaction after completion of inner transaction
org.springframework.orm.hibernate3.HibernateTemplate - Found thread-bound Session for HibernateTemplate
org.hibernate.event.def.AbstractSaveEventListener - generated identifier: 402883e750f6e82e0150f6e833cb0000, using strategy: org.hibernate.id.UUIDHexGenerator
org.springframework.orm.hibernate3.HibernateTemplate - Not closing pre-bound Hibernate Session after HibernateTemplate
org.springframework.orm.hibernate3.HibernateTransactionManager - Initiating transaction commit
org.springframework.orm.hibernate3.HibernateTransactionManager - Committing Hibernate transaction on Session [org.hibernate.impl.SessionImpl@86d1da]
org.hibernate.transaction.JDBCTransaction - commit
org.hibernate.event.def.AbstractFlushingEventListener - processing flush-time cascades
org.hibernate.event.def.AbstractFlushingEventListener - dirty checking collections
org.hibernate.event.def.AbstractFlushingEventListener - Flushed: 1 insertions, 0 updates, 0 deletions to 1 objects
org.hibernate.event.def.AbstractFlushingEventListener - Flushed: 0 (re)creations, 0 updates, 0 removals to 0 collections
org.hibernate.pretty.Printer - listing entities:
org.hibernate.pretty.Printer - com.lyl.system.entity.User{sex=null, userCode=000008, password=m123, updateDate=Wed Nov 11 22:17:04 CST 2015, tephone=13145453211, id=402883e750f6e82e0150f6e833cb0000, createUser=1, enableFlag=false, address=上海市松江区, email=132333@qq.com, userName=zhangsan, createDate=Wed Nov 11 22:17:04 CST 2015, updateUser=1}
org.hibernate.jdbc.AbstractBatcher - about to open PreparedStatement (open PreparedStatements: 0, globally: 0)
org.hibernate.SQL -
insert
into
demo1_user
(createDate, createUser, enableFlag, updateDate, updateUser, address, email, password, sex, tephone, userCode, userName, id)
values
(?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)
Hibernate:
insert
into
demo1_user
(createDate, createUser, enableFlag, updateDate, updateUser, address, email, password, sex, tephone, userCode, userName, id)
values
(?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)
org.hibernate.cache.UpdateTimestampsCache - Pre-invalidating space [demo1_user]
org.hibernate.jdbc.AbstractBatcher - Executing batch size: 1
org.hibernate.jdbc.AbstractBatcher - about to close PreparedStatement (open PreparedStatements: 1, globally: 1)
org.hibernate.transaction.JDBCTransaction - re-enabling autocommit
org.hibernate.transaction.JDBCTransaction - committed JDBC Connection
org.hibernate.jdbc.ConnectionManager - transaction completed on session with on_close connection release mode; be sure to close the session to release JDBC resources!
org.hibernate.cache.UpdateTimestampsCache - Invalidating space [demo1_user], timestamp: 5927941833596929
org.springframework.orm.hibernate3.HibernateTransactionManager - Closing Hibernate Session [org.hibernate.impl.SessionImpl@86d1da] after transaction
org.springframework.orm.hibernate3.SessionFactoryUtils - Closing Hibernate Session
org.hibernate.jdbc.ConnectionManager - releasing JDBC connection [ (open PreparedStatements: 0, globally: 0) (open ResultSets: 0, globally: 0)]
org.hibernate.jdbc.ConnectionManager - transaction completed on session with on_close connection release mode; be sure to close the session to release JDBC resources!
有上面日志可以看出,首先从spring bean工厂里面取得单例userService,进入save方法后开启事务,并打开session ,在执行到调用方法codeGenerateService.generateUserCode_REQUIRES_NEW()获取用户代码时,在codeGenerateService的方法generateUserCode_REQUIRES_NEW()时根据配置,方法内又开启了一个新事务,当generateUserCode_REQUIRES_NEW()调用完成后,将新开启的事务就提交了,因此我们可以通过try catch捕获执行运行时异常(包括数据库执行异常),如果不捕获发生的异常,导致UserService的save方法事务回滚,保存失败。
假设我们有UserService方法中,同样声明了一个生成用户代码的方法如下:
public String generateUserCode_REQUIRES_NEW(){ Map<String, Object> paramMap = new HashMap<String, Object>(); paramMap.put("codeType", SystemEnum.CODE_TYPE.USER_CODE); List<CodeGenerate> codeList = baseDao.findByHQL( "from CodeGenerate where codeType=:codeType", paramMap); CodeGenerate cg = codeList.get(0); String value = cg.getValue(); Integer i = Integer.valueOf(value); i = i + 1; cg.setValue(i.toString()); baseDao.update(cg); Double d = new Double(Math.pow(10, 6)); int a = d.intValue() + i; String str = new Integer(a).toString(); str = str.substring(1); return str; }
在UserService的调用本类声明的方法generateUserCode_REQUIRES_NEW()会怎么样呢?看下面的日志就知道了。
2015-11-11 10:34:36:DEBUG main org.springframework.orm.hibernate3.HibernateTransactionManager - Creating new transaction with name [com.lyl.system.service.UserService.save]: PROPAGATION_REQUIRED,ISOLATION_DEFAULT
2015-11-11 10:34:36:DEBUG main org.hibernate.impl.SessionImpl - opened session at timestamp: 5927946143420416
2015-11-11 10:34:36:DEBUG main org.springframework.orm.hibernate3.HibernateTransactionManager - Opened new Session [org.hibernate.impl.SessionImpl@86d1da] for Hibernate transaction
2015-11-11 10:34:36:DEBUG main org.springframework.orm.hibernate3.HibernateTransactionManager - Preparing JDBC Connection of Hibernate Session [org.hibernate.impl.SessionImpl@86d1da]
2015-11-11 10:34:36:DEBUG net.sf.ehcache.CacheManager@6691da net.sf.ehcache.util.UpdateChecker - Checking for update...
2015-11-11 10:34:36:DEBUG main org.hibernate.transaction.JDBCTransaction - begin
2015-11-11 10:34:36:DEBUG main org.hibernate.jdbc.ConnectionManager - opening JDBC connection
2015-11-11 10:34:36:DEBUG main org.hibernate.transaction.JDBCTransaction - current autocommit status: true
2015-11-11 10:34:36:DEBUG main org.hibernate.transaction.JDBCTransaction - disabling autocommit
2015-11-11 10:34:36:DEBUG main org.springframework.orm.hibernate3.HibernateTransactionManager - Exposing Hibernate transaction as JDBC transaction [jdbc:mysql://127.0.0.1:3306/test?useUnicode=true&characterEncoding=UTF-8, UserName=root@localhost, MySQL Connector Java]
2015-11-11 10:34:36:DEBUG main org.springframework.orm.hibernate3.HibernateTemplate - Found thread-bound Session for HibernateTemplate
2015-11-11 10:34:36:DEBUG main org.hibernate.jdbc.AbstractBatcher - about to open ResultSet (open ResultSets: 0, globally: 0)
2015-11-11 10:34:36:DEBUG main org.hibernate.loader.Loader - result row: EntityKey[com.lyl.system.entity.CodeGenerate#USER_CODE]
2015-11-11 10:34:36:DEBUG main org.hibernate.jdbc.AbstractBatcher - about to close ResultSet (open ResultSets: 1, globally: 1)
2015-11-11 10:34:36:DEBUG main org.hibernate.jdbc.AbstractBatcher - about to close PreparedStatement (open PreparedStatements: 1, globally: 1)
2015-11-11 10:34:36:DEBUG main org.hibernate.engine.TwoPhaseLoad - resolving associations for [com.lyl.system.entity.CodeGenerate#USER_CODE]
2015-11-11 10:34:36:DEBUG main org.hibernate.engine.TwoPhaseLoad - done materializing entity [com.lyl.system.entity.CodeGenerate#USER_CODE]
2015-11-11 10:34:36:DEBUG main org.hibernate.engine.StatefulPersistenceContext - initializing non-lazy collections
2015-11-11 10:34:36:DEBUG main org.springframework.orm.hibernate3.HibernateTemplate - Not closing pre-bound Hibernate Session after HibernateTemplate
2015-11-11 10:34:36:DEBUG main org.springframework.orm.hibernate3.HibernateTemplate - Found thread-bound Session for HibernateTemplate
2015-11-11 10:34:36:DEBUG main org.springframework.orm.hibernate3.HibernateTemplate - Not closing pre-bound Hibernate Session after HibernateTemplate
2015-11-11 10:34:36:DEBUG main org.springframework.orm.hibernate3.HibernateTemplate - Found thread-bound Session for HibernateTemplate
2015-11-11 10:34:36:DEBUG main org.hibernate.event.def.AbstractSaveEventListener - generated identifier: 402883e750f6f83e0150f6f8438c0000, using strategy: org.hibernate.id.UUIDHexGenerator
2015-11-11 10:34:36:DEBUG main org.springframework.orm.hibernate3.HibernateTemplate - Not closing pre-bound Hibernate Session after HibernateTemplate
2015-11-11 10:34:36:DEBUG main org.springframework.orm.hibernate3.HibernateTransactionManager - Initiating transaction commit
2015-11-11 10:34:36:DEBUG main org.springframework.orm.hibernate3.HibernateTransactionManager - Committing Hibernate transaction on Session [org.hibernate.impl.SessionImpl@86d1da]
2015-11-11 10:34:36:DEBUG main org.hibernate.transaction.JDBCTransaction - commit
2015-11-11 10:34:36:DEBUG main org.hibernate.event.def.AbstractFlushingEventListener - processing flush-time cascades
2015-11-11 10:34:36:DEBUG main org.hibernate.event.def.AbstractFlushingEventListener - dirty checking collections
2015-11-11 10:34:36:DEBUG main org.hibernate.event.def.AbstractFlushingEventListener - Flushed: 1 insertions, 1 updates, 0 deletions to 2 objects
2015-11-11 10:34:36:DEBUG main org.hibernate.event.def.AbstractFlushingEventListener - Flushed: 0 (re)creations, 0 updates, 0 removals to 0 collections
2015-11-11 10:34:36:DEBUG main org.hibernate.pretty.Printer - listing entities:
2015-11-11 10:34:36:DEBUG main org.hibernate.pretty.Printer - com.lyl.system.entity.User{sex=null, userCode=000010, password=m123, updateDate=Wed Nov 11 22:34:36 CST 2015, tephone=13145453211, id=402883e750f6f83e0150f6f8438c0000, createUser=1, enableFlag=false, address=上海市松江区, email=132333@qq.com, userName=zhangsan, createDate=Wed Nov 11 22:34:36 CST 2015, updateUser=1}
2015-11-11 10:34:36:DEBUG main org.hibernate.pretty.Printer - com.lyl.system.entity.CodeGenerate{value=10, codeType=USER_CODE}
2015-11-11 10:34:36:DEBUG main org.hibernate.jdbc.AbstractBatcher - about to open PreparedStatement (open PreparedStatements: 0, globally: 0)
2015-11-11 10:34:36:DEBUG main org.hibernate.SQL -
Hibernate:
insert
into
demo1_user
(createDate, createUser, enableFlag, updateDate, updateUser, address, email, password, sex, tephone, userCode, userName, id)
values
(?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)
2015-11-11 10:34:36:DEBUG main org.hibernate.cache.UpdateTimestampsCache - Pre-invalidating space [demo1_user]
2015-11-11 10:34:36:DEBUG main org.hibernate.jdbc.AbstractBatcher - Executing batch size: 1
2015-11-11 10:34:36:DEBUG main org.hibernate.jdbc.AbstractBatcher - about to close PreparedStatement (open PreparedStatements: 1, globally: 1)
2015-11-11 10:34:36:DEBUG main org.hibernate.jdbc.AbstractBatcher - about to open PreparedStatement (open PreparedStatements: 0, globally: 0)
2015-11-11 10:34:36:DEBUG main org.hibernate.SQL -
Hibernate:
update
demo1_code_generate
set
value=?
where
codeType=?
2015-11-11 10:34:36:DEBUG main org.hibernate.cache.UpdateTimestampsCache - Pre-invalidating space [demo1_code_generate]
2015-11-11 10:34:36:DEBUG main org.hibernate.jdbc.AbstractBatcher - Executing batch size: 1
2015-11-11 10:34:36:DEBUG main org.hibernate.jdbc.AbstractBatcher - about to close PreparedStatement (open PreparedStatements: 1, globally: 1)
2015-11-11 10:34:36:DEBUG main org.hibernate.transaction.JDBCTransaction - re-enabling autocommit
2015-11-11 10:34:36:DEBUG main org.hibernate.transaction.JDBCTransaction - committed JDBC Connection
2015-11-11 10:34:36:DEBUG main org.hibernate.jdbc.ConnectionManager - transaction completed on session with on_close connection release mode; be sure to close the session to release JDBC resources!
2015-11-11 10:34:36:DEBUG main org.hibernate.cache.UpdateTimestampsCache - Invalidating space [demo1_code_generate], timestamp: 5927946145214465
2015-11-11 10:34:36:DEBUG main org.hibernate.cache.UpdateTimestampsCache - Invalidating space [demo1_user], timestamp: 5927946145214465
2015-11-11 10:34:36:DEBUG main org.springframework.orm.hibernate3.HibernateTransactionManager - Closing Hibernate Session [org.hibernate.impl.SessionImpl@86d1da] after transaction
2015-11-11 10:34:36:DEBUG main org.springframework.orm.hibernate3.SessionFactoryUtils - Closing Hibernate Session
2015-11-11 10:34:36:DEBUG main org.hibernate.jdbc.ConnectionManager - releasing JDBC connection [ (open PreparedStatements: 0, globally: 0) (open ResultSets: 0, globally: 0)]
2015-11-11 10:34:36:DEBUG main org.hibernate.jdbc.ConnectionManager - transaction completed on session with on_close connection release mode; be sure to close the session to release JDBC resources!
UserService调用用本类中的EQUIRES_NEW结尾的方法并没有 开启事务,也就是说时它们属于同一个事务,而且执行是顺序我我们注意到打印save中的insert语句,再打印generateUserCode_REQUIRES_NEW()方法的update语句,说明调用方法比被调方法中的(影响数据)语句先执行。
总结:
当我们需要保证执行某个操作时单独事务的时候,需要注意两点:
1、首先需要在配置文件中声明那些需要启用新事务REQUIRES_NEW
2、调用方法和被调用需要开启新事务的方法不在同一个类中。(类中的A方法不能调用同类中B方法,即使B方法已经声明需要开启新事务)。
相关推荐
7. **事务管理**:EJB 3提供了一种声明式事务管理方式,通过`@TransactionAttribute`注解,开发者可以轻松控制事务的隔离级别、传播行为和回滚规则。 8. **安全性**:EJB 3集成了Java EE的安全模型,可以使用`@...
Fluent软件应用过程中的一些比较重要的说明摘记
软考信息系统管理师考试摘记。 项 目 管 理 知 识 体 系(九大管理) INPUT TOOL OUTPUT 4.1 制定项目章程 1、合同(如果适用) 1、项目选择方法 1、项目章程 2、项目工作说明书 2、项目管理方法系 3、事业环境...
以上摘录自《Effective C++》中的知识点涵盖了C++编程中的许多重要方面,从基础语法到高级特性均有涉及。通过学习这些最佳实践,开发者可以编写出更高效、更健壮、更容易维护的C++代码。这些规则和指导原则不仅适用...
《胡希恕伤寒论坛讲座》摘记.doc
自主研修摘记为我们提供了一系列策略,旨在实现这一目标,并且这些策略在教学实践中被证明是行之有效的。 首先,创设情境,激发兴趣是教师与学生接触的第一个环节,也是极为重要的一步。通过结合教材内容和学生心理...
《第5课网络摘记教学设计.doc》这一文档,正是针对这一需求,精心设计的一堂课程。这节课不仅仅是一次简单的信息技术教学,更是一次激发学生对航天科技兴趣,提高他们信息搜集、处理及科技学习能力的实践活动。 ...
"胡希恕伤寒论坛讲座摘记" 本文摘记了胡希恕伤寒论坛的讲座要点,总共十八点,涵盖了中医基础理论、方剂学、诊断学等多方面的知识点。 一、温病不能发汗,不能吃泻药,更不能用火攻,只能用白虎汤。 本点讲述了...
Codelife 不止代码 - 自阅读加注标签-技术规划的借鉴 有摘记和感想.md,提供了原文的详细目录大纲,更重要的是给出了自学摘记,记录下诸多感想。 人的学习进步体现在对抽象问题的概括和具体问题的有针对性的见解,...
### Hibrenate 学习摘记 #### Hibernate 概述与基本配置 Hibernate 是一个开源的对象关系映射(ORM)框架,它简化了 Java 应用程序与数据库之间的交互过程。通过将对象模型与数据库模型进行映射,开发人员可以更...
构建高性能Web站点涉及多个关键领域,包括服务器并发策略、动态内存缓存、动态脚本加速、浏览器缓存、Web服务器缓存以及反向代理缓存。这些策略的优化对于提升网站性能至关重要。 首先,服务器并发策略是提高Web...
- 分时系统:为了解决多道批处理系统的交互能力问题,分时系统允许多个用户通过终端以交互的方式使用计算机资源,实现了多路性、独立性、及时性、交互性等特性。 - 实时系统:系统能够及时响应外部事件的请求,在...
【高中政治有效课堂教学探究】 尊敬的各位领导,同行们,大家好!我今天要与大家分享的是我在高中政治教学中关于有效课堂教学的一些探索和心得。在农村高中环境下,面对学生素质、师资力量及教学设施的局限,如何...
在当今数字化浪潮的推动下,企业对于高效、用户导向和适应性强的B端产品需求日益增长。Facebook作为互联网界的巨头,在设计B端产品时所遵循的四项基本原则,不仅体现了对用户体验和效率的极致追求,也体现了对产品...
#### 二、UNIX系统特性 - **模块化设计**:UNIX系统的设计强调模块化,这意味着其功能组件可以独立地进行开发和维护,同时也便于系统的扩展和定制。 - **命令行界面**:尽管现代UNIX系统支持图形用户界面(GUI),但...
在新时代教育改革的浪潮中,各地学校积极响应国家教育政策,探索适合本地实际的教改之路。2021-2022年,自贡市绿盛实验学校作为改革的先锋,不仅在本地深入实践课堂教学改革,还远赴山东,向当地的名校学习先进的...
最近在编写 Grace PHP5 Framework 中,我得到很多类的实例化的心得。Grace PHP5 Framework 是一个完全基于 MVC 架构的框架,具有良好的扩展性。它对于类的调用可以说非常的灵活。
斯蒂芬·P·罗宾斯是全球知名的管理学权威,他的著作被广泛应用于商学院的教育和企业培训中。这份“斯蒂芬P罗宾斯管理学笔记”是一份宝贵的考研资料,它涵盖了管理学的核心概念、理论和实践,旨在帮助学生深入理解和...
通过独特的白色塑料杯设计,强调产品的“新鲜”特性,以此区别于竞品。 3. **品牌概念创建**:左岸咖啡馆的概念来源于法国塞纳河左岸的文化艺术氛围,目标消费者定位于17-22岁的年轻女性,她们对文学艺术有情感共鸣...