Added: 
openejb/trunk/openejb3/container/openejb-jee/src/main/java/org/apache/openejb/jee/sun/Timeout.java
URL: 
http://svn.apache.org/viewvc/openejb/trunk/openejb3/container/openejb-jee/src/main/java/org/apache/openejb/jee/sun/Timeout.java?rev=585036&view=auto
==============================================================================
--- 
openejb/trunk/openejb3/container/openejb-jee/src/main/java/org/apache/openejb/jee/sun/Timeout.java
 (added)
+++ 
openejb/trunk/openejb3/container/openejb-jee/src/main/java/org/apache/openejb/jee/sun/Timeout.java
 Mon Oct 15 21:38:53 2007
@@ -0,0 +1,67 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+package org.apache.openejb.jee.sun;
+
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlAttribute;
+import javax.xml.bind.annotation.XmlType;
+import javax.xml.bind.annotation.XmlValue;
+import javax.xml.bind.annotation.adapters.CollapsedStringAdapter;
+import javax.xml.bind.annotation.adapters.NormalizedStringAdapter;
+import javax.xml.bind.annotation.adapters.XmlJavaTypeAdapter;
+
[EMAIL PROTECTED](XmlAccessType.FIELD)
[EMAIL PROTECTED](name = "", propOrder = {"value"})
+public class Timeout {
+    @XmlAttribute
+    @XmlJavaTypeAdapter(NormalizedStringAdapter.class)
+    protected String name;
+    @XmlAttribute
+    @XmlJavaTypeAdapter(CollapsedStringAdapter.class)
+    protected String scope;
+    @XmlValue
+    protected String value;
+
+    public String getName() {
+        return name;
+    }
+
+    public void setName(String value) {
+        this.name = value;
+    }
+
+    public String getScope() {
+        if (scope == null) {
+            return "request.attribute";
+        } else {
+            return scope;
+        }
+    }
+
+    public void setScope(String value) {
+        this.scope = value;
+    }
+
+    public String getvalue() {
+        return value;
+    }
+
+    public void setvalue(String value) {
+        this.value = value;
+    }
+}

Modified: 
openejb/trunk/openejb3/container/openejb-jee/src/main/java/org/apache/openejb/jee/sun/TransportConfig.java
URL: 
http://svn.apache.org/viewvc/openejb/trunk/openejb3/container/openejb-jee/src/main/java/org/apache/openejb/jee/sun/TransportConfig.java?rev=585036&r1=585035&r2=585036&view=diff
==============================================================================
--- 
openejb/trunk/openejb3/container/openejb-jee/src/main/java/org/apache/openejb/jee/sun/TransportConfig.java
 (original)
+++ 
openejb/trunk/openejb3/container/openejb-jee/src/main/java/org/apache/openejb/jee/sun/TransportConfig.java
 Mon Oct 15 21:38:53 2007
@@ -14,19 +14,13 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-
 package org.apache.openejb.jee.sun;
 
 import javax.xml.bind.annotation.XmlAccessType;
 import javax.xml.bind.annotation.XmlAccessorType;
 import javax.xml.bind.annotation.XmlElement;
-import javax.xml.bind.annotation.XmlRootElement;
 import javax.xml.bind.annotation.XmlType;
 
-
-/**
- * 
- */
 @XmlAccessorType(XmlAccessType.FIELD)
 @XmlType(name = "", propOrder = {
     "integrity",
@@ -34,9 +28,7 @@
     "establishTrustInTarget",
     "establishTrustInClient"
 })
[EMAIL PROTECTED](name = "transport-config")
 public class TransportConfig {
-
     @XmlElement(required = true)
     protected String integrity;
     @XmlElement(required = true)
@@ -46,100 +38,35 @@
     @XmlElement(name = "establish-trust-in-client", required = true)
     protected String establishTrustInClient;
 
-    /**
-     * Gets the value of the integrity property.
-     * 
-     * @return
-     *     possible object is
-     *     [EMAIL PROTECTED] String }
-     *     
-     */
     public String getIntegrity() {
         return integrity;
     }
 
-    /**
-     * Sets the value of the integrity property.
-     * 
-     * @param value
-     *     allowed object is
-     *     [EMAIL PROTECTED] String }
-     *     
-     */
     public void setIntegrity(String value) {
         this.integrity = value;
     }
 
-    /**
-     * Gets the value of the confidentiality property.
-     * 
-     * @return
-     *     possible object is
-     *     [EMAIL PROTECTED] String }
-     *     
-     */
     public String getConfidentiality() {
         return confidentiality;
     }
 
-    /**
-     * Sets the value of the confidentiality property.
-     * 
-     * @param value
-     *     allowed object is
-     *     [EMAIL PROTECTED] String }
-     *     
-     */
     public void setConfidentiality(String value) {
         this.confidentiality = value;
     }
 
-    /**
-     * Gets the value of the establishTrustInTarget property.
-     * 
-     * @return
-     *     possible object is
-     *     [EMAIL PROTECTED] String }
-     *     
-     */
     public String getEstablishTrustInTarget() {
         return establishTrustInTarget;
     }
 
-    /**
-     * Sets the value of the establishTrustInTarget property.
-     * 
-     * @param value
-     *     allowed object is
-     *     [EMAIL PROTECTED] String }
-     *     
-     */
     public void setEstablishTrustInTarget(String value) {
         this.establishTrustInTarget = value;
     }
 
-    /**
-     * Gets the value of the establishTrustInClient property.
-     * 
-     * @return
-     *     possible object is
-     *     [EMAIL PROTECTED] String }
-     *     
-     */
     public String getEstablishTrustInClient() {
         return establishTrustInClient;
     }
 
-    /**
-     * Sets the value of the establishTrustInClient property.
-     * 
-     * @param value
-     *     allowed object is
-     *     [EMAIL PROTECTED] String }
-     *     
-     */
     public void setEstablishTrustInClient(String value) {
         this.establishTrustInClient = value;
     }
-
 }

