You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@beehive.apache.org by ek...@apache.org on 2005/06/14 21:36:41 UTC

svn commit: r190652 [7/7] - in /incubator/beehive/trunk/wsm: drt/negative/WEB-INF/ drt/negative/WEB-INF/src/ drt/negative/WEB-INF/src/web/negative/ drt/tests/org/apache/beehive/wsm/jsr181/model/ drt/tests/org/apache/beehive/wsm/jsr181/model/fakeAnnotations/ drt/tests/org/apache/beehive/wsm/jsr181/processor/apt/ drt/tests/org/apache/beehive/wsm/jsr181/wsdl/ drt/webapp/WEB-INF/ drt/webapp/WEB-INF/src/ drt/webapp/WEB-INF/src/org/apache/beehive/wsm/axis/ drt/webapp/WEB-INF/src/web/ schemas/ src/api/javax/jws/ src/api/javax/jws/soap/ src/runtime/META-INF/services/ src/runtime/org/apache/beehive/wsm/axis/ src/runtime/org/apache/beehive/wsm/axis/ant/ src/runtime/org/apache/beehive/wsm/axis/databinding/ src/runtime/org/apache/beehive/wsm/axis/handlers/ src/runtime/org/apache/beehive/wsm/axis/registration/ src/runtime/org/apache/beehive/wsm/axis/tools/ src/runtime/org/apache/beehive/wsm/axis/util/ src/runtime/org/apache/beehive/wsm/databinding/ src/runtime/org/apache/beehive/wsm/databinding/xmlbeans/ src/runtime/org/apache/beehive/wsm/model/ src/runtime/org/apache/beehive/wsm/model/java/ src/runtime/org/apache/beehive/wsm/model/jsr181/ src/runtime/org/apache/beehive/wsm/processor/apt/ src/runtime/org/apache/beehive/wsm/registration/ src/runtime/org/apache/beehive/wsm/util/ src/runtime/org/apache/beehive/wsm/wsdl/

Modified: incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/model/BeehiveWsSOAPBindingInfo.java
URL: http://svn.apache.org/viewcvs/incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/model/BeehiveWsSOAPBindingInfo.java?rev=190652&r1=190651&r2=190652&view=diff
==============================================================================
--- incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/model/BeehiveWsSOAPBindingInfo.java (original)
+++ incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/model/BeehiveWsSOAPBindingInfo.java Tue Jun 14 12:36:38 2005
@@ -1,57 +1,57 @@
-/*
- * Copyright 2005 The Apache Software Foundation
- *
- * Licensed 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.
- *
- * $Header:$
- */
-package org.apache.beehive.wsm.model;
-
-import javax.jws.soap.SOAPBinding;
-
-/**
- * @author dmehrtash
- */
-public interface BeehiveWsSOAPBindingInfo {
-    
-    /**
-     * @return Returns the parameterStyle.
-     */
-    public abstract SOAPBinding.ParameterStyle getParameterStyle();
-
-    /**
-     * @param parameterStyle The parameterStyle to set.
-     */
-    public abstract void setParameterStyle(
-        SOAPBinding.ParameterStyle parameterStyle);
-
-    /**
-     * @return Returns the style.
-     */
-    public abstract SOAPBinding.Style getStyle();
-
-    /**
-     * @param style The style to set.
-     */
-    public abstract void setStyle(SOAPBinding.Style style);
-
-    /**
-     * @return Returns the use.
-     */
-    public abstract SOAPBinding.Use getUse();
-
-    /**
-     * @param use The use to set.
-     */
-    public abstract void setUse(SOAPBinding.Use use);
+/*
+ * Copyright 2005 The Apache Software Foundation
+ *
+ * Licensed 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.
+ *
+ * $Header:$
+ */
+package org.apache.beehive.wsm.model;
+
+import javax.jws.soap.SOAPBinding;
+
+/**
+ * @author dmehrtash
+ */
+public interface BeehiveWsSOAPBindingInfo {
+    
+    /**
+     * @return Returns the parameterStyle.
+     */
+    public abstract SOAPBinding.ParameterStyle getParameterStyle();
+
+    /**
+     * @param parameterStyle The parameterStyle to set.
+     */
+    public abstract void setParameterStyle(
+        SOAPBinding.ParameterStyle parameterStyle);
+
+    /**
+     * @return Returns the style.
+     */
+    public abstract SOAPBinding.Style getStyle();
+
+    /**
+     * @param style The style to set.
+     */
+    public abstract void setStyle(SOAPBinding.Style style);
+
+    /**
+     * @return Returns the use.
+     */
+    public abstract SOAPBinding.Use getUse();
+
+    /**
+     * @param use The use to set.
+     */
+    public abstract void setUse(SOAPBinding.Use use);
 }

Propchange: incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/model/BeehiveWsSOAPBindingInfo.java
------------------------------------------------------------------------------
    svn:eol-style = native

Modified: incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/model/BeehiveWsSOAPMessageHandlerInfo.java
URL: http://svn.apache.org/viewcvs/incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/model/BeehiveWsSOAPMessageHandlerInfo.java?rev=190652&r1=190651&r2=190652&view=diff
==============================================================================
--- incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/model/BeehiveWsSOAPMessageHandlerInfo.java (original)
+++ incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/model/BeehiveWsSOAPMessageHandlerInfo.java Tue Jun 14 12:36:38 2005
@@ -1,72 +1,72 @@
-/*
- * Copyright 2005 The Apache Software Foundation
- *
- * Licensed 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.
- *
- * $Header:$Factory
- */
-package org.apache.beehive.wsm.model;
-
-import java.util.Collection;
-import java.util.Map;
-
-/**
- * @author dmehrtash
- */
-public interface BeehiveWsSOAPMessageHandlerInfo {
-
-    /**
-     * @return Returns the className.
-     */
-    public abstract String getClassName();
-
-    /**
-     * @param className The className to set.
-     */
-    public abstract void setClassName(String className);
-
-    /**
-     * @return Returns the name.
-     */
-    public abstract String getName();
-
-    /**
-     * @param name The name to set.
-     */
-    public abstract void setName(String name);
-
-    /**
-     * @return Returns the headers.
-     */
-    public abstract Collection<String> getHeaders();
-
-    public abstract void addHeader(String header);
-
-    /**
-     * @return Returns the params.
-     */
-    public abstract Map<String, String> getParameterMap();
-
-    public abstract void addInitParam(String key, String value);
-
-    public abstract void addInitParams(Map<String, String> params);
-
-    /**
-     * @return Returns the roles.
-     */
-    public abstract Collection<String> getRoles();
-
-    public abstract void addRole(String role);
-
-    public abstract void addRoles(Collection<String> roles);
+/*
+ * Copyright 2005 The Apache Software Foundation
+ *
+ * Licensed 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.
+ *
+ * $Header:$Factory
+ */
+package org.apache.beehive.wsm.model;
+
+import java.util.Collection;
+import java.util.Map;
+
+/**
+ * @author dmehrtash
+ */
+public interface BeehiveWsSOAPMessageHandlerInfo {
+
+    /**
+     * @return Returns the className.
+     */
+    public abstract String getClassName();
+
+    /**
+     * @param className The className to set.
+     */
+    public abstract void setClassName(String className);
+
+    /**
+     * @return Returns the name.
+     */
+    public abstract String getName();
+
+    /**
+     * @param name The name to set.
+     */
+    public abstract void setName(String name);
+
+    /**
+     * @return Returns the headers.
+     */
+    public abstract Collection<String> getHeaders();
+
+    public abstract void addHeader(String header);
+
+    /**
+     * @return Returns the params.
+     */
+    public abstract Map<String, String> getParameterMap();
+
+    public abstract void addInitParam(String key, String value);
+
+    public abstract void addInitParams(Map<String, String> params);
+
+    /**
+     * @return Returns the roles.
+     */
+    public abstract Collection<String> getRoles();
+
+    public abstract void addRole(String role);
+
+    public abstract void addRoles(Collection<String> roles);
 }

Propchange: incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/model/BeehiveWsSOAPMessageHandlerInfo.java
------------------------------------------------------------------------------
    svn:eol-style = native

Modified: incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/model/BeehiveWsSecurityRolesInfo.java
URL: http://svn.apache.org/viewcvs/incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/model/BeehiveWsSecurityRolesInfo.java?rev=190652&r1=190651&r2=190652&view=diff
==============================================================================
--- incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/model/BeehiveWsSecurityRolesInfo.java (original)
+++ incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/model/BeehiveWsSecurityRolesInfo.java Tue Jun 14 12:36:38 2005
@@ -1,44 +1,44 @@
-/*
- * Copyright 2005 The Apache Software Foundation
- *
- * Licensed 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.
- *
- * $Header:$
- */
-package org.apache.beehive.wsm.model;
-
-import java.util.Collection;
-
-/**
- * @author dmehrtash
- */
-public interface BeehiveWsSecurityRolesInfo {
-    
-    /**
-     * @return Returns the wrRolesAllowed.
-     */
-    public abstract Collection<String> getRolesAllowed();
-
-    public abstract void addRolesAllowed(String role);
-
-    public abstract void addRolesAllowed(Collection<String> roles);
-
-    /**
-     * @return Returns the RolesReferenced.
-     */
-    public abstract Collection<String> getRolesReferenced();
-
-    public abstract void addRolesReferenced(String role);
-
-    public abstract void addRolesReferenced(Collection<String> roles);
+/*
+ * Copyright 2005 The Apache Software Foundation
+ *
+ * Licensed 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.
+ *
+ * $Header:$
+ */
+package org.apache.beehive.wsm.model;
+
+import java.util.Collection;
+
+/**
+ * @author dmehrtash
+ */
+public interface BeehiveWsSecurityRolesInfo {
+    
+    /**
+     * @return Returns the wrRolesAllowed.
+     */
+    public abstract Collection<String> getRolesAllowed();
+
+    public abstract void addRolesAllowed(String role);
+
+    public abstract void addRolesAllowed(Collection<String> roles);
+
+    /**
+     * @return Returns the RolesReferenced.
+     */
+    public abstract Collection<String> getRolesReferenced();
+
+    public abstract void addRolesReferenced(String role);
+
+    public abstract void addRolesReferenced(Collection<String> roles);
 }

Propchange: incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/model/BeehiveWsSecurityRolesInfo.java
------------------------------------------------------------------------------
    svn:eol-style = native

Modified: incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/model/BeehiveWsTypeMetadata.java
URL: http://svn.apache.org/viewcvs/incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/model/BeehiveWsTypeMetadata.java?rev=190652&r1=190651&r2=190652&view=diff
==============================================================================
--- incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/model/BeehiveWsTypeMetadata.java (original)
+++ incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/model/BeehiveWsTypeMetadata.java Tue Jun 14 12:36:38 2005
@@ -1,93 +1,93 @@
-/*
- * Copyright 2004 The Apache Software Foundation
- *
- * Licensed 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.
- *
- * $Header:$Factory
- */
-package org.apache.beehive.wsm.model;
-
-import java.net.URL;
-import java.util.Collection;
-import java.util.List;
-
-import org.apache.beehive.wsm.model.java.JavaTypeInfo;
-
-/**
- * @author Daryoush
- */
-public interface BeehiveWsTypeMetadata {
-
-    void initHandlersFromChainConfig(URL chainConfigURL, String chainName)
-        throws Exception;
-
-    String getHcFileName();
-
-    void setHcFileName(String hcFileName);
-
-    public String getHcName();
-
-    public void setHcName(String hcName);
-
-    String getSiValue();
-
-    void setSiValue(String siValue);
-
-    BeehiveWsSOAPBindingInfo getSoapBinding();
-
-    void setSoapBinding(BeehiveWsSOAPBindingInfo soapBinding);
-
-    String getWsName();
-
-    void setWsName(String wsName);
-
-    String getWsServiceName();
-
-    void setWsServiceName(String wsServiceName);
-
-    String getWsTargetNamespace();
-
-    void setWsTargetNamespace(String wsTargetNamespace);
-
-    public String[] getTargetNamespaceParts();
-
-    String getWsEndpointInterface();
-
-    void setWsEndpointInterface(String wsEndpointInterface);
-
-    String getWsWsdlLocation();
-
-    void setWsWsdlLocation(String wsWsdlLocation);
-
-    Collection<? extends BeehiveWsMethodMetadata> getMethods();
-
-    public abstract BeehiveWsMethodMetadata getMethod(String methodName, Class... paramTypes);
-
-    /**
-     * @throws ValidationException if duplicate methods are encountered or if a
-     *                             Document style service attempts to overload methods.
-     */
-    void addMethod(BeehiveWsMethodMetadata method)
-        throws ValidationException;
-
-    List<? extends BeehiveWsSOAPMessageHandlerInfo> getSoapHandlers();
-
-    void addSOAPHandler(BeehiveWsSOAPMessageHandlerInfo soapHandler);
-
-    String getClassName();
-
-    void setClassName(String className);
-
-    void merge(JavaTypeInfo jt)
-        throws Exception;
-}
+/*
+ * Copyright 2004 The Apache Software Foundation
+ *
+ * Licensed 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.
+ *
+ * $Header:$Factory
+ */
+package org.apache.beehive.wsm.model;
+
+import java.net.URL;
+import java.util.Collection;
+import java.util.List;
+
+import org.apache.beehive.wsm.model.java.JavaTypeInfo;
+
+/**
+ * @author Daryoush
+ */
+public interface BeehiveWsTypeMetadata {
+
+    void initHandlersFromChainConfig(URL chainConfigURL, String chainName)
+        throws Exception;
+
+    String getHcFileName();
+
+    void setHcFileName(String hcFileName);
+
+    public String getHcName();
+
+    public void setHcName(String hcName);
+
+    String getSiValue();
+
+    void setSiValue(String siValue);
+
+    BeehiveWsSOAPBindingInfo getSoapBinding();
+
+    void setSoapBinding(BeehiveWsSOAPBindingInfo soapBinding);
+
+    String getWsName();
+
+    void setWsName(String wsName);
+
+    String getWsServiceName();
+
+    void setWsServiceName(String wsServiceName);
+
+    String getWsTargetNamespace();
+
+    void setWsTargetNamespace(String wsTargetNamespace);
+
+    public String[] getTargetNamespaceParts();
+
+    String getWsEndpointInterface();
+
+    void setWsEndpointInterface(String wsEndpointInterface);
+
+    String getWsWsdlLocation();
+
+    void setWsWsdlLocation(String wsWsdlLocation);
+
+    Collection<? extends BeehiveWsMethodMetadata> getMethods();
+
+    public abstract BeehiveWsMethodMetadata getMethod(String methodName, Class... paramTypes);
+
+    /**
+     * @throws ValidationException if duplicate methods are encountered or if a
+     *                             Document style service attempts to overload methods.
+     */
+    void addMethod(BeehiveWsMethodMetadata method)
+        throws ValidationException;
+
+    List<? extends BeehiveWsSOAPMessageHandlerInfo> getSoapHandlers();
+
+    void addSOAPHandler(BeehiveWsSOAPMessageHandlerInfo soapHandler);
+
+    String getClassName();
+
+    void setClassName(String className);
+
+    void merge(JavaTypeInfo jt)
+        throws Exception;
+}

Propchange: incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/model/BeehiveWsTypeMetadata.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/model/ValidationException.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/model/java/JavaMethodInfo.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/model/java/JavaParameterInfo.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/model/java/JavaTypeInfo.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/model/jsr181/Jsr181ObjectModelStore.java
------------------------------------------------------------------------------
    svn:eol-style = native

Modified: incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/model/jsr181/SOAPMessageHandlerInfo.java
URL: http://svn.apache.org/viewcvs/incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/model/jsr181/SOAPMessageHandlerInfo.java?rev=190652&r1=190651&r2=190652&view=diff
==============================================================================
--- incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/model/jsr181/SOAPMessageHandlerInfo.java (original)
+++ incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/model/jsr181/SOAPMessageHandlerInfo.java Tue Jun 14 12:36:38 2005
@@ -1,151 +1,151 @@
-/*
- * Copyright 2004 The Apache Software Foundation
- *
- * Licensed 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.
- *
- * $Header:$
- */
-package org.apache.beehive.wsm.model.jsr181;
-
-import java.util.ArrayList;
-import java.util.Arrays;
-import java.util.Collection;
-import java.util.Collections;
-import java.util.HashMap;
-import java.util.Map;
-import javax.jws.soap.InitParam;
-import javax.jws.soap.SOAPMessageHandler;
-
-import org.apache.beehive.wsm.model.BeehiveWsSOAPMessageHandlerInfo;
-
-public class SOAPMessageHandlerInfo
-    implements java.io.Serializable, BeehiveWsSOAPMessageHandlerInfo {
-    private static final long serialVersionUID = 1L;
-
-    private String name;
-    private String className;
-    private HashMap<String, String> parameterMap = new HashMap<String, String>();
-    private Collection<String> roles = new ArrayList<String>();
-    private Collection<String> headers = new ArrayList<String>();
-
-    /**
-     *
-     */
-    public SOAPMessageHandlerInfo(SOAPMessageHandler annotation) {
-
-        // validate className
-        String className = annotation.className();
-        if(0 == className.length()) {
-            throw new IllegalArgumentException("className required to configure a SOAPMessageHandler");
-        }
-
-        // set fields from annotation
-        setClassName(className);
-        setName((0 < annotation.name().length()) ? annotation.name() : className);
-        for(InitParam p : annotation.initParams()) {
-            addInitParam(p.name(), p.value());
-        }
-        addRoles(Arrays.asList(annotation.roles()));
-        for(String s : annotation.headers()) {
-            addHeader(s);
-        }
-    }
-
-    public SOAPMessageHandlerInfo(String handlerClassName,
-                                  String handlerName,
-                                  Map<String, String> initParams,
-                                  Collection<String> roles,
-                                  Collection<String> headers) {
-        setClassName(handlerClassName);
-        setName((handlerName != null && handlerName.length() > 0) ? handlerName : handlerClassName);
-        addInitParams(initParams);
-        addRoles(roles);
-        addHeaders(headers);
-    }
-
-    /**
-     * @return Returns the className.
-     */
-    public String getClassName() {
-        return className;
-    }
-
-    /**
-     * @param className The className to set.
-     */
-    public void setClassName(String className) {
-        this.className = className;
-    }
-
-    /**
-     * @return Returns the name.
-     */
-    public String getName() {
-        return name;
-    }
-
-    /**
-     * @param name The name to set.
-     */
-    public void setName(String name) {
-        this.name = name;
-    }
-
-    /**
-     * @return Returns the headers.
-     */
-    public Collection<String> getHeaders() {
-        return Collections.unmodifiableCollection(headers);
-    }
-
-    public void addHeader(String header) {
-        this.headers.add(header);
-    }
-
-    /**
-     * @param headers
-     */
-    private void addHeaders(Collection<String> headers) {
-        this.headers.addAll(headers);
-    }
-
-    /**
-     * @return Returns the params.
-     */
-    public Map<String, String> getParameterMap() {
-        return Collections.unmodifiableMap(parameterMap);
-    }
-
-    public void addInitParam(String key, String value) {
-        parameterMap.put(key, value);
-    }
-
-    public void addInitParams(Map<String, String> params) {
-        parameterMap.putAll(params);
-    }
-
-    /**
-     * @return Returns the roles.
-     */
-    public Collection<String> getRoles() {
-        return Collections.unmodifiableCollection(roles);
-    }
-
-    public void addRole(String role) {
-        this.roles.add(role);
-    }
-
-    public void addRoles(Collection<String> roles) {
-        this.roles.addAll(roles);
-    }
-}
+/*
+ * Copyright 2004 The Apache Software Foundation
+ *
+ * Licensed 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.
+ *
+ * $Header:$
+ */
+package org.apache.beehive.wsm.model.jsr181;
+
+import java.util.ArrayList;
+import java.util.Arrays;
+import java.util.Collection;
+import java.util.Collections;
+import java.util.HashMap;
+import java.util.Map;
+import javax.jws.soap.InitParam;
+import javax.jws.soap.SOAPMessageHandler;
+
+import org.apache.beehive.wsm.model.BeehiveWsSOAPMessageHandlerInfo;
+
+public class SOAPMessageHandlerInfo
+    implements java.io.Serializable, BeehiveWsSOAPMessageHandlerInfo {
+    private static final long serialVersionUID = 1L;
+
+    private String name;
+    private String className;
+    private HashMap<String, String> parameterMap = new HashMap<String, String>();
+    private Collection<String> roles = new ArrayList<String>();
+    private Collection<String> headers = new ArrayList<String>();
+
+    /**
+     *
+     */
+    public SOAPMessageHandlerInfo(SOAPMessageHandler annotation) {
+
+        // validate className
+        String className = annotation.className();
+        if(0 == className.length()) {
+            throw new IllegalArgumentException("className required to configure a SOAPMessageHandler");
+        }
+
+        // set fields from annotation
+        setClassName(className);
+        setName((0 < annotation.name().length()) ? annotation.name() : className);
+        for(InitParam p : annotation.initParams()) {
+            addInitParam(p.name(), p.value());
+        }
+        addRoles(Arrays.asList(annotation.roles()));
+        for(String s : annotation.headers()) {
+            addHeader(s);
+        }
+    }
+
+    public SOAPMessageHandlerInfo(String handlerClassName,
+                                  String handlerName,
+                                  Map<String, String> initParams,
+                                  Collection<String> roles,
+                                  Collection<String> headers) {
+        setClassName(handlerClassName);
+        setName((handlerName != null && handlerName.length() > 0) ? handlerName : handlerClassName);
+        addInitParams(initParams);
+        addRoles(roles);
+        addHeaders(headers);
+    }
+
+    /**
+     * @return Returns the className.
+     */
+    public String getClassName() {
+        return className;
+    }
+
+    /**
+     * @param className The className to set.
+     */
+    public void setClassName(String className) {
+        this.className = className;
+    }
+
+    /**
+     * @return Returns the name.
+     */
+    public String getName() {
+        return name;
+    }
+
+    /**
+     * @param name The name to set.
+     */
+    public void setName(String name) {
+        this.name = name;
+    }
+
+    /**
+     * @return Returns the headers.
+     */
+    public Collection<String> getHeaders() {
+        return Collections.unmodifiableCollection(headers);
+    }
+
+    public void addHeader(String header) {
+        this.headers.add(header);
+    }
+
+    /**
+     * @param headers
+     */
+    private void addHeaders(Collection<String> headers) {
+        this.headers.addAll(headers);
+    }
+
+    /**
+     * @return Returns the params.
+     */
+    public Map<String, String> getParameterMap() {
+        return Collections.unmodifiableMap(parameterMap);
+    }
+
+    public void addInitParam(String key, String value) {
+        parameterMap.put(key, value);
+    }
+
+    public void addInitParams(Map<String, String> params) {
+        parameterMap.putAll(params);
+    }
+
+    /**
+     * @return Returns the roles.
+     */
+    public Collection<String> getRoles() {
+        return Collections.unmodifiableCollection(roles);
+    }
+
+    public void addRole(String role) {
+        this.roles.add(role);
+    }
+
+    public void addRoles(Collection<String> roles) {
+        this.roles.addAll(roles);
+    }
+}

Propchange: incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/model/jsr181/SOAPMessageHandlerInfo.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/processor/apt/MirrorMethodInfo.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/processor/apt/MirrorParameterInfo.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/processor/apt/MirrorTypeInfo.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/processor/apt/TypeMirrorUtil.java
------------------------------------------------------------------------------
    svn:eol-style = native

Modified: incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/processor/apt/WebServiceMetadataViewer.java
URL: http://svn.apache.org/viewcvs/incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/processor/apt/WebServiceMetadataViewer.java?rev=190652&r1=190651&r2=190652&view=diff
==============================================================================
--- incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/processor/apt/WebServiceMetadataViewer.java (original)
+++ incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/processor/apt/WebServiceMetadataViewer.java Tue Jun 14 12:36:38 2005
@@ -1,160 +1,160 @@
-/*
- * Copyright 2004 The Apache Software Foundation
- *
- * Licensed 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.
- *
- * $Header:$
- */
-package org.apache.beehive.wsm.processor.apt;
-
-import java.util.Collection;
-
-import org.apache.beehive.wsm.model.BeehiveWsMethodMetadata;
-import org.apache.beehive.wsm.model.BeehiveWsParameterMetadata;
-import org.apache.beehive.wsm.model.BeehiveWsSOAPBindingInfo;
-import org.apache.beehive.wsm.model.BeehiveWsTypeMetadata;
-
-public class WebServiceMetadataViewer {
-
-    // adhock. assume Metadata is not nested more than 5 times.  :p
-    private static String[] TABS = new String[]{
-        "",
-        "   ",
-        "      ",
-        "         ",
-        "            ",
-        "               "
-    };
-
-    /* whack
-    public static void print(BeehiveWsTypeMetadata webServiceTYPEMetadata) {
-        print(0, webServiceTYPEMetadata);
-    }
-    */
-
-    public static void print(int tab, BeehiveWsTypeMetadata webServiceTYPEMetadata) {
-        print(tab, "<TYPE > > >WebServiceTYPEMetadata");
-        print(tab, "wsName", webServiceTYPEMetadata.getWsName());
-        print(tab, "wsServiceName", webServiceTYPEMetadata.getWsServiceName());
-        print(tab, "wsWsdlLocation", webServiceTYPEMetadata.getWsWsdlLocation());
-        print(tab, "wsTargetNamespace", webServiceTYPEMetadata.getWsTargetNamespace());
-        print(tab, "wsEndpointInterface", webServiceTYPEMetadata.getWsEndpointInterface());
-        print(tab, "hcFileName", webServiceTYPEMetadata.getHcFileName());
-        print(tab, "hcName", webServiceTYPEMetadata.getHcName());
-        //print( tab, "siRunAs"             , webServiceTYPEMetadata.getSiRunAs() );
-//        print(tab, "serviceImplementationBean", webServiceTYPEMetadata.getServiceImplementationBean());
-        print("");
-        tab++;
-        print(tab, webServiceTYPEMetadata.getMethods());
-        print(tab, webServiceTYPEMetadata.getSoapBinding());
-    }
-
-    /* whack
-    public static void print(Collection collection) {
-        print(0, collection);
-    }
-    */
-
-    public static void print(int tab, Collection collection) {
-        if(collection == null)
-            return;
-        for(Object element : collection) {
-            if(element instanceof BeehiveWsTypeMetadata) {
-                print(tab, (BeehiveWsTypeMetadata)element);
-            }
-            else if(element instanceof BeehiveWsMethodMetadata) {
-                print(tab, (BeehiveWsMethodMetadata)element);
-            }
-            else if(element instanceof BeehiveWsParameterMetadata) {
-                print(tab, (BeehiveWsParameterMetadata)element);
-            }
-        }
-    }
-
-    /* whack
-    public static void print(BeehiveWsMethodMetadata webServiceMETHODMetadata) {
-        print(0, webServiceMETHODMetadata);
-    }
-    */
-
-    public static void print(int tab, BeehiveWsMethodMetadata webServiceMETHODMetadata) {
-        if(webServiceMETHODMetadata == null)
-            return;
-        print(tab, "<METHOD > > > > > >WebServiceMETHODMetadata");
-        print(tab, "wmOperationName", webServiceMETHODMetadata.getWmOperationName());
-        print(tab, "wmAction", webServiceMETHODMetadata.getWmAction());
-        print(tab, "oneway", webServiceMETHODMetadata.isOneWay() ? "true" : "false");
-        print(tab, "wrName", webServiceMETHODMetadata.getWrName());
-        print(tab, "javaMethodName", webServiceMETHODMetadata.getJavaMethodName());
-        print(tab, "javaReturnType", webServiceMETHODMetadata.getJavaReturnType());
-
-        //print( tab, "DwRequestElement");
-        //print( tab, webServiceMETHODMetadata.getDwRequestElement() );
-        //print( tab, webServiceMETHODMetadata.getDwResponseElement() );
-
-        //print( tab, "DwResponseElement");
-        //print( tab, webServiceMETHODMetadata.getSoapBinding() );
-
-        print("");
-        tab++;
-        print(tab, webServiceMETHODMetadata.getParams());
-    }
-
-    /* whack
-    public static void print(BeehiveWsParameterMetadata webServicePARAMETERMetadata) {
-        print(0, webServicePARAMETERMetadata);
-    }
-    */
-
-    public static void print(int tab, BeehiveWsParameterMetadata webServicePARAMETERMetadata) {
-        if(webServicePARAMETERMetadata == null)
-            return;
-        print(tab, "<PARAM > > > > > > > > >WebServicePARAMETERMetadata");
-        print(tab, "wpName", webServicePARAMETERMetadata.getWpName());
-        print(tab, "wpMode", webServicePARAMETERMetadata.getWpMode());
-        print(tab, "wpHeader", webServicePARAMETERMetadata.isWpHeader() ? "true" : "false");
-        print(tab, "javaType", webServicePARAMETERMetadata.getJavaType());
-        //print( "defaultName", webServicePARAMETERMetadata.getDefaultName());
-
-        print("");
-    }
-
-    /* whack
-    public static void print(BeehiveWsSOAPBindingInfo soapBindingInfo) {
-        print(0, soapBindingInfo);
-    }
-    */
-
-    public static void print(int tab, BeehiveWsSOAPBindingInfo soapBindingInfo) {
-        if(soapBindingInfo == null)
-            return;
-        print(tab, ">SOAPBindingInfo");
-        print(tab, "style", soapBindingInfo.getStyle());
-        print(tab, "use", soapBindingInfo.getUse());
-        print(tab, "style", soapBindingInfo.getParameterStyle());
-    }
-
-
-    public static void print(int tab, String msg, Object data) {
-        print(tab, msg + " : " + data);
-    }
-
-    public static void print(int tab, String msg) {
-        print(TABS[tab] + msg);
-    }
-
-    public static void print(String msg) {
-        System.out.println(msg);
-    }
-
-}
+/*
+ * Copyright 2004 The Apache Software Foundation
+ *
+ * Licensed 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.
+ *
+ * $Header:$
+ */
+package org.apache.beehive.wsm.processor.apt;
+
+import java.util.Collection;
+
+import org.apache.beehive.wsm.model.BeehiveWsMethodMetadata;
+import org.apache.beehive.wsm.model.BeehiveWsParameterMetadata;
+import org.apache.beehive.wsm.model.BeehiveWsSOAPBindingInfo;
+import org.apache.beehive.wsm.model.BeehiveWsTypeMetadata;
+
+public class WebServiceMetadataViewer {
+
+    // adhock. assume Metadata is not nested more than 5 times.  :p
+    private static String[] TABS = new String[]{
+        "",
+        "   ",
+        "      ",
+        "         ",
+        "            ",
+        "               "
+    };
+
+    /* whack
+    public static void print(BeehiveWsTypeMetadata webServiceTYPEMetadata) {
+        print(0, webServiceTYPEMetadata);
+    }
+    */
+
+    public static void print(int tab, BeehiveWsTypeMetadata webServiceTYPEMetadata) {
+        print(tab, "<TYPE > > >WebServiceTYPEMetadata");
+        print(tab, "wsName", webServiceTYPEMetadata.getWsName());
+        print(tab, "wsServiceName", webServiceTYPEMetadata.getWsServiceName());
+        print(tab, "wsWsdlLocation", webServiceTYPEMetadata.getWsWsdlLocation());
+        print(tab, "wsTargetNamespace", webServiceTYPEMetadata.getWsTargetNamespace());
+        print(tab, "wsEndpointInterface", webServiceTYPEMetadata.getWsEndpointInterface());
+        print(tab, "hcFileName", webServiceTYPEMetadata.getHcFileName());
+        print(tab, "hcName", webServiceTYPEMetadata.getHcName());
+        //print( tab, "siRunAs"             , webServiceTYPEMetadata.getSiRunAs() );
+//        print(tab, "serviceImplementationBean", webServiceTYPEMetadata.getServiceImplementationBean());
+        print("");
+        tab++;
+        print(tab, webServiceTYPEMetadata.getMethods());
+        print(tab, webServiceTYPEMetadata.getSoapBinding());
+    }
+
+    /* whack
+    public static void print(Collection collection) {
+        print(0, collection);
+    }
+    */
+
+    public static void print(int tab, Collection collection) {
+        if(collection == null)
+            return;
+        for(Object element : collection) {
+            if(element instanceof BeehiveWsTypeMetadata) {
+                print(tab, (BeehiveWsTypeMetadata)element);
+            }
+            else if(element instanceof BeehiveWsMethodMetadata) {
+                print(tab, (BeehiveWsMethodMetadata)element);
+            }
+            else if(element instanceof BeehiveWsParameterMetadata) {
+                print(tab, (BeehiveWsParameterMetadata)element);
+            }
+        }
+    }
+
+    /* whack
+    public static void print(BeehiveWsMethodMetadata webServiceMETHODMetadata) {
+        print(0, webServiceMETHODMetadata);
+    }
+    */
+
+    public static void print(int tab, BeehiveWsMethodMetadata webServiceMETHODMetadata) {
+        if(webServiceMETHODMetadata == null)
+            return;
+        print(tab, "<METHOD > > > > > >WebServiceMETHODMetadata");
+        print(tab, "wmOperationName", webServiceMETHODMetadata.getWmOperationName());
+        print(tab, "wmAction", webServiceMETHODMetadata.getWmAction());
+        print(tab, "oneway", webServiceMETHODMetadata.isOneWay() ? "true" : "false");
+        print(tab, "wrName", webServiceMETHODMetadata.getWrName());
+        print(tab, "javaMethodName", webServiceMETHODMetadata.getJavaMethodName());
+        print(tab, "javaReturnType", webServiceMETHODMetadata.getJavaReturnType());
+
+        //print( tab, "DwRequestElement");
+        //print( tab, webServiceMETHODMetadata.getDwRequestElement() );
+        //print( tab, webServiceMETHODMetadata.getDwResponseElement() );
+
+        //print( tab, "DwResponseElement");
+        //print( tab, webServiceMETHODMetadata.getSoapBinding() );
+
+        print("");
+        tab++;
+        print(tab, webServiceMETHODMetadata.getParams());
+    }
+
+    /* whack
+    public static void print(BeehiveWsParameterMetadata webServicePARAMETERMetadata) {
+        print(0, webServicePARAMETERMetadata);
+    }
+    */
+
+    public static void print(int tab, BeehiveWsParameterMetadata webServicePARAMETERMetadata) {
+        if(webServicePARAMETERMetadata == null)
+            return;
+        print(tab, "<PARAM > > > > > > > > >WebServicePARAMETERMetadata");
+        print(tab, "wpName", webServicePARAMETERMetadata.getWpName());
+        print(tab, "wpMode", webServicePARAMETERMetadata.getWpMode());
+        print(tab, "wpHeader", webServicePARAMETERMetadata.isWpHeader() ? "true" : "false");
+        print(tab, "javaType", webServicePARAMETERMetadata.getJavaType());
+        //print( "defaultName", webServicePARAMETERMetadata.getDefaultName());
+
+        print("");
+    }
+
+    /* whack
+    public static void print(BeehiveWsSOAPBindingInfo soapBindingInfo) {
+        print(0, soapBindingInfo);
+    }
+    */
+
+    public static void print(int tab, BeehiveWsSOAPBindingInfo soapBindingInfo) {
+        if(soapBindingInfo == null)
+            return;
+        print(tab, ">SOAPBindingInfo");
+        print(tab, "style", soapBindingInfo.getStyle());
+        print(tab, "use", soapBindingInfo.getUse());
+        print(tab, "style", soapBindingInfo.getParameterStyle());
+    }
+
+
+    public static void print(int tab, String msg, Object data) {
+        print(tab, msg + " : " + data);
+    }
+
+    public static void print(int tab, String msg) {
+        print(TABS[tab] + msg);
+    }
+
+    public static void print(String msg) {
+        System.out.println(msg);
+    }
+
+}

Propchange: incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/processor/apt/WebServiceMetadataViewer.java
------------------------------------------------------------------------------
    svn:eol-style = native

Modified: incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/registration/TypeRegistrar.java
URL: http://svn.apache.org/viewcvs/incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/registration/TypeRegistrar.java?rev=190652&r1=190651&r2=190652&view=diff
==============================================================================
--- incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/registration/TypeRegistrar.java (original)
+++ incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/registration/TypeRegistrar.java Tue Jun 14 12:36:38 2005
@@ -1,281 +1,281 @@
-/*
- * 
- * Copyright 2001-2004 The Apache Software Foundation.
- * 
- * 
- * Licensed 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.beehive.wsm.registration;
-
-import java.io.File;
-import java.lang.reflect.Array;
-import java.lang.reflect.Field;
-import java.lang.reflect.GenericArrayType;
-import java.lang.reflect.InvocationTargetException;
-import java.lang.reflect.ParameterizedType;
-import java.lang.reflect.Type;
-import java.rmi.Remote;
-import javax.jws.soap.SOAPBinding;
-import javax.xml.namespace.QName;
-import javax.xml.rpc.encoding.TypeMapping;
-import javax.xml.rpc.holders.Holder;
-
-import org.apache.beehive.wsm.databinding.BindingLookupService;
-import org.apache.beehive.wsm.databinding.GenericHolder;
-import org.apache.commons.logging.Log;
-import org.apache.commons.logging.LogFactory;
-
-public abstract class TypeRegistrar {
-
-    private static Log LOGGER = LogFactory.getLog(TypeRegistrar.class);
-
-    /* todo: need to figure out how to protect these since they're used by subclasses */
-    protected TypeMapping mTypeMapping;
-    protected BindingLookupService lookupService;
-
-    /**
-     * @param typeMapping
-     * @param lookupService
-     */
-    public TypeRegistrar(TypeMapping typeMapping, BindingLookupService lookupService) {
-        super();
-        mTypeMapping = typeMapping;
-        this.lookupService = lookupService;
-    }
-
-    /**
-     * @param cls
-     * @return QName
-     */
-    protected abstract QName getRegisteredQName(Class cls);
-
-    /**
-     * @param cls
-     * @param q
-     */
-    abstract protected void registerClassAsWithDefaultSearialization(Class cls,
-                                                                     QName q,
-                                                                     SOAPBinding.Style style,
-                                                                     SOAPBinding.Use use);
-
-    /**
-     * @param cls
-     * @param q
-     */
-    abstract protected void registerClassAsXMLBeans(Class cls, QName q);
-
-    /**
-     * @param cls
-     * @param q
-     * @throws ClassNotFoundException
-     * @throws NoSuchMethodException
-     * @throws InstantiationException
-     * @throws IllegalAccessException
-     * @throws InvocationTargetException
-     */
-    abstract protected void registerClassAsDataHandler(Class cls, QName q)
-        throws ClassNotFoundException,
-        NoSuchMethodException,
-        InstantiationException,
-        IllegalAccessException,
-        InvocationTargetException;
-
-    /**
-     * @param cls
-     * @param q
-     */
-    abstract protected void registerClassAsSoapEncodedArray(Class cls, QName q);
-
-    /**
-     * @param cls
-     * @param q
-     * @return boolean
-     */
-    abstract protected boolean classIsRegistered(Class cls, QName q);
-
-    /**
-     * @return QName
-     */
-    abstract public QName getVoidType();
-
-    abstract protected boolean isBuiltInType(Class cls);
-
-    abstract protected QName getBuiltInTypeQname(Class cls);
-
-    public QName registerType(Class cls, SOAPBinding.Style style,
-                              SOAPBinding.Use use) {
-        QName q;
-        if(SOAPBinding.Use.ENCODED == use && cls.isArray()) {
-            q = lookupService.class2qname(cls.getComponentType());
-        }
-        else {
-            q = lookupService.class2qname(cls);
-        }
-        return registerType(cls, q, style, use);
-    }
-
-    public QName registerType(Class cls, QName q, SOAPBinding.Style style, SOAPBinding.Use use) {
-        try {
-            LOGGER.debug("Register class: " + cls.getCanonicalName() + " qName: " + q);
-
-            if(Void.TYPE.equals(cls))
-                return null;
-
-            if(isBuiltInType(cls))
-                return getBuiltInTypeQname(cls);
-            if(q == null)
-                throw new RuntimeException(
-                    "Invalid registeration requestion qname is null");
-
-            if(cls.isArray()) {
-                if(SOAPBinding.Use.ENCODED == use) {
-
-                    // The Qname modification was needed to run the GoogleThe qname of the array must be different from the qname of the element.
-                    // I don't think the qname really matters, as the array qname wont be in the message
-                    // The qname of the array is available in the WSDL, but at this point we don't
-                    // have the information, I have added "Array" at the end of the qname, it can
-                    // be anything else and the code seems to work (from the client side).
-                    // if this needs to be the real name of the array, somehow WSDL information
-                    // must be made available to this method.
-                    QName arrayQname = new QName(q.getNamespaceURI(), q.getLocalPart() + "Array");
-
-                    if(!classIsRegistered(cls, arrayQname))
-                        registerClassAsSoapEncodedArray(cls, arrayQname);
-                }
-                // incase of literal, or encoded register the class also
-                q = registerType(cls.getComponentType(), q, style, use);
-            }
-            else if(!classIsRegistered(cls, q)) {
-
-                if(org.apache.xmlbeans.XmlObject.class.isAssignableFrom(cls)) {
-                    registerClassAsXMLBeans(cls, q);
-                }
-                /*
-                 * NOTE jcolwell@bea.com 2004-Oct-11 -- these datahandler using
-                 * classes are generally already registered but just in case...
-                 */
-                else if(isActivationEnabled()
-                    && (java.awt.Image.class.isAssignableFrom(cls)
-                    || getMultipartClass().isAssignableFrom(cls)
-                    || getDataHandlerClass().isAssignableFrom(cls))) {
-                    try {
-                        registerClassAsDataHandler(cls, q);
-                    }
-                    catch(Exception e) {
-                        /*
-                               * FIXME jcolwell@bea.com 2004-Oct-08 -- log this
-                               * properly
-                               */
-                        e.printStackTrace();
-                    }
-                }
-                /*
-                 * NOTE jcolwell@bea.com 2004-Oct-11 -- java.rmi.Remote is
-                 * prohibited by the jax-rpc spec.
-                 */
-                /*
-                 * NOTE jcolwell@bea.com 2004-Oct-11 -- restricting against File
-                 * since, it doesn't make sense to serialize as a bean. That and
-                 * it causes an infinite loop as it keeps returning itself from
-                 * the getAbsoluteFile and getCanonicalFile calls
-                 */
-                else if(!Remote.class.isAssignableFrom(cls) && !File.class.isAssignableFrom(cls)) {
-                    registerClassAsWithDefaultSearialization(cls, q, style, use);
-                }
-                else {
-                    throw new RuntimeException("failed to register "
-                        + cls.getName()
-                        + " as a valid web service datatype,"
-                        + " consider using a custom type mapping");
-                }
-            }
-            LOGGER.info("Registered class: " + cls.getCanonicalName() + " qName: " + q);
-            return q;
-        }
-        catch(RuntimeException e) {
-            LOGGER.error("Failed to register class: " + cls.getCanonicalName()
-                + " type: " + q.getNamespaceURI() + ":" + q.getLocalPart());
-
-            e.printStackTrace();
-            throw e;
-        }
-    }
-
-    private boolean isActivationEnabled() {
-        return null != getDataHandlerClass() && null != getMultipartClass();
-    }
-
-    private Class getDataHandlerClass() {
-        try {
-            return getClass().getClassLoader().loadClass("javax.activation.DataHandler");
-        }
-        catch(Exception e) {
-        }
-        return null;
-    }
-
-    private Class getMultipartClass() {
-        try {
-            return getClass().getClassLoader().loadClass("javax.mail.internet.MimeMultipart");
-        }
-        catch(Exception e) {
-        }
-        return null;
-    }
-
-    /**
-     * @param t
-     */
-    static public Class getHoldersValueClass(Type t) {
-        Class res = null;
-
-        if(t instanceof ParameterizedType) {
-            ParameterizedType pt = (ParameterizedType)t;
-            Type raw = pt.getRawType();
-            if(GenericHolder.class.isAssignableFrom((Class)raw)) {
-                Type[] typeArgs = pt.getActualTypeArguments();
-                if(typeArgs[0] instanceof GenericArrayType) {
-                    Class arrayElementType = (Class)((GenericArrayType)typeArgs[0]).getGenericComponentType();
-                    res = Array.newInstance(arrayElementType, 0).getClass();
-                }
-                else {
-                    res = (Class)typeArgs[0];
-                }
-            }
-            else {
-                throw new RuntimeException("Invalid parameterized type for holder: " + t);
-            }
-
-        }
-        else if(t instanceof Class) {
-            if(Holder.class.isAssignableFrom((Class)t)) {
-                // if type is not a holder type, there is no point to dig any
-                // deeper
-                Field[] publicFields = ((Class)t).getFields();
-                for(int i = 0; i < publicFields.length; i++) {
-                    if(0 == "value".compareTo(publicFields[i].getName())) {
-                        res = publicFields[i].getType();
-                        break;
-                    }
-                }
-            }
-            else {
-                throw new RuntimeException("Invalid class.  Type: " + t + " is not a holder.");
-            }
-        }
-        // other wise just return the type
-        return res;
-    }
+/*
+ * 
+ * Copyright 2001-2004 The Apache Software Foundation.
+ * 
+ * 
+ * Licensed 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.beehive.wsm.registration;
+
+import java.io.File;
+import java.lang.reflect.Array;
+import java.lang.reflect.Field;
+import java.lang.reflect.GenericArrayType;
+import java.lang.reflect.InvocationTargetException;
+import java.lang.reflect.ParameterizedType;
+import java.lang.reflect.Type;
+import java.rmi.Remote;
+import javax.jws.soap.SOAPBinding;
+import javax.xml.namespace.QName;
+import javax.xml.rpc.encoding.TypeMapping;
+import javax.xml.rpc.holders.Holder;
+
+import org.apache.beehive.wsm.databinding.BindingLookupService;
+import org.apache.beehive.wsm.databinding.GenericHolder;
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
+
+public abstract class TypeRegistrar {
+
+    private static Log LOGGER = LogFactory.getLog(TypeRegistrar.class);
+
+    /* todo: need to figure out how to protect these since they're used by subclasses */
+    protected TypeMapping mTypeMapping;
+    protected BindingLookupService lookupService;
+
+    /**
+     * @param typeMapping
+     * @param lookupService
+     */
+    public TypeRegistrar(TypeMapping typeMapping, BindingLookupService lookupService) {
+        super();
+        mTypeMapping = typeMapping;
+        this.lookupService = lookupService;
+    }
+
+    /**
+     * @param cls
+     * @return QName
+     */
+    protected abstract QName getRegisteredQName(Class cls);
+
+    /**
+     * @param cls
+     * @param q
+     */
+    abstract protected void registerClassAsWithDefaultSearialization(Class cls,
+                                                                     QName q,
+                                                                     SOAPBinding.Style style,
+                                                                     SOAPBinding.Use use);
+
+    /**
+     * @param cls
+     * @param q
+     */
+    abstract protected void registerClassAsXMLBeans(Class cls, QName q);
+
+    /**
+     * @param cls
+     * @param q
+     * @throws ClassNotFoundException
+     * @throws NoSuchMethodException
+     * @throws InstantiationException
+     * @throws IllegalAccessException
+     * @throws InvocationTargetException
+     */
+    abstract protected void registerClassAsDataHandler(Class cls, QName q)
+        throws ClassNotFoundException,
+        NoSuchMethodException,
+        InstantiationException,
+        IllegalAccessException,
+        InvocationTargetException;
+
+    /**
+     * @param cls
+     * @param q
+     */
+    abstract protected void registerClassAsSoapEncodedArray(Class cls, QName q);
+
+    /**
+     * @param cls
+     * @param q
+     * @return boolean
+     */
+    abstract protected boolean classIsRegistered(Class cls, QName q);
+
+    /**
+     * @return QName
+     */
+    abstract public QName getVoidType();
+
+    abstract protected boolean isBuiltInType(Class cls);
+
+    abstract protected QName getBuiltInTypeQname(Class cls);
+
+    public QName registerType(Class cls, SOAPBinding.Style style,
+                              SOAPBinding.Use use) {
+        QName q;
+        if(SOAPBinding.Use.ENCODED == use && cls.isArray()) {
+            q = lookupService.class2qname(cls.getComponentType());
+        }
+        else {
+            q = lookupService.class2qname(cls);
+        }
+        return registerType(cls, q, style, use);
+    }
+
+    public QName registerType(Class cls, QName q, SOAPBinding.Style style, SOAPBinding.Use use) {
+        try {
+            LOGGER.debug("Register class: " + cls.getCanonicalName() + " qName: " + q);
+
+            if(Void.TYPE.equals(cls))
+                return null;
+
+            if(isBuiltInType(cls))
+                return getBuiltInTypeQname(cls);
+            if(q == null)
+                throw new RuntimeException(
+                    "Invalid registeration requestion qname is null");
+
+            if(cls.isArray()) {
+                if(SOAPBinding.Use.ENCODED == use) {
+
+                    // The Qname modification was needed to run the GoogleThe qname of the array must be different from the qname of the element.
+                    // I don't think the qname really matters, as the array qname wont be in the message
+                    // The qname of the array is available in the WSDL, but at this point we don't
+                    // have the information, I have added "Array" at the end of the qname, it can
+                    // be anything else and the code seems to work (from the client side).
+                    // if this needs to be the real name of the array, somehow WSDL information
+                    // must be made available to this method.
+                    QName arrayQname = new QName(q.getNamespaceURI(), q.getLocalPart() + "Array");
+
+                    if(!classIsRegistered(cls, arrayQname))
+                        registerClassAsSoapEncodedArray(cls, arrayQname);
+                }
+                // incase of literal, or encoded register the class also
+                q = registerType(cls.getComponentType(), q, style, use);
+            }
+            else if(!classIsRegistered(cls, q)) {
+
+                if(org.apache.xmlbeans.XmlObject.class.isAssignableFrom(cls)) {
+                    registerClassAsXMLBeans(cls, q);
+                }
+                /*
+                 * NOTE jcolwell@bea.com 2004-Oct-11 -- these datahandler using
+                 * classes are generally already registered but just in case...
+                 */
+                else if(isActivationEnabled()
+                    && (java.awt.Image.class.isAssignableFrom(cls)
+                    || getMultipartClass().isAssignableFrom(cls)
+                    || getDataHandlerClass().isAssignableFrom(cls))) {
+                    try {
+                        registerClassAsDataHandler(cls, q);
+                    }
+                    catch(Exception e) {
+                        /*
+                               * FIXME jcolwell@bea.com 2004-Oct-08 -- log this
+                               * properly
+                               */
+                        e.printStackTrace();
+                    }
+                }
+                /*
+                 * NOTE jcolwell@bea.com 2004-Oct-11 -- java.rmi.Remote is
+                 * prohibited by the jax-rpc spec.
+                 */
+                /*
+                 * NOTE jcolwell@bea.com 2004-Oct-11 -- restricting against File
+                 * since, it doesn't make sense to serialize as a bean. That and
+                 * it causes an infinite loop as it keeps returning itself from
+                 * the getAbsoluteFile and getCanonicalFile calls
+                 */
+                else if(!Remote.class.isAssignableFrom(cls) && !File.class.isAssignableFrom(cls)) {
+                    registerClassAsWithDefaultSearialization(cls, q, style, use);
+                }
+                else {
+                    throw new RuntimeException("failed to register "
+                        + cls.getName()
+                        + " as a valid web service datatype,"
+                        + " consider using a custom type mapping");
+                }
+            }
+            LOGGER.info("Registered class: " + cls.getCanonicalName() + " qName: " + q);
+            return q;
+        }
+        catch(RuntimeException e) {
+            LOGGER.error("Failed to register class: " + cls.getCanonicalName()
+                + " type: " + q.getNamespaceURI() + ":" + q.getLocalPart());
+
+            e.printStackTrace();
+            throw e;
+        }
+    }
+
+    private boolean isActivationEnabled() {
+        return null != getDataHandlerClass() && null != getMultipartClass();
+    }
+
+    private Class getDataHandlerClass() {
+        try {
+            return getClass().getClassLoader().loadClass("javax.activation.DataHandler");
+        }
+        catch(Exception e) {
+        }
+        return null;
+    }
+
+    private Class getMultipartClass() {
+        try {
+            return getClass().getClassLoader().loadClass("javax.mail.internet.MimeMultipart");
+        }
+        catch(Exception e) {
+        }
+        return null;
+    }
+
+    /**
+     * @param t
+     */
+    static public Class getHoldersValueClass(Type t) {
+        Class res = null;
+
+        if(t instanceof ParameterizedType) {
+            ParameterizedType pt = (ParameterizedType)t;
+            Type raw = pt.getRawType();
+            if(GenericHolder.class.isAssignableFrom((Class)raw)) {
+                Type[] typeArgs = pt.getActualTypeArguments();
+                if(typeArgs[0] instanceof GenericArrayType) {
+                    Class arrayElementType = (Class)((GenericArrayType)typeArgs[0]).getGenericComponentType();
+                    res = Array.newInstance(arrayElementType, 0).getClass();
+                }
+                else {
+                    res = (Class)typeArgs[0];
+                }
+            }
+            else {
+                throw new RuntimeException("Invalid parameterized type for holder: " + t);
+            }
+
+        }
+        else if(t instanceof Class) {
+            if(Holder.class.isAssignableFrom((Class)t)) {
+                // if type is not a holder type, there is no point to dig any
+                // deeper
+                Field[] publicFields = ((Class)t).getFields();
+                for(int i = 0; i < publicFields.length; i++) {
+                    if(0 == "value".compareTo(publicFields[i].getName())) {
+                        res = publicFields[i].getType();
+                        break;
+                    }
+                }
+            }
+            else {
+                throw new RuntimeException("Invalid class.  Type: " + t + " is not a holder.");
+            }
+        }
+        // other wise just return the type
+        return res;
+    }
 }

Propchange: incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/registration/TypeRegistrar.java
------------------------------------------------------------------------------
    svn:eol-style = native

Modified: incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/util/InvalidTypeMappingException.java
URL: http://svn.apache.org/viewcvs/incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/util/InvalidTypeMappingException.java?rev=190652&r1=190651&r2=190652&view=diff
==============================================================================
--- incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/util/InvalidTypeMappingException.java (original)
+++ incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/util/InvalidTypeMappingException.java Tue Jun 14 12:36:38 2005
@@ -1,44 +1,44 @@
-/*
- * InvalidTypeMappingException.java
- * 
- * Copyright 2001-2004 The Apache Software Foundation.
- * 
- * 
- * Licensed 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.beehive.wsm.util;
-
-/**
- * ****************************************************************************
- *
- * @author Jonathan Colwell
- */
-public class InvalidTypeMappingException
-    extends Exception {
-
-    public InvalidTypeMappingException() {
-        super();
-    }
-
-    public InvalidTypeMappingException(String message) {
-        super(message);
-    }
-
-    public InvalidTypeMappingException(String message, Throwable cause) {
-        super(message, cause);
-    }
-
-    public InvalidTypeMappingException(Throwable cause) {
-        super(cause);
-    }
-}
+/*
+ * InvalidTypeMappingException.java
+ * 
+ * Copyright 2001-2004 The Apache Software Foundation.
+ * 
+ * 
+ * Licensed 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.beehive.wsm.util;
+
+/**
+ * ****************************************************************************
+ *
+ * @author Jonathan Colwell
+ */
+public class InvalidTypeMappingException
+    extends Exception {
+
+    public InvalidTypeMappingException() {
+        super();
+    }
+
+    public InvalidTypeMappingException(String message) {
+        super(message);
+    }
+
+    public InvalidTypeMappingException(String message, Throwable cause) {
+        super(message, cause);
+    }
+
+    public InvalidTypeMappingException(Throwable cause) {
+        super(cause);
+    }
+}

Propchange: incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/util/InvalidTypeMappingException.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/wsdl/Model2AJava.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/wsdl/Schema.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/wsdl/Utilities.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/wsdl/WSDLParser.java
------------------------------------------------------------------------------
    svn:eol-style = native

Modified: incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/wsdl/wsdl2ajava.vm
URL: http://svn.apache.org/viewcvs/incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/wsdl/wsdl2ajava.vm?rev=190652&r1=190651&r2=190652&view=diff
==============================================================================
--- incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/wsdl/wsdl2ajava.vm (original)
+++ incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/wsdl/wsdl2ajava.vm Tue Jun 14 12:36:38 2005
@@ -1,182 +1,182 @@
-
-##
-##
-##
-#macro(webService $name $targetNamespace $wsdlLocation)
-@WebService (
-     name = "$name",
-     targetNamespace = "$targetNamespace"#if($wsdlLocation),
-     wsdlLocation = "$wsdlLocation"
-#end
-)
-#end
-##
-##
-##
-#macro(handlerChain $fileName $name)
-#if( $fileName || $name)
-@HandlerChain (
-     name = "$name",
-     file = "$fileName"
-)
-#end
-#end
-##
-##
-##
-#macro( soapBinding $sb)
-@SOAPBinding (
-     style = SOAPBinding.Style.$sb.style,
-     use = SOAPBinding.Use.$sb.use,
-     parameterStyle = SOAPBinding.ParameterStyle.$sb.parameterStyle
-)
-#end
-##
-##
-##
-#macro( soapMsgHandlers $handlers)
-#if($handlers.size() > 0)
-@SOAPMessageHandlers (
-#foreach( $smh in $handlers)
-     @SOAPMessageHandler (
-          name = "$smh.name",
-          className = "$snm.className" ,
-          roles = {
-#foreach($role in $smh.roles)
-               "$role"
-#end
-          }
-          headers = {
-#foreach($header in $smh.headers)
-               "$header"
-#end	
-          }
-          initParams = {
-#foreach($paramName in $smh.parameterMap.keySet())
-               @InitParam(
-                    name = "$paramName"
-                    value = "$smh.parameterMap.get($paramName)"
-               )
-#end
-          }
-     )
-#end
-)
-#end
-#end
-##
-##
-##
-#macro( webMethod $method)
-     @WebMethod(
-          operationName = "$method.wmOperationName"#if($method.wmAction),
-          action =" $method.wmAction"
-#end
-     )
-
-#end
-##
-##
-##
-#macro( results $method)
-#if($method.oneWay)
-     @Oneway
-#else 
-     @WebResult(
-          name = "$method.wrName",
-          targetNamespace = "$method.wrTargetNamespace" 
-     )
-#end
-#end
-##
-##
-
-##
-##
-#macro(params $method)
-#set($size=$method.params.size())
-#set($ctr=0)
-#foreach( $param in $method.params)
-#set($ctr=$ctr + 1)
-               @WebParam(
-                    name = "$param.wpName",
-                    targetNamespace = "$param.wpTargetNamespace",
-                    mode = WebParam.Mode.$param.wpMode,
-                    header = $param.wpHeader
-## For now use the hack to get the correct name. later change this to use element  -- Daryoush
-##              )$param.javaType.name $param.wpName#if($ctr < $size), 
-               )$param.javaTypeFullName $param.wpName#if($ctr < $size), 
-#end
-#end
-#end
-##
-##
-##	
-/* 
-This file is an Annotated java file that that is automatically generated 
-from wsdl: $webServiceOM.wsWsdlLocation
-
-*/
-#set($packageName="")
-#set($ctr=0)
-#set($size=$webServiceOM.targetNamespaceParts.size())
-#foreach( $dirName in $webServiceOM.targetNamespaceParts)
-#if($ctr != 0) #set($packageName="$packageName.")#end
-#set($ctr=$ctr + 1)
-#set($packageName="$packageName$dirName")
-#end
-##  package $packageName;   For now just use web as package name
-
-package web;
-
-import java.rmi.RemoteException;
-
-import javax.jws.Oneway;
-import javax.jws.WebMethod;
-import javax.jws.WebParam;
-import javax.jws.WebResult;
-import javax.jws.WebService;
-import javax.jws.soap.SOAPBinding;
-
-
-#webService($webServiceOM.wsName $webServiceOM.wsTargetNamespace $webServiceOM.wsWsdlLocation)
-#handlerChain($webServiceOM.hcFileName $webServiceOM.name)
-#soapBinding($webServiceOM.soapBinding)
-#soapMsgHandlers($webServiceOM.soapHandlers)
-public class $webServiceOM.wsName {
-
-#foreach( $method in $webServiceOM.methods)
-      /**********************************************
-       *
-#foreach( $param in $method.params)      
-       * @param $param.wpName
-       *
-#end
-       * @throws java.rmi.RemoteException
-       *
-       ***********************************************/
-#webMethod($method)
-#results($method)
-## For now use the hack to get the correct name. later change this to use element  -- Daryoush
-##     public $method.javaReturnType.name $method.javaMethodName (#if($method.params.size() == 0)) 
-     public $method.javaReturnTypeFullName $method.javaMethodName (#if($method.params.size() == 0)) 
-          #if(!$method.oneWay)throws RemoteException#end {#end
-#if($method.params.size() > 0)
-
-#params($method)
-)  
-          #if(!$method.oneWay)throws RemoteException#end  {
-#end
-		
-           //TODO:  Implement the method logic here...
-#if($method.javaReturnType.name == "void")
-           return;
-#else
-           return null;
-#end
-         
-      }
-
-#end
-}
-
+
+##
+##
+##
+#macro(webService $name $targetNamespace $wsdlLocation)
+@WebService (
+     name = "$name",
+     targetNamespace = "$targetNamespace"#if($wsdlLocation),
+     wsdlLocation = "$wsdlLocation"
+#end
+)
+#end
+##
+##
+##
+#macro(handlerChain $fileName $name)
+#if( $fileName || $name)
+@HandlerChain (
+     name = "$name",
+     file = "$fileName"
+)
+#end
+#end
+##
+##
+##
+#macro( soapBinding $sb)
+@SOAPBinding (
+     style = SOAPBinding.Style.$sb.style,
+     use = SOAPBinding.Use.$sb.use,
+     parameterStyle = SOAPBinding.ParameterStyle.$sb.parameterStyle
+)
+#end
+##
+##
+##
+#macro( soapMsgHandlers $handlers)
+#if($handlers.size() > 0)
+@SOAPMessageHandlers (
+#foreach( $smh in $handlers)
+     @SOAPMessageHandler (
+          name = "$smh.name",
+          className = "$snm.className" ,
+          roles = {
+#foreach($role in $smh.roles)
+               "$role"
+#end
+          }
+          headers = {
+#foreach($header in $smh.headers)
+               "$header"
+#end	
+          }
+          initParams = {
+#foreach($paramName in $smh.parameterMap.keySet())
+               @InitParam(
+                    name = "$paramName"
+                    value = "$smh.parameterMap.get($paramName)"
+               )
+#end
+          }
+     )
+#end
+)
+#end
+#end
+##
+##
+##
+#macro( webMethod $method)
+     @WebMethod(
+          operationName = "$method.wmOperationName"#if($method.wmAction),
+          action =" $method.wmAction"
+#end
+     )
+
+#end
+##
+##
+##
+#macro( results $method)
+#if($method.oneWay)
+     @Oneway
+#else 
+     @WebResult(
+          name = "$method.wrName",
+          targetNamespace = "$method.wrTargetNamespace" 
+     )
+#end
+#end
+##
+##
+
+##
+##
+#macro(params $method)
+#set($size=$method.params.size())
+#set($ctr=0)
+#foreach( $param in $method.params)
+#set($ctr=$ctr + 1)
+               @WebParam(
+                    name = "$param.wpName",
+                    targetNamespace = "$param.wpTargetNamespace",
+                    mode = WebParam.Mode.$param.wpMode,
+                    header = $param.wpHeader
+## For now use the hack to get the correct name. later change this to use element  -- Daryoush
+##              )$param.javaType.name $param.wpName#if($ctr < $size), 
+               )$param.javaTypeFullName $param.wpName#if($ctr < $size), 
+#end
+#end
+#end
+##
+##
+##	
+/* 
+This file is an Annotated java file that that is automatically generated 
+from wsdl: $webServiceOM.wsWsdlLocation
+
+*/
+#set($packageName="")
+#set($ctr=0)
+#set($size=$webServiceOM.targetNamespaceParts.size())
+#foreach( $dirName in $webServiceOM.targetNamespaceParts)
+#if($ctr != 0) #set($packageName="$packageName.")#end
+#set($ctr=$ctr + 1)
+#set($packageName="$packageName$dirName")
+#end
+##  package $packageName;   For now just use web as package name
+
+package web;
+
+import java.rmi.RemoteException;
+
+import javax.jws.Oneway;
+import javax.jws.WebMethod;
+import javax.jws.WebParam;
+import javax.jws.WebResult;
+import javax.jws.WebService;
+import javax.jws.soap.SOAPBinding;
+
+
+#webService($webServiceOM.wsName $webServiceOM.wsTargetNamespace $webServiceOM.wsWsdlLocation)
+#handlerChain($webServiceOM.hcFileName $webServiceOM.name)
+#soapBinding($webServiceOM.soapBinding)
+#soapMsgHandlers($webServiceOM.soapHandlers)
+public class $webServiceOM.wsName {
+
+#foreach( $method in $webServiceOM.methods)
+      /**********************************************
+       *
+#foreach( $param in $method.params)      
+       * @param $param.wpName
+       *
+#end
+       * @throws java.rmi.RemoteException
+       *
+       ***********************************************/
+#webMethod($method)
+#results($method)
+## For now use the hack to get the correct name. later change this to use element  -- Daryoush
+##     public $method.javaReturnType.name $method.javaMethodName (#if($method.params.size() == 0)) 
+     public $method.javaReturnTypeFullName $method.javaMethodName (#if($method.params.size() == 0)) 
+          #if(!$method.oneWay)throws RemoteException#end {#end
+#if($method.params.size() > 0)
+
+#params($method)
+)  
+          #if(!$method.oneWay)throws RemoteException#end  {
+#end
+		
+           //TODO:  Implement the method logic here...
+#if($method.javaReturnType.name == "void")
+           return;
+#else
+           return null;
+#end
+         
+      }
+
+#end
+}
+

Propchange: incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/wsdl/wsdl2ajava.vm
------------------------------------------------------------------------------
    svn:eol-style = native