⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 package-summary.html

📁 ejb20_src_relationships.rar
💻 HTML
📖 第 1 页 / 共 2 页
字号:
  <dd><a href="ejb-jar.xml">ejb-jar.xml</a>
  <dd><a href="weblogic-ejb-jar.xml">weblogic-ejb-jar.xml</a>
  <dd><a href="weblogic-cmp-rdbms-jar.xml">weblogic-cmp-rdbms-jar.xml</a>

<p>
<li> Server (EJBean)
  <dd><a href="ArtistBean.java">ArtistBean.java</a>
  <dd><a href="BandBean.java">BandBean.java</a>
  <dd><a href="FanClubBean.java">FanClubBean.java</a>
  <dd><a href="MusicLibraryBean.java">MusicLibraryBean.java</a>
  <dd><a href="RecordingBean.java">RecordingBean.java</a>
  
</ul>

Start with the XML deployment files <a href="ejb-jar.xml">ejb-jar.xml</a>,  <a href="weblogic-ejb-jar.xml">weblogic-ejb-jar.xml</a> and <a href="weblogic-cmp-rdbms-jar.xml">weblogic-cmp-rdbms-jar.xml</a> to find the general
structure of the EJBean, which classes are used for the different
objects and interfaces, then look at <a href="Client.java">Client</a> code to see how the application works.

<p>
<h3>
Pre-Built Examples</h3>
<p>This EJB 2.0 example is not shipped pre-built. Before you can run this example, 
you must first create a table in Oracle, build the example following the instructions 
in <a href="#Build the example">Build the example</a>, and then run the example using the instructions below.

<p>
The following four sections cover what to do:

<p>
<ol>
  <li><a href="#Set up the database">Set up the database</a>
  <li><a href="#Build the example">Build the example</a>
  <li><a href="#Start the Examples server">Start the Examples server</a>
  <li><a href="#Run the example">Run the example</a>
</ol>

<h3><a name="Set up the database">Set up the database</a></h3>

This example is preconfigured to work with the PointBase database, included with the WebLogic Server distribution. As you'll use a database for the persistent storage of the entity EJBean, 
you'll need to set it up.
The persistent storage is completely invisible to the client;
the actual storage is handled by the EJBean directly and not the
container.
<p>
With database persistence, each instance of an EJBean is written to a
row in a table. If you want or need to run this example with Oracle, see <a href=../../../database_setup.html>Database SetUp</a> for instructions.

<p>
The following tables, created using the <font face="Courier New" size=-1>table.ddl </font>file supplied with this example's package must be created and exist in the database before you run example:

<ol>
<li>fanclubs
<li>recordings
<li>artists
<li>bands
<li>band_artist
<li>artist_sequence
</ol>

<p>
The persistent storage is completely invisible to the
client; the actual storage is handled automatically by the container
and not by the EJB.  

<h3><a name="Build the example">Build the example</a></h3>

Set up your development shell as described in 
<a href=../../../examples.html#environment>Setting up your environment</a>.

<p>
We provide a build script for you to build the example:

<p>The build script is <b><a href="build.xml">build.xml</a></b>.
<p>Run the build script using the following Java  ant command:
<pre>prompt&gt;<b> ant</b></pre>

<p>
The script builds the example and places the files in the
correct locations in your WebLogic Server distribution:
<ul>

<li>Client.jar file: in <font face="Courier New" size=-1>SAMPLES_HOME\server\examples\build\clientclasses</font>
<li>EJB (in EAR file): in <font face="Courier New" size=-1>SAMPLES_HOME\domains\examples\applications\ejb20_relationship_bands.ear</font>

</ul>

<p>
Running the build script places the EJB in the <font face="Courier New"
size=-1>%applications%</font> directory, where it automatically 
deploys once the server is started. If you are already running the server and then build 
the EJB, it is automatically placed in this directory and instantly deployed. 
<p>
Additional information on using the build scripts
is found in
<a href="../../../examples.html#buildScripts">More About Building Examples</a>.


<h3><a name="Start the Examples server">Start the Examples server</a></h3>

<ol>
<li><a href=../../../examples.html#startServer>Start the Examples server</a>.
<!-- Taking this out because the EJB deploys automatically when server starts; no need for manual deployment instructions
<p>
<li><a href=../../../examples.html#console  >
Start the Administration Console.</a>
<p>
<li>Click the Deployments node in the left pane and select EJB. 
<p>
A list of deployed EJBs displays in the left pane. 
<p>
<li>Choose the EJB that you want to deploy from the list of deployment units. 
<p>
<li>On the Edit EJB Descriptor page in the right pane, select the Targets tab.
<p>
<li> Verify that the EJB is deployed on the examplesServer. The examplesServer should be listed in the Chosen column.
 </li>