Added: 
openejb/trunk/openejb3/container/openejb-jee/src/main/java/org/apache/openejb/jee/sun/UrlPattern.java
URL: 
http://svn.apache.org/viewvc/openejb/trunk/openejb3/container/openejb-jee/src/main/java/org/apache/openejb/jee/sun/UrlPattern.java?rev=585036&view=auto
==============================================================================
--- 
openejb/trunk/openejb3/container/openejb-jee/src/main/java/org/apache/openejb/jee/sun/UrlPattern.java
 (added)
+++ 
openejb/trunk/openejb3/container/openejb-jee/src/main/java/org/apache/openejb/jee/sun/UrlPattern.java
 Mon Oct 15 21:38:53 2007
@@ -0,0 +1,37 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+package org.apache.openejb.jee.sun;
+
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlType;
+import javax.xml.bind.annotation.XmlValue;
+
[EMAIL PROTECTED](XmlAccessType.FIELD)
[EMAIL PROTECTED](name = "", propOrder = {"value"})
+public class UrlPattern {
+    @XmlValue
+    protected String value;
+
+    public String getvalue() {
+        return value;
+    }
+
+    public void setvalue(String value) {
+        this.value = value;
+    }
+}

Modified: 
openejb/trunk/openejb3/container/openejb-jee/src/main/java/org/apache/openejb/jee/sun/Web.java
URL: 
http://svn.apache.org/viewvc/openejb/trunk/openejb3/container/openejb-jee/src/main/java/org/apache/openejb/jee/sun/Web.java?rev=585036&r1=585035&r2=585036&view=diff
==============================================================================
--- 
openejb/trunk/openejb3/container/openejb-jee/src/main/java/org/apache/openejb/jee/sun/Web.java
 (original)
+++ 
openejb/trunk/openejb3/container/openejb-jee/src/main/java/org/apache/openejb/jee/sun/Web.java
 Mon Oct 15 21:38:53 2007
@@ -14,78 +14,34 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-
 package org.apache.openejb.jee.sun;
 
 import javax.xml.bind.annotation.XmlAccessType;
 import javax.xml.bind.annotation.XmlAccessorType;
 import javax.xml.bind.annotation.XmlElement;
-import javax.xml.bind.annotation.XmlRootElement;
 import javax.xml.bind.annotation.XmlType;
 
-
-/**
- * 
- */
 @XmlAccessorType(XmlAccessType.FIELD)
[EMAIL PROTECTED](name = "", propOrder = {
-    "webUri",
-    "contextRoot"
-})
[EMAIL PROTECTED](name = "web")
[EMAIL PROTECTED](name = "", propOrder = {"webUri", "contextRoot"})
 public class Web {
-
     @XmlElement(name = "web-uri", required = true)
     protected String webUri;
     @XmlElement(name = "context-root", required = true)
     protected String contextRoot;
 
-    /**
-     * Gets the value of the webUri property.
-     * 
-     * @return
-     *     possible object is
-     *     [EMAIL PROTECTED] String }
-     *     
-     */
     public String getWebUri() {
         return webUri;
     }
 
-    /**
-     * Sets the value of the webUri property.
-     * 
-     * @param value
-     *     allowed object is
-     *     [EMAIL PROTECTED] String }
-     *     
-     */
     public void setWebUri(String value) {
         this.webUri = value;
     }
 
-    /**
-     * Gets the value of the contextRoot property.
-     * 
-     * @return
-     *     possible object is
-     *     [EMAIL PROTECTED] String }
-     *     
-     */
     public String getContextRoot() {
         return contextRoot;
     }
 
-    /**
-     * Sets the value of the contextRoot property.
-     * 
-     * @param value
-     *     allowed object is
-     *     [EMAIL PROTECTED] String }
-     *     
-     */
     public void setContextRoot(String value) {
         this.contextRoot = value;
     }
-
 }

