javax.ejb.MessageDrivenBean翻译

<!-- ========= START OF TOP NAVBAR ======= --> <!-- -->
JavaTM 2 Platform
Ent. Ed. v1.4
<!-- ========= END OF TOP NAVBAR ========= -->
<!-- ======== START OF CLASS DATA ======== -->

javax.ejb
Interface MessageDrivenBean

All Superinterfaces:
EnterpriseBean, Serializable

public interface MessageDrivenBean
extends EnterpriseBean

The MessageDrivenBean interface is implemented by every message-driven enterprise Bean class. The container uses the MessageDrivenBean methods to notify the enterprise Bean instances of the instance's life cycle events. 每一个消息驱动企业Bean的类都应该实现MessageDrivenBean接口。容器使用MessageDrivenBean的方法 将实例的生命周期事件通知企业Bean。


<!-- ======== NESTED CLASS SUMMARY ======== --><!-- =========== FIELD SUMMARY =========== --><!-- ======== CONSTRUCTOR SUMMARY ======== --><!-- ========== METHOD SUMMARY =========== --><!-- -->

Method Summary
void ejbRemove()
A container invokes this method before it ends the life of the message-driven object. 容器调用该方法来终止消息驱动bean对象。
void setMessageDrivenContext(MessageDrivenContextctx)
Set the associated message-driven context. 设置关联的消息驱动bean上下文。

<!-- ============ FIELD DETAIL =========== --><!-- ========= CONSTRUCTOR DETAIL ======== --><!-- ============ METHOD DETAIL ========== --><!-- -->

Method Detail
<!-- -->

setMessageDrivenContext

public void setMessageDrivenContext(MessageDrivenContextctx)
                             throws EJBException
Set the associated message-driven context. The container calls this method after the instance creation. 设置关联的消息驱动bean上下文。容器在实例创建后调用该方法。

The enterprise Bean instance should store the reference to the context object in an instance variable. 企业Bean实例应当在实例变量中保存上下文对象的引用。

This method is called with no transaction context. 方法调用不含事务上下文。

Parameters:
ctx - A MessageDrivenContext interface for the instance. 实例的MessageDrivenContext接口。
Throws:
EJBException - Thrown by the method to indicate a failure caused by a system-level error. 方法抛出该异常表示一个由系统级错误引起的失败。

<!-- -->

ejbRemove

public void ejbRemove()
               throws EJBException
A container invokes this method before it ends the life of the message-driven object. This happens when a container decides to terminate the message-driven object. 容器调用该方法来终止消息驱动bean对象。当容器决定终止消息驱动bean时发生。

This method is called with no transaction context. 方法调用不含事务上下文。

Throws:
EJBException - Thrown by the method to indicate a failure caused by a system-level error. 方法抛出该异常表示一个由系统级错误引起的失败。
<!-- ========= END OF CLASS DATA ========= -->
<!-- ======= START OF BOTTOM NAVBAR ====== --> <!-- -->
JavaTM 2 Platform
Ent. Ed. v1.4
<!-- ======== END OF BOTTOM NAVBAR ======= -->
Submit a bug or feature

Copyright 2003 Sun Microsystems, Inc. All rights reserved.

你可能感兴趣的:(html,bean,ejb,sun)