entitybean.html
来自「SUN公司官方J2EE中文帮助文档 应该不错 有兴趣的下来看看 html格式的」· HTML 代码 · 共 423 行 · 第 1/2 页
HTML
423 行
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Frameset//EN""http://www.w3.org/TR/REC-html40/frameset.dtd">
<!--NewPage-->
<HTML>
<HEAD>
<!-- Generated by javadoc on Thu Jan 17 03:51:30 PST 2002 -->
<TITLE>
Java 2 Platform EE v1.3: Interface EntityBean
</TITLE>
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../stylesheet.css" TITLE="Style">
</HEAD>
<BODY BGCOLOR="white">
<!-- ========== START OF NAVBAR ========== -->
<A NAME="navbar_top"><!-- --></A>
<TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0">
<TR>
<TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
<A NAME="navbar_top_firstrow"><!-- --></A>
<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3">
<TR ALIGN="center" VALIGN="top">
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A> </TD>
<TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> <FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A> </TD>
</TR>
</TABLE>
</TD>
<TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
</EM>
</TD>
</TR>
<TR>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
<A HREF="../../javax/ejb/EnterpriseBean.html"><B>PREV CLASS</B></A>
<A HREF="../../javax/ejb/EntityContext.html"><B>NEXT CLASS</B></A></FONT></TD>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
<A HREF="../../index.html" TARGET="_top"><B>FRAMES</B></A>
<A HREF="EntityBean.html" TARGET="_top"><B>NO FRAMES</B></A></FONT></TD>
</TR>
<TR>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
SUMMARY: INNER | FIELD | CONSTR | <A HREF="#method_summary">METHOD</A></FONT></TD>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
DETAIL: FIELD | CONSTR | <A HREF="#method_detail">METHOD</A></FONT></TD>
</TR>
</TABLE>
<!-- =========== END OF NAVBAR =========== -->
<HR>
<!-- ======== START OF CLASS DATA ======== -->
<H2>
<FONT SIZE="-1">
javax.ejb</FONT>
<BR>
Interface EntityBean</H2>
<DL>
<DT><B>All Superinterfaces:</B> <DD><A HREF="../../javax/ejb/EnterpriseBean.html">EnterpriseBean</A>, java.io.Serializable</DD>
</DL>
<HR>
<DL>
<DT>public interface <B>EntityBean</B><DT>extends <A HREF="../../javax/ejb/EnterpriseBean.html">EnterpriseBean</A></DL>
<P>
The EntityBean interface is implemented by every entity enterprise Bean
class. The container uses the EntityBean methods to notify the enterprise
Bean instances of the instance's life cycle events.
<P>
<HR>
<P>
<!-- ======== INNER CLASS SUMMARY ======== -->
<!-- =========== FIELD SUMMARY =========== -->
<!-- ======== CONSTRUCTOR SUMMARY ======== -->
<!-- ========== METHOD SUMMARY =========== -->
<A NAME="method_summary"><!-- --></A>
<TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TD COLSPAN=2><FONT SIZE="+2">
<B>Method Summary</B></FONT></TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../javax/ejb/EntityBean.html#ejbActivate()">ejbActivate</A></B>()</CODE>
<BR>
A container invokes this method when the instance
is taken out of the pool of available instances to become associated
with a specific EJB object.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../javax/ejb/EntityBean.html#ejbLoad()">ejbLoad</A></B>()</CODE>
<BR>
A container invokes this method to instruct the
instance to synchronize its state by loading it state from the
underlying database.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../javax/ejb/EntityBean.html#ejbPassivate()">ejbPassivate</A></B>()</CODE>
<BR>
A container invokes this method on an instance before the instance
becomes disassociated with a specific EJB object.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../javax/ejb/EntityBean.html#ejbRemove()">ejbRemove</A></B>()</CODE>
<BR>
A container invokes this method before it removes the EJB object
that is currently associated with the instance.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../javax/ejb/EntityBean.html#ejbStore()">ejbStore</A></B>()</CODE>
<BR>
A container invokes this method to instruct the
instance to synchronize its state by storing it to the underlying
database.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../javax/ejb/EntityBean.html#setEntityContext(javax.ejb.EntityContext)">setEntityContext</A></B>(<A HREF="../../javax/ejb/EntityContext.html">EntityContext</A> ctx)</CODE>
<BR>
Set the associated entity context.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../javax/ejb/EntityBean.html#unsetEntityContext()">unsetEntityContext</A></B>()</CODE>
<BR>
Unset the associated entity context.</TD>
</TR>
</TABLE>
<P>
<!-- ============ FIELD DETAIL =========== -->
<!-- ========= CONSTRUCTOR DETAIL ======== -->
<!-- ============ METHOD DETAIL ========== -->
<A NAME="method_detail"><!-- --></A>
<TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TD COLSPAN=1><FONT SIZE="+2">
<B>Method Detail</B></FONT></TD>
</TR>
</TABLE>
<A NAME="setEntityContext(javax.ejb.EntityContext)"><!-- --></A><H3>
setEntityContext</H3>
<PRE>
public void <B>setEntityContext</B>(<A HREF="../../javax/ejb/EntityContext.html">EntityContext</A> ctx)
throws <A HREF="../../javax/ejb/EJBException.html">EJBException</A>,
java.rmi.RemoteException</PRE>
<DL>
<DD>Set the associated entity context. The container invokes this method
on an instance after the instance has been created.
<p> This method is called in an unspecified transaction context.<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>ctx</CODE> - An EntityContext interface for the instance. The instance
should store the reference to the context in an instance variable.<DT><B>Throws:</B><DD><CODE><A HREF="../../javax/ejb/EJBException.html">EJBException</A></CODE> - Thrown by the method to indicate a failure
caused by a system-level error.<DD><CODE>java.rmi.RemoteException</CODE> - This exception is defined in the method
signature to provide backward compatibility for enterprise beans
written for the EJB 1.0 specification. Enterprise beans written
for the EJB 1.1 specification should throw the
javax.ejb.EJBException instead of this exception.
Enterprise beans written for the EJB2.0 and higher specifications
must throw the javax.ejb.EJBException instead of this exception.</DL>
</DD>
</DL>
<HR>
<A NAME="unsetEntityContext()"><!-- --></A><H3>
unsetEntityContext</H3>
<PRE>
public void <B>unsetEntityContext</B>()
throws <A HREF="../../javax/ejb/EJBException.html">EJBException</A>,
java.rmi.RemoteException</PRE>
<DL>
<DD>Unset the associated entity context. The container calls this method
before removing the instance.
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?