KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > com > sun > enterprise > tools > verifier > tests > ejb > EjbClientJarManifestClassPath


1 /*
2  * The contents of this file are subject to the terms
3  * of the Common Development and Distribution License
4  * (the License). You may not use this file except in
5  * compliance with the License.
6  *
7  * You can obtain a copy of the license at
8  * https://glassfish.dev.java.net/public/CDDLv1.0.html or
9  * glassfish/bootstrap/legal/CDDLv1.0.txt.
10  * See the License for the specific language governing
11  * permissions and limitations under the License.
12  *
13  * When distributing Covered Code, include this CDDL
14  * Header Notice in each file and include the License file
15  * at glassfish/bootstrap/legal/CDDLv1.0.txt.
16  * If applicable, add the following below the CDDL Header,
17  * with the fields enclosed by brackets [] replaced by
18  * you own identifying information:
19  * "Portions Copyrighted [year] [name of copyright owner]"
20  *
21  * Copyright 2006 Sun Microsystems, Inc. All rights reserved.
22  */

23 package com.sun.enterprise.tools.verifier.tests.ejb;
24
25 import com.sun.enterprise.tools.verifier.tests.ejb.EjbTest;
26 import com.sun.enterprise.deployment.EjbDescriptor;
27 import com.sun.enterprise.deployment.EjbSessionDescriptor;
28 import com.sun.enterprise.tools.verifier.tests.ejb.EjbCheck;
29 import com.sun.enterprise.tools.verifier.*;
30 import com.sun.enterprise.tools.verifier.tests.*;
31
32 /**
33  * The EJB specification does not specify whether the ejb-jar file should
34  * include the classes that are in the ejb-client JAR by copy or by reference.
35  * If the by-copy approach is used, the producer simply includes all the class
36  * files in the ejb-client JAR file also in the ejb-jar file. If the
37  * by-reference approach is used, the ejb-jar file producer does not duplicate
38  * the content of the ejb-client JAR file in the ejb-jar file, but instead uses
39  * a Manifest Class-Path entry in the ejb-jar file to specify that the ejb-jar
40  * file depends on the ejb-client JAR at runtime.
41  */

42 public class EjbClientJarManifestClassPath extends EjbTest implements EjbCheck {
43
44
45
46
47     /**
48      * The EJB specification does not specify whether the ejb-jar file should
49      * include the classes that are in the ejb-client JAR by copy or by reference.
50      * If the by-copy approach is used, the producer simply includes all the class
51      * files in the ejb-client JAR file also in the ejb-jar file. If the
52      * by-reference approach is used, the ejb-jar file producer does not duplicate
53      * the content of the ejb-client JAR file in the ejb-jar file, but instead uses
54      * a Manifest Class-Path entry in the ejb-jar file to specify that the ejb-jar
55      * file depends on the ejb-client JAR at runtime.
56      *
57      * @param descriptor the Enterprise Java Bean deployment descriptor
58      *
59      * @return <code>Result</code> the results for this assertion
60      */

61     public Result check(EjbDescriptor descriptor) {
62
63     Result result = getInitializedResult();
64     ComponentNameConstructor compName = getVerifierContext().getComponentNameConstructor();
65
66     // Stub test class placeholder
67
// fill in guts/logic - pass/fail accordingly in future
68
// once DOL returns proper value
69
result.setStatus(Result.NOT_IMPLEMENTED);
70     result.addNaDetails(smh.getLocalString
71                 ("tests.componentNameConstructor",
72                  "For [ {0} ]",
73                  new Object JavaDoc[] {compName.toString()}));
74     result.addNaDetails
75         (smh.getLocalString
76          (getClass().getName() + ".notImplemented",
77           "No static testing done - yet."));
78     return result;
79
80     }
81 }
82
Popular Tags