Modified: 
openejb/trunk/openejb3/container/openejb-jee/src/main/java/org/apache/openejb/jee/sun/WebserviceDescription.java
URL: 
http://svn.apache.org/viewvc/openejb/trunk/openejb3/container/openejb-jee/src/main/java/org/apache/openejb/jee/sun/WebserviceDescription.java?rev=585036&r1=585035&r2=585036&view=diff
==============================================================================
--- 
openejb/trunk/openejb3/container/openejb-jee/src/main/java/org/apache/openejb/jee/sun/WebserviceDescription.java
 (original)
+++ 
openejb/trunk/openejb3/container/openejb-jee/src/main/java/org/apache/openejb/jee/sun/WebserviceDescription.java
 Mon Oct 15 21:38:53 2007
@@ -14,78 +14,37 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-
 package org.apache.openejb.jee.sun;
 
 import javax.xml.bind.annotation.XmlAccessType;
 import javax.xml.bind.annotation.XmlAccessorType;
 import javax.xml.bind.annotation.XmlElement;
-import javax.xml.bind.annotation.XmlRootElement;
 import javax.xml.bind.annotation.XmlType;
 
-
-/**
- * 
- */
 @XmlAccessorType(XmlAccessType.FIELD)
 @XmlType(name = "", propOrder = {
     "webserviceDescriptionName",
     "wsdlPublishLocation"
 })
[EMAIL PROTECTED](name = "webservice-description")
 public class WebserviceDescription {
-
     @XmlElement(name = "webservice-description-name", required = true)
     protected String webserviceDescriptionName;
     @XmlElement(name = "wsdl-publish-location")
     protected String wsdlPublishLocation;
 
-    /**
-     * Gets the value of the webserviceDescriptionName property.
-     * 
-     * @return
-     *     possible object is
-     *     [EMAIL PROTECTED] String }
-     *     
-     */
     public String getWebserviceDescriptionName() {
         return webserviceDescriptionName;
     }
 
-    /**
-     * Sets the value of the webserviceDescriptionName property.
-     * 
-     * @param value
-     *     allowed object is
-     *     [EMAIL PROTECTED] String }
-     *     
-     */
     public void setWebserviceDescriptionName(String value) {
         this.webserviceDescriptionName = value;
     }
 
-    /**
-     * Gets the value of the wsdlPublishLocation property.
-     * 
-     * @return
-     *     possible object is
-     *     [EMAIL PROTECTED] String }
-     *     
-     */
     public String getWsdlPublishLocation() {
         return wsdlPublishLocation;
     }
 
-    /**
-     * Sets the value of the wsdlPublishLocation property.
-     * 
-     * @param value
-     *     allowed object is
-     *     [EMAIL PROTECTED] String }
-     *     
-     */
     public void setWsdlPublishLocation(String value) {
         this.wsdlPublishLocation = value;
     }
-
 }

Modified: 
openejb/trunk/openejb3/container/openejb-jee/src/main/java/org/apache/openejb/jee/sun/WebserviceEndpoint.java
URL: 
http://svn.apache.org/viewvc/openejb/trunk/openejb3/container/openejb-jee/src/main/java/org/apache/openejb/jee/sun/WebserviceEndpoint.java?rev=585036&r1=585035&r2=585036&view=diff
==============================================================================
--- 
openejb/trunk/openejb3/container/openejb-jee/src/main/java/org/apache/openejb/jee/sun/WebserviceEndpoint.java
 (original)
+++ 
openejb/trunk/openejb3/container/openejb-jee/src/main/java/org/apache/openejb/jee/sun/WebserviceEndpoint.java
 Mon Oct 15 21:38:53 2007
@@ -14,22 +14,16 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-
 package org.apache.openejb.jee.sun;
 
-import java.util.ArrayList;
-import java.util.List;
 import javax.xml.bind.annotation.XmlAccessType;
 import javax.xml.bind.annotation.XmlAccessorType;
 import javax.xml.bind.annotation.XmlElement;
 import javax.xml.bind.annotation.XmlElements;
-import javax.xml.bind.annotation.XmlRootElement;
 import javax.xml.bind.annotation.XmlType;
+import java.util.ArrayList;
+import java.util.List;
 
-
-/**
- * 
- */
 @XmlAccessorType(XmlAccessType.FIELD)
 @XmlType(name = "", propOrder = {
     "portComponentName",
@@ -41,9 +35,7 @@
     "servletImplClass",
     "debuggingEnabled"
 })
[EMAIL PROTECTED](name = "webservice-endpoint")
 public class WebserviceEndpoint {
-
     @XmlElement(name = "port-component-name", required = true)
     protected String portComponentName;
     @XmlElement(name = "endpoint-address-uri")
@@ -64,77 +56,22 @@
     @XmlElement(name = "debugging-enabled")
     protected String debuggingEnabled;
 
-    /**
-     * Gets the value of the portComponentName property.
-     * 
-     * @return
-     *     possible object is
-     *     [EMAIL PROTECTED] String }
-     *     
-     */
     public String getPortComponentName() {
         return portComponentName;
     }
 
-    /**
-     * Sets the value of the portComponentName property.
-     * 
-     * @param value
-     *     allowed object is
-     *     [EMAIL PROTECTED] String }
-     *     
-     */
     public void setPortComponentName(String value) {
         this.portComponentName = value;
     }
 
-    /**
-     * Gets the value of the endpointAddressUri property.
-     * 
-     * @return
-     *     possible object is
-     *     [EMAIL PROTECTED] String }
-     *     
-     */
     public String getEndpointAddressUri() {
         return endpointAddressUri;
     }
 
-    /**
-     * Sets the value of the endpointAddressUri property.
-     * 
-     * @param value
-     *     allowed object is
-     *     [EMAIL PROTECTED] String }
-     *     
-     */
     public void setEndpointAddressUri(String value) {
         this.endpointAddressUri = value;
     }
 
-    /**
-     * Gets the value of the loginConfigOrMessageSecurityBinding property.
-     * 
-     * <p>
-     * This accessor method returns a reference to the live list,
-     * not a snapshot. Therefore any modification you make to the
-     * returned list will be present inside the JAXB object.
-     * This is why there is not a <CODE>set</CODE> method for the 
loginConfigOrMessageSecurityBinding property.
-     * 
-     * <p>
-     * For example, to add a new item, do as follows:
-     * <pre>
-     *    getLoginConfigOrMessageSecurityBinding().add(newItem);
-     * </pre>
-     * 
-     * 
-     * <p>
-     * Objects of the following type(s) are allowed in the list
-     * [EMAIL PROTECTED] LoginConfig }
-     * [EMAIL PROTECTED] MessageSecurityBinding }
-     * 
-     * 
-     */
     public List<Object> getLoginConfigOrMessageSecurityBinding() {
         if (loginConfigOrMessageSecurityBinding == null) {
             loginConfigOrMessageSecurityBinding = new ArrayList<Object>();
@@ -142,124 +79,43 @@
         return this.loginConfigOrMessageSecurityBinding;
     }
 
-    /**
-     * Gets the value of the transportGuarantee property.
-     * 
-     * @return
-     *     possible object is
-     *     [EMAIL PROTECTED] String }
-     *     
-     */
     public String getTransportGuarantee() {
         return transportGuarantee;
     }
 
-    /**
-     * Sets the value of the transportGuarantee property.
-     * 
-     * @param value
-     *     allowed object is
-     *     [EMAIL PROTECTED] String }
-     *     
-     */
     public void setTransportGuarantee(String value) {
         this.transportGuarantee = value;
     }
 
-    /**
-     * Gets the value of the serviceQname property.
-     * 
-     * @return
-     *     possible object is
-     *     [EMAIL PROTECTED] ServiceQname }
-     *     
-     */
     public ServiceQname getServiceQname() {
         return serviceQname;
     }
 
-    /**
-     * Sets the value of the serviceQname property.
-     * 
-     * @param value
-     *     allowed object is
-     *     [EMAIL PROTECTED] ServiceQname }
-     *     
-     */
     public void setServiceQname(ServiceQname value) {
         this.serviceQname = value;
     }
 
-    /**
-     * Gets the value of the tieClass property.
-     * 
-     * @return
-     *     possible object is
-     *     [EMAIL PROTECTED] String }
-     *     
-     */
     public String getTieClass() {
         return tieClass;
     }
 
-    /**
-     * Sets the value of the tieClass property.
-     * 
-     * @param value
-     *     allowed object is
-     *     [EMAIL PROTECTED] String }
-     *     
-     */
     public void setTieClass(String value) {
         this.tieClass = value;
     }
 
-    /**
-     * Gets the value of the servletImplClass property.
-     * 
-     * @return
-     *     possible object is
-     *     [EMAIL PROTECTED] String }
-     *     
-     */
     public String getServletImplClass() {
         return servletImplClass;
     }
 
-    /**
-     * Sets the value of the servletImplClass property.
-     * 
-     * @param value
-     *     allowed object is
-     *     [EMAIL PROTECTED] String }
-     *     
-     */
     public void setServletImplClass(String value) {
         this.servletImplClass = value;
     }
 
-    /**
-     * Gets the value of the debuggingEnabled property.
-     * 
-     * @return
-     *     possible object is
-     *     [EMAIL PROTECTED] String }
-     *     
-     */
     public String getDebuggingEnabled() {
         return debuggingEnabled;
     }
 
-    /**
-     * Sets the value of the debuggingEnabled property.
-     * 
-     * @param value
-     *     allowed object is
-     *     [EMAIL PROTECTED] String }
-     *     
-     */
     public void setDebuggingEnabled(String value) {
         this.debuggingEnabled = value;
     }
-
 }

Modified: 
openejb/trunk/openejb3/container/openejb-jee/src/main/java/org/apache/openejb/jee/sun/WsdlPort.java
URL: 
http://svn.apache.org/viewvc/openejb/trunk/openejb3/container/openejb-jee/src/main/java/org/apache/openejb/jee/sun/WsdlPort.java?rev=585036&r1=585035&r2=585036&view=diff
==============================================================================
--- 
openejb/trunk/openejb3/container/openejb-jee/src/main/java/org/apache/openejb/jee/sun/WsdlPort.java
 (original)
+++ 
openejb/trunk/openejb3/container/openejb-jee/src/main/java/org/apache/openejb/jee/sun/WsdlPort.java
 Mon Oct 15 21:38:53 2007
@@ -14,78 +14,37 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-
 package org.apache.openejb.jee.sun;
 
 import javax.xml.bind.annotation.XmlAccessType;
 import javax.xml.bind.annotation.XmlAccessorType;
 import javax.xml.bind.annotation.XmlElement;
-import javax.xml.bind.annotation.XmlRootElement;
 import javax.xml.bind.annotation.XmlType;
 
-
-/**
- * 
- */
 @XmlAccessorType(XmlAccessType.FIELD)
 @XmlType(name = "", propOrder = {
     "namespaceURI",
     "localpart"
 })
[EMAIL PROTECTED](name = "wsdl-port")
 public class WsdlPort {
-
     @XmlElement(required = true)
     protected String namespaceURI;
     @XmlElement(required = true)
     protected String localpart;
 
-    /**
-     * Gets the value of the namespaceURI property.
-     * 
-     * @return
-     *     possible object is
-     *     [EMAIL PROTECTED] String }
-     *     
-     */
     public String getNamespaceURI() {
         return namespaceURI;
     }
 
-    /**
-     * Sets the value of the namespaceURI property.
-     * 
-     * @param value
-     *     allowed object is
-     *     [EMAIL PROTECTED] String }
-     *     
-     */
     public void setNamespaceURI(String value) {
         this.namespaceURI = value;
     }
 
-    /**
-     * Gets the value of the localpart property.
-     * 
-     * @return
-     *     possible object is
-     *     [EMAIL PROTECTED] String }
-     *     
-     */
     public String getLocalpart() {
         return localpart;
     }
 
-    /**
-     * Sets the value of the localpart property.
-     * 
-     * @param value
-     *     allowed object is
-     *     [EMAIL PROTECTED] String }
-     *     
-     */
     public void setLocalpart(String value) {
         this.localpart = value;
     }
-
 }

Modified: 
openejb/trunk/openejb3/container/openejb-jee/src/test/java/org/apache/openejb/jee/JeeTest.java
URL: 
http://svn.apache.org/viewvc/openejb/trunk/openejb3/container/openejb-jee/src/test/java/org/apache/openejb/jee/JeeTest.java?rev=585036&r1=585035&r2=585036&view=diff
==============================================================================
--- 
openejb/trunk/openejb3/container/openejb-jee/src/test/java/org/apache/openejb/jee/JeeTest.java
 (original)
+++ 
openejb/trunk/openejb3/container/openejb-jee/src/test/java/org/apache/openejb/jee/JeeTest.java
 Mon Oct 15 21:38:53 2007
@@ -17,31 +17,34 @@
  */
 package org.apache.openejb.jee;
 
-import junit.framework.TestCase;
 import junit.framework.AssertionFailedError;
+import junit.framework.TestCase;
+import org.xml.sax.Attributes;
+import org.xml.sax.InputSource;
+import org.xml.sax.SAXException;
+import org.xml.sax.XMLReader;
+import org.xml.sax.helpers.XMLFilterImpl;
 
 import javax.xml.bind.JAXBContext;
-import javax.xml.bind.JAXBException;
 import javax.xml.bind.Marshaller;
 import javax.xml.bind.Unmarshaller;
 import javax.xml.bind.ValidationEvent;
 import javax.xml.bind.ValidationEventHandler;
+import javax.xml.parsers.SAXParser;
+import javax.xml.parsers.SAXParserFactory;
+import javax.xml.transform.sax.SAXSource;
 import java.io.BufferedInputStream;
 import java.io.ByteArrayInputStream;
 import java.io.ByteArrayOutputStream;
+import java.io.File;
+import java.io.FileOutputStream;
 import java.io.IOException;
 import java.io.InputStream;
-import java.io.FileOutputStream;
-import java.io.File;
 
 /**
  * @version $Revision$ $Date$
  */
 public class JeeTest extends TestCase {
-
-    /**
-     * @throws Exception
-     */
     public void testEjbJar() throws Exception {
         marshalAndUnmarshal(EjbJar.class, "ejb-jar-example1.xml");
     }
@@ -58,22 +61,33 @@
         marshalAndUnmarshal(WebApp.class, "web-example.xml");
     }
 
+    public void testTld() throws Exception {
+        marshalAndUnmarshal(TldTaglib.class, "tld-example.xml");
+    }
+
     public void testRar() throws Exception {
         marshalAndUnmarshal(Connector.class, "connector-example.xml");
     }
 
-    private <T> void marshalAndUnmarshal(Class<T> type, String xmlFileName) 
throws JAXBException, IOException {
+    private <T> void marshalAndUnmarshal(Class<T> type, String xmlFileName) 
throws Exception {
+        SAXParserFactory factory = SAXParserFactory.newInstance();
+        factory.setNamespaceAware(true);
+        factory.setValidating(false);
+        SAXParser parser = factory.newSAXParser();
+
         JAXBContext ctx = JAXBContext.newInstance(type);
         Unmarshaller unmarshaller = ctx.createUnmarshaller();
 
+        NamespaceFilter xmlFilter = new NamespaceFilter(parser.getXMLReader());
+        xmlFilter.setContentHandler(unmarshaller.getUnmarshallerHandler());
+        unmarshaller.setEventHandler(new TestValidationEventHandler());
+
         InputStream in = 
this.getClass().getClassLoader().getResourceAsStream(xmlFileName);
         String expected = readContent(in);
 
-        Object object = unmarshaller.unmarshal(new 
ByteArrayInputStream(expected.getBytes()));
-//        JAXBElement element =  (JAXBElement) object;
-        unmarshaller.setEventHandler(new TestValidationEventHandler());
-//        T app = (T) element.getValue();
-//        System.out.println("unmarshalled");
+        SAXSource source = new SAXSource(xmlFilter, new InputSource(new 
ByteArrayInputStream(expected.getBytes())));
+
+        Object object = unmarshaller.unmarshal(source);
 
         Marshaller marshaller = ctx.createMarshaller();
         marshaller.setProperty("jaxb.formatted.output", true);
@@ -89,6 +103,22 @@
         } catch (AssertionFailedError e) {
             writeToTmpFile(bytes, xmlFileName);
             throw e;            
+        }
+    }
+
+    public static class NamespaceFilter extends XMLFilterImpl {
+        private static final InputSource EMPTY_INPUT_SOURCE = new 
InputSource(new ByteArrayInputStream(new byte[0]));
+
+        public NamespaceFilter(XMLReader xmlReader) {
+            super(xmlReader);
+        }
+
+        public InputSource resolveEntity(String publicId, String systemId) 
throws SAXException, IOException {
+            return EMPTY_INPUT_SOURCE;
+        }
+
+        public void startElement(String uri, String localName, String qname, 
Attributes atts) throws SAXException {
+            super.startElement("http://java.sun.com/xml/ns/javaee";, localName, 
qname, atts);
         }
     }
 

Added: 
openejb/trunk/openejb3/container/openejb-jee/src/test/resources/tld-example.xml
URL: 
http://svn.apache.org/viewvc/openejb/trunk/openejb3/container/openejb-jee/src/test/resources/tld-example.xml?rev=585036&view=auto
==============================================================================
--- 
openejb/trunk/openejb3/container/openejb-jee/src/test/resources/tld-example.xml 
(added)
+++ 
openejb/trunk/openejb3/container/openejb-jee/src/test/resources/tld-example.xml 
Mon Oct 15 21:38:53 2007
@@ -0,0 +1,214 @@
+<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
+<taglib xmlns="http://java.sun.com/xml/ns/javaee"; version="2.5" id="ID001">
+    <description xml:lang="">description0</description>
+    <display-name xml:lang="en-US">display-name0</display-name>
+    <icon xml:lang="" id="ID007">
+        <small-icon>small-icon0</small-icon>
+        <large-icon>large-icon0</large-icon>
+    </icon>
+    <tlib-version>0</tlib-version>
+    <short-name>short-name0</short-name>
+    <uri>http://www.oxygenxml.com/</uri>
+    <validator id="ID017">
+        <description xml:lang="">description1</description>
+        <validator-class>validator-class0</validator-class>
+        <init-param id="ID023">
+            <description xml:lang="en-US" id="ID025">description2</description>
+            <param-name>param-name0</param-name>
+            <param-value>param-value0</param-value>
+        </init-param>
+    </validator>
+    <listener id="ID031">
+        <description xml:lang="en-US" id="ID033">description3</description>
+        <display-name xml:lang="en-US" id="ID035">display-name1</display-name>
+        <icon xml:lang="en-US" id="ID037">
+            <small-icon>small-icon1</small-icon>
+            <large-icon>large-icon1</large-icon>
+        </icon>
+        <listener-class>listener-class0</listener-class>
+    </listener>
+    <listener id="ID931">
+        <description xml:lang="en-US" id="ID033">description3</description>
+        <display-name xml:lang="en-US" id="ID035">display-name1</display-name>
+        <icon xml:lang="" id="ID037">
+            <small-icon>small-icon1</small-icon>
+            <large-icon>large-icon1</large-icon>
+        </icon>
+        <listener-class>listener-class0</listener-class>
+    </listener>
+    <tag id="ID045">
+        <description xml:lang="">description4</description>
+        <display-name xml:lang="en-US">display-name2</display-name>
+        <icon xml:lang="en-US" id="ID051">
+            <small-icon>small-icon2</small-icon>
+            <large-icon>large-icon2</large-icon>
+        </icon>
+        <name>name0</name>
+        <tag-class>tag-class0</tag-class>
+        <tei-class>tei-class0</tei-class>
+        <body-content>tagdependent</body-content>
+        <variable id="ID065">
+            <description xml:lang="en-US">description5</description>
+            <name-given>$</name-given>
+            <variable-class>variable-class0</variable-class>
+            <declare>true</declare>
+            <scope>NESTED</scope>
+        </variable>
+        <attribute id="ID077">
+            <description xml:lang="">description6</description>
+            <name>$</name>
+            <required>true</required>
+            <rtexprvalue>true</rtexprvalue>
+            <type>type0</type>
+            <deferred-value id="ID089">
+                <type>type1</type>
+            </deferred-value>
+        </attribute>
+        <dynamic-attributes>true</dynamic-attributes>
+        <example>example0</example>
+        <tag-extension namespace="http://www.oxygenxml.com/"; id="ID097">
+            <extension-element></extension-element>
+            <extension-element></extension-element>
+            <extension-element></extension-element>
+        </tag-extension>
+    </tag>
+    <tag id="ID945">
+        <description xml:lang="en-US">description4</description>
+        <display-name xml:lang="">display-name2</display-name>
+        <icon xml:lang="" id="ID051">
+            <small-icon>small-icon2</small-icon>
+            <large-icon>large-icon2</large-icon>
+        </icon>
+        <name>name0</name>
+        <tag-class>tag-class0</tag-class>
+        <tei-class>tei-class0</tei-class>
+        <body-content>tagdependent</body-content>
+        <variable id="ID065">
+            <description xml:lang="">description5</description>
+            <name-from-attribute>$</name-from-attribute>
+            <variable-class>variable-class0</variable-class>
+            <declare>true</declare>
+            <scope>NESTED</scope>
+        </variable>
+        <attribute id="ID077">
+            <description xml:lang="">description6</description>
+            <name>$</name>
+            <required>true</required>
+            <rtexprvalue>true</rtexprvalue>
+            <type>type0</type>
+            <deferred-method id="ID089">
+                <method-signature>method-signature0</method-signature>
+            </deferred-method>
+        </attribute>
+        <dynamic-attributes>true</dynamic-attributes>
+        <example>example0</example>
+        <tag-extension namespace="http://www.oxygenxml.com/"; id="ID097">
+            <extension-element></extension-element>
+            <extension-element></extension-element>
+            <extension-element></extension-element>
+        </tag-extension>
+    </tag>
+    <tag id="ID045">
+        <description xml:lang="en-US">description4</description>
+        <display-name xml:lang="en-US">display-name2</display-name>
+        <icon xml:lang="en-US" id="ID051">
+            <small-icon>small-icon2</small-icon>
+            <large-icon>large-icon2</large-icon>
+        </icon>
+        <name>name0</name>
+        <tag-class>tag-class0</tag-class>
+        <tei-class>tei-class0</tei-class>
+        <body-content>tagdependent</body-content>
+        <variable id="ID065">
+            <description xml:lang="">description5</description>
+            <name-from-attribute>$</name-from-attribute>
+            <variable-class>variable-class0</variable-class>
+            <declare>true</declare>
+            <scope>NESTED</scope>
+        </variable>
+        <attribute id="ID077">
+            <description xml:lang="">description6</description>
+            <name>$</name>
+            <required>true</required>
+            <fragment>true</fragment>
+        </attribute>
+        <dynamic-attributes>true</dynamic-attributes>
+        <example>example0</example>
+        <tag-extension namespace="http://www.oxygenxml.com/"; id="ID091">
+            <extension-element></extension-element>
+            <extension-element></extension-element>
+            <extension-element></extension-element>
+        </tag-extension>
+    </tag>
+    <tag-file id="ID105">
+        <description xml:lang="en-US">description7</description>
+        <display-name xml:lang="">display-name3</display-name>
+        <icon xml:lang="en-US" id="ID111">
+            <small-icon>small-icon3</small-icon>
+            <large-icon>large-icon3</large-icon>
+        </icon>
+        <name>name1</name>
+        <path>path0</path>
+        <example>example1</example>
+        <tag-extension namespace="http://www.oxygenxml.com/"; id="ID123">
+            <extension-element></extension-element>
+            <extension-element></extension-element>
+            <extension-element></extension-element>
+        </tag-extension>
+    </tag-file>
+    <tag-file id="ID999">
+        <description xml:lang="">description7</description>
+        <display-name xml:lang="">display-name3</display-name>
+        <icon xml:lang="en-US" id="ID105">
+            <small-icon>small-icon3</small-icon>
+            <large-icon>large-icon3</large-icon>
+        </icon>
+        <name>name1</name>
+        <path>path0</path>
+        <example>example1</example>
+        <tag-extension namespace="http://www.oxygenxml.com/"; id="ID117">
+            <extension-element></extension-element>
+            <extension-element></extension-element>
+            <extension-element></extension-element>
+        </tag-extension>
+    </tag-file>
+    <function id="ID131">
+        <description xml:lang="en-US">description8</description>
+        <display-name xml:lang="en-US">display-name4</display-name>
+        <icon xml:lang="" id="ID137">
+            <small-icon>small-icon4</small-icon>
+            <large-icon>large-icon4</large-icon>
+        </icon>
+        <name>name2</name>
+        <function-class>function-class0</function-class>
+        <function-signature>function-signature0</function-signature>
+        <example>example2</example>
+        <function-extension namespace="http://www.oxygenxml.com/"; id="ID151">
+            <extension-element></extension-element>
+            <extension-element></extension-element>
+            <extension-element></extension-element>
+        </function-extension>
+    </function>
+    <function id="ID925">
+        <description xml:lang="">description8</description>
+        <display-name xml:lang="en-US">display-name4</display-name>
+        <icon xml:lang="en-US" id="ID131">
+            <small-icon>small-icon4</small-icon>
+            <large-icon>large-icon4</large-icon>
+        </icon>
+        <name>name2</name>
+        <function-class>function-class0</function-class>
+        <function-signature>function-signature0</function-signature>
+        <example>example2</example>
+        <function-extension namespace="http://www.oxygenxml.com/"; id="ID145">
+            <extension-element></extension-element>
+            <extension-element></extension-element>
+            <extension-element></extension-element>
+        </function-extension>
+    </function>
+    <taglib-extension namespace="http://www.oxygenxml.com/"; id="ID159">
+        <extension-element></extension-element>
+        <extension-element></extension-element>
+        <extension-element></extension-element>
+    </taglib-extension>
+</taglib>

Modified: openejb/trunk/openejb3/pom.xml
URL: 
http://svn.apache.org/viewvc/openejb/trunk/openejb3/pom.xml?rev=585036&r1=585035&r2=585036&view=diff
==============================================================================
--- openejb/trunk/openejb3/pom.xml (original)
+++ openejb/trunk/openejb3/pom.xml Mon Oct 15 21:38:53 2007
@@ -504,44 +504,16 @@
         <version>2.0.1</version>
         <exclusions>
           <exclusion>
-            <groupId>org.apache.geronimo.modules</groupId>
-            <artifactId>geronimo-naming</artifactId>
-          </exclusion>
-          <exclusion>
-            <groupId>org.apache.geronimo.modules</groupId>
-            <artifactId>geronimo-deployment</artifactId>
-          </exclusion>
-          <exclusion>
-            <groupId>org.apache.geronimo.modules</groupId>
-            <artifactId>geronimo-j2ee</artifactId>
-          </exclusion>
-          <exclusion>
-            <groupId>org.apache.geronimo.modules</groupId>
-            <artifactId>geronimo-management</artifactId>
-          </exclusion>
-          <exclusion>
-            <groupId>org.apache.geronimo.modules</groupId>
-            <artifactId>geronimo-common</artifactId>
-          </exclusion>
-          <exclusion>
-            <groupId>org.apache.geronimo.modules</groupId>
-            <artifactId>geronimo-security</artifactId>
-          </exclusion>
-          <exclusion>
             <groupId>org.apache.geronimo.specs</groupId>
-            <artifactId>geronimo-j2ee-jacc_1.0_spec</artifactId>
+            <artifactId>geronimo-jta_1.1_spec</artifactId>
           </exclusion>
           <exclusion>
             <groupId>org.apache.geronimo.specs</groupId>
             <artifactId>geronimo-j2ee-connector_1.5_spec</artifactId>
           </exclusion>
           <exclusion>
-            <groupId>org.apache.geronimo.specs</groupId>
-            <artifactId>geronimo-jta_1.0.1B_spec</artifactId>
-          </exclusion>
-          <exclusion>
-            <groupId>regexp</groupId>
-            <artifactId>regexp</artifactId>
+            <groupId>org.objectweb.howl</groupId>
+            <artifactId>howl</artifactId>
           </exclusion>
         </exclusions>
       </dependency>
@@ -551,20 +523,8 @@
         <version>2.0.1</version>
         <exclusions>
           <exclusion>
-            <groupId>org.apache.geronimo.modules</groupId>
-            <artifactId>geronimo-core</artifactId>
-          </exclusion>
-          <exclusion>
-            <groupId>org.apache.geronimo.modules</groupId>
-            <artifactId>geronimo-j2ee</artifactId>
-          </exclusion>
-          <exclusion>
-            <groupId>org.apache.geronimo.specs</groupId>
-            <artifactId>geronimo-jta_1.0.1B_spec</artifactId>
-          </exclusion>
-          <exclusion>
             <groupId>org.apache.geronimo.specs</groupId>
-            <artifactId>geronimo-ejb_2.1_spec</artifactId>
+            <artifactId>geronimo-jta_1.1_spec</artifactId>
           </exclusion>
           <exclusion>
             <groupId>org.apache.geronimo.specs</groupId>


Reply via email to