</ul>
-->
<p>
If you need more information about how to use connection pools, read
<a href="http://e-docs.bea.com/wls/docs81/jdbc/index.html"> Using
WebLogic JDBC: Using connection pools</a>.
</ol>

<h3><a name="Run the example"></a>Run the example</h3>

<p>
<ol>
<li>Run the client in a separate command line window. Set up your client as described in 
<a href=../../../examples.html#environment>Setting up your environment</a>,
and then run the client by entering:

 <pre>prompt&gt;<b> ant run </b> </pre>

<p>
<li>You should receive output similar to this:</ol>
<pre><font face="Courier New">Welcome to the Hipster Music Library...

Added these bands...
Band Name: Genesis Band Founder: Peter Gabriel startDate: 1969-12-31
Band Name: Beastie Boys Band Founder: Mike Diamond startDate: 1981-12-31
Band Name: Britney Spears Band Founder: Britney Spears startDate: 1997-12-31
Band Name: Seth's Saxophone All-Stars Band Founder: Saxophone Seth startDate: 19
98-11-12


Added these Recordings...
Recording: Title: Duke Band: Genesis Recording Date: 1982-03-05
Recording: Title: Invisible Touch Band: Genesis Recording Date: 1985-03-05
Recording: Title: Sounds of Science Band: Beastie Boys Recording Date: 1997-03-0
5
Recording: Title: Licensed To Ill Band: Beastie Boys Recording Date: 1990-03-05
Recording: Title: Paul's Boutique Band: Beastie Boys Recording Date: 1989-03-05
Recording: Title: Britney's First Album Band: Britney Spears Recording Date: 19
99-03-05
Recording: Title: Saxophone Seth Plays the Blues Band: Seth's Saxophone All-Star
s Recording Date: 2001-03-23



Printing out Fan-Club Write-Up for each Band
Write-up for band: Genesis is: Genesis Fan Club
Write-up for band: Beastie Boys is: Beastie Boys Fan Club
Write-up for band: Britney Spears is: Britney Spears Fan Club
Write-up for band: Seth's Saxophone All-Stars is: Seth's Saxophone All-Stars Fan
 Club

Good bye...
</font></pre>

</ol>

<h2>There's more...</h2

<p>
Read more about:
<ul>
<li>EJB in the 
<a href="http://e-docs.bea.com/wls/docs81/ejb/index.html">BEA WebLogic Server Enterprise Java Beans</a>
</ul>
<P>

<P>
<HR>

<!-- ========== START OF NAVBAR ========== -->
<A NAME="navbar_bottom"><!-- --></A>
<TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0">
<TR>
<TD COLSPAN=3 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
<A NAME="navbar_bottom_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>&nbsp;</TD>
  <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Package</B></FONT>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <FONT CLASS="NavBarFont1">Class</FONT>&nbsp;</TD>
  </TR>
</TABLE>
</TD>
<TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
</td><td valign=bottom align=right>Documentation is available at<br> <a href=http://e-docs.bea.com/wls/docs81>http://e-docs.bea.com/wls/docs81</a></td></EM>
</TD>
</TR>

<TR>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
&nbsp;<A HREF="../../../../examples/ejb20/message/package-summary.html"><B>PREV PACKAGE</B></A>&nbsp;
&nbsp;<A HREF="../../../../examples/ejb20/sequence/userDesignated/package-summary.html"><B>NEXT PACKAGE</B></A></FONT></TD>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
  <A HREF="../../../../index.html" TARGET="_top"><B>FRAMES</B></A>  &nbsp;
&nbsp;<A HREF="package-summary.html" TARGET="_top"><B>NO FRAMES</B></A>  &nbsp;
&nbsp;
<SCRIPT>
  <!--
  if(window==top) {
    document.writeln('<A HREF="../../../../allclasses-noframe.html" TARGET=""><B>All Classes</B></A>');
  }
  //-->
</SCRIPT>
<NOSCRIPT>
<A HREF="../../../../allclasses-noframe.html" TARGET=""><B>All Classes</B></A>
</NOSCRIPT>
</FONT></TD>
</TR>
</TABLE>
<!-- =========== END OF NAVBAR =========== -->

<HR>
<a href=http://e-docs.bea.com/wls/docs81/copyright.html>Copyright</a> &copy; 2003 BEA Systems, Inc. All Rights Reserved.
</BODY>
</HTML>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -