ws-wsrf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sc...@apache.org
Subject svn commit: r227033 [25/27] - in /webservices/wsrf/trunk: ./ src/java/org/apache/ws/ src/java/org/apache/ws/addressing/ src/java/org/apache/ws/addressing/v2003_03/ src/java/org/apache/ws/addressing/v2004_08_10/ src/java/org/apache/ws/resource/ src/java...
Date Tue, 02 Aug 2005 16:30:44 GMT
Modified: webservices/wsrf/trunk/src/java/org/apache/ws/util/velocity/CommonsLogLogSystem.java
URL: http://svn.apache.org/viewcvs/webservices/wsrf/trunk/src/java/org/apache/ws/util/velocity/CommonsLogLogSystem.java?rev=227033&r1=227032&r2=227033&view=diff
==============================================================================
--- webservices/wsrf/trunk/src/java/org/apache/ws/util/velocity/CommonsLogLogSystem.java (original)
+++ webservices/wsrf/trunk/src/java/org/apache/ws/util/velocity/CommonsLogLogSystem.java Tue Aug  2 09:28:49 2005
@@ -1,104 +1,103 @@
-/*
- * Copyright 2003 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.ws.util.velocity;
-
-import org.apache.commons.logging.Log;
-import org.apache.commons.logging.LogFactory;
-import org.apache.velocity.runtime.RuntimeServices;
-import org.apache.velocity.runtime.log.LogSystem;
-
-/**
- * Redirects Velocity's LogSystem messages to commons-logging
- * (snarfed from <a href="http://jakarta.apache.org/velocity/tools/generic/">Velocity
- * Generic Tools</a> project).
- *
- * <p>To use, first set up commons-logging, then tell Velocity to use
- * this class for logging by adding the following to your velocity.properties:
- *
- * <code>
- * runtime.log.logsystem.class = org.apache.velocity.tools.generic.log.CommonsLogLogSystem
- * </code>
- * </p>
- *
- * <p>You may also set this property to specify what log/name Velocity's
- * messages should be logged to (example below is default).
- * <code>
- * runtime.log.logsystem.commons.logging.name = org.apache.velocity
- * </code>
- * </p>
- *
- * @author <a href="mailto:nathan@esha.com">Nathan Bubna</a>
- * @since VelocityTools 1.1
- * @version $Id: CommonsLogLogSystem.java,v 1.3 2004/02/18 20:10:38 nbubna Exp $
- */
-public class CommonsLogLogSystem implements LogSystem
-{
-
-    /** Property key for specifying the name for the log instance */
-    public static final String LOGSYSTEM_COMMONS_LOG_NAME =
-        "runtime.log.logsystem.commons.logging.name";
-
-    /** Default name for the commons-logging instance */
-    public static final String DEFAULT_LOG_NAME = "org.apache.velocity";
-
-
-    /** the commons-logging Log instance */
-    protected Log log;
-
-
-    /********** LogSystem methods *************/
-
-    public void init(RuntimeServices rs) throws Exception
-    {
-        String name =
-            (String)rs.getProperty(LOGSYSTEM_COMMONS_LOG_NAME);
-
-        if (name == null)
-        {
-            name = DEFAULT_LOG_NAME;
-        }
-        log = LogFactory.getLog(name);
-        logVelocityMessage(LogSystem.DEBUG_ID,
-                           "CommonsLogLogSystem name is '" + name + "'");
-    }
-
-    /**
-     * Send a log message from Velocity.
-     */
-    public void logVelocityMessage(int level, String message)
-    {
-        switch (level)
-        {
-            case LogSystem.WARN_ID:
-                log.warn(message);
-                break;
-            case LogSystem.INFO_ID:
-                log.info(message);
-                break;
-            case LogSystem.DEBUG_ID:
-                log.debug(message);
-                break;
-            case LogSystem.ERROR_ID:
-                log.error(message);
-                break;
-            default:
-                log.debug(message);
-                break;
-        }
-    }
-
-}
+/*=============================================================================*
+ *  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.
+ *=============================================================================*/
+package org.apache.ws.util.velocity;
+
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
+import org.apache.velocity.runtime.RuntimeServices;
+import org.apache.velocity.runtime.log.LogSystem;
+
+/**
+ * Redirects Velocity's LogSystem messages to commons-logging
+ * (snarfed from <a href="http://jakarta.apache.org/velocity/tools/generic/">Velocity
+ * Generic Tools</a> project).
+ *
+ * <p>To use, first set up commons-logging, then tell Velocity to use
+ * this class for logging by adding the following to your velocity.properties:
+ *
+ * <code>
+ * runtime.log.logsystem.class = org.apache.velocity.tools.generic.log.CommonsLogLogSystem
+ * </code>
+ * </p>
+ *
+ * <p>You may also set this property to specify what log/name Velocity's
+ * messages should be logged to (example below is default).
+ * <code>
+ * runtime.log.logsystem.commons.logging.name = org.apache.velocity
+ * </code>
+ * </p>
+ *
+ * @author <a href="mailto:nathan@esha.com">Nathan Bubna</a>
+ * @since VelocityTools 1.1
+ * @version $Id: CommonsLogLogSystem.java,v 1.3 2004/02/18 20:10:38 nbubna Exp $
+ */
+public class CommonsLogLogSystem
+   implements LogSystem
+{
+   /** Property key for specifying the name for the log instance */
+   public static final String LOGSYSTEM_COMMONS_LOG_NAME = "runtime.log.logsystem.commons.logging.name";
+
+   /** Default name for the commons-logging instance */
+   public static final String DEFAULT_LOG_NAME = "org.apache.velocity";
+
+   /** the commons-logging Log instance */
+   protected Log log;
+
+   /********** LogSystem methods *************/
+   public void init( RuntimeServices rs )
+   throws Exception
+   {
+      String name = (String) rs.getProperty( LOGSYSTEM_COMMONS_LOG_NAME );
+
+      if ( name == null )
+      {
+         name = DEFAULT_LOG_NAME;
+      }
+
+      log = LogFactory.getLog( name );
+      logVelocityMessage( LogSystem.DEBUG_ID, "CommonsLogLogSystem name is '" + name + "'" );
+   }
+
+   /**
+    * Send a log message from Velocity.
+    */
+   public void logVelocityMessage( int    level,
+                                   String message )
+   {
+      switch ( level )
+      {
+         case LogSystem.WARN_ID:
+            log.warn( message );
+            break;
+
+         case LogSystem.INFO_ID:
+            log.info( message );
+            break;
+
+         case LogSystem.DEBUG_ID:
+            log.debug( message );
+            break;
+
+         case LogSystem.ERROR_ID:
+            log.error( message );
+            break;
+
+         default:
+            log.debug( message );
+            break;
+      }
+   }
+}
\ No newline at end of file

Modified: webservices/wsrf/trunk/src/java/org/apache/ws/util/work/WorkItemImpl.java
URL: http://svn.apache.org/viewcvs/webservices/wsrf/trunk/src/java/org/apache/ws/util/work/WorkItemImpl.java?rev=227033&r1=227032&r2=227033&view=diff
==============================================================================
--- webservices/wsrf/trunk/src/java/org/apache/ws/util/work/WorkItemImpl.java (original)
+++ webservices/wsrf/trunk/src/java/org/apache/ws/util/work/WorkItemImpl.java Tue Aug  2 09:28:49 2005
@@ -25,7 +25,6 @@
 public class WorkItemImpl
    implements WorkItem
 {
-
    private int m_status = -1;
 
    /**
@@ -72,5 +71,4 @@
          m_status = status;
       }
    }
-
 }

Modified: webservices/wsrf/trunk/src/java/org/apache/ws/util/work/WorkManagerImpl.java
URL: http://svn.apache.org/viewcvs/webservices/wsrf/trunk/src/java/org/apache/ws/util/work/WorkManagerImpl.java?rev=227033&r1=227032&r2=227033&view=diff
==============================================================================
--- webservices/wsrf/trunk/src/java/org/apache/ws/util/work/WorkManagerImpl.java (original)
+++ webservices/wsrf/trunk/src/java/org/apache/ws/util/work/WorkManagerImpl.java Tue Aug  2 09:28:49 2005
@@ -28,7 +28,6 @@
 import org.apache.ws.util.i18n.Keys;
 import org.apache.ws.util.i18n.Messages;
 import org.apache.ws.util.i18n.MessagesImpl;
-
 import java.util.Collection;
 import java.util.HashMap;
 import java.util.Iterator;
@@ -45,8 +44,11 @@
 public class WorkManagerImpl
    implements WorkManager
 {
-   private static final Log LOG = LogFactory.getLog( WorkManagerImpl.class );
-   public static final Messages MSG = MessagesImpl.getInstance();
+   private static final Log     LOG = LogFactory.getLog( WorkManagerImpl.class );
+
+   /** DOCUMENT_ME */
+   public static final Messages MSG = MessagesImpl.getInstance(  );
+
    /**
     * DOCUMENT_ME
     */
@@ -69,7 +71,8 @@
     */
    public WorkManagerImpl( int maxPoolSize )
    {
-      LOG.debug(MSG.getMessage( Keys.CREATE_WRK_MGR_POOL_SZE, Integer.toString(maxPoolSize)));
+      LOG.debug( MSG.getMessage( Keys.CREATE_WRK_MGR_POOL_SZE,
+                                 Integer.toString( maxPoolSize ) ) );
       this.pool = new PooledExecutor( maxPoolSize );
    }
 
@@ -80,7 +83,8 @@
     */
    public void setMaximumPoolSize( int maxPoolSize )
    {
-      LOG.debug(MSG.getMessage( Keys.WRK_MGR_POOL_SIZE,Integer.toString(maxPoolSize)));
+      LOG.debug( MSG.getMessage( Keys.WRK_MGR_POOL_SIZE,
+                                 Integer.toString( maxPoolSize ) ) );
       this.pool.setMaximumPoolSize( maxPoolSize );
    }
 
@@ -106,7 +110,7 @@
 
       if ( work == null )
       {
-         throw new IllegalArgumentException( MSG.getMessage( Keys.NULL_WORK) );
+         throw new IllegalArgumentException( MSG.getMessage( Keys.NULL_WORK ) );
       }
 
       WorkItem workItem = new WorkItemImpl(  );

Modified: webservices/wsrf/trunk/src/java/org/apache/ws/util/xml/NamespaceContext.java
URL: http://svn.apache.org/viewcvs/webservices/wsrf/trunk/src/java/org/apache/ws/util/xml/NamespaceContext.java?rev=227033&r1=227032&r2=227033&view=diff
==============================================================================
--- webservices/wsrf/trunk/src/java/org/apache/ws/util/xml/NamespaceContext.java (original)
+++ webservices/wsrf/trunk/src/java/org/apache/ws/util/xml/NamespaceContext.java Tue Aug  2 09:28:49 2005
@@ -1,53 +1,51 @@
-/*=============================================================================*
- *  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.
- *=============================================================================*/
-package org.apache.ws.util.xml;
-
-import java.util.Iterator;
-
-/**
- * Interface for read only XML Namespace context processing.
- *
- * @author Ian Springer (ian DOT springer AT hp DOT com)
- */
-public interface NamespaceContext
-{
-
-    /**
-     * Get Namespace URI bound to a prefix in the current scope.
-     *
-     * @param prefix the prefix to resolve
-     *
-     * @return
-     */
-    String getNamespaceURI(String prefix);
-
-    /**
-     * Get prefix bound to Namespace URI in the current scope.
-     *
-     * @param namespaceURI
-     * @return
-     */
-    String getPrefix(String namespaceURI);
-
-    /**
-     * Get all prefixes bound to a Namespace URI in the current scope.
-     *
-     * @param namespaceURI
-     * @return
-     */
-    Iterator getPrefixes(String namespaceURI);
-
-}
+/*=============================================================================*
+ *  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.
+ *=============================================================================*/
+package org.apache.ws.util.xml;
+
+import java.util.Iterator;
+
+/**
+ * Interface for read only XML Namespace context processing.
+ *
+ * @author Ian Springer (ian DOT springer AT hp DOT com)
+ */
+public interface NamespaceContext
+{
+   /**
+    * Get Namespace URI bound to a prefix in the current scope.
+    *
+    * @param prefix the prefix to resolve
+    *
+    * @return
+    */
+   String getNamespaceURI( String prefix );
+
+   /**
+    * Get prefix bound to Namespace URI in the current scope.
+    *
+    * @param namespaceURI
+    * @return
+    */
+   String getPrefix( String namespaceURI );
+
+   /**
+    * Get all prefixes bound to a Namespace URI in the current scope.
+    *
+    * @param namespaceURI
+    * @return
+    */
+   Iterator getPrefixes( String namespaceURI );
+}
\ No newline at end of file

Modified: webservices/wsrf/trunk/src/java/org/apache/ws/util/xml/impl/DomNamespaceContext.java
URL: http://svn.apache.org/viewcvs/webservices/wsrf/trunk/src/java/org/apache/ws/util/xml/impl/DomNamespaceContext.java?rev=227033&r1=227032&r2=227033&view=diff
==============================================================================
--- webservices/wsrf/trunk/src/java/org/apache/ws/util/xml/impl/DomNamespaceContext.java (original)
+++ webservices/wsrf/trunk/src/java/org/apache/ws/util/xml/impl/DomNamespaceContext.java Tue Aug  2 09:28:49 2005
@@ -1,104 +1,128 @@
-/*=============================================================================*
- *  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.
- *=============================================================================*/
-package org.apache.ws.util.xml.impl;
-
-import org.apache.ws.util.xml.NamespaceContext;
-import org.w3c.dom.NamedNodeMap;
-import org.w3c.dom.Node;
-
-import java.util.ArrayList;
-import java.util.Iterator;
-import java.util.List;
-
-/**
- * A namespace context based on a DOM {@link Node}.
- */
-public class DomNamespaceContext implements NamespaceContext
-{
-
-    private static final String XMLNS_XML =
-            "http://www.w3.org/XML/1998/namespace";
-
-    private Node m_context;
-
-    public DomNamespaceContext( Node context )
-    {
-        m_context = context;
-    }
-
-    /**
-     * Snarfed from Xalan's <code>org.apache.xml.utils.PrefixResolverDefault</code> class.      
-     */
-    public String getNamespaceURI( String prefix )
-    {
-        String namespaceURI = null;
-        if ( prefix.equals( "xml" ) )
-        {
-            namespaceURI = XMLNS_XML;
-        }
-        else
-        {
-            Node parent = m_context;
-            int type;
-            while ( ( null != parent ) && ( null == namespaceURI )
-                    && ( ( ( type = parent.getNodeType() ) == Node.ELEMENT_NODE )
-                    || ( type == Node.ENTITY_REFERENCE_NODE ) ) )
-            {
-                if ( type == Node.ELEMENT_NODE )
-                {
-                    NamedNodeMap attribMap = parent.getAttributes();
-                    for ( int i = 0; i < attribMap.getLength(); i++ )
-                    {
-                        Node attrib = attribMap.item( i );
-                        String attribName = attrib.getNodeName();
-                        boolean isPrefix = attribName.startsWith( "xmlns:" );
-                        if ( isPrefix || attribName.equals( "xmlns" ) )
-                        {
-                            int index = attribName.indexOf( ':' );
-                            String declaredPrefix = isPrefix ? attribName.substring( index + 1 ) : "";
-                            if ( declaredPrefix.equals( prefix ) )
-                            {
-                                namespaceURI = attrib.getNodeValue();
-                                break;
-                            }
-                        }
-                    }
-                }
-                parent = parent.getParentNode();
-            }
-        }
-        return namespaceURI;
-    }
-
-    public String getPrefix( String namespaceURI )
-    {
-        // TODO (low-priority)
-        return null;
-    }
-
-    public Iterator getPrefixes( String namespaceURI )
-    {
-        List prefixes = new ArrayList();
-        // TODO (low-priority)
-        return prefixes.iterator();
-    }
-
-    public Node getContextNode()
-    {
-        return m_context;
-    }
-
-}
+/*=============================================================================*
+ *  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.
+ *=============================================================================*/
+package org.apache.ws.util.xml.impl;
+
+import org.apache.ws.util.xml.NamespaceContext;
+import org.w3c.dom.NamedNodeMap;
+import org.w3c.dom.Node;
+import java.util.ArrayList;
+import java.util.Iterator;
+import java.util.List;
+
+/**
+ * A namespace context based on a DOM {@link Node}.
+ */
+public class DomNamespaceContext
+   implements NamespaceContext
+{
+   private static final String XMLNS_XML = "http://www.w3.org/XML/1998/namespace";
+   private Node                m_context;
+
+   /**
+    * Creates a new {@link DomNamespaceContext} object.
+    *
+    * @param context DOCUMENT_ME
+    */
+   public DomNamespaceContext( Node context )
+   {
+      m_context = context;
+   }
+
+   /**
+    * DOCUMENT_ME
+    *
+    * @return DOCUMENT_ME
+    */
+   public Node getContextNode(  )
+   {
+      return m_context;
+   }
+
+   /**
+    * Snarfed from Xalan's <code>org.apache.xml.utils.PrefixResolverDefault</code> class.
+    */
+   public String getNamespaceURI( String prefix )
+   {
+      String namespaceURI = null;
+      if ( prefix.equals( "xml" ) )
+      {
+         namespaceURI = XMLNS_XML;
+      }
+      else
+      {
+         Node parent = m_context;
+         int  type;
+         while ( ( null != parent )
+                 && ( null == namespaceURI )
+                 && ( ( ( type = parent.getNodeType(  ) ) == Node.ELEMENT_NODE )
+                 || ( type == Node.ENTITY_REFERENCE_NODE ) ) )
+         {
+            if ( type == Node.ELEMENT_NODE )
+            {
+               NamedNodeMap attribMap = parent.getAttributes(  );
+               for ( int i = 0; i < attribMap.getLength(  ); i++ )
+               {
+                  Node    attrib     = attribMap.item( i );
+                  String  attribName = attrib.getNodeName(  );
+                  boolean isPrefix   = attribName.startsWith( "xmlns:" );
+                  if ( isPrefix || attribName.equals( "xmlns" ) )
+                  {
+                     int    index          = attribName.indexOf( ':' );
+                     String declaredPrefix = isPrefix ? attribName.substring( index + 1 ) : "";
+                     if ( declaredPrefix.equals( prefix ) )
+                     {
+                        namespaceURI = attrib.getNodeValue(  );
+                        break;
+                     }
+                  }
+               }
+            }
+
+            parent = parent.getParentNode(  );
+         }
+      }
+
+      return namespaceURI;
+   }
+
+   /**
+    * DOCUMENT_ME
+    *
+    * @param namespaceURI DOCUMENT_ME
+    *
+    * @return DOCUMENT_ME
+    */
+   public String getPrefix( String namespaceURI )
+   {
+      // TODO (low-priority)
+      return null;
+   }
+
+   /**
+    * DOCUMENT_ME
+    *
+    * @param namespaceURI DOCUMENT_ME
+    *
+    * @return DOCUMENT_ME
+    */
+   public Iterator getPrefixes( String namespaceURI )
+   {
+      List prefixes = new ArrayList(  );
+
+      // TODO (low-priority)
+      return prefixes.iterator(  );
+   }
+}
\ No newline at end of file

Modified: webservices/wsrf/trunk/src/java/org/apache/ws/util/xml/impl/XmlBeansNamespaceContext.java
URL: http://svn.apache.org/viewcvs/webservices/wsrf/trunk/src/java/org/apache/ws/util/xml/impl/XmlBeansNamespaceContext.java?rev=227033&r1=227032&r2=227033&view=diff
==============================================================================
--- webservices/wsrf/trunk/src/java/org/apache/ws/util/xml/impl/XmlBeansNamespaceContext.java (original)
+++ webservices/wsrf/trunk/src/java/org/apache/ws/util/xml/impl/XmlBeansNamespaceContext.java Tue Aug  2 09:28:49 2005
@@ -1,89 +1,121 @@
-/*=============================================================================*
- *  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.
- *=============================================================================*/
-package org.apache.ws.util.xml.impl;
-
-import org.apache.ws.util.xml.NamespaceContext;
-import org.apache.xmlbeans.XmlCursor;
-import org.apache.xmlbeans.XmlObject;
-
-import java.util.ArrayList;
-import java.util.Iterator;
-import java.util.List;
-
-/**
- * A namespace context based on an XMLBeans {@link XmlObject}.
- */
-public class XmlBeansNamespaceContext implements NamespaceContext
-{
-
-    private XmlObject m_context;
-
-    public XmlBeansNamespaceContext( XmlObject context )
-    {
-        m_context = context;
-    }
-
-    public String getNamespaceURI( String prefix )
-    {
-        if ( m_context == null )
-        {
-            return null;
-        }
-        XmlCursor cursor = m_context.newCursor();
-        try
-        {
-            return cursor.namespaceForPrefix( prefix );
-        }
-        finally
-        {
-            cursor.dispose();
-        }
-    }
-
-    public String getPrefix( String namespaceURI )
-    {
-        if ( m_context == null )
-        {
-            return null;
-        }
-        XmlCursor cursor = m_context.newCursor();
-        try
-        {
-            return cursor.prefixForNamespace( namespaceURI );
-        }
-        finally
-        {
-            cursor.dispose();
-        }
-    }
-
-    public Iterator getPrefixes( String namespaceURI )
-    {
-        List prefixes = new ArrayList();
-        String prefix = getPrefix( namespaceURI );
-        if ( prefix != null )
-        {
-           prefixes.add( prefix );
-        }
-        return prefixes.iterator();
-    }
-
-    public XmlObject getContextXmlObject()
-    {
-        return m_context;
-    }
-
-}
+/*=============================================================================*
+ *  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.
+ *=============================================================================*/
+package org.apache.ws.util.xml.impl;
+
+import org.apache.ws.util.xml.NamespaceContext;
+import org.apache.xmlbeans.XmlCursor;
+import org.apache.xmlbeans.XmlObject;
+import java.util.ArrayList;
+import java.util.Iterator;
+import java.util.List;
+
+/**
+ * A namespace context based on an XMLBeans {@link XmlObject}.
+ */
+public class XmlBeansNamespaceContext
+   implements NamespaceContext
+{
+   private XmlObject m_context;
+
+   /**
+    * Creates a new {@link XmlBeansNamespaceContext} object.
+    *
+    * @param context DOCUMENT_ME
+    */
+   public XmlBeansNamespaceContext( XmlObject context )
+   {
+      m_context = context;
+   }
+
+   /**
+    * DOCUMENT_ME
+    *
+    * @return DOCUMENT_ME
+    */
+   public XmlObject getContextXmlObject(  )
+   {
+      return m_context;
+   }
+
+   /**
+    * DOCUMENT_ME
+    *
+    * @param prefix DOCUMENT_ME
+    *
+    * @return DOCUMENT_ME
+    */
+   public String getNamespaceURI( String prefix )
+   {
+      if ( m_context == null )
+      {
+         return null;
+      }
+
+      XmlCursor cursor = m_context.newCursor(  );
+      try
+      {
+         return cursor.namespaceForPrefix( prefix );
+      }
+      finally
+      {
+         cursor.dispose(  );
+      }
+   }
+
+   /**
+    * DOCUMENT_ME
+    *
+    * @param namespaceURI DOCUMENT_ME
+    *
+    * @return DOCUMENT_ME
+    */
+   public String getPrefix( String namespaceURI )
+   {
+      if ( m_context == null )
+      {
+         return null;
+      }
+
+      XmlCursor cursor = m_context.newCursor(  );
+      try
+      {
+         return cursor.prefixForNamespace( namespaceURI );
+      }
+      finally
+      {
+         cursor.dispose(  );
+      }
+   }
+
+   /**
+    * DOCUMENT_ME
+    *
+    * @param namespaceURI DOCUMENT_ME
+    *
+    * @return DOCUMENT_ME
+    */
+   public Iterator getPrefixes( String namespaceURI )
+   {
+      List   prefixes = new ArrayList(  );
+      String prefix = getPrefix( namespaceURI );
+      if ( prefix != null )
+      {
+         prefixes.add( prefix );
+      }
+
+      return prefixes.iterator(  );
+   }
+}
\ No newline at end of file

Modified: webservices/wsrf/trunk/src/test/org/apache/ws/resource/TestFixtureFactory.java
URL: http://svn.apache.org/viewcvs/webservices/wsrf/trunk/src/test/org/apache/ws/resource/TestFixtureFactory.java?rev=227033&r1=227032&r2=227033&view=diff
==============================================================================
--- webservices/wsrf/trunk/src/test/org/apache/ws/resource/TestFixtureFactory.java (original)
+++ webservices/wsrf/trunk/src/test/org/apache/ws/resource/TestFixtureFactory.java Tue Aug  2 09:28:49 2005
@@ -1,50 +1,56 @@
-/*=============================================================================*
- *  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.
- *=============================================================================*/
-package org.apache.ws.resource;
-
-import org.apache.axis.message.addressing.AddressingHeaders;
-import org.apache.axis.message.addressing.To;
-import org.apache.axis.message.addressing.Action;
-import org.apache.axis.types.URI;
-import org.apache.axis.MessageContext;
-import org.apache.axis.server.AxisServer;
-
-import javax.xml.rpc.handler.soap.SOAPMessageContext;
-
-/**
- * Factory for various test fixture objects.
- */
-public abstract class TestFixtureFactory
-{
-
-    public static SOAPMessageContext createSOAPMessageContext() throws Exception
-    {
-        SOAPMessageContext msgContext = new MessageContext( new AxisServer() );
-        AddressingHeaders wsaHeaders = createAddressingHeaders();
-        msgContext.setProperty( org.apache.axis.message.addressing.Constants.ENV_ADDRESSING_REQUEST_HEADERS, wsaHeaders );
-        return msgContext;
-    }
-
-    private static AddressingHeaders createAddressingHeaders()
-            throws URI.MalformedURIException
-    {
-        AddressingHeaders wsaHeaders = new AddressingHeaders( );
-        wsaHeaders.setTo( new To( "http://localhost:8080/wsrf/services/sushi" ) );
-        wsaHeaders.setAction( new Action( new URI( "urn:action" ) ) );
-        return wsaHeaders;
-    }
-
-}
+/*=============================================================================*
+ *  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.
+ *=============================================================================*/
+package org.apache.ws.resource;
+
+import org.apache.axis.MessageContext;
+import org.apache.axis.message.addressing.Action;
+import org.apache.axis.message.addressing.AddressingHeaders;
+import org.apache.axis.message.addressing.To;
+import org.apache.axis.server.AxisServer;
+import org.apache.axis.types.URI;
+import javax.xml.rpc.handler.soap.SOAPMessageContext;
+
+/**
+ * Factory for various test fixture objects.
+ */
+public abstract class TestFixtureFactory
+{
+   /**
+    * DOCUMENT_ME
+    *
+    * @return DOCUMENT_ME
+    *
+    * @throws Exception DOCUMENT_ME
+    */
+   public static SOAPMessageContext createSOAPMessageContext(  )
+   throws Exception
+   {
+      SOAPMessageContext msgContext = new MessageContext( new AxisServer(  ) );
+      AddressingHeaders  wsaHeaders = createAddressingHeaders(  );
+      msgContext.setProperty( org.apache.axis.message.addressing.Constants.ENV_ADDRESSING_REQUEST_HEADERS,
+                              wsaHeaders );
+      return msgContext;
+   }
+
+   private static AddressingHeaders createAddressingHeaders(  )
+   throws URI.MalformedURIException
+   {
+      AddressingHeaders wsaHeaders = new AddressingHeaders(  );
+      wsaHeaders.setTo( new To( "http://localhost:8080/wsrf/services/sushi" ) );
+      wsaHeaders.setAction( new Action( new URI( "urn:action" ) ) );
+      return wsaHeaders;
+   }
+}
\ No newline at end of file

Modified: webservices/wsrf/trunk/src/test/org/apache/ws/resource/metadataexchange/v2004_09/MetadataExchangePortTypeTest.java
URL: http://svn.apache.org/viewcvs/webservices/wsrf/trunk/src/test/org/apache/ws/resource/metadataexchange/v2004_09/MetadataExchangePortTypeTest.java?rev=227033&r1=227032&r2=227033&view=diff
==============================================================================
--- webservices/wsrf/trunk/src/test/org/apache/ws/resource/metadataexchange/v2004_09/MetadataExchangePortTypeTest.java (original)
+++ webservices/wsrf/trunk/src/test/org/apache/ws/resource/metadataexchange/v2004_09/MetadataExchangePortTypeTest.java Tue Aug  2 09:28:49 2005
@@ -1,47 +1,67 @@
-package org.apache.ws.resource.metadataexchange.v2004_09;
-
-import org.apache.ws.resource.properties.v2004_06.porttype.impl.AbstractWsrpPortTypeImplTestCase;
-import org.apache.ws.util.jndi.XmlBeanJndiUtils;
-
-/**
- * @author Sal Campana
- */
-public class MetadataExchangePortTypeTest extends AbstractWsrpPortTypeImplTestCase
-{
-
-    protected void setUp() throws Exception
-    {
-        super.setUp();
-        XmlBeanJndiUtils.initFromInputStream(
-                this.getClass().getClassLoader().getResourceAsStream(
-                        "org/apache/ws/resource/metadataexchange/v2004_09/jndi-config.xml" ) );
-    }
-
-    //todo figure out how to do this test with url, epr and filesystem in junit
-    public void testGetMetadata()
-    {
-        /*SushiResourceContext context = new SushiResourceContext();
-        MetadataExchangePortTypeImpl portTypeImpl = new MetadataExchangePortTypeImpl(context);
-         GetMetadataDocument getMetadataDocument = GetMetadataDocument.Factory.newInstance();
-         GetMetadataDocument.GetMetadata request = getMetadataDocument.addNewGetMetadata();
-         request.setDialect("http://schemas.xmlsoap.org/wsdl");
-
-         MetadataDocument metadata = portTypeImpl.getMetadata(getMetadataDocument);
-
-         assertNotNull(metadata);*/
-
-        assertTrue( true );
-    }
-
-    public void testGet()
-    {/*
-       SushiResourceContext context = new SushiResourceContext();
-       MetadataExchangePortTypeImpl portTypeImpl = new MetadataExchangePortTypeImpl(context);
-
-       AnyXmlType anyXmlType = portTypeImpl.get();
-       assertNotNull(anyXmlType);
-        */
-        assertTrue( true );
-    }
-
-}
+/*=============================================================================*
+ *  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.
+ *=============================================================================*/
+package org.apache.ws.resource.metadataexchange.v2004_09;
+
+import org.apache.ws.resource.properties.v2004_06.porttype.impl.AbstractWsrpPortTypeImplTestCase;
+import org.apache.ws.util.jndi.XmlBeanJndiUtils;
+
+/**
+ * @author Sal Campana
+ */
+public class MetadataExchangePortTypeTest
+   extends AbstractWsrpPortTypeImplTestCase
+{
+   /**
+    * DOCUMENT_ME
+    */
+   public void testGet(  )
+   { /*
+         SushiResourceContext context = new SushiResourceContext();
+         MetadataExchangePortTypeImpl portTypeImpl = new MetadataExchangePortTypeImpl(context);
+      
+                AnyXmlType anyXmlType = portTypeImpl.get();
+                assertNotNull(anyXmlType);
+       */
+      assertTrue( true );
+   }
+
+   //todo figure out how to do this test with url, epr and filesystem in junit
+   public void testGetMetadata(  )
+   {
+      /*SushiResourceContext context = new SushiResourceContext();
+         MetadataExchangePortTypeImpl portTypeImpl = new MetadataExchangePortTypeImpl(context);
+          GetMetadataDocument getMetadataDocument = GetMetadataDocument.Factory.newInstance();
+          GetMetadataDocument.GetMetadata request = getMetadataDocument.addNewGetMetadata();
+          request.setDialect("http://schemas.xmlsoap.org/wsdl");
+      
+                  MetadataDocument metadata = portTypeImpl.getMetadata(getMetadataDocument);
+      
+                  assertNotNull(metadata);*/
+      assertTrue( true );
+   }
+
+   /**
+    * DOCUMENT_ME
+    *
+    * @throws Exception DOCUMENT_ME
+    */
+   protected void setUp(  )
+   throws Exception
+   {
+      super.setUp(  );
+      XmlBeanJndiUtils.initFromInputStream( this.getClass(  ).getClassLoader(  ).getResourceAsStream( "org/apache/ws/resource/metadataexchange/v2004_09/jndi-config.xml" ) );
+   }
+}
\ No newline at end of file

Modified: webservices/wsrf/trunk/src/test/org/apache/ws/resource/properties/AbstractResourcePropertiesTestCase.java
URL: http://svn.apache.org/viewcvs/webservices/wsrf/trunk/src/test/org/apache/ws/resource/properties/AbstractResourcePropertiesTestCase.java?rev=227033&r1=227032&r2=227033&view=diff
==============================================================================
--- webservices/wsrf/trunk/src/test/org/apache/ws/resource/properties/AbstractResourcePropertiesTestCase.java (original)
+++ webservices/wsrf/trunk/src/test/org/apache/ws/resource/properties/AbstractResourcePropertiesTestCase.java Tue Aug  2 09:28:49 2005
@@ -26,7 +26,6 @@
 import org.apache.xmlbeans.impl.tool.SchemaCompiler;
 import org.oasisOpen.docs.wsrf.x2004.x10.wsrfWSResourceMetadataDescriptor10Draft01.DefinitionsDocument;
 import org.oasisOpen.docs.wsrf.x2004.x10.wsrfWSResourceMetadataDescriptor10Draft01.MetadataDescriptorType;
-
 import java.io.File;
 import java.io.FileOutputStream;
 import java.io.IOException;
@@ -40,89 +39,136 @@
  *
  * @author Ian Springer
  */
-public abstract class AbstractResourcePropertiesTestCase extends TestCase
+public abstract class AbstractResourcePropertiesTestCase
+   extends TestCase
 {
+   /** DOCUMENT_ME */
+   public static final String    NSURI_SUSHI = "http://ws.apache.org/resource/properties/test/sushi";
 
-   public static final String NSURI_SUSHI = "http://ws.apache.org/resource/properties/test/sushi";
+   /** DOCUMENT_ME */
+   protected static final String RESOURCE_PATH_SUSHI_PROPS_XSD    =
+      "org/apache/ws/resource/properties/SushiProperties.xsd";
 
-   protected static final String RESOURCE_PATH_SUSHI_PROPS_XSD = "org/apache/ws/resource/properties/SushiProperties.xsd";
-   protected static final String RESOURCE_PATH_SUSHI_PROPS_XML = "org/apache/ws/resource/properties/SushiProperties.xml";
-   protected static final String RESOURCE_PATH_SUSHI_METADATA_XML = "org/apache/ws/resource/properties/SushiMetadata.wsrmd";
+   /** DOCUMENT_ME */
+   protected static final String RESOURCE_PATH_SUSHI_PROPS_XML    =
+      "org/apache/ws/resource/properties/SushiProperties.xml";
 
-   protected static final File BASE_TMP_DIR = new File( System.getProperty( "java.io.tmpdir" ), "ws.apache.org/wsrf" );;
-   protected static final File SRC_DIR = new File( BASE_TMP_DIR, "generated_src" );
-   protected static final File CLASSES_DIR = new File( BASE_TMP_DIR, "generated_classes" );
+   /** DOCUMENT_ME */
+   protected static final String RESOURCE_PATH_SUSHI_METADATA_XML =
+      "org/apache/ws/resource/properties/SushiMetadata.wsrmd";
 
-   protected XmlBeansResourcePropertySet m_resourcePropSet;
-   protected SushiResourceContext m_resourceContext;
+   /** DOCUMENT_ME */
+   protected static final File BASE_TMP_DIR =
+      new File( System.getProperty( "java.io.tmpdir" ), "ws.apache.org/wsrf" );
+
+   /** DOCUMENT_ME */
+   protected static final File SRC_DIR     = new File( BASE_TMP_DIR, "generated_src" );
+
+   /** DOCUMENT_ME */
+   protected static final File CLASSES_DIR = new File( BASE_TMP_DIR, "generated_classes" );
 
    static
    {
       try
       {
-         XmlBeanJndiUtils.initJNDI();
-         compileSushiPropsXsd();
+         XmlBeanJndiUtils.initJNDI(  );
+         compileSushiPropsXsd(  );
       }
       catch ( Exception e )
       {
          throw new RuntimeException( "Failed to either initialize JNDI or compile SushiProperties.xsd.", e );
       }
-      enableSushiPropsTypeClassLoader();
+
+      enableSushiPropsTypeClassLoader(  );
    }
 
-   protected static void compileSushiPropsXsd() throws Exception
+   /** DOCUMENT_ME */
+   protected XmlBeansResourcePropertySet m_resourcePropSet;
+
+   /** DOCUMENT_ME */
+   protected SushiResourceContext m_resourceContext;
+
+   /**
+    * DOCUMENT_ME
+    *
+    * @throws Exception DOCUMENT_ME
+    * @throws RuntimeException DOCUMENT_ME
+    */
+   protected static void compileSushiPropsXsd(  )
+   throws Exception
    {
       InputStream xsdInStream = ClassLoader.getSystemResourceAsStream( RESOURCE_PATH_SUSHI_PROPS_XSD );
-      BASE_TMP_DIR.mkdirs();
+      BASE_TMP_DIR.mkdirs(  );
       File xsdFile = new File( BASE_TMP_DIR, "SushiProperties.xsd" );
-      CopyUtils.copy( xsdInStream, new FileOutputStream( xsdFile ) );
-      if ( ! compileSchema( xsdFile ) )
+      CopyUtils.copy( xsdInStream,
+                      new FileOutputStream( xsdFile ) );
+      if ( !compileSchema( xsdFile ) )
       {
-         throw new RuntimeException();
+         throw new RuntimeException(  );
       }
    }
 
-   protected static void enableSushiPropsTypeClassLoader()
+   /**
+    * DOCUMENT_ME
+    */
+   protected static void enableSushiPropsTypeClassLoader(  )
    {
       ClassLoader fileSystemTypeSystemClassLoader = null;
       try
       {
-         fileSystemTypeSystemClassLoader = new URLClassLoader( new URL[]{CLASSES_DIR.toURL()} );
+         fileSystemTypeSystemClassLoader = new URLClassLoader( new URL[]
+                                                               {
+                                                                  CLASSES_DIR.toURL(  )
+                                                               } );
       }
       catch ( MalformedURLException mue )
       {
          throw new RuntimeException( mue );
       }
-      Thread.currentThread().setContextClassLoader( fileSystemTypeSystemClassLoader );
+
+      Thread.currentThread(  ).setContextClassLoader( fileSystemTypeSystemClassLoader );
    }
 
-   protected void initResourcePropsDoc()
-         throws XmlException, IOException, MetaDataViolationException
+   /**
+    * DOCUMENT_ME
+    *
+    * @throws XmlException DOCUMENT_ME
+    * @throws IOException DOCUMENT_ME
+    * @throws MetaDataViolationException DOCUMENT_ME
+    */
+   protected void initResourcePropsDoc(  )
+   throws XmlException, 
+          IOException, 
+          MetaDataViolationException
    {
-      InputStream in = Thread.currentThread().getContextClassLoader().getResourceAsStream( RESOURCE_PATH_SUSHI_PROPS_XML );
-      XmlObject propsDocXBean = XmlObject.Factory.parse( in );
-      in.close();
-      in = Thread.currentThread().getContextClassLoader().getResourceAsStream( RESOURCE_PATH_SUSHI_METADATA_XML );
-      DefinitionsDocument metadataDocXBean = (DefinitionsDocument) XmlObject.Factory.parse( in );
-      MetadataDescriptorType metadataDesc = metadataDocXBean.getDefinitions().getMetadataDescriptorArray( 0 );
-      in.close();
-      ResourcePropertySetMetaData propSetMetaData = new XmlBeansResourcePropertySetMetaData( propsDocXBean.schemaType(), metadataDesc );
+      InputStream in            =
+         Thread.currentThread(  ).getContextClassLoader(  ).getResourceAsStream( RESOURCE_PATH_SUSHI_PROPS_XML );
+      XmlObject   propsDocXBean = XmlObject.Factory.parse( in );
+      in.close(  );
+      in = Thread.currentThread(  ).getContextClassLoader(  ).getResourceAsStream( RESOURCE_PATH_SUSHI_METADATA_XML );
+      DefinitionsDocument    metadataDocXBean = (DefinitionsDocument) XmlObject.Factory.parse( in );
+      MetadataDescriptorType metadataDesc = metadataDocXBean.getDefinitions(  ).getMetadataDescriptorArray( 0 );
+      in.close(  );
+      ResourcePropertySetMetaData propSetMetaData =
+         new XmlBeansResourcePropertySetMetaData( propsDocXBean.schemaType(  ), metadataDesc );
       m_resourcePropSet = new XmlBeansResourcePropertySet( propsDocXBean, propSetMetaData );
    }
 
    private static boolean compileSchema( File xsdFile )
    {
-      SchemaCompiler.Parameters scompParams = new SchemaCompiler.Parameters();
+      SchemaCompiler.Parameters scompParams = new SchemaCompiler.Parameters(  );
       scompParams.setSrcDir( SRC_DIR );
       scompParams.setClassesDir( CLASSES_DIR );
-      scompParams.setXsdFiles( new File[] {xsdFile} );
+      scompParams.setXsdFiles( new File[]
+                               {
+                                  xsdFile
+                               } );
       scompParams.setDownload( true );
       scompParams.setQuiet( true );
-      XmlErrorPrinter errorPrinter = new XmlErrorPrinter(true, null);
+      XmlErrorPrinter errorPrinter = new XmlErrorPrinter( true, null );
       scompParams.setErrorListener( errorPrinter );
-      SRC_DIR.mkdirs(); // necessary?
-      CLASSES_DIR.mkdirs(); // necessary?
+      SRC_DIR.mkdirs(  ); // necessary?
+      CLASSES_DIR.mkdirs(  ); // necessary?
       return SchemaCompiler.compile( scompParams );
    }
-
-}
+}
\ No newline at end of file

Modified: webservices/wsrf/trunk/src/test/org/apache/ws/resource/properties/AbstractSushiService.java
URL: http://svn.apache.org/viewcvs/webservices/wsrf/trunk/src/test/org/apache/ws/resource/properties/AbstractSushiService.java?rev=227033&r1=227032&r2=227033&view=diff
==============================================================================
--- webservices/wsrf/trunk/src/test/org/apache/ws/resource/properties/AbstractSushiService.java (original)
+++ webservices/wsrf/trunk/src/test/org/apache/ws/resource/properties/AbstractSushiService.java Tue Aug  2 09:28:49 2005
@@ -1,166 +1,166 @@
-/*=============================================================================*
- *  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.
- *=============================================================================*/
-package org.apache.ws.resource.properties;
-
-import org.apache.ws.resource.ResourceContext;
-import org.apache.ws.resource.properties.v2004_06.porttype.SetResourcePropertiesPortType;
-import org.apache.ws.resource.properties.v2004_06.porttype.GetMultipleResourcePropertiesPortType;
-import org.apache.ws.resource.properties.v2004_06.porttype.GetResourcePropertyPortType;
-import org.apache.ws.resource.properties.v2004_06.porttype.QueryResourcePropertiesPortType;
-import org.apache.ws.resource.properties.v2004_06.porttype.impl.GetMultipleResourcePropertiesPortTypeImpl;
-import org.apache.ws.resource.properties.v2004_06.porttype.impl.SetResourcePropertiesPortTypeImpl;
-import org.apache.ws.resource.properties.v2004_06.porttype.impl.GetResourcePropertyPortTypeImpl;
-import org.apache.ws.resource.properties.v2004_06.porttype.impl.QueryResourcePropertiesPortTypeImpl;
-import org.apache.ws.resource.handler.SoapMethodNameMap;
-import org.apache.ws.resource.handler.WsrfService;
-import org.apache.ws.resource.handler.ServiceSoapMethodNameMap;
-import org.oasisOpen.docs.wsrf.x2004.x06.wsrfWSResourceProperties12Draft01.GetMultipleResourcePropertiesDocument;
-import org.oasisOpen.docs.wsrf.x2004.x06.wsrfWSResourceProperties12Draft01.GetMultipleResourcePropertiesResponseDocument;
-import org.oasisOpen.docs.wsrf.x2004.x06.wsrfWSResourceProperties12Draft01.GetResourcePropertyDocument;
-import org.oasisOpen.docs.wsrf.x2004.x06.wsrfWSResourceProperties12Draft01.GetResourcePropertyResponseDocument;
-import org.oasisOpen.docs.wsrf.x2004.x06.wsrfWSResourceProperties12Draft01.QueryResourcePropertiesDocument;
-import org.oasisOpen.docs.wsrf.x2004.x06.wsrfWSResourceProperties12Draft01.QueryResourcePropertiesResponseDocument;
-import org.oasisOpen.docs.wsrf.x2004.x06.wsrfWSResourceProperties12Draft01.SetResourcePropertiesDocument;
-import org.oasisOpen.docs.wsrf.x2004.x06.wsrfWSResourceProperties12Draft01.SetResourcePropertiesResponseDocument;
-import javax.xml.namespace.QName;
-
-/**
- * @author Sal Campana
- */
-public abstract class AbstractSushiService
-   implements WsrfService,
-        GetResourcePropertyPortType,
-        GetMultipleResourcePropertiesPortType,
-        SetResourcePropertiesPortType,
-        QueryResourcePropertiesPortType
-{
-   /** DOCUMENT_ME */
-   public static final String TARGET_NSURI    = "http://ws.apache.org/resource/sushi";
-
-   /** DOCUMENT_ME */
-   public static final String TARGET_NSPREFIX = "fish";
-
-   /**
-    * DOCUMENT_ME
-    */
-   private ServiceSoapMethodNameMap m_methodNameMap;
-
-   /**
-    * DOCUMENT_ME
-    */
-   private boolean isInitialized = false;
-
-   /**
-    * DOCUMENT_ME
-    *
-    * @param requestQname DOCUMENT_ME
-    *
-    * @return DOCUMENT_ME
-    */
-   public String getMethodName( QName requestQname )
-   {
-      if ( !isInitialized )
-      {
-         init(  );
-      }
-
-      return m_methodNameMap.getMethodName( requestQname );
-   }
-
-   /**
-    * DOCUMENT_ME
-    *
-    * @return DOCUMENT_ME
-    */
-   public abstract ResourceContext getResourceContext(  );
-
-   /**
-    * DOCUMENT_ME
-    *
-    * @return DOCUMENT_ME
-    */
-   public final SoapMethodNameMap getMethodNameMap(  )
-   {
-      return m_methodNameMap;
-   }
-
-   /**
-    * DOCUMENT_ME
-    *
-    * @param requestDoc DOCUMENT_ME
-    *
-    * @return DOCUMENT_ME
-    */
-   public GetMultipleResourcePropertiesResponseDocument getMultipleResourceProperties( GetMultipleResourcePropertiesDocument requestDoc )
-   {
-      return new GetMultipleResourcePropertiesPortTypeImpl( getResourceContext(  ) ).getMultipleResourceProperties( requestDoc );
-   }
-
-   /**
-    * DOCUMENT_ME
-    *
-    * @param requestDoc DOCUMENT_ME
-    *
-    * @return DOCUMENT_ME
-    */
-   public SetResourcePropertiesResponseDocument setResourceProperties( SetResourcePropertiesDocument requestDoc )
-   {
-      return new SetResourcePropertiesPortTypeImpl( getResourceContext(  ) ).setResourceProperties( requestDoc );
-   }
-
-   /**
-    * DOCUMENT_ME
-    *
-    * @param requestDoc DOCUMENT_ME
-    *
-    * @return DOCUMENT_ME
-    */
-   public GetResourcePropertyResponseDocument getResourceProperty( GetResourcePropertyDocument requestDoc )
-   {
-      return new GetResourcePropertyPortTypeImpl( getResourceContext(  ) ).getResourceProperty( requestDoc );
-   }
-
-   /**
-    * DOCUMENT_ME
-    */
-   public void init(  )
-   {
-      m_methodNameMap    = new ServiceSoapMethodNameMap( getResourceContext(  ) );
-      isInitialized      = true;
-   }
-
-   /**
-    * DOCUMENT_ME
-    *
-    * @param requestDoc DOCUMENT_ME
-    *
-    * @return DOCUMENT_ME
-    */
-   public QueryResourcePropertiesResponseDocument queryResourceProperties( QueryResourcePropertiesDocument requestDoc )
-   {
-      return new QueryResourcePropertiesPortTypeImpl( getResourceContext(  ) ).queryResourceProperties( requestDoc );
-   }
-
-   /**
-    * DOCUMENT_ME
-    *
-    * @return DOCUMENT_ME
-    */
-   protected final boolean isInitialized(  )
-   {
-      return isInitialized;
-   }
+/*=============================================================================*
+ *  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.
+ *=============================================================================*/
+package org.apache.ws.resource.properties;
+
+import org.apache.ws.resource.ResourceContext;
+import org.apache.ws.resource.handler.ServiceSoapMethodNameMap;
+import org.apache.ws.resource.handler.SoapMethodNameMap;
+import org.apache.ws.resource.handler.WsrfService;
+import org.apache.ws.resource.properties.v2004_06.porttype.GetMultipleResourcePropertiesPortType;
+import org.apache.ws.resource.properties.v2004_06.porttype.GetResourcePropertyPortType;
+import org.apache.ws.resource.properties.v2004_06.porttype.QueryResourcePropertiesPortType;
+import org.apache.ws.resource.properties.v2004_06.porttype.SetResourcePropertiesPortType;
+import org.apache.ws.resource.properties.v2004_06.porttype.impl.GetMultipleResourcePropertiesPortTypeImpl;
+import org.apache.ws.resource.properties.v2004_06.porttype.impl.GetResourcePropertyPortTypeImpl;
+import org.apache.ws.resource.properties.v2004_06.porttype.impl.QueryResourcePropertiesPortTypeImpl;
+import org.apache.ws.resource.properties.v2004_06.porttype.impl.SetResourcePropertiesPortTypeImpl;
+import org.oasisOpen.docs.wsrf.x2004.x06.wsrfWSResourceProperties12Draft01.GetMultipleResourcePropertiesDocument;
+import org.oasisOpen.docs.wsrf.x2004.x06.wsrfWSResourceProperties12Draft01.GetMultipleResourcePropertiesResponseDocument;
+import org.oasisOpen.docs.wsrf.x2004.x06.wsrfWSResourceProperties12Draft01.GetResourcePropertyDocument;
+import org.oasisOpen.docs.wsrf.x2004.x06.wsrfWSResourceProperties12Draft01.GetResourcePropertyResponseDocument;
+import org.oasisOpen.docs.wsrf.x2004.x06.wsrfWSResourceProperties12Draft01.QueryResourcePropertiesDocument;
+import org.oasisOpen.docs.wsrf.x2004.x06.wsrfWSResourceProperties12Draft01.QueryResourcePropertiesResponseDocument;
+import org.oasisOpen.docs.wsrf.x2004.x06.wsrfWSResourceProperties12Draft01.SetResourcePropertiesDocument;
+import org.oasisOpen.docs.wsrf.x2004.x06.wsrfWSResourceProperties12Draft01.SetResourcePropertiesResponseDocument;
+import javax.xml.namespace.QName;
+
+/**
+ * @author Sal Campana
+ */
+public abstract class AbstractSushiService
+   implements WsrfService,
+              GetResourcePropertyPortType,
+              GetMultipleResourcePropertiesPortType,
+              SetResourcePropertiesPortType,
+              QueryResourcePropertiesPortType
+{
+   /** DOCUMENT_ME */
+   public static final String TARGET_NSURI = "http://ws.apache.org/resource/sushi";
+
+   /** DOCUMENT_ME */
+   public static final String TARGET_NSPREFIX = "fish";
+
+   /**
+    * DOCUMENT_ME
+    */
+   private ServiceSoapMethodNameMap m_methodNameMap;
+
+   /**
+    * DOCUMENT_ME
+    */
+   private boolean isInitialized = false;
+
+   /**
+    * DOCUMENT_ME
+    *
+    * @param requestQname DOCUMENT_ME
+    *
+    * @return DOCUMENT_ME
+    */
+   public String getMethodName( QName requestQname )
+   {
+      if ( !isInitialized )
+      {
+         init(  );
+      }
+
+      return m_methodNameMap.getMethodName( requestQname );
+   }
+
+   /**
+    * DOCUMENT_ME
+    *
+    * @return DOCUMENT_ME
+    */
+   public abstract ResourceContext getResourceContext(  );
+
+   /**
+    * DOCUMENT_ME
+    *
+    * @return DOCUMENT_ME
+    */
+   public final SoapMethodNameMap getMethodNameMap(  )
+   {
+      return m_methodNameMap;
+   }
+
+   /**
+    * DOCUMENT_ME
+    *
+    * @param requestDoc DOCUMENT_ME
+    *
+    * @return DOCUMENT_ME
+    */
+   public GetMultipleResourcePropertiesResponseDocument getMultipleResourceProperties( GetMultipleResourcePropertiesDocument requestDoc )
+   {
+      return new GetMultipleResourcePropertiesPortTypeImpl( getResourceContext(  ) ).getMultipleResourceProperties( requestDoc );
+   }
+
+   /**
+    * DOCUMENT_ME
+    *
+    * @param requestDoc DOCUMENT_ME
+    *
+    * @return DOCUMENT_ME
+    */
+   public SetResourcePropertiesResponseDocument setResourceProperties( SetResourcePropertiesDocument requestDoc )
+   {
+      return new SetResourcePropertiesPortTypeImpl( getResourceContext(  ) ).setResourceProperties( requestDoc );
+   }
+
+   /**
+    * DOCUMENT_ME
+    *
+    * @param requestDoc DOCUMENT_ME
+    *
+    * @return DOCUMENT_ME
+    */
+   public GetResourcePropertyResponseDocument getResourceProperty( GetResourcePropertyDocument requestDoc )
+   {
+      return new GetResourcePropertyPortTypeImpl( getResourceContext(  ) ).getResourceProperty( requestDoc );
+   }
+
+   /**
+    * DOCUMENT_ME
+    */
+   public void init(  )
+   {
+      m_methodNameMap    = new ServiceSoapMethodNameMap( getResourceContext(  ) );
+      isInitialized      = true;
+   }
+
+   /**
+    * DOCUMENT_ME
+    *
+    * @param requestDoc DOCUMENT_ME
+    *
+    * @return DOCUMENT_ME
+    */
+   public QueryResourcePropertiesResponseDocument queryResourceProperties( QueryResourcePropertiesDocument requestDoc )
+   {
+      return new QueryResourcePropertiesPortTypeImpl( getResourceContext(  ) ).queryResourceProperties( requestDoc );
+   }
+
+   /**
+    * DOCUMENT_ME
+    *
+    * @return DOCUMENT_ME
+    */
+   protected final boolean isInitialized(  )
+   {
+      return isInitialized;
+   }
 }

Modified: webservices/wsrf/trunk/src/test/org/apache/ws/resource/properties/Ebi.java
URL: http://svn.apache.org/viewcvs/webservices/wsrf/trunk/src/test/org/apache/ws/resource/properties/Ebi.java?rev=227033&r1=227032&r2=227033&view=diff
==============================================================================
--- webservices/wsrf/trunk/src/test/org/apache/ws/resource/properties/Ebi.java (original)
+++ webservices/wsrf/trunk/src/test/org/apache/ws/resource/properties/Ebi.java Tue Aug  2 09:28:49 2005
@@ -1,21 +1,45 @@
-package org.apache.ws.resource.properties;
-
-/**
- * @author Sal Campana
- */
-public class Ebi
-{
-
-    private String m_pieces = "8";
-
-    public String getNumberOfPieces()
-    {
-        return m_pieces;
-    }
-
-    public void setNumberOfPieces(String value)
-    {
-        m_pieces = value;
-    }
-
-}
+/*=============================================================================*
+ *  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.
+ *=============================================================================*/
+package org.apache.ws.resource.properties;
+
+
+/**
+ * @author Sal Campana
+ */
+public class Ebi
+{
+   private String m_pieces = "8";
+
+   /**
+    * DOCUMENT_ME
+    *
+    * @param value DOCUMENT_ME
+    */
+   public void setNumberOfPieces( String value )
+   {
+      m_pieces = value;
+   }
+
+   /**
+    * DOCUMENT_ME
+    *
+    * @return DOCUMENT_ME
+    */
+   public String getNumberOfPieces(  )
+   {
+      return m_pieces;
+   }
+}
\ No newline at end of file

Modified: webservices/wsrf/trunk/src/test/org/apache/ws/resource/properties/SushiCallback.java
URL: http://svn.apache.org/viewcvs/webservices/wsrf/trunk/src/test/org/apache/ws/resource/properties/SushiCallback.java?rev=227033&r1=227032&r2=227033&view=diff
==============================================================================
--- webservices/wsrf/trunk/src/test/org/apache/ws/resource/properties/SushiCallback.java (original)
+++ webservices/wsrf/trunk/src/test/org/apache/ws/resource/properties/SushiCallback.java Tue Aug  2 09:28:49 2005
@@ -1,94 +1,170 @@
-package org.apache.ws.resource.properties;
-
-import org.apache.ws.util.XmlBeanUtils;
-import org.apache.ws.resource.properties.impl.CallbackFailedException;
-import org.apache.xmlbeans.XmlObject;
-import org.apache.xmlbeans.XmlInt;
-
-import javax.xml.namespace.QName;
-
-/**
- * @author Sal Campana
- */
-public class SushiCallback implements SetResourcePropertyCallback
-{
-    private SushiPlate m_plate;
-    private boolean m_deleteInvoked, m_insertInvoked, m_updateInvoked;
-
-    public SushiCallback( SushiPlate plate )
-    {
-        m_plate = plate;
-    }
-
-    public SushiPlate getPlate()
-    {
-        return m_plate;
-    }
-
-    public ResourceProperty refreshProperty( ResourceProperty prop )  throws CallbackFailedException
-    {
-        QName propName = getPropName( prop );
-
-        if ( SushiPropertyQNames.EBI.equals( propName ) )
-        {
-            Ebi ebi = m_plate.getEbi();
-            String pieces = ebi.getNumberOfPieces();
-            try
-            {
-                XmlInt ebiElem = (XmlInt) prop.get( 0 );
-                XmlBeanUtils.setValue( ebiElem, pieces );
-            }
-            catch ( Exception e )
-            {
-                e.printStackTrace();
-            }
-        }
-        return prop;
-    }
-
-    private QName getPropName( ResourceProperty prop )
-    {
-        return prop.getMetaData().getName();
-    }
-
-    public void deleteProperty( QName propQName )   throws CallbackFailedException
-    {
-        m_deleteInvoked = true;
-    }
-
-    public void insertProperty( Object[] prop )  throws CallbackFailedException
-    {
-        m_insertInvoked = true;
-    }
-
-    public void updateProperty( Object[] prop )  throws CallbackFailedException
-    {
-        m_updateInvoked = true;
-        Object o = prop[0];
-        if ( o instanceof XmlObject )
-        {
-            XmlObject xmlObject = (XmlObject) o;
-            QName name = XmlBeanUtils.getName( xmlObject );
-            if ( name.getLocalPart().equals( "Ebi" ) )
-            {
-                m_plate.getEbi().setNumberOfPieces( XmlBeanUtils.getValue( xmlObject ) );
-            }
-        }
-
-    }
-
-    public boolean deleteWasInvoked()
-    {
-        return m_deleteInvoked;
-    }
-
-    public boolean insertWasInvoked()
-    {
-        return m_insertInvoked;
-    }
-
-    public boolean updateWasInvoked()
-    {
-        return m_updateInvoked;
-    }
-}
+/*=============================================================================*
+ *  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.
+ *=============================================================================*/
+package org.apache.ws.resource.properties;
+
+import org.apache.ws.resource.properties.impl.CallbackFailedException;
+import org.apache.ws.util.XmlBeanUtils;
+import org.apache.xmlbeans.XmlInt;
+import org.apache.xmlbeans.XmlObject;
+import javax.xml.namespace.QName;
+
+/**
+ * @author Sal Campana
+ */
+public class SushiCallback
+   implements SetResourcePropertyCallback
+{
+   private SushiPlate m_plate;
+   private boolean    m_deleteInvoked;
+   private boolean    m_insertInvoked;
+   private boolean    m_updateInvoked;
+
+   /**
+    * Creates a new {@link SushiCallback} object.
+    *
+    * @param plate DOCUMENT_ME
+    */
+   public SushiCallback( SushiPlate plate )
+   {
+      m_plate = plate;
+   }
+
+   /**
+    * DOCUMENT_ME
+    *
+    * @return DOCUMENT_ME
+    */
+   public SushiPlate getPlate(  )
+   {
+      return m_plate;
+   }
+
+   /**
+    * DOCUMENT_ME
+    *
+    * @param propQName DOCUMENT_ME
+    *
+    * @throws CallbackFailedException DOCUMENT_ME
+    */
+   public void deleteProperty( QName propQName )
+   throws CallbackFailedException
+   {
+      m_deleteInvoked = true;
+   }
+
+   /**
+    * DOCUMENT_ME
+    *
+    * @return DOCUMENT_ME
+    */
+   public boolean deleteWasInvoked(  )
+   {
+      return m_deleteInvoked;
+   }
+
+   /**
+    * DOCUMENT_ME
+    *
+    * @param prop DOCUMENT_ME
+    *
+    * @throws CallbackFailedException DOCUMENT_ME
+    */
+   public void insertProperty( Object[] prop )
+   throws CallbackFailedException
+   {
+      m_insertInvoked = true;
+   }
+
+   /**
+    * DOCUMENT_ME
+    *
+    * @return DOCUMENT_ME
+    */
+   public boolean insertWasInvoked(  )
+   {
+      return m_insertInvoked;
+   }
+
+   /**
+    * DOCUMENT_ME
+    *
+    * @param prop DOCUMENT_ME
+    *
+    * @return DOCUMENT_ME
+    *
+    * @throws CallbackFailedException DOCUMENT_ME
+    */
+   public ResourceProperty refreshProperty( ResourceProperty prop )
+   throws CallbackFailedException
+   {
+      QName propName = getPropName( prop );
+
+      if ( SushiPropertyQNames.EBI.equals( propName ) )
+      {
+         Ebi    ebi    = m_plate.getEbi(  );
+         String pieces = ebi.getNumberOfPieces(  );
+         try
+         {
+            XmlInt ebiElem = (XmlInt) prop.get( 0 );
+            XmlBeanUtils.setValue( ebiElem, pieces );
+         }
+         catch ( Exception e )
+         {
+            e.printStackTrace(  );
+         }
+      }
+
+      return prop;
+   }
+
+   /**
+    * DOCUMENT_ME
+    *
+    * @param prop DOCUMENT_ME
+    *
+    * @throws CallbackFailedException DOCUMENT_ME
+    */
+   public void updateProperty( Object[] prop )
+   throws CallbackFailedException
+   {
+      m_updateInvoked = true;
+      Object o = prop[0];
+      if ( o instanceof XmlObject )
+      {
+         XmlObject xmlObject = (XmlObject) o;
+         QName     name = XmlBeanUtils.getName( xmlObject );
+         if ( name.getLocalPart(  ).equals( "Ebi" ) )
+         {
+            m_plate.getEbi(  ).setNumberOfPieces( XmlBeanUtils.getValue( xmlObject ) );
+         }
+      }
+   }
+
+   /**
+    * DOCUMENT_ME
+    *
+    * @return DOCUMENT_ME
+    */
+   public boolean updateWasInvoked(  )
+   {
+      return m_updateInvoked;
+   }
+
+   private QName getPropName( ResourceProperty prop )
+   {
+      return prop.getMetaData(  ).getName(  );
+   }
+}
\ No newline at end of file

Modified: webservices/wsrf/trunk/src/test/org/apache/ws/resource/properties/SushiHome.java
URL: http://svn.apache.org/viewcvs/webservices/wsrf/trunk/src/test/org/apache/ws/resource/properties/SushiHome.java?rev=227033&r1=227032&r2=227033&view=diff
==============================================================================
--- webservices/wsrf/trunk/src/test/org/apache/ws/resource/properties/SushiHome.java (original)
+++ webservices/wsrf/trunk/src/test/org/apache/ws/resource/properties/SushiHome.java Tue Aug  2 09:28:49 2005
@@ -1,162 +1,198 @@
-/*=============================================================================*
- *  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.
- *=============================================================================*/
-package org.apache.ws.resource.properties;
-
-import org.apache.ws.resource.PropertiesResource;
-import org.apache.ws.resource.Resource;
-import org.apache.ws.resource.impl.AbstractResourceHome;
-import org.apache.ws.resource.properties.impl.XmlBeansResourcePropertySet;
-import org.apache.ws.resource.properties.v2004_06.impl.NamespaceVersionHolderImpl;
-import org.apache.xmlbeans.XmlObject;
-import org.apache.xmlbeans.XmlOptions;
-
-import javax.xml.namespace.QName;
-import java.io.InputStream;
-import java.io.Serializable;
-import java.util.Map;
-
-/**
- * @author Sal Campana
- */
-public class SushiHome
-        extends AbstractResourceHome
-        implements Serializable
-{
-
-    /**
-     * The service endpoint name as registered with the SOAP Platform.  This is useful for building EPR's. *
-     */
-    public static final QName SERVICE_NAME = javax.xml.namespace.QName.valueOf(
-            "{http://ws.apache.org/resource/properties/test/sushi}sushi" );
-
-    /**
-     * The management PortType associated with this resource. This is useful for building EPR's.*
-     */
-    public static final QName PORT_TYPE = javax.xml.namespace.QName.valueOf(
-            "{http://ws.apache.org/resource/properties/test/sushi}sushi" );
-
-    /**
-     * The WSDL Port name associated with the resource. This is useful for building EPR's. *
-     */
-    public static final String PORT_NAME = "sushi";
-
-    /**
-     * The name of the resource key for this resource. *
-     */
-    public static final QName RESOURCE_ID_REF_PARAM_NAME = javax.xml.namespace.QName.valueOf(
-            "{http://ws.apache.org/resource/properties/test/sushi}ResourceID" );
-
-    /**
-     * DOCUMENT_ME
-     */
-    protected static String RESOURCE_PROPS_RESOURCE_PATH =
-            "org/apache/ws/resource/properties/SushiProperties.xml";
-    private boolean m_isOpenContent;
-    private static final NamespaceVersionHolder SPEC_NAMESPACE_SET = new NamespaceVersionHolderImpl();
-
-    public SushiHome( boolean isOpenContent ) throws Exception
-    {
-        m_isOpenContent = isOpenContent;
-        setResourceClassName( SushiResource.class.getName() );
-        setResourceIdentifierReferenceParameterName( RESOURCE_ID_REF_PARAM_NAME.toString() );
-        resetResourceMap();
-        init();
-    }
-
-    public void init() throws Exception
-    {
-        super.init();
-        InputStream in = getClass().getClassLoader().getResourceAsStream( RESOURCE_PROPS_RESOURCE_PATH );
-        XmlOptions parseOpts = new XmlOptions().setLoadStripWhitespace();
-        if ( !m_isOpenContent )
-        {
-            parseOpts.setLoadReplaceDocumentElement(
-                    new QName( AbstractResourcePropertiesTestCase.NSURI_SUSHI, "ClosedSushiProperties", "sushi" ) );
-        }
-        XmlObject propsDocXBean = XmlObject.Factory.parse( in, parseOpts );
-        in.close();
-        ResourcePropertySet propSet = new XmlBeansResourcePropertySet( propsDocXBean );
-        Resource resource = createInstance( SushiResourceContext.ID );
-        ( (PropertiesResource) resource ).setResourcePropertySet( propSet );
-        add( resource );
-    }
-
-    public void setResourcePropsDocPath
-            ( String
-            propsDoc )
-    {
-        SushiHome.RESOURCE_PROPS_RESOURCE_PATH = propsDoc;
-    }
-
-    public QName getServiceName
-            ()
-    {
-        return SERVICE_NAME;
-    }
-
-    public QName getPortType
-            ()
-    {
-        return PORT_TYPE;
-    }
-
-    public String getServicePortName
-            ()
-    {
-        return PORT_NAME;
-    }
-
-    public QName getResourceIdentifierReferenceParameterQName
-            ()
-    {
-        return RESOURCE_ID_REF_PARAM_NAME;
-    }
-
-    /**
-     * Map containing all SushiResource instances - this map <em>must</em> be static for compatibility with certain JNDI
-     * providers.
-     */
-    private static Map s_resources;
-
-    /**
-     * Returns a map of all SushiResource instances. Used by the {@link AbstractResourceHome} superclass.
-     */
-    protected synchronized final Map getResourceMap
-            ()
-    {
-        if ( s_resources == null )
-        {
-            s_resources = AbstractResourceHome.createResourceMap( m_resourceIsPersistent );
-        }
-        return s_resources;
-    }
-
-    /**
-     * Resets (clears) the resource map.
-     */
-    public synchronized final void resetResourceMap
-            ()
-    {
-        if ( s_resources != null )
-        {
-           s_resources.clear();
-        }
-    }
-    public org.apache.ws.resource.properties.NamespaceVersionHolder getNamespaceVersionHolder()
-    {
-        return SPEC_NAMESPACE_SET; 
-    }
-}
+/*=============================================================================*
+ *  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.
+ *=============================================================================*/
+package org.apache.ws.resource.properties;
+
+import org.apache.ws.resource.PropertiesResource;
+import org.apache.ws.resource.Resource;
+import org.apache.ws.resource.impl.AbstractResourceHome;
+import org.apache.ws.resource.properties.impl.XmlBeansResourcePropertySet;
+import org.apache.ws.resource.properties.v2004_06.impl.NamespaceVersionHolderImpl;
+import org.apache.xmlbeans.XmlObject;
+import org.apache.xmlbeans.XmlOptions;
+import javax.xml.namespace.QName;
+import java.io.InputStream;
+import java.io.Serializable;
+import java.util.Map;
+
+/**
+ * @author Sal Campana
+ */
+public class SushiHome
+   extends AbstractResourceHome
+   implements Serializable
+{
+   /**
+    * The service endpoint name as registered with the SOAP Platform.  This is useful for building EPR's. *
+    */
+   public static final QName SERVICE_NAME =
+      javax.xml.namespace.QName.valueOf( "{http://ws.apache.org/resource/properties/test/sushi}sushi" );
+
+   /**
+    * The management PortType associated with this resource. This is useful for building EPR's.*
+    */
+   public static final QName PORT_TYPE =
+      javax.xml.namespace.QName.valueOf( "{http://ws.apache.org/resource/properties/test/sushi}sushi" );
+
+   /**
+    * The WSDL Port name associated with the resource. This is useful for building EPR's. *
+    */
+   public static final String PORT_NAME = "sushi";
+
+   /**
+    * The name of the resource key for this resource. *
+    */
+   public static final QName RESOURCE_ID_REF_PARAM_NAME =
+      javax.xml.namespace.QName.valueOf( "{http://ws.apache.org/resource/properties/test/sushi}ResourceID" );
+
+   /**
+    * DOCUMENT_ME
+    */
+   protected static String RESOURCE_PROPS_RESOURCE_PATH = "org/apache/ws/resource/properties/SushiProperties.xml";
+   private static final NamespaceVersionHolder SPEC_NAMESPACE_SET = new NamespaceVersionHolderImpl(  );
+
+   /**
+    * Map containing all SushiResource instances - this map <em>must</em> be static for compatibility with certain JNDI
+    * providers.
+    */
+   private static Map s_resources;
+   private boolean    m_isOpenContent;
+
+   /**
+    * Creates a new {@link SushiHome} object.
+    *
+    * @param isOpenContent DOCUMENT_ME
+    *
+    * @throws Exception DOCUMENT_ME
+    */
+   public SushiHome( boolean isOpenContent )
+   throws Exception
+   {
+      m_isOpenContent = isOpenContent;
+      setResourceClassName( SushiResource.class.getName(  ) );
+      setResourceIdentifierReferenceParameterName( RESOURCE_ID_REF_PARAM_NAME.toString(  ) );
+      resetResourceMap(  );
+      init(  );
+   }
+
+   /**
+    * DOCUMENT_ME
+    *
+    * @return DOCUMENT_ME
+    */
+   public QName getPortType(  )
+   {
+      return PORT_TYPE;
+   }
+
+   /**
+    * DOCUMENT_ME
+    *
+    * @return DOCUMENT_ME
+    */
+   public QName getResourceIdentifierReferenceParameterQName(  )
+   {
+      return RESOURCE_ID_REF_PARAM_NAME;
+   }
+
+   /**
+    * DOCUMENT_ME
+    *
+    * @param propsDoc DOCUMENT_ME
+    */
+   public void setResourcePropsDocPath( String propsDoc )
+   {
+      SushiHome.RESOURCE_PROPS_RESOURCE_PATH = propsDoc;
+   }
+
+   /**
+    * DOCUMENT_ME
+    *
+    * @return DOCUMENT_ME
+    */
+   public QName getServiceName(  )
+   {
+      return SERVICE_NAME;
+   }
+
+   /**
+    * DOCUMENT_ME
+    *
+    * @return DOCUMENT_ME
+    */
+   public String getServicePortName(  )
+   {
+      return PORT_NAME;
+   }
+
+   /**
+    * DOCUMENT_ME
+    *
+    * @throws Exception DOCUMENT_ME
+    */
+   public void init(  )
+   throws Exception
+   {
+      super.init(  );
+      InputStream in        = getClass(  ).getClassLoader(  ).getResourceAsStream( RESOURCE_PROPS_RESOURCE_PATH );
+      XmlOptions  parseOpts = new XmlOptions(  ).setLoadStripWhitespace(  );
+      if ( !m_isOpenContent )
+      {
+         parseOpts.setLoadReplaceDocumentElement( new QName( AbstractResourcePropertiesTestCase.NSURI_SUSHI,
+                                                             "ClosedSushiProperties", "sushi" ) );
+      }
+
+      XmlObject propsDocXBean = XmlObject.Factory.parse( in, parseOpts );
+      in.close(  );
+      ResourcePropertySet propSet  = new XmlBeansResourcePropertySet( propsDocXBean );
+      Resource            resource = createInstance( SushiResourceContext.ID );
+      ( (PropertiesResource) resource ).setResourcePropertySet( propSet );
+      add( resource );
+   }
+
+   /**
+    * Resets (clears) the resource map.
+    */
+   public final synchronized void resetResourceMap(  )
+   {
+      if ( s_resources != null )
+      {
+         s_resources.clear(  );
+      }
+   }
+
+   /**
+    * DOCUMENT_ME
+    *
+    * @return DOCUMENT_ME
+    */
+   public org.apache.ws.resource.properties.NamespaceVersionHolder getNamespaceVersionHolder(  )
+   {
+      return SPEC_NAMESPACE_SET;
+   }
+
+   /**
+    * Returns a map of all SushiResource instances. Used by the {@link AbstractResourceHome} superclass.
+    */
+   protected final synchronized Map getResourceMap(  )
+   {
+      if ( s_resources == null )
+      {
+         s_resources = AbstractResourceHome.createResourceMap( m_resourceIsPersistent );
+      }
+
+      return s_resources;
+   }
+}
\ No newline at end of file

Modified: webservices/wsrf/trunk/src/test/org/apache/ws/resource/properties/SushiPlate.java
URL: http://svn.apache.org/viewcvs/webservices/wsrf/trunk/src/test/org/apache/ws/resource/properties/SushiPlate.java?rev=227033&r1=227032&r2=227033&view=diff
==============================================================================
--- webservices/wsrf/trunk/src/test/org/apache/ws/resource/properties/SushiPlate.java (original)
+++ webservices/wsrf/trunk/src/test/org/apache/ws/resource/properties/SushiPlate.java Tue Aug  2 09:28:49 2005
@@ -1,14 +1,35 @@
-package org.apache.ws.resource.properties;
-
-/**
- * @author Sal Campana
- */
-public class SushiPlate
-{
-    private Ebi m_ebi = new Ebi();
-
-    public Ebi getEbi()
-    {
-        return m_ebi;
-    }
-}
+/*=============================================================================*
+ *  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.
+ *=============================================================================*/
+package org.apache.ws.resource.properties;
+
+
+/**
+ * @author Sal Campana
+ */
+public class SushiPlate
+{
+   private Ebi m_ebi = new Ebi(  );
+
+   /**
+    * DOCUMENT_ME
+    *
+    * @return DOCUMENT_ME
+    */
+   public Ebi getEbi(  )
+   {
+      return m_ebi;
+   }
+}
\ No newline at end of file

Modified: webservices/wsrf/trunk/src/test/org/apache/ws/resource/properties/SushiPropertyQNames.java
URL: http://svn.apache.org/viewcvs/webservices/wsrf/trunk/src/test/org/apache/ws/resource/properties/SushiPropertyQNames.java?rev=227033&r1=227032&r2=227033&view=diff
==============================================================================
--- webservices/wsrf/trunk/src/test/org/apache/ws/resource/properties/SushiPropertyQNames.java (original)
+++ webservices/wsrf/trunk/src/test/org/apache/ws/resource/properties/SushiPropertyQNames.java Tue Aug  2 09:28:49 2005
@@ -24,27 +24,32 @@
  */
 public interface SushiPropertyQNames
 {
+   /** DOCUMENT_ME */
+   QName OPEN_SUSHI_PROPERTIES =
+      new QName( "http://ws.apache.org/resource/properties/test/sushi", "OpenSushiProperties", "sushi" );
 
-    QName OPEN_SUSHI_PROPERTIES =
-            new QName( "http://ws.apache.org/resource/properties/test/sushi", "OpenSushiProperties", "sushi" );
+   /** DOCUMENT_ME */
+   QName CLOSED_SUSHI_PROPERTIES =
+      new QName( "http://ws.apache.org/resource/properties/test/sushi", "ClosedSushiProperties", "sushi" );
 
-    QName CLOSED_SUSHI_PROPERTIES =
-            new QName( "http://ws.apache.org/resource/properties/test/sushi", "ClosedSushiProperties", "sushi" );
+   /** DOCUMENT_ME */
+   QName AKAGI = new QName( "http://ws.apache.org/resource/properties/test/sushi", "Akagi", "sushi" );
 
-    QName AKAGI =
-            new QName( "http://ws.apache.org/resource/properties/test/sushi", "Akagi", "sushi" );
+   /** DOCUMENT_ME */
+   QName HAMACHI = new QName( "http://ws.apache.org/resource/properties/test/sushi", "Hamachi", "sushi" );
 
-    QName HAMACHI =
-            new QName( "http://ws.apache.org/resource/properties/test/sushi", "Hamachi", "sushi" );
+   /** DOCUMENT_ME */
+   QName EBI = new QName( "http://ws.apache.org/resource/properties/test/sushi", "Ebi", "sushi" );
 
-    QName EBI = new QName( "http://ws.apache.org/resource/properties/test/sushi", "Ebi", "sushi" );
+   /** DOCUMENT_ME */
+   QName IKA = new QName( "http://ws.apache.org/resource/properties/test/sushi", "Ika", "sushi" );
 
-    QName IKA = new QName( "http://ws.apache.org/resource/properties/test/sushi", "Ika", "sushi" );
+   /** DOCUMENT_ME */
+   QName OHTORO = new QName( "http://ws.apache.org/resource/properties/test/sushi", "Ohtoro", "sushi" );
 
-    QName OHTORO = new QName( "http://ws.apache.org/resource/properties/test/sushi", "Ohtoro", "sushi" );
+   /** DOCUMENT_ME */
+   QName FUGU = new QName( "http://ws.apache.org/resource/properties/test/sushi/blowfish", "Fugu", "fu" );
 
-    QName FUGU = new QName( "http://ws.apache.org/resource/properties/test/sushi/blowfish", "Fugu", "fu" );
-
-    QName UNI = new QName( "http://ws.apache.org/resource/properties/test/sushi", "Uni", "sushi" );
-
-}
+   /** DOCUMENT_ME */
+   QName UNI = new QName( "http://ws.apache.org/resource/properties/test/sushi", "Uni", "sushi" );
+}
\ No newline at end of file



Mime
View raw message