浏览 2552 次
锁定老帖子 主题:seam 组件的默认作用域
该帖已经被评为新手帖
|
|
---|---|
作者 | 正文 |
发表时间:2008-06-16
有状态Session Bean : Conversation Context。它们绝不会绑定到page 或stateless context Entity Bean : Conversation Context JavaBeans : Event Context 消息驱动Bean : 不能被绑定到Seam上下文 声明:ITeye文章版权属于作者,受法律保护。没有作者书面许可不得转载。
推荐链接
|
|
返回顶楼 | |
发表时间:2008-06-16
Entity Bean默认绑定到了Conversation Context ?
|
|
返回顶楼 | |
发表时间:2008-06-17
无语...
请不要把EJB的组件和Seam的JSF组件混为一谈,EJB是个规范,不是由SEAM来决定它的生命周期的 |
|
返回顶楼 | |
发表时间:2008-06-17
无语...
请不要把EJB的组件和Seam的JSF组件混为一谈,EJB是个规范,不是由SEAM来决定它的生命周期的 seam 属于扩展ejb应用,将ejb内容无缝的粘合到整个应用框架。 seam的思想将来会成为标准的j2ee web beans实现 |
|
返回顶楼 | |
发表时间:2008-06-17
hantsy 19 小时前 Entity Bean默认绑定到了Conversation Context ? 我查过官方手册了,Entity Bean确实是默认绑定到了Conversation Context。 下面的原文: 4.2.3. Entity beans Entity beans may be bound to a context variable and function as a seam component. Because entities have a persistent identity in addition to their contextual identity, entity instances are usually bound explicitly in Java code, rather than being instantiated implicitly by Seam. Entity bean components do not support bijection or context demarcation. Nor does invocation of an entity bean trigger validation. Entity beans are not usually used as JSF action listeners, but do often function as backing beans that provide properties to JSF components for display or form submission. In particular, it is common to use an entity as a backing bean, together with a stateless session bean action listener to implement create/update/delete type functionality. By default, entity beans are bound to the conversation context. They may never be bound to the stateless context. Note that it in a clustered environment is somewhat less efficient to bind an entity bean directly to a conversation or session scoped Seam context variable than it would be to hold a reference to the entity bean in a stateful session bean. For this reason, not all Seam applications define entity beans to be Seam components. Seam entity bean components may be instantiated using Component.getInstance(), @In(create=true) or directly using the new operator. |
|
返回顶楼 | |