ws-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From d...@apache.org
Subject cvs commit: ws-site/targets/ews/xref/org/apache/geronimo/ews/ws4j2ee/module AbstractModule.html DirModule.html EARModule.html JarModule.html Module.html ModuleFactory.html package-frame.html package-summary.html WARModule.html
Date Wed, 10 Nov 2004 19:49:16 GMT
dims        2004/11/10 11:49:16

  Added:       targets/ews/xref/org/apache/geronimo/ews/ws4j2ee/module
                        AbstractModule.html DirModule.html EARModule.html
                        JarModule.html Module.html ModuleFactory.html
                        package-frame.html package-summary.html
                        WARModule.html
  Log:
  Adding a web site for EWS
  
  Revision  Changes    Path
  1.1                  ws-site/targets/ews/xref/org/apache/geronimo/ews/ws4j2ee/module/AbstractModule.html
  
  Index: AbstractModule.html
  ===================================================================
  <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
  <head>
  <meta http-equiv="content-type" content="text/html; charset=ISO-8859-1" /><title>AbstractModule xref</title>
  <link type="text/css" rel="stylesheet" href="../../../../../../stylesheet.css" />
  </head>
  <body>
  <div id="overview"><a href="../../../../../../../apidocs/org/apache/geronimo/ews/ws4j2ee/module/AbstractModule.html">View Javadoc</a></div><pre>
  
  <a name="1" href="#1">1</a>   <em class="comment">/*</em>
  <a name="2" href="#2">2</a>   <em class="comment"> * Copyright 2001-2004 The Apache Software Foundation.</em>
  <a name="3" href="#3">3</a>   <em class="comment"> * </em>
  <a name="4" href="#4">4</a>   <em class="comment"> * Licensed under the Apache License, Version 2.0 (the "License");</em>
  <a name="5" href="#5">5</a>   <em class="comment"> * you may not use this file except in compliance with the License.</em>
  <a name="6" href="#6">6</a>   <em class="comment"> * You may obtain a copy of the License at</em>
  <a name="7" href="#7">7</a>   <em class="comment"> * </em>
  <a name="8" href="#8">8</a>   <em class="comment"> *      <a href="http://www.apache.org/licenses/LICENSE-2.0" target="alexandria_uri">http://www.apache.org/licenses/LICENSE-2.0</a></em>
  <a name="9" href="#9">9</a>   <em class="comment"> * </em>
  <a name="10" href="#10">10</a>  <em class="comment"> * Unless required by applicable law or agreed to in writing, software</em>
  <a name="11" href="#11">11</a>  <em class="comment"> * distributed under the License is distributed on an "AS IS" BASIS,</em>
  <a name="12" href="#12">12</a>  <em class="comment"> * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.</em>
  <a name="13" href="#13">13</a>  <em class="comment"> * See the License for the specific language governing permissions and</em>
  <a name="14" href="#14">14</a>  <em class="comment"> * limitations under the License.</em>
  <a name="15" href="#15">15</a>  <em class="comment"> */</em>
  <a name="16" href="#16">16</a>  
  <a name="17" href="#17">17</a>  <strong>package</strong> <a href="../../../../../../org/apache/geronimo/ews/ws4j2ee/module/package-summary.html">org.apache.geronimo.ews.ws4j2ee.module</a>;
  <a name="18" href="#18">18</a>  
  <a name="19" href="#19">19</a>  <strong>import</strong> org.apache.geronimo.ews.ws4j2ee.toWs.GenerationFault;
  <a name="20" href="#20">20</a>  
  <a name="21" href="#21">21</a>  <strong>import</strong> java.io.IOException;
  <a name="22" href="#22">22</a>  <strong>import</strong> java.io.InputStream;
  <a name="23" href="#23">23</a>  <strong>import</strong> java.util.jar.JarFile;
  <a name="24" href="#24">24</a>  <strong>import</strong> java.util.zip.ZipEntry;
  <a name="25" href="#25">25</a>  <strong>import</strong> java.util.zip.ZipFile;
  <a name="26" href="#26">26</a>  
  <a name="27" href="#27">27</a>  <em>/**<em>*</em></em>
  <a name="28" href="#28">28</a>  <em> * @author Srinath Perera(hemapani@opensource.lk)</em>
  <a name="29" href="#29">29</a>  <em> */</em>
  <a name="30" href="#30">30</a>  <strong>public</strong> <strong>abstract</strong> <strong>class</strong> <a href="../../../../../../org/apache/geronimo/ews/ws4j2ee/module/AbstractModule.html">AbstractModule</a> implements <a href="../../../../../../org/apache/geronimo/ews/ws4j2ee/module/Module.html">Module</a> {
  <a name="31" href="#31">31</a>      <strong>protected</strong> InputStream wscfFile;
  <a name="32" href="#32">32</a>      <strong>protected</strong> InputStream webddfile;
  <a name="33" href="#33">33</a>      <strong>protected</strong> InputStream ejbJarfile;
  <a name="34" href="#34">34</a>      <strong>protected</strong> InputStream wsdlfile;
  <a name="35" href="#35">35</a>      <strong>protected</strong> InputStream jaxrpcfile;
  <a name="36" href="#36">36</a>      <strong>protected</strong> ZipFile zip;
  <a name="37" href="#37">37</a>      <strong>protected</strong> ClassLoader parentCL;
  <a name="38" href="#38">38</a>  
  <a name="39" href="#39">39</a>      <strong>public</strong> <a href="../../../../../../org/apache/geronimo/ews/ws4j2ee/module/AbstractModule.html">AbstractModule</a>(String jarFile, ClassLoader parentCL) throws GenerationFault {
  <a name="40" href="#40">40</a>          <strong>try</strong> {
  <a name="41" href="#41">41</a>              <strong>this</strong>.parentCL = parentCL;
  <a name="42" href="#42">42</a>              zip = <strong>new</strong> JarFile(jarFile);
  <a name="43" href="#43">43</a>          } <strong>catch</strong> (IOException e) {
  <a name="44" href="#44">44</a>              e.printStackTrace();
  <a name="45" href="#45">45</a>              <strong>throw</strong> GenerationFault.createGenerationFault(e);
  <a name="46" href="#46">46</a>          }
  <a name="47" href="#47">47</a>      }
  <a name="48" href="#48">48</a>  
  <a name="49" href="#49">49</a>      <strong>public</strong> InputStream getInputStreamForJarEntry(String path)
  <a name="50" href="#50">50</a>              throws <a href="../../../../../../org/apache/geronimo/ews/ws4j2ee/toWs/GenerationFault.html">GenerationFault</a> {
  <a name="51" href="#51">51</a>          <strong>try</strong> {
  <a name="52" href="#52">52</a>              ZipEntry zentry = zip.getEntry(path);
  <a name="53" href="#53">53</a>              <strong>if</strong> (zentry != <strong>null</strong>) {
  <a name="54" href="#54">54</a>                  <strong>return</strong> zip.getInputStream(zentry);
  <a name="55" href="#55">55</a>              } <strong>else</strong> {
  <a name="56" href="#56">56</a>                  <strong>return</strong> <strong>null</strong>;
  <a name="57" href="#57">57</a>              }
  <a name="58" href="#58">58</a>          } <strong>catch</strong> (IOException e) {
  <a name="59" href="#59">59</a>              e.printStackTrace();
  <a name="60" href="#60">60</a>              <strong>throw</strong> GenerationFault.createGenerationFault(e);
  <a name="61" href="#61">61</a>          }
  <a name="62" href="#62">62</a>      }
  <a name="63" href="#63">63</a>  
  <a name="64" href="#64">64</a>      <strong>public</strong> InputStream getInputStreamForJarEntry(String jarFile, String path)
  <a name="65" href="#65">65</a>              throws <a href="../../../../../../org/apache/geronimo/ews/ws4j2ee/toWs/GenerationFault.html">GenerationFault</a> {
  <a name="66" href="#66">66</a>          <strong>try</strong> {
  <a name="67" href="#67">67</a>              ZipEntry zentry = zip.getEntry(path);
  <a name="68" href="#68">68</a>              <strong>if</strong> (zentry != <strong>null</strong>) {
  <a name="69" href="#69">69</a>                  <strong>return</strong> zip.getInputStream(zentry);
  <a name="70" href="#70">70</a>              } <strong>else</strong> {
  <a name="71" href="#71">71</a>                  <strong>return</strong> <strong>null</strong>;
  <a name="72" href="#72">72</a>              }
  <a name="73" href="#73">73</a>          } <strong>catch</strong> (IOException e) {
  <a name="74" href="#74">74</a>              e.printStackTrace();
  <a name="75" href="#75">75</a>              <strong>throw</strong> GenerationFault.createGenerationFault(e);
  <a name="76" href="#76">76</a>          }
  <a name="77" href="#77">77</a>      }
  <a name="78" href="#78">78</a>  
  <a name="79" href="#79">79</a>      <strong>public</strong> <strong>void</strong> loadtheClassesInJarFile() throws GenerationFault {
  <a name="80" href="#80">80</a>      }
  <a name="81" href="#81">81</a>  
  <a name="82" href="#82">82</a>      <em>/**<em>*</em></em>
  <a name="83" href="#83">83</a>  <em>     * @return</em>
  <a name="84" href="#84">84</a>  <em>     */</em>
  <a name="85" href="#85">85</a>      <strong>public</strong> InputStream getEjbJarfile() {
  <a name="86" href="#86">86</a>          <strong>return</strong> ejbJarfile;
  <a name="87" href="#87">87</a>      }
  <a name="88" href="#88">88</a>  
  <a name="89" href="#89">89</a>      <em>/**<em>*</em></em>
  <a name="90" href="#90">90</a>  <em>     * @return</em>
  <a name="91" href="#91">91</a>  <em>     */</em>
  <a name="92" href="#92">92</a>      <strong>public</strong> InputStream getWebddfile() {
  <a name="93" href="#93">93</a>          <strong>return</strong> webddfile;
  <a name="94" href="#94">94</a>      }
  <a name="95" href="#95">95</a>  
  <a name="96" href="#96">96</a>      <em>/**<em>*</em></em>
  <a name="97" href="#97">97</a>  <em>     * @return</em>
  <a name="98" href="#98">98</a>  <em>     */</em>
  <a name="99" href="#99">99</a>      <strong>public</strong> InputStream getWscfFile() {
  <a name="100" href="#100">100</a>         <strong>return</strong> wscfFile;
  <a name="101" href="#101">101</a>     }
  <a name="102" href="#102">102</a> 
  <a name="103" href="#103">103</a>     <em>/**<em>*</em></em>
  <a name="104" href="#104">104</a> <em>     * @param stream</em>
  <a name="105" href="#105">105</a> <em>     */</em>
  <a name="106" href="#106">106</a>     <strong>public</strong> <strong>void</strong> setEjbJarfile(InputStream stream) {
  <a name="107" href="#107">107</a>         ejbJarfile = stream;
  <a name="108" href="#108">108</a>     }
  <a name="109" href="#109">109</a> 
  <a name="110" href="#110">110</a>     <em>/**<em>*</em></em>
  <a name="111" href="#111">111</a> <em>     * @param stream</em>
  <a name="112" href="#112">112</a> <em>     */</em>
  <a name="113" href="#113">113</a>     <strong>public</strong> <strong>void</strong> setWebddfile(InputStream stream) {
  <a name="114" href="#114">114</a>         webddfile = stream;
  <a name="115" href="#115">115</a>     }
  <a name="116" href="#116">116</a> 
  <a name="117" href="#117">117</a>     <em>/**<em>*</em></em>
  <a name="118" href="#118">118</a> <em>     * @param stream</em>
  <a name="119" href="#119">119</a> <em>     */</em>
  <a name="120" href="#120">120</a>     <strong>public</strong> <strong>void</strong> setWscfFile(InputStream stream) {
  <a name="121" href="#121">121</a>         wscfFile = stream;
  <a name="122" href="#122">122</a>     }
  <a name="123" href="#123">123</a> 
  <a name="124" href="#124">124</a>     <strong>public</strong> InputStream findFileInModule(String path) throws GenerationFault {
  <a name="125" href="#125">125</a>         <strong>return</strong> getInputStreamForJarEntry(path);
  <a name="126" href="#126">126</a>     }
  <a name="127" href="#127">127</a> 
  <a name="128" href="#128">128</a> }
  </pre>
  <hr/><div id="footer">This page was automatically generated by <a href="http://maven.apache.org/">Maven</a></div></body>
  </html>
  
  
  
  
  1.1                  ws-site/targets/ews/xref/org/apache/geronimo/ews/ws4j2ee/module/DirModule.html
  
  Index: DirModule.html
  ===================================================================
  <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
  <head>
  <meta http-equiv="content-type" content="text/html; charset=ISO-8859-1" /><title>DirModule xref</title>
  <link type="text/css" rel="stylesheet" href="../../../../../../stylesheet.css" />
  </head>
  <body>
  <div id="overview"><a href="../../../../../../../apidocs/org/apache/geronimo/ews/ws4j2ee/module/DirModule.html">View Javadoc</a></div><pre>
  
  <a name="1" href="#1">1</a>   <em class="comment">/*</em>
  <a name="2" href="#2">2</a>   <em class="comment"> * Copyright 2001-2004 The Apache Software Foundation.</em>
  <a name="3" href="#3">3</a>   <em class="comment"> * </em>
  <a name="4" href="#4">4</a>   <em class="comment"> * Licensed under the Apache License, Version 2.0 (the "License");</em>
  <a name="5" href="#5">5</a>   <em class="comment"> * you may not use this file except in compliance with the License.</em>
  <a name="6" href="#6">6</a>   <em class="comment"> * You may obtain a copy of the License at</em>
  <a name="7" href="#7">7</a>   <em class="comment"> * </em>
  <a name="8" href="#8">8</a>   <em class="comment"> *      <a href="http://www.apache.org/licenses/LICENSE-2.0" target="alexandria_uri">http://www.apache.org/licenses/LICENSE-2.0</a></em>
  <a name="9" href="#9">9</a>   <em class="comment"> * </em>
  <a name="10" href="#10">10</a>  <em class="comment"> * Unless required by applicable law or agreed to in writing, software</em>
  <a name="11" href="#11">11</a>  <em class="comment"> * distributed under the License is distributed on an "AS IS" BASIS,</em>
  <a name="12" href="#12">12</a>  <em class="comment"> * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.</em>
  <a name="13" href="#13">13</a>  <em class="comment"> * See the License for the specific language governing permissions and</em>
  <a name="14" href="#14">14</a>  <em class="comment"> * limitations under the License.</em>
  <a name="15" href="#15">15</a>  <em class="comment"> */</em>
  <a name="16" href="#16">16</a>  
  <a name="17" href="#17">17</a>  <strong>package</strong> <a href="../../../../../../org/apache/geronimo/ews/ws4j2ee/module/package-summary.html">org.apache.geronimo.ews.ws4j2ee.module</a>;
  <a name="18" href="#18">18</a>  
  <a name="19" href="#19">19</a>  <strong>import</strong> org.apache.geronimo.ews.ws4j2ee.toWs.GenerationFault;
  <a name="20" href="#20">20</a>  
  <a name="21" href="#21">21</a>  <strong>import</strong> java.io.File;
  <a name="22" href="#22">22</a>  <strong>import</strong> java.io.FileInputStream;
  <a name="23" href="#23">23</a>  <strong>import</strong> java.io.FileNotFoundException;
  <a name="24" href="#24">24</a>  <strong>import</strong> java.io.InputStream;
  <a name="25" href="#25">25</a>  <strong>import</strong> java.net.MalformedURLException;
  <a name="26" href="#26">26</a>  <strong>import</strong> java.net.URL;
  <a name="27" href="#27">27</a>  <strong>import</strong> java.net.URLClassLoader;
  <a name="28" href="#28">28</a>  <strong>import</strong> java.util.ArrayList;
  <a name="29" href="#29">29</a>  
  <a name="30" href="#30">30</a>  <em>/**<em>*</em></em>
  <a name="31" href="#31">31</a>  <em> * @author Srinath Perera(hemapani@opensource.lk)</em>
  <a name="32" href="#32">32</a>  <em> */</em>
  <a name="33" href="#33">33</a>  <strong>public</strong> <strong>class</strong> <a href="../../../../../../org/apache/geronimo/ews/ws4j2ee/module/DirModule.html">DirModule</a> implements <a href="../../../../../../org/apache/geronimo/ews/ws4j2ee/module/Module.html">Module</a> {
  <a name="34" href="#34">34</a>      <strong>protected</strong> InputStream wscfFile;
  <a name="35" href="#35">35</a>      <strong>protected</strong> InputStream webddfile;
  <a name="36" href="#36">36</a>      <strong>protected</strong> InputStream ejbJarfile;
  <a name="37" href="#37">37</a>      <strong>private</strong> String location;
  <a name="38" href="#38">38</a>      <strong>private</strong> ClassLoader parentCL;
  <a name="39" href="#39">39</a>  
  <a name="40" href="#40">40</a>      <em>/**<em>*</em></em>
  <a name="41" href="#41">41</a>  <em>     * @param jarFile</em>
  <a name="42" href="#42">42</a>  <em>     * @throws GenerationFault</em>
  <a name="43" href="#43">43</a>  <em>     */</em>
  <a name="44" href="#44">44</a>      <strong>public</strong> <a href="../../../../../../org/apache/geronimo/ews/ws4j2ee/module/DirModule.html">DirModule</a>(String location, ClassLoader parentCL)
  <a name="45" href="#45">45</a>              throws <a href="../../../../../../org/apache/geronimo/ews/ws4j2ee/toWs/GenerationFault.html">GenerationFault</a> {
  <a name="46" href="#46">46</a>          File file = <strong>null</strong>;
  <a name="47" href="#47">47</a>          <strong>this</strong>.parentCL = parentCL;
  <a name="48" href="#48">48</a>          <strong>this</strong>.location = location;
  <a name="49" href="#49">49</a>          <strong>try</strong> {
  <a name="50" href="#50">50</a>              file = <strong>new</strong> File(location + <span class="string">"/WEB-INF/webservices.xml"</span>);
  <a name="51" href="#51">51</a>              <strong>if</strong> (file.exists()) {
  <a name="52" href="#52">52</a>                  wscfFile = <strong>new</strong> FileInputStream(file);
  <a name="53" href="#53">53</a>              } <strong>else</strong> {
  <a name="54" href="#54">54</a>                  file = <strong>new</strong> File(location + <span class="string">"/META-INF/webservices.xml"</span>);
  <a name="55" href="#55">55</a>                  <strong>if</strong> (file.exists()) {
  <a name="56" href="#56">56</a>                      wscfFile = <strong>new</strong> FileInputStream(file);
  <a name="57" href="#57">57</a>                  } <strong>else</strong> {
  <a name="58" href="#58">58</a>                      wscfFile = <strong>new</strong> FileInputStream(<strong>new</strong> File(location + <span class="string">"/webservices.xml"</span>));
  <a name="59" href="#59">59</a>                  }
  <a name="60" href="#60">60</a>              }
  <a name="61" href="#61">61</a>              findDDs();
  <a name="62" href="#62">62</a>          } <strong>catch</strong> (FileNotFoundException e) {
  <a name="63" href="#63">63</a>              e.printStackTrace();
  <a name="64" href="#64">64</a>              <strong>throw</strong> GenerationFault.createGenerationFault(e);
  <a name="65" href="#65">65</a>          }
  <a name="66" href="#66">66</a>      }
  <a name="67" href="#67">67</a>  
  <a name="68" href="#68">68</a>      <em>/**<em>*</em></em>
  <a name="69" href="#69">69</a>  <em>     * @param jarFile</em>
  <a name="70" href="#70">70</a>  <em>     * @throws GenerationFault</em>
  <a name="71" href="#71">71</a>  <em>     */</em>
  <a name="72" href="#72">72</a>      <strong>public</strong> <a href="../../../../../../org/apache/geronimo/ews/ws4j2ee/module/DirModule.html">DirModule</a>(File wscfDDFile)
  <a name="73" href="#73">73</a>              throws <a href="../../../../../../org/apache/geronimo/ews/ws4j2ee/toWs/GenerationFault.html">GenerationFault</a> {
  <a name="74" href="#74">74</a>          <strong>try</strong> {
  <a name="75" href="#75">75</a>              wscfFile = <strong>new</strong> FileInputStream(wscfDDFile);
  <a name="76" href="#76">76</a>              File parent = wscfDDFile.getParentFile();
  <a name="77" href="#77">77</a>              String parentName = parent.getAbsolutePath();
  <a name="78" href="#78">78</a>              <strong>if</strong> (parentName.endsWith(<span class="string">"WEB-INF"</span>)
  <a name="79" href="#79">79</a>                      || parentName.endsWith(<span class="string">"WEB-INF/"</span>)
  <a name="80" href="#80">80</a>                      || parentName.endsWith(<span class="string">"WEB-INF"</span>)
  <a name="81" href="#81">81</a>                      || parentName.endsWith(<span class="string">"META-INF/"</span>)) {
  <a name="82" href="#82">82</a>                  <strong>this</strong>.location = parent.getParentFile().getAbsolutePath();
  <a name="83" href="#83">83</a>              } <strong>else</strong> {
  <a name="84" href="#84">84</a>                  <strong>this</strong>.location = parent.getAbsolutePath();
  <a name="85" href="#85">85</a>              }
  <a name="86" href="#86">86</a>              findDDs();
  <a name="87" href="#87">87</a>          } <strong>catch</strong> (FileNotFoundException e) {
  <a name="88" href="#88">88</a>              e.printStackTrace();
  <a name="89" href="#89">89</a>              <strong>throw</strong> GenerationFault.createGenerationFault(e);
  <a name="90" href="#90">90</a>          }
  <a name="91" href="#91">91</a>      }
  <a name="92" href="#92">92</a>  
  <a name="93" href="#93">93</a>      <strong>public</strong> <strong>void</strong> findDDs() throws GenerationFault {
  <a name="94" href="#94">94</a>          <strong>try</strong> {
  <a name="95" href="#95">95</a>              File file = <strong>new</strong> File(location + <span class="string">"/META-INF/ejb-jar.xml"</span>);
  <a name="96" href="#96">96</a>              <strong>if</strong> (file.exists()) {
  <a name="97" href="#97">97</a>                  ejbJarfile = <strong>new</strong> FileInputStream(file);
  <a name="98" href="#98">98</a>              } <strong>else</strong> {
  <a name="99" href="#99">99</a>                  file = <strong>new</strong> File(location + <span class="string">"/ejb-jar.xml"</span>);
  <a name="100" href="#100">100</a>                 <strong>if</strong> (file.exists()) {
  <a name="101" href="#101">101</a>                     ejbJarfile = <strong>new</strong> FileInputStream(file);
  <a name="102" href="#102">102</a>                 }
  <a name="103" href="#103">103</a>             }
  <a name="104" href="#104">104</a>             file = <strong>new</strong> File(location + <span class="string">"WEB-INF/web.xml"</span>);
  <a name="105" href="#105">105</a>             <strong>if</strong> (file.exists()) {
  <a name="106" href="#106">106</a>                 webddfile = <strong>new</strong> FileInputStream(file);
  <a name="107" href="#107">107</a>             } <strong>else</strong> {
  <a name="108" href="#108">108</a>                 file = <strong>new</strong> File(location + <span class="string">"/web.xml"</span>);
  <a name="109" href="#109">109</a>                 <strong>if</strong> (file.exists()) {
  <a name="110" href="#110">110</a>                     webddfile = <strong>new</strong> FileInputStream(file);
  <a name="111" href="#111">111</a>                 }
  <a name="112" href="#112">112</a>             }
  <a name="113" href="#113">113</a>             <strong>if</strong> (wscfFile == <strong>null</strong>)
  <a name="114" href="#114">114</a>                 <strong>throw</strong> <strong>new</strong> <a href="../../../../../../org/apache/geronimo/ews/ws4j2ee/toWs/GenerationFault.html">GenerationFault</a>(<span class="string">"wscf file must not be null"</span>);
  <a name="115" href="#115">115</a>         } <strong>catch</strong> (FileNotFoundException e) {
  <a name="116" href="#116">116</a>             e.printStackTrace();
  <a name="117" href="#117">117</a>             <strong>throw</strong> GenerationFault.createGenerationFault(e);
  <a name="118" href="#118">118</a>         }
  <a name="119" href="#119">119</a>     }
  <a name="120" href="#120">120</a> 
  <a name="121" href="#121">121</a>     <strong>public</strong> ClassLoader getClassLoaderWithPackageLoaded() throws GenerationFault {
  <a name="122" href="#122">122</a>         <strong>try</strong> {
  <a name="123" href="#123">123</a>             File file = <strong>new</strong> File(location);
  <a name="124" href="#124">124</a>             <strong>return</strong> <strong>new</strong> URLClassLoader(<strong>new</strong> URL[]{file.toURL()}, parentCL);
  <a name="125" href="#125">125</a>         } <strong>catch</strong> (MalformedURLException e) {
  <a name="126" href="#126">126</a>             e.printStackTrace();
  <a name="127" href="#127">127</a>             <strong>throw</strong> GenerationFault.createGenerationFault(e);
  <a name="128" href="#128">128</a>         }
  <a name="129" href="#129">129</a>     }
  <a name="130" href="#130">130</a> 
  <a name="131" href="#131">131</a>     <strong>public</strong> ArrayList getClassPathElements() throws GenerationFault {
  <a name="132" href="#132">132</a>         ArrayList elements = <strong>new</strong> ArrayList();
  <a name="133" href="#133">133</a>         elements.add(<strong>new</strong> File(location));
  <a name="134" href="#134">134</a>         <strong>return</strong> elements;
  <a name="135" href="#135">135</a>     }
  <a name="136" href="#136">136</a> 
  <a name="137" href="#137">137</a>     <strong>public</strong> InputStream getEjbJarfile() throws GenerationFault {
  <a name="138" href="#138">138</a>         <strong>return</strong> ejbJarfile;
  <a name="139" href="#139">139</a>     }
  <a name="140" href="#140">140</a> 
  <a name="141" href="#141">141</a>     <strong>public</strong> InputStream getWebddfile() throws GenerationFault {
  <a name="142" href="#142">142</a>         <strong>return</strong> webddfile;
  <a name="143" href="#143">143</a>     }
  <a name="144" href="#144">144</a> 
  <a name="145" href="#145">145</a>     <strong>public</strong> InputStream getWscfFile() throws GenerationFault {
  <a name="146" href="#146">146</a>         <strong>return</strong> wscfFile;
  <a name="147" href="#147">147</a>     }
  <a name="148" href="#148">148</a> 
  <a name="149" href="#149">149</a>     <strong>public</strong> <strong>void</strong> setEjbJarfile(InputStream stream) throws GenerationFault {
  <a name="150" href="#150">150</a>         <strong>this</strong>.ejbJarfile = stream;
  <a name="151" href="#151">151</a>     }
  <a name="152" href="#152">152</a> 
  <a name="153" href="#153">153</a>     <strong>public</strong> <strong>void</strong> setWebddfile(InputStream stream) throws GenerationFault {
  <a name="154" href="#154">154</a>         <strong>this</strong>.webddfile = stream;
  <a name="155" href="#155">155</a>     }
  <a name="156" href="#156">156</a> 
  <a name="157" href="#157">157</a>     <strong>public</strong> <strong>void</strong> setWscfFile(InputStream stream) throws GenerationFault {
  <a name="158" href="#158">158</a>         <strong>this</strong>.wscfFile = stream;
  <a name="159" href="#159">159</a>     }
  <a name="160" href="#160">160</a> 
  <a name="161" href="#161">161</a>     <em class="comment">/*<em class="comment"> (non-Javadoc)</em></em>
  <a name="162" href="#162">162</a> <em class="comment">     * @see org.apache.geronimo.ews.ws4j2ee.utils.packager.load.PackageModule#findFileInModule(java.lang.String)</em>
  <a name="163" href="#163">163</a> <em class="comment">     */</em>
  <a name="164" href="#164">164</a>     <strong>public</strong> InputStream findFileInModule(String path) throws GenerationFault {
  <a name="165" href="#165">165</a>         <strong>try</strong> {
  <a name="166" href="#166">166</a>             File file = <strong>new</strong> File(location + <span class="string">"/"</span> + path);
  <a name="167" href="#167">167</a>             <strong>if</strong> (file.exists())
  <a name="168" href="#168">168</a>                 <strong>new</strong> FileInputStream(file);
  <a name="169" href="#169">169</a>             <strong>return</strong> <strong>null</strong>;
  <a name="170" href="#170">170</a>         } <strong>catch</strong> (FileNotFoundException e) {
  <a name="171" href="#171">171</a>             e.printStackTrace();
  <a name="172" href="#172">172</a>             <strong>throw</strong> GenerationFault.createGenerationFault(e);
  <a name="173" href="#173">173</a>         }
  <a name="174" href="#174">174</a>     }
  <a name="175" href="#175">175</a> 
  <a name="176" href="#176">176</a> }
  </pre>
  <hr/><div id="footer">This page was automatically generated by <a href="http://maven.apache.org/">Maven</a></div></body>
  </html>
  
  
  
  
  1.1                  ws-site/targets/ews/xref/org/apache/geronimo/ews/ws4j2ee/module/EARModule.html
  
  Index: EARModule.html
  ===================================================================
  <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
  <head>
  <meta http-equiv="content-type" content="text/html; charset=ISO-8859-1" /><title>EARModule xref</title>
  <link type="text/css" rel="stylesheet" href="../../../../../../stylesheet.css" />
  </head>
  <body>
  <div id="overview"><a href="../../../../../../../apidocs/org/apache/geronimo/ews/ws4j2ee/module/EARModule.html">View Javadoc</a></div><pre>
  
  <a name="1" href="#1">1</a>   <em class="comment">/*</em>
  <a name="2" href="#2">2</a>   <em class="comment"> * Copyright 2001-2004 The Apache Software Foundation.</em>
  <a name="3" href="#3">3</a>   <em class="comment"> * </em>
  <a name="4" href="#4">4</a>   <em class="comment"> * Licensed under the Apache License, Version 2.0 (the "License");</em>
  <a name="5" href="#5">5</a>   <em class="comment"> * you may not use this file except in compliance with the License.</em>
  <a name="6" href="#6">6</a>   <em class="comment"> * You may obtain a copy of the License at</em>
  <a name="7" href="#7">7</a>   <em class="comment"> * </em>
  <a name="8" href="#8">8</a>   <em class="comment"> *      <a href="http://www.apache.org/licenses/LICENSE-2.0" target="alexandria_uri">http://www.apache.org/licenses/LICENSE-2.0</a></em>
  <a name="9" href="#9">9</a>   <em class="comment"> * </em>
  <a name="10" href="#10">10</a>  <em class="comment"> * Unless required by applicable law or agreed to in writing, software</em>
  <a name="11" href="#11">11</a>  <em class="comment"> * distributed under the License is distributed on an "AS IS" BASIS,</em>
  <a name="12" href="#12">12</a>  <em class="comment"> * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.</em>
  <a name="13" href="#13">13</a>  <em class="comment"> * See the License for the specific language governing permissions and</em>
  <a name="14" href="#14">14</a>  <em class="comment"> * limitations under the License.</em>
  <a name="15" href="#15">15</a>  <em class="comment"> */</em>
  <a name="16" href="#16">16</a>  
  <a name="17" href="#17">17</a>  <strong>package</strong> <a href="../../../../../../org/apache/geronimo/ews/ws4j2ee/module/package-summary.html">org.apache.geronimo.ews.ws4j2ee.module</a>;
  <a name="18" href="#18">18</a>  
  <a name="19" href="#19">19</a>  <strong>import</strong> org.apache.geronimo.ews.ws4j2ee.toWs.GenerationFault;
  <a name="20" href="#20">20</a>  <strong>import</strong> org.apache.geronimo.ews.ws4j2ee.toWs.UnrecoverableGenerationFault;
  <a name="21" href="#21">21</a>  <strong>import</strong> org.apache.geronimo.ews.ws4j2ee.utils.FileUtils;
  <a name="22" href="#22">22</a>  <strong>import</strong> org.apache.geronimo.ews.ws4j2ee.utils.TemporaryRepository;
  <a name="23" href="#23">23</a>  <strong>import</strong> org.apache.geronimo.ews.ws4j2ee.utils.UncompressingJarClassLoader;
  <a name="24" href="#24">24</a>  
  <a name="25" href="#25">25</a>  <strong>import</strong> java.io.File;
  <a name="26" href="#26">26</a>  <strong>import</strong> java.io.IOException;
  <a name="27" href="#27">27</a>  <strong>import</strong> java.io.InputStream;
  <a name="28" href="#28">28</a>  <strong>import</strong> java.util.ArrayList;
  <a name="29" href="#29">29</a>  <strong>import</strong> java.util.Enumeration;
  <a name="30" href="#30">30</a>  <strong>import</strong> java.util.Vector;
  <a name="31" href="#31">31</a>  <strong>import</strong> java.util.zip.ZipEntry;
  <a name="32" href="#32">32</a>  <strong>import</strong> java.util.zip.ZipFile;
  <a name="33" href="#33">33</a>  
  <a name="34" href="#34">34</a>  <em>/**<em>*</em></em>
  <a name="35" href="#35">35</a>  <em> * @author hemapani@opensource.lk</em>
  <a name="36" href="#36">36</a>  <em> */</em>
  <a name="37" href="#37">37</a>  <strong>public</strong> <strong>class</strong> <a href="../../../../../../org/apache/geronimo/ews/ws4j2ee/module/EARModule.html">EARModule</a> implements <a href="../../../../../../org/apache/geronimo/ews/ws4j2ee/module/Module.html">Module</a> {
  <a name="38" href="#38">38</a>      <strong>private</strong> <a href="../../../../../../org/apache/geronimo/ews/ws4j2ee/module/Module.html">Module</a> pkgModule;
  <a name="39" href="#39">39</a>      <strong>private</strong> <a href="../../../../../../org/apache/geronimo/ews/ws4j2ee/utils/UncompressingJarClassLoader.html">UncompressingJarClassLoader</a> cl;
  <a name="40" href="#40">40</a>      <strong>private</strong> Vector classPathElements;
  <a name="41" href="#41">41</a>      <strong>private</strong> ClassLoader parentCL;
  <a name="42" href="#42">42</a>  
  <a name="43" href="#43">43</a>      <em>/**<em>*</em></em>
  <a name="44" href="#44">44</a>  <em>     * @param jarFile</em>
  <a name="45" href="#45">45</a>  <em>     * @throws GenerationFault</em>
  <a name="46" href="#46">46</a>  <em>     */</em>
  <a name="47" href="#47">47</a>      <strong>public</strong> <a href="../../../../../../org/apache/geronimo/ews/ws4j2ee/module/EARModule.html">EARModule</a>(String jarFile)
  <a name="48" href="#48">48</a>              throws <a href="../../../../../../org/apache/geronimo/ews/ws4j2ee/toWs/GenerationFault.html">GenerationFault</a> {
  <a name="49" href="#49">49</a>          <strong>try</strong> {
  <a name="50" href="#50">50</a>              ZipFile earFile = <strong>new</strong> ZipFile(jarFile);
  <a name="51" href="#51">51</a>              Enumeration enumeration = earFile.entries();
  <a name="52" href="#52">52</a>              <strong>while</strong> (enumeration.hasMoreElements()) {
  <a name="53" href="#53">53</a>                  ZipEntry entry = (ZipEntry) enumeration.nextElement();
  <a name="54" href="#54">54</a>                  <strong>if</strong> (entry.getName().endsWith(<span class="string">".war"</span>) || entry.getName().endsWith(<span class="string">".jar"</span>)) {
  <a name="55" href="#55">55</a>                      File outWar = <strong>new</strong> File(TemporaryRepository.getEntry(), entry.getName());
  <a name="56" href="#56">56</a>                      FileUtils.uncompressFile(earFile.getInputStream(entry), outWar);
  <a name="57" href="#57">57</a>                      pkgModule = ModuleFactory.createPackageModule(outWar.getAbsolutePath());
  <a name="58" href="#58">58</a>                  }
  <a name="59" href="#59">59</a>              }
  <a name="60" href="#60">60</a>          } <strong>catch</strong> (UnrecoverableGenerationFault e) {
  <a name="61" href="#61">61</a>              e.printStackTrace();
  <a name="62" href="#62">62</a>              <strong>throw</strong> GenerationFault.createGenerationFault(e);
  <a name="63" href="#63">63</a>          } <strong>catch</strong> (IOException e) {
  <a name="64" href="#64">64</a>              e.printStackTrace();
  <a name="65" href="#65">65</a>              <strong>throw</strong> GenerationFault.createGenerationFault(e);
  <a name="66" href="#66">66</a>          }
  <a name="67" href="#67">67</a>      }
  <a name="68" href="#68">68</a>  
  <a name="69" href="#69">69</a>      <em>/**<em>*</em></em>
  <a name="70" href="#70">70</a>  <em>     * @return</em>
  <a name="71" href="#71">71</a>  <em>     * @throws GenerationFault</em>
  <a name="72" href="#72">72</a>  <em>     */</em>
  <a name="73" href="#73">73</a>      <strong>public</strong> ClassLoader getClassLoaderWithPackageLoaded() throws GenerationFault {
  <a name="74" href="#74">74</a>          <strong>return</strong> pkgModule.getClassLoaderWithPackageLoaded();
  <a name="75" href="#75">75</a>      }
  <a name="76" href="#76">76</a>  
  <a name="77" href="#77">77</a>      <em>/**<em>*</em></em>
  <a name="78" href="#78">78</a>  <em>     * @return</em>
  <a name="79" href="#79">79</a>  <em>     * @throws GenerationFault</em>
  <a name="80" href="#80">80</a>  <em>     */</em>
  <a name="81" href="#81">81</a>      <strong>public</strong> ArrayList getClassPathElements() throws GenerationFault {
  <a name="82" href="#82">82</a>          <strong>return</strong> pkgModule.getClassPathElements();
  <a name="83" href="#83">83</a>      }
  <a name="84" href="#84">84</a>  
  <a name="85" href="#85">85</a>      <strong>public</strong> <strong>boolean</strong> equals(Object obj) {
  <a name="86" href="#86">86</a>          <strong>return</strong> pkgModule.equals(obj);
  <a name="87" href="#87">87</a>      }
  <a name="88" href="#88">88</a>  
  <a name="89" href="#89">89</a>      <em>/**<em>*</em></em>
  <a name="90" href="#90">90</a>  <em>     * @param path</em>
  <a name="91" href="#91">91</a>  <em>     * @return</em>
  <a name="92" href="#92">92</a>  <em>     * @throws GenerationFault</em>
  <a name="93" href="#93">93</a>  <em>     */</em>
  <a name="94" href="#94">94</a>      <strong>public</strong> InputStream findFileInModule(String path) throws GenerationFault {
  <a name="95" href="#95">95</a>          <strong>return</strong> pkgModule.findFileInModule(path);
  <a name="96" href="#96">96</a>      }
  <a name="97" href="#97">97</a>  
  <a name="98" href="#98">98</a>      <em>/**<em>*</em></em>
  <a name="99" href="#99">99</a>  <em>     * @return</em>
  <a name="100" href="#100">100</a> <em>     * @throws GenerationFault</em>
  <a name="101" href="#101">101</a> <em>     */</em>
  <a name="102" href="#102">102</a>     <strong>public</strong> InputStream getEjbJarfile() throws GenerationFault {
  <a name="103" href="#103">103</a>         <strong>return</strong> pkgModule.getEjbJarfile();
  <a name="104" href="#104">104</a>     }
  <a name="105" href="#105">105</a> 
  <a name="106" href="#106">106</a>     <em>/**<em>*</em></em>
  <a name="107" href="#107">107</a> <em>     * @return</em>
  <a name="108" href="#108">108</a> <em>     * @throws GenerationFault</em>
  <a name="109" href="#109">109</a> <em>     */</em>
  <a name="110" href="#110">110</a>     <strong>public</strong> InputStream getWebddfile() throws GenerationFault {
  <a name="111" href="#111">111</a>         <strong>return</strong> pkgModule.getWebddfile();
  <a name="112" href="#112">112</a>     }
  <a name="113" href="#113">113</a> 
  <a name="114" href="#114">114</a>     <em>/**<em>*</em></em>
  <a name="115" href="#115">115</a> <em>     * @return</em>
  <a name="116" href="#116">116</a> <em>     * @throws GenerationFault</em>
  <a name="117" href="#117">117</a> <em>     */</em>
  <a name="118" href="#118">118</a>     <strong>public</strong> InputStream getWscfFile() throws GenerationFault {
  <a name="119" href="#119">119</a>         <strong>return</strong> pkgModule.getWscfFile();
  <a name="120" href="#120">120</a>     }
  <a name="121" href="#121">121</a> 
  <a name="122" href="#122">122</a>     <em class="comment">/*<em class="comment"> (non-Javadoc)</em></em>
  <a name="123" href="#123">123</a> <em class="comment">     * @see java.lang.Object#hashCode()</em>
  <a name="124" href="#124">124</a> <em class="comment">     */</em>
  <a name="125" href="#125">125</a>     <strong>public</strong> <strong>int</strong> hashCode() {
  <a name="126" href="#126">126</a>         <strong>return</strong> pkgModule.hashCode();
  <a name="127" href="#127">127</a>     }
  <a name="128" href="#128">128</a> 
  <a name="129" href="#129">129</a>     <em>/**<em>*</em></em>
  <a name="130" href="#130">130</a> <em>     * @param stream</em>
  <a name="131" href="#131">131</a> <em>     * @throws GenerationFault</em>
  <a name="132" href="#132">132</a> <em>     */</em>
  <a name="133" href="#133">133</a>     <strong>public</strong> <strong>void</strong> setEjbJarfile(InputStream stream) throws GenerationFault {
  <a name="134" href="#134">134</a>         pkgModule.setEjbJarfile(stream);
  <a name="135" href="#135">135</a>     }
  <a name="136" href="#136">136</a> 
  <a name="137" href="#137">137</a>     <em>/**<em>*</em></em>
  <a name="138" href="#138">138</a> <em>     * @param stream</em>
  <a name="139" href="#139">139</a> <em>     * @throws GenerationFault</em>
  <a name="140" href="#140">140</a> <em>     */</em>
  <a name="141" href="#141">141</a>     <strong>public</strong> <strong>void</strong> setWebddfile(InputStream stream) throws GenerationFault {
  <a name="142" href="#142">142</a>         pkgModule.setWebddfile(stream);
  <a name="143" href="#143">143</a>     }
  <a name="144" href="#144">144</a> 
  <a name="145" href="#145">145</a>     <em>/**<em>*</em></em>
  <a name="146" href="#146">146</a> <em>     * @param stream</em>
  <a name="147" href="#147">147</a> <em>     * @throws GenerationFault</em>
  <a name="148" href="#148">148</a> <em>     */</em>
  <a name="149" href="#149">149</a>     <strong>public</strong> <strong>void</strong> setWscfFile(InputStream stream) throws GenerationFault {
  <a name="150" href="#150">150</a>         pkgModule.setWscfFile(stream);
  <a name="151" href="#151">151</a>     }
  <a name="152" href="#152">152</a> 
  <a name="153" href="#153">153</a>     <em class="comment">/*<em class="comment"> (non-Javadoc)</em></em>
  <a name="154" href="#154">154</a> <em class="comment">     * @see java.lang.Object#toString()</em>
  <a name="155" href="#155">155</a> <em class="comment">     */</em>
  <a name="156" href="#156">156</a>     <strong>public</strong> String toString() {
  <a name="157" href="#157">157</a>         <strong>return</strong> pkgModule.toString();
  <a name="158" href="#158">158</a>     }
  <a name="159" href="#159">159</a> }
  </pre>
  <hr/><div id="footer">This page was automatically generated by <a href="http://maven.apache.org/">Maven</a></div></body>
  </html>
  
  
  
  
  1.1                  ws-site/targets/ews/xref/org/apache/geronimo/ews/ws4j2ee/module/JarModule.html
  
  Index: JarModule.html
  ===================================================================
  <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
  <head>
  <meta http-equiv="content-type" content="text/html; charset=ISO-8859-1" /><title>JarModule xref</title>
  <link type="text/css" rel="stylesheet" href="../../../../../../stylesheet.css" />
  </head>
  <body>
  <div id="overview"><a href="../../../../../../../apidocs/org/apache/geronimo/ews/ws4j2ee/module/JarModule.html">View Javadoc</a></div><pre>
  
  <a name="1" href="#1">1</a>   <em class="comment">/*</em>
  <a name="2" href="#2">2</a>   <em class="comment"> * Copyright 2001-2004 The Apache Software Foundation.</em>
  <a name="3" href="#3">3</a>   <em class="comment"> * </em>
  <a name="4" href="#4">4</a>   <em class="comment"> * Licensed under the Apache License, Version 2.0 (the "License");</em>
  <a name="5" href="#5">5</a>   <em class="comment"> * you may not use this file except in compliance with the License.</em>
  <a name="6" href="#6">6</a>   <em class="comment"> * You may obtain a copy of the License at</em>
  <a name="7" href="#7">7</a>   <em class="comment"> * </em>
  <a name="8" href="#8">8</a>   <em class="comment"> *      <a href="http://www.apache.org/licenses/LICENSE-2.0" target="alexandria_uri">http://www.apache.org/licenses/LICENSE-2.0</a></em>
  <a name="9" href="#9">9</a>   <em class="comment"> * </em>
  <a name="10" href="#10">10</a>  <em class="comment"> * Unless required by applicable law or agreed to in writing, software</em>
  <a name="11" href="#11">11</a>  <em class="comment"> * distributed under the License is distributed on an "AS IS" BASIS,</em>
  <a name="12" href="#12">12</a>  <em class="comment"> * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.</em>
  <a name="13" href="#13">13</a>  <em class="comment"> * See the License for the specific language governing permissions and</em>
  <a name="14" href="#14">14</a>  <em class="comment"> * limitations under the License.</em>
  <a name="15" href="#15">15</a>  <em class="comment"> */</em>
  <a name="16" href="#16">16</a>  
  <a name="17" href="#17">17</a>  <strong>package</strong> <a href="../../../../../../org/apache/geronimo/ews/ws4j2ee/module/package-summary.html">org.apache.geronimo.ews.ws4j2ee.module</a>;
  <a name="18" href="#18">18</a>  
  <a name="19" href="#19">19</a>  <strong>import</strong> org.apache.geronimo.ews.ws4j2ee.toWs.GenerationFault;
  <a name="20" href="#20">20</a>  
  <a name="21" href="#21">21</a>  <strong>import</strong> java.io.File;
  <a name="22" href="#22">22</a>  <strong>import</strong> java.net.MalformedURLException;
  <a name="23" href="#23">23</a>  <strong>import</strong> java.net.URL;
  <a name="24" href="#24">24</a>  <strong>import</strong> java.net.URLClassLoader;
  <a name="25" href="#25">25</a>  <strong>import</strong> java.util.ArrayList;
  <a name="26" href="#26">26</a>  
  <a name="27" href="#27">27</a>  <em>/**<em>*</em></em>
  <a name="28" href="#28">28</a>  <em> * @author Srinath Perera(hemapani@opensource.lk)</em>
  <a name="29" href="#29">29</a>  <em> */</em>
  <a name="30" href="#30">30</a>  <strong>public</strong> <strong>class</strong> <a href="../../../../../../org/apache/geronimo/ews/ws4j2ee/module/JarModule.html">JarModule</a> <strong>extends</strong> <a href="../../../../../../org/apache/geronimo/ews/ws4j2ee/module/AbstractModule.html">AbstractModule</a> {
  <a name="31" href="#31">31</a>      <strong>private</strong> ClassLoader cl;
  <a name="32" href="#32">32</a>      <strong>private</strong> ArrayList list = <strong>new</strong> ArrayList(1);
  <a name="33" href="#33">33</a>  
  <a name="34" href="#34">34</a>      <em>/**<em>*</em></em>
  <a name="35" href="#35">35</a>  <em>     * @param jarFile</em>
  <a name="36" href="#36">36</a>  <em>     * @throws GenerationFault</em>
  <a name="37" href="#37">37</a>  <em>     */</em>
  <a name="38" href="#38">38</a>      <strong>public</strong> <a href="../../../../../../org/apache/geronimo/ews/ws4j2ee/module/JarModule.html">JarModule</a>(String jarFile, ClassLoader parentCL)
  <a name="39" href="#39">39</a>              throws <a href="../../../../../../org/apache/geronimo/ews/ws4j2ee/toWs/GenerationFault.html">GenerationFault</a> {
  <a name="40" href="#40">40</a>          <strong>super</strong>(jarFile, parentCL);
  <a name="41" href="#41">41</a>          <strong>try</strong> {
  <a name="42" href="#42">42</a>              <strong>this</strong>.parentCL = parentCL;
  <a name="43" href="#43">43</a>              list.add(<strong>new</strong> File(jarFile));
  <a name="44" href="#44">44</a>              cl = <strong>new</strong> URLClassLoader(<strong>new</strong> URL[]{(<strong>new</strong> File(jarFile)).toURL()}, parentCL);
  <a name="45" href="#45">45</a>              wscfFile = getInputStreamForJarEntry(jarFile, <span class="string">"META-INF/webservices.xml"</span>);
  <a name="46" href="#46">46</a>              <strong>if</strong> (wscfFile == <strong>null</strong>) {
  <a name="47" href="#47">47</a>                  wscfFile =
  <a name="48" href="#48">48</a>                          getInputStreamForJarEntry(jarFile, <span class="string">"META-INF/webservice.xml"</span>);
  <a name="49" href="#49">49</a>              }
  <a name="50" href="#50">50</a>              <strong>if</strong> (wscfFile == <strong>null</strong>) {
  <a name="51" href="#51">51</a>                  wscfFile = getInputStreamForJarEntry(jarFile, <span class="string">"webservice.xml"</span>);
  <a name="52" href="#52">52</a>              }
  <a name="53" href="#53">53</a>              webddfile = getInputStreamForJarEntry(jarFile, <span class="string">"META-INF/web.xml"</span>);
  <a name="54" href="#54">54</a>              <strong>if</strong> (wscfFile == <strong>null</strong>) {
  <a name="55" href="#55">55</a>                  webddfile = getInputStreamForJarEntry(jarFile, <span class="string">"web.xml"</span>);
  <a name="56" href="#56">56</a>              }
  <a name="57" href="#57">57</a>              ejbJarfile = getInputStreamForJarEntry(jarFile, <span class="string">"META-INF/ejb-jar.xml"</span>);
  <a name="58" href="#58">58</a>              <strong>if</strong> (wscfFile == <strong>null</strong>)
  <a name="59" href="#59">59</a>                  <strong>throw</strong> <strong>new</strong> <a href="../../../../../../org/apache/geronimo/ews/ws4j2ee/toWs/GenerationFault.html">GenerationFault</a>(<span class="string">"wscf file must not be null"</span>);
  <a name="60" href="#60">60</a>          } <strong>catch</strong> (MalformedURLException e) {
  <a name="61" href="#61">61</a>              e.printStackTrace();
  <a name="62" href="#62">62</a>              <strong>throw</strong> GenerationFault.createGenerationFault(e);
  <a name="63" href="#63">63</a>          }
  <a name="64" href="#64">64</a>      }
  <a name="65" href="#65">65</a>  
  <a name="66" href="#66">66</a>      <em class="comment">/*<em class="comment"> (non-Javadoc)</em></em>
  <a name="67" href="#67">67</a>  <em class="comment">     * @see org.apache.geronimo.ews.ws4j2ee.utils.packager.load.PackageModule#getClassLoaderWithPackageLoaded()</em>
  <a name="68" href="#68">68</a>  <em class="comment">     */</em>
  <a name="69" href="#69">69</a>      <strong>public</strong> ClassLoader getClassLoaderWithPackageLoaded() {
  <a name="70" href="#70">70</a>          <strong>return</strong> cl;
  <a name="71" href="#71">71</a>      }
  <a name="72" href="#72">72</a>  
  <a name="73" href="#73">73</a>      <strong>public</strong> ArrayList getClassPathElements() {
  <a name="74" href="#74">74</a>          <strong>return</strong> list;
  <a name="75" href="#75">75</a>      }
  <a name="76" href="#76">76</a>  }
  </pre>
  <hr/><div id="footer">This page was automatically generated by <a href="http://maven.apache.org/">Maven</a></div></body>
  </html>
  
  
  
  
  1.1                  ws-site/targets/ews/xref/org/apache/geronimo/ews/ws4j2ee/module/Module.html
  
  Index: Module.html
  ===================================================================
  <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
  <head>
  <meta http-equiv="content-type" content="text/html; charset=ISO-8859-1" /><title>Module xref</title>
  <link type="text/css" rel="stylesheet" href="../../../../../../stylesheet.css" />
  </head>
  <body>
  <div id="overview"><a href="../../../../../../../apidocs/org/apache/geronimo/ews/ws4j2ee/module/Module.html">View Javadoc</a></div><pre>
  
  <a name="1" href="#1">1</a>   <em class="comment">/*</em>
  <a name="2" href="#2">2</a>   <em class="comment"> * Copyright 2001-2004 The Apache Software Foundation.</em>
  <a name="3" href="#3">3</a>   <em class="comment"> * </em>
  <a name="4" href="#4">4</a>   <em class="comment"> * Licensed under the Apache License, Version 2.0 (the "License");</em>
  <a name="5" href="#5">5</a>   <em class="comment"> * you may not use this file except in compliance with the License.</em>
  <a name="6" href="#6">6</a>   <em class="comment"> * You may obtain a copy of the License at</em>
  <a name="7" href="#7">7</a>   <em class="comment"> * </em>
  <a name="8" href="#8">8</a>   <em class="comment"> *      <a href="http://www.apache.org/licenses/LICENSE-2.0" target="alexandria_uri">http://www.apache.org/licenses/LICENSE-2.0</a></em>
  <a name="9" href="#9">9</a>   <em class="comment"> * </em>
  <a name="10" href="#10">10</a>  <em class="comment"> * Unless required by applicable law or agreed to in writing, software</em>
  <a name="11" href="#11">11</a>  <em class="comment"> * distributed under the License is distributed on an "AS IS" BASIS,</em>
  <a name="12" href="#12">12</a>  <em class="comment"> * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.</em>
  <a name="13" href="#13">13</a>  <em class="comment"> * See the License for the specific language governing permissions and</em>
  <a name="14" href="#14">14</a>  <em class="comment"> * limitations under the License.</em>
  <a name="15" href="#15">15</a>  <em class="comment"> */</em>
  <a name="16" href="#16">16</a>  
  <a name="17" href="#17">17</a>  <strong>package</strong> <a href="../../../../../../org/apache/geronimo/ews/ws4j2ee/module/package-summary.html">org.apache.geronimo.ews.ws4j2ee.module</a>;
  <a name="18" href="#18">18</a>  
  <a name="19" href="#19">19</a>  <strong>import</strong> org.apache.geronimo.ews.ws4j2ee.toWs.GenerationFault;
  <a name="20" href="#20">20</a>  
  <a name="21" href="#21">21</a>  <strong>import</strong> java.io.InputStream;
  <a name="22" href="#22">22</a>  <strong>import</strong> java.util.ArrayList;
  <a name="23" href="#23">23</a>  
  <a name="24" href="#24">24</a>  <em>/**<em>*</em></em>
  <a name="25" href="#25">25</a>  <em> * &lt;p>This reprsents a packaged module jar,WAR,EAR file. the implementation</em>
  <a name="26" href="#26">26</a>  <em> * classes of this interface should provide the acsses to the DD files and give</em>
  <a name="27" href="#27">27</a>  <em> * a class loader that load the class files in the jar file.&lt;/p></em>
  <a name="28" href="#28">28</a>  <em> *</em>
  <a name="29" href="#29">29</a>  <em> * @author hemapani</em>
  <a name="30" href="#30">30</a>  <em> */</em>
  <a name="31" href="#31">31</a>  <strong>public</strong> <strong>interface</strong> <a href="../../../../../../org/apache/geronimo/ews/ws4j2ee/module/Module.html">Module</a> {
  <a name="32" href="#32">32</a>      <strong>public</strong> InputStream getEjbJarfile() throws GenerationFault;
  <a name="33" href="#33">33</a>  
  <a name="34" href="#34">34</a>      <strong>public</strong> InputStream getWebddfile() throws GenerationFault;
  <a name="35" href="#35">35</a>  
  <a name="36" href="#36">36</a>      <strong>public</strong> InputStream getWscfFile() throws GenerationFault;
  <a name="37" href="#37">37</a>  
  <a name="38" href="#38">38</a>      <strong>public</strong> <strong>void</strong> setEjbJarfile(InputStream stream) throws GenerationFault;
  <a name="39" href="#39">39</a>  
  <a name="40" href="#40">40</a>      <strong>public</strong> <strong>void</strong> setWebddfile(InputStream stream) throws GenerationFault;
  <a name="41" href="#41">41</a>  
  <a name="42" href="#42">42</a>      <strong>public</strong> <strong>void</strong> setWscfFile(InputStream stream) throws GenerationFault;
  <a name="43" href="#43">43</a>  
  <a name="44" href="#44">44</a>      <strong>public</strong> ClassLoader getClassLoaderWithPackageLoaded() throws GenerationFault;
  <a name="45" href="#45">45</a>  
  <a name="46" href="#46">46</a>      <strong>public</strong> ArrayList getClassPathElements() throws GenerationFault;
  <a name="47" href="#47">47</a>  
  <a name="48" href="#48">48</a>      <strong>public</strong> InputStream findFileInModule(String path) throws GenerationFault;
  <a name="49" href="#49">49</a>  }
  </pre>
  <hr/><div id="footer">This page was automatically generated by <a href="http://maven.apache.org/">Maven</a></div></body>
  </html>
  
  
  
  
  1.1                  ws-site/targets/ews/xref/org/apache/geronimo/ews/ws4j2ee/module/ModuleFactory.html
  
  Index: ModuleFactory.html
  ===================================================================
  <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
  <head>
  <meta http-equiv="content-type" content="text/html; charset=ISO-8859-1" /><title>ModuleFactory xref</title>
  <link type="text/css" rel="stylesheet" href="../../../../../../stylesheet.css" />
  </head>
  <body>
  <div id="overview"><a href="../../../../../../../apidocs/org/apache/geronimo/ews/ws4j2ee/module/ModuleFactory.html">View Javadoc</a></div><pre>
  
  <a name="1" href="#1">1</a>   <em class="comment">/*</em>
  <a name="2" href="#2">2</a>   <em class="comment"> * Copyright 2001-2004 The Apache Software Foundation.</em>
  <a name="3" href="#3">3</a>   <em class="comment"> * </em>
  <a name="4" href="#4">4</a>   <em class="comment"> * Licensed under the Apache License, Version 2.0 (the "License");</em>
  <a name="5" href="#5">5</a>   <em class="comment"> * you may not use this file except in compliance with the License.</em>
  <a name="6" href="#6">6</a>   <em class="comment"> * You may obtain a copy of the License at</em>
  <a name="7" href="#7">7</a>   <em class="comment"> * </em>
  <a name="8" href="#8">8</a>   <em class="comment"> *      <a href="http://www.apache.org/licenses/LICENSE-2.0" target="alexandria_uri">http://www.apache.org/licenses/LICENSE-2.0</a></em>
  <a name="9" href="#9">9</a>   <em class="comment"> * </em>
  <a name="10" href="#10">10</a>  <em class="comment"> * Unless required by applicable law or agreed to in writing, software</em>
  <a name="11" href="#11">11</a>  <em class="comment"> * distributed under the License is distributed on an "AS IS" BASIS,</em>
  <a name="12" href="#12">12</a>  <em class="comment"> * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.</em>
  <a name="13" href="#13">13</a>  <em class="comment"> * See the License for the specific language governing permissions and</em>
  <a name="14" href="#14">14</a>  <em class="comment"> * limitations under the License.</em>
  <a name="15" href="#15">15</a>  <em class="comment"> */</em>
  <a name="16" href="#16">16</a>  
  <a name="17" href="#17">17</a>  <strong>package</strong> <a href="../../../../../../org/apache/geronimo/ews/ws4j2ee/module/package-summary.html">org.apache.geronimo.ews.ws4j2ee.module</a>;
  <a name="18" href="#18">18</a>  
  <a name="19" href="#19">19</a>  <strong>import</strong> org.apache.geronimo.ews.ws4j2ee.toWs.GenerationFault;
  <a name="20" href="#20">20</a>  <strong>import</strong> org.apache.geronimo.ews.ws4j2ee.toWs.UnrecoverableGenerationFault;
  <a name="21" href="#21">21</a>  
  <a name="22" href="#22">22</a>  <strong>import</strong> java.io.File;
  <a name="23" href="#23">23</a>  
  <a name="24" href="#24">24</a>  <em>/**<em>*</em></em>
  <a name="25" href="#25">25</a>  <em> * @author Srinath Perera(hemapani@opensource.lk)</em>
  <a name="26" href="#26">26</a>  <em> */</em>
  <a name="27" href="#27">27</a>  <strong>public</strong> <strong>class</strong> <a href="../../../../../../org/apache/geronimo/ews/ws4j2ee/module/ModuleFactory.html">ModuleFactory</a> {
  <a name="28" href="#28">28</a>  
  <a name="29" href="#29">29</a>      <em>/**<em>*</em></em>
  <a name="30" href="#30">30</a>  <em>     * @param path        - path to the package</em>
  <a name="31" href="#31">31</a>  <em>     * @param firstmodule - is it the first module or a module inside other module</em>
  <a name="32" href="#32">32</a>  <em>     * @return</em>
  <a name="33" href="#33">33</a>  <em>     * @throws GenerationFault</em>
  <a name="34" href="#34">34</a>  <em>     */</em>
  <a name="35" href="#35">35</a>      <strong>public</strong> <strong>static</strong> <a href="../../../../../../org/apache/geronimo/ews/ws4j2ee/module/Module.html">Module</a> createPackageModule(String path) throws UnrecoverableGenerationFault {
  <a name="36" href="#36">36</a>          <strong>return</strong> createPackageModule(path, Thread.currentThread().getContextClassLoader());
  <a name="37" href="#37">37</a>      }
  <a name="38" href="#38">38</a>  
  <a name="39" href="#39">39</a>      <strong>public</strong> <strong>static</strong> <a href="../../../../../../org/apache/geronimo/ews/ws4j2ee/module/Module.html">Module</a> createPackageModule(String path,
  <a name="40" href="#40">40</a>                                               ClassLoader parentCL) throws UnrecoverableGenerationFault {
  <a name="41" href="#41">41</a>          <strong>try</strong> {
  <a name="42" href="#42">42</a>              <strong>if</strong> (path != <strong>null</strong>) {
  <a name="43" href="#43">43</a>                  File file = <strong>new</strong> File(path);
  <a name="44" href="#44">44</a>                  <strong>if</strong> (!file.exists())
  <a name="45" href="#45">45</a>                      <strong>throw</strong> <strong>new</strong> <a href="../../../../../../org/apache/geronimo/ews/ws4j2ee/toWs/UnrecoverableGenerationFault.html">UnrecoverableGenerationFault</a>(<span class="string">"file not found "</span> + file.getAbsolutePath());
  <a name="46" href="#46">46</a>                  <strong>if</strong> (file.isDirectory()) {
  <a name="47" href="#47">47</a>                      <strong>return</strong> <strong>new</strong> <a href="../../../../../../org/apache/geronimo/ews/ws4j2ee/module/DirModule.html">DirModule</a>(path, parentCL);
  <a name="48" href="#48">48</a>                  } <strong>else</strong> <strong>if</strong> (path.endsWith(<span class="string">".jar"</span>) || path.endsWith(<span class="string">".JAR"</span>))
  <a name="49" href="#49">49</a>                      <strong>return</strong> <strong>new</strong> <a href="../../../../../../org/apache/geronimo/ews/ws4j2ee/module/JarModule.html">JarModule</a>(path, parentCL);
  <a name="50" href="#50">50</a>                  <strong>else</strong> <strong>if</strong> (path.endsWith(<span class="string">".war"</span>) || path.endsWith(<span class="string">".WAR"</span>))
  <a name="51" href="#51">51</a>                      <strong>return</strong> <strong>new</strong> <a href="../../../../../../org/apache/geronimo/ews/ws4j2ee/module/WARModule.html">WARModule</a>(path, parentCL);
  <a name="52" href="#52">52</a>                  <strong>else</strong> <strong>if</strong> (path.endsWith(<span class="string">".ear"</span>) || path.endsWith(<span class="string">".EAR"</span>))
  <a name="53" href="#53">53</a>                      <strong>return</strong> <strong>new</strong> <a href="../../../../../../org/apache/geronimo/ews/ws4j2ee/module/EARModule.html">EARModule</a>(path);
  <a name="54" href="#54">54</a>                  <strong>else</strong> <strong>if</strong> (path.endsWith(<span class="string">".xml"</span>))
  <a name="55" href="#55">55</a>                      <strong>return</strong> <strong>new</strong> <a href="../../../../../../org/apache/geronimo/ews/ws4j2ee/module/DirModule.html">DirModule</a>(<strong>new</strong> File(path));
  <a name="56" href="#56">56</a>                  <strong>else</strong>
  <a name="57" href="#57">57</a>                      <strong>throw</strong> <strong>new</strong> <a href="../../../../../../org/apache/geronimo/ews/ws4j2ee/toWs/UnrecoverableGenerationFault.html">UnrecoverableGenerationFault</a>(<span class="string">"unknown type of file"</span>);
  <a name="58" href="#58">58</a>              }
  <a name="59" href="#59">59</a>          } <strong>catch</strong> (GenerationFault e) {
  <a name="60" href="#60">60</a>              <strong>throw</strong> <strong>new</strong> <a href="../../../../../../org/apache/geronimo/ews/ws4j2ee/toWs/UnrecoverableGenerationFault.html">UnrecoverableGenerationFault</a>(path + <span class="string">" not found "</span>, e);
  <a name="61" href="#61">61</a>          }
  <a name="62" href="#62">62</a>          <strong>throw</strong> <strong>new</strong> <a href="../../../../../../org/apache/geronimo/ews/ws4j2ee/toWs/UnrecoverableGenerationFault.html">UnrecoverableGenerationFault</a>(<span class="string">"path is null"</span>);
  <a name="63" href="#63">63</a>      }
  <a name="64" href="#64">64</a>  }
  </pre>
  <hr/><div id="footer">This page was automatically generated by <a href="http://maven.apache.org/">Maven</a></div></body>
  </html>
  
  
  
  
  1.1                  ws-site/targets/ews/xref/org/apache/geronimo/ews/ws4j2ee/module/package-frame.html
  
  Index: package-frame.html
  ===================================================================
  
  
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "DTD/xhtml1-transitional.dtd">
    <html lang="en">
      <head>
        <meta http-equiv="content-type" content="text/html; charset=ISO-8859-1"></meta>
        <title>Enterprise Web Services 1.0 Reference Package org.apache.geronimo.ews.ws4j2ee.module</title>
        <link rel="stylesheet" href="../../../../../../stylesheet.css" type="text/css" title="style"></link>
      </head>
      <body>
  
        <h3>
          <a href="package-summary.html" target="classFrame">org.apache.geronimo.ews.ws4j2ee.module</a>
        </h3>
  
        <h3>Classes</h3>
  
        <ul>
          
            <li>
              <a href="AbstractModule.html" target="classFrame">AbstractModule</a>
            </li>
          
            <li>
              <a href="DirModule.html" target="classFrame">DirModule</a>
            </li>
          
            <li>
              <a href="EARModule.html" target="classFrame">EARModule</a>
            </li>
          
            <li>
              <a href="JarModule.html" target="classFrame">JarModule</a>
            </li>
          
            <li>
              <a href="Module.html" target="classFrame">Module</a>
            </li>
          
            <li>
              <a href="ModuleFactory.html" target="classFrame">ModuleFactory</a>
            </li>
          
            <li>
              <a href="WARModule.html" target="classFrame">WARModule</a>
            </li>
          
        </ul>
  
      </body>
    </html>
  
  
  
  1.1                  ws-site/targets/ews/xref/org/apache/geronimo/ews/ws4j2ee/module/package-summary.html
  
  Index: package-summary.html
  ===================================================================
  
  
    
  
    
      
  
      
  
      
  
    
        <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "DTD/xhtml1-transitional.dtd">
        <html lang="en">
          <head>
            <meta http-equiv="content-type" content="text/html; charset=ISO-8859-1"></meta>
            <title>Enterprise Web Services 1.0 Reference Package </title>
            <link rel="stylesheet" href="../../../../../../stylesheet.css" type="text/css" title="style"></link>
          </head>
          <body>
  
            
        
        
  
        <div class="overview">
          <ul>
            <li>
              <a href="../../../../../../overview-summary.html">Overview</a>
            </li>
            <li class="selected">Package</li>
          </ul>
        </div>
        <div class="framenoframe">
          <ul>
            <li>
              <a href="../../../../../../index.html" target="_top">FRAMES</a>
            </li>
            <li>
              <a href="package-summary.html" target="_top">NO FRAMES</a>
            </li>
          </ul>
        </div>
  
        
  
      
        
        <h2>Package org.apache.geronimo.ews.ws4j2ee.module</h2>
  
        <table class="summary">
          <thead>
            <tr>
              <th>Class Summary</th>
            </tr>
          </thead>
  
          <tbody>
            
              <tr>
                <td>
                  <a href="AbstractModule.html" target="classFrame">AbstractModule</a>
                </td>
              </tr>
            
              <tr>
                <td>
                  <a href="DirModule.html" target="classFrame">DirModule</a>
                </td>
              </tr>
            
              <tr>
                <td>
                  <a href="EARModule.html" target="classFrame">EARModule</a>
                </td>
              </tr>
            
              <tr>
                <td>
                  <a href="JarModule.html" target="classFrame">JarModule</a>
                </td>
              </tr>
            
              <tr>
                <td>
                  <a href="Module.html" target="classFrame">Module</a>
                </td>
              </tr>
            
              <tr>
                <td>
                  <a href="ModuleFactory.html" target="classFrame">ModuleFactory</a>
                </td>
              </tr>
            
              <tr>
                <td>
                  <a href="WARModule.html" target="classFrame">WARModule</a>
                </td>
              </tr>
            
          </tbody>
        </table>
  
      
        
        
  
        <div class="overview">
          <ul>
            <li>
              <a href="../../../../../../overview-summary.html">Overview</a>
            </li>
            <li class="selected">Package</li>
          </ul>
        </div>
        <div class="framenoframe">
          <ul>
            <li>
              <a href="../../../../../../index.html" target="_top">FRAMES</a>
            </li>
            <li>
              <a href="package-summary.html" target="_top">NO FRAMES</a>
            </li>
          </ul>
        </div>
  
        
  
      
      
  
            <hr></hr>
  
            Copyright &copy;  Apache Software Foundation. All Rights Reserved.
          </body>
        </html>
      
  
  
  
  1.1                  ws-site/targets/ews/xref/org/apache/geronimo/ews/ws4j2ee/module/WARModule.html
  
  Index: WARModule.html
  ===================================================================
  <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
  <head>
  <meta http-equiv="content-type" content="text/html; charset=ISO-8859-1" /><title>WARModule xref</title>
  <link type="text/css" rel="stylesheet" href="../../../../../../stylesheet.css" />
  </head>
  <body>
  <div id="overview"><a href="../../../../../../../apidocs/org/apache/geronimo/ews/ws4j2ee/module/WARModule.html">View Javadoc</a></div><pre>
  
  <a name="1" href="#1">1</a>   <em class="comment">/*</em>
  <a name="2" href="#2">2</a>   <em class="comment"> * Copyright 2001-2004 The Apache Software Foundation.</em>
  <a name="3" href="#3">3</a>   <em class="comment"> * </em>
  <a name="4" href="#4">4</a>   <em class="comment"> * Licensed under the Apache License, Version 2.0 (the "License");</em>
  <a name="5" href="#5">5</a>   <em class="comment"> * you may not use this file except in compliance with the License.</em>
  <a name="6" href="#6">6</a>   <em class="comment"> * You may obtain a copy of the License at</em>
  <a name="7" href="#7">7</a>   <em class="comment"> * </em>
  <a name="8" href="#8">8</a>   <em class="comment"> *      <a href="http://www.apache.org/licenses/LICENSE-2.0" target="alexandria_uri">http://www.apache.org/licenses/LICENSE-2.0</a></em>
  <a name="9" href="#9">9</a>   <em class="comment"> * </em>
  <a name="10" href="#10">10</a>  <em class="comment"> * Unless required by applicable law or agreed to in writing, software</em>
  <a name="11" href="#11">11</a>  <em class="comment"> * distributed under the License is distributed on an "AS IS" BASIS,</em>
  <a name="12" href="#12">12</a>  <em class="comment"> * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.</em>
  <a name="13" href="#13">13</a>  <em class="comment"> * See the License for the specific language governing permissions and</em>
  <a name="14" href="#14">14</a>  <em class="comment"> * limitations under the License.</em>
  <a name="15" href="#15">15</a>  <em class="comment"> */</em>
  <a name="16" href="#16">16</a>  
  <a name="17" href="#17">17</a>  <strong>package</strong> <a href="../../../../../../org/apache/geronimo/ews/ws4j2ee/module/package-summary.html">org.apache.geronimo.ews.ws4j2ee.module</a>;
  <a name="18" href="#18">18</a>  
  <a name="19" href="#19">19</a>  <strong>import</strong> org.apache.geronimo.ews.ws4j2ee.toWs.GenerationFault;
  <a name="20" href="#20">20</a>  <strong>import</strong> org.apache.geronimo.ews.ws4j2ee.utils.FileUtils;
  <a name="21" href="#21">21</a>  <strong>import</strong> org.apache.geronimo.ews.ws4j2ee.utils.TemporaryRepository;
  <a name="22" href="#22">22</a>  
  <a name="23" href="#23">23</a>  <strong>import</strong> java.io.File;
  <a name="24" href="#24">24</a>  <strong>import</strong> java.io.IOException;
  <a name="25" href="#25">25</a>  <strong>import</strong> java.net.MalformedURLException;
  <a name="26" href="#26">26</a>  <strong>import</strong> java.net.URL;
  <a name="27" href="#27">27</a>  <strong>import</strong> java.net.URLClassLoader;
  <a name="28" href="#28">28</a>  <strong>import</strong> java.util.ArrayList;
  <a name="29" href="#29">29</a>  
  <a name="30" href="#30">30</a>  <em>/**<em>*</em></em>
  <a name="31" href="#31">31</a>  <em> * @author Srinath Perera(hemapani@opensource.lk)</em>
  <a name="32" href="#32">32</a>  <em> */</em>
  <a name="33" href="#33">33</a>  <strong>public</strong> <strong>class</strong> <a href="../../../../../../org/apache/geronimo/ews/ws4j2ee/module/WARModule.html">WARModule</a> <strong>extends</strong> <a href="../../../../../../org/apache/geronimo/ews/ws4j2ee/module/AbstractModule.html">AbstractModule</a> {
  <a name="34" href="#34">34</a>      <strong>private</strong> ArrayList urls;
  <a name="35" href="#35">35</a>      <strong>private</strong> ClassLoader cl;
  <a name="36" href="#36">36</a>  
  <a name="37" href="#37">37</a>      <em>/**<em>*</em></em>
  <a name="38" href="#38">38</a>  <em>     * @param jarFile</em>
  <a name="39" href="#39">39</a>  <em>     * @throws GenerationFault</em>
  <a name="40" href="#40">40</a>  <em>     */</em>
  <a name="41" href="#41">41</a>      <strong>public</strong> <a href="../../../../../../org/apache/geronimo/ews/ws4j2ee/module/WARModule.html">WARModule</a>(String jarFile, ClassLoader parentCL)
  <a name="42" href="#42">42</a>              throws <a href="../../../../../../org/apache/geronimo/ews/ws4j2ee/toWs/GenerationFault.html">GenerationFault</a> {
  <a name="43" href="#43">43</a>          <strong>super</strong>(jarFile, parentCL);
  <a name="44" href="#44">44</a>          <strong>try</strong> {
  <a name="45" href="#45">45</a>              urls = FileUtils.uncompressWar(TemporaryRepository.getEntry(), <strong>new</strong> File(zip.getName()));
  <a name="46" href="#46">46</a>              URL[] aurls = <strong>new</strong> URL[urls.size()];
  <a name="47" href="#47">47</a>              <strong>for</strong> (<strong>int</strong> i = 0; i &lt; aurls.length; i++) {
  <a name="48" href="#48">48</a>                  aurls[i] = ((File) urls.get(i)).toURL();
  <a name="49" href="#49">49</a>                  System.out.println(aurls[i]);
  <a name="50" href="#50">50</a>              }
  <a name="51" href="#51">51</a>              cl = <strong>new</strong> URLClassLoader(aurls, Thread.currentThread().getContextClassLoader());
  <a name="52" href="#52">52</a>              wscfFile = getInputStreamForJarEntry(jarFile, <span class="string">"WEB-INF/webservices.xml"</span>);
  <a name="53" href="#53">53</a>              <strong>if</strong> (wscfFile == <strong>null</strong>) {
  <a name="54" href="#54">54</a>                  wscfFile = getInputStreamForJarEntry(jarFile, <span class="string">"webservices.xml"</span>);
  <a name="55" href="#55">55</a>              }
  <a name="56" href="#56">56</a>              webddfile = getInputStreamForJarEntry(jarFile, <span class="string">"WEB-INF/web.xml"</span>);
  <a name="57" href="#57">57</a>              <strong>if</strong> (webddfile == <strong>null</strong>)
  <a name="58" href="#58">58</a>                  webddfile = getInputStreamForJarEntry(jarFile, <span class="string">"web.xml"</span>);
  <a name="59" href="#59">59</a>              <strong>if</strong> (wscfFile == <strong>null</strong>)
  <a name="60" href="#60">60</a>                  <strong>throw</strong> <strong>new</strong> <a href="../../../../../../org/apache/geronimo/ews/ws4j2ee/toWs/GenerationFault.html">GenerationFault</a>(<span class="string">"wscf file must not be null"</span>);
  <a name="61" href="#61">61</a>          } <strong>catch</strong> (MalformedURLException e) {
  <a name="62" href="#62">62</a>              e.printStackTrace();
  <a name="63" href="#63">63</a>              <strong>throw</strong> GenerationFault.createGenerationFault(e);
  <a name="64" href="#64">64</a>          } <strong>catch</strong> (IOException e) {
  <a name="65" href="#65">65</a>              e.printStackTrace();
  <a name="66" href="#66">66</a>              <strong>throw</strong> GenerationFault.createGenerationFault(e);
  <a name="67" href="#67">67</a>          } <strong>catch</strong> (GenerationFault e) {
  <a name="68" href="#68">68</a>              e.printStackTrace();
  <a name="69" href="#69">69</a>              <strong>throw</strong> GenerationFault.createGenerationFault(e);
  <a name="70" href="#70">70</a>          }
  <a name="71" href="#71">71</a>      }
  <a name="72" href="#72">72</a>  
  <a name="73" href="#73">73</a>      <em class="comment">/*<em class="comment"> (non-Javadoc)</em></em>
  <a name="74" href="#74">74</a>  <em class="comment">     * @see org.apache.geronimo.ews.ws4j2ee.utils.packager.load.PackageModule#getClassLoaderWithPackageLoaded()</em>
  <a name="75" href="#75">75</a>  <em class="comment">     */</em>
  <a name="76" href="#76">76</a>      <strong>public</strong> ClassLoader getClassLoaderWithPackageLoaded() throws GenerationFault {
  <a name="77" href="#77">77</a>          <strong>return</strong> cl;
  <a name="78" href="#78">78</a>      }
  <a name="79" href="#79">79</a>  
  <a name="80" href="#80">80</a>      <strong>public</strong> ArrayList getClassPathElements() {
  <a name="81" href="#81">81</a>          <strong>return</strong> urls;
  <a name="82" href="#82">82</a>      }
  <a name="83" href="#83">83</a>  
  <a name="84" href="#84">84</a>  }
  </pre>
  <hr/><div id="footer">This page was automatically generated by <a href="http://maven.apache.org/">Maven</a></div></body>
  </html>
  
  
  
  

Mime
View raw message