axis-java-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From chinth...@apache.org
Subject svn commit: r231169 [1/2] - in /webservices/axis/trunk/java: modules/addressing/test/org/apache/axis2/handlers/util/ modules/common/src/org/apache/axis2/i18n/ modules/core/src/org/apache/axis2/clientapi/ modules/core/src/org/apache/axis2/context/ modul...
Date Wed, 10 Aug 2005 05:01:39 GMT
Author: chinthaka
Date: Tue Aug  9 21:56:37 2005
New Revision: 231169

URL: http://svn.apache.org/viewcvs?rev=231169&view=rev
Log:
- Fixing OMChidren extraction bug
- Applying Chamil's patch SMTOP docs

Code Cleanup
- simplifying boolean expressions
- changing redundant variables within methods
- removing redundant continue statements
- removing unncessary type casts
- some more using Code Analysis tool (IDEA)

Modified:
    webservices/axis/trunk/java/modules/addressing/test/org/apache/axis2/handlers/util/TestUtil.java
    webservices/axis/trunk/java/modules/common/src/org/apache/axis2/i18n/Messages.java
    webservices/axis/trunk/java/modules/common/src/org/apache/axis2/i18n/ProjectResourceBundle.java
    webservices/axis/trunk/java/modules/core/src/org/apache/axis2/clientapi/Call.java
    webservices/axis/trunk/java/modules/core/src/org/apache/axis2/clientapi/InOutMEPClient.java
    webservices/axis/trunk/java/modules/core/src/org/apache/axis2/clientapi/MessageSender.java
    webservices/axis/trunk/java/modules/core/src/org/apache/axis2/clientapi/Stub.java
    webservices/axis/trunk/java/modules/core/src/org/apache/axis2/context/ConfigurationContext.java
    webservices/axis/trunk/java/modules/core/src/org/apache/axis2/deployment/DeploymentEngine.java
    webservices/axis/trunk/java/modules/core/src/org/apache/axis2/deployment/DeploymentParser.java
    webservices/axis/trunk/java/modules/core/src/org/apache/axis2/deployment/listener/RepositoryListenerImpl.java
    webservices/axis/trunk/java/modules/core/src/org/apache/axis2/deployment/repository/util/ArchiveReader.java
    webservices/axis/trunk/java/modules/core/src/org/apache/axis2/deployment/repository/util/WSInfoList.java
    webservices/axis/trunk/java/modules/core/src/org/apache/axis2/deployment/util/PhasesInfo.java
    webservices/axis/trunk/java/modules/core/src/org/apache/axis2/description/OperationDescription.java
    webservices/axis/trunk/java/modules/core/src/org/apache/axis2/description/ServiceDescription.java
    webservices/axis/trunk/java/modules/core/src/org/apache/axis2/engine/AbstractDispatcher.java
    webservices/axis/trunk/java/modules/core/src/org/apache/axis2/engine/AddressingBasedDispatcher.java
    webservices/axis/trunk/java/modules/core/src/org/apache/axis2/engine/RequestURIBasedDispatcher.java
    webservices/axis/trunk/java/modules/core/src/org/apache/axis2/engine/SOAPActionBasedDispatcher.java
    webservices/axis/trunk/java/modules/core/src/org/apache/axis2/engine/SOAPMessageBodyBasedDispatcher.java
    webservices/axis/trunk/java/modules/core/src/org/apache/axis2/phaseresolver/PhaseResolver.java
    webservices/axis/trunk/java/modules/core/src/org/apache/axis2/phaseresolver/util/PhaseValidator.java
    webservices/axis/trunk/java/modules/core/src/org/apache/axis2/transport/http/AxisServlet.java
    webservices/axis/trunk/java/modules/core/src/org/apache/axis2/transport/http/ChunkedInputStream.java
    webservices/axis/trunk/java/modules/core/src/org/apache/axis2/transport/http/CommonsHTTPTransportSender.java
    webservices/axis/trunk/java/modules/core/src/org/apache/axis2/transport/http/HTTPTransportUtils.java
    webservices/axis/trunk/java/modules/core/src/org/apache/axis2/transport/http/ListingAgent.java
    webservices/axis/trunk/java/modules/core/src/org/apache/axis2/transport/mail/server/POP3Worker.java
    webservices/axis/trunk/java/modules/core/src/org/apache/axis2/transport/tcp/TCPServer.java
    webservices/axis/trunk/java/modules/core/test/org/apache/axis2/engine/MessageContextInjectionTest.java
    webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/engine/CharctersetEncodingTest.java
    webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/engine/CommonsHTTPEchoRawXMLTest.java
    webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/engine/EchoRawXMLChunckedTest.java
    webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/engine/EchoRawXMLLoadTest.java
    webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/engine/EchoRawXMLOnTwoChannelsSyncTest.java
    webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/engine/EchoRawXMLTest.java
    webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/engine/FaultHandlingTest.java
    webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/engine/ServiceDispatchingTest.java
    webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/engine/util/MyInOutMEPClient.java
    webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/groovy/GroovyServiceTest.java
    webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/integration/UtilServer.java
    webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/mtom/EchoRawMTOMTest.java
    webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/rest/RESTBasedEchoRawXMLTest.java
    webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/swa/EchoSwA.java
    webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/tcp/TCPEchoRawXMLTest.java
    webservices/axis/trunk/java/modules/saaj/src/javax/xml/namespace/QName.java
    webservices/axis/trunk/java/modules/saaj/src/org/apache/axis2/saaj/MessageFactoryImpl.java
    webservices/axis/trunk/java/modules/saaj/src/org/apache/axis2/saaj/NodeImpl.java
    webservices/axis/trunk/java/modules/saaj/src/org/apache/axis2/saaj/PrefixedQName.java
    webservices/axis/trunk/java/modules/saaj/src/org/apache/axis2/saaj/SOAPDocumentImpl.java
    webservices/axis/trunk/java/modules/saaj/src/org/apache/axis2/saaj/SOAPElementImpl.java
    webservices/axis/trunk/java/modules/saaj/src/org/apache/axis2/saaj/SOAPEnvelopeImpl.java
    webservices/axis/trunk/java/modules/saaj/src/org/apache/axis2/saaj/TextImpl.java
    webservices/axis/trunk/java/modules/saaj/src/org/apache/axis2/util/XMLUtils.java
    webservices/axis/trunk/java/modules/saaj/test/org/apache/axis2/saaj/EnvelopeTest.java
    webservices/axis/trunk/java/modules/samples/src/sample/amazon/amazonSimpleQueueService/util/QueueManager.java
    webservices/axis/trunk/java/modules/samples/src/sample/amazon/search/GUIHandler.java
    webservices/axis/trunk/java/modules/samples/src/sample/amazon/search/LinkFollower.java
    webservices/axis/trunk/java/modules/samples/src/sample/google/common/util/PropertyLoader.java
    webservices/axis/trunk/java/modules/samples/src/sample/google/search/ClientCallbackHandler.java
    webservices/axis/trunk/java/modules/samples/src/sample/google/search/LinkFollower.java
    webservices/axis/trunk/java/modules/samples/src/sample/google/spellcheck/FormModel.java
    webservices/axis/trunk/java/modules/samples/src/sample/groovy/GroovyReceiver.java
    webservices/axis/trunk/java/modules/samples/src/sample/mtom/imagetransfer/client/MTOMClientModel.java
    webservices/axis/trunk/java/modules/samples/src/sample/mtom/imagetransfer/client/UserInterface.java
    webservices/axis/trunk/java/modules/samples/src/sample/mtom/interop/client/InteropClientModel.java
    webservices/axis/trunk/java/modules/samples/src/sample/mtom/interop/client/UserInterface.java
    webservices/axis/trunk/java/modules/samples/src/userguide/clients/ClientForWebServiceWithModule.java
    webservices/axis/trunk/java/modules/samples/src/userguide/clients/EchoBlockingClient.java
    webservices/axis/trunk/java/modules/samples/src/userguide/clients/EchoBlockingDualClient.java
    webservices/axis/trunk/java/modules/wsdl/src/org/apache/axis2/wsdl/builder/WOMBuilderFactory.java
    webservices/axis/trunk/java/modules/wsdl/src/org/apache/axis2/wsdl/codegen/CodeGenerationEngine.java
    webservices/axis/trunk/java/modules/wsdl/src/org/apache/axis2/wsdl/codegen/emitter/MultiLanguageClientEmitter.java
    webservices/axis/trunk/java/modules/wsdl/src/org/apache/axis2/wsdl/codegen/extension/SimpleDBExtension.java
    webservices/axis/trunk/java/modules/wsdl/src/org/apache/axis2/wsdl/util/XMLUtils.java
    webservices/axis/trunk/java/modules/wsdl/test/org/apache/axis2/wsdl/codegen/WSDL2JavaTest.java
    webservices/axis/trunk/java/modules/wsdl/test/org/apache/wsdl/InterfaceTest.java
    webservices/axis/trunk/java/modules/xml/src/org/apache/axis2/attachments/PartOnFile.java
    webservices/axis/trunk/java/modules/xml/src/org/apache/axis2/om/impl/llom/serialize/StreamingOMSerializer.java
    webservices/axis/trunk/java/modules/xml/src/org/apache/axis2/om/impl/llom/traverse/OMChildrenWithSpecificAttributeIterator.java
    webservices/axis/trunk/java/modules/xml/src/org/apache/axis2/soap/impl/llom/SOAPEnvelopeImpl.java
    webservices/axis/trunk/java/modules/xml/src/org/apache/axis2/soap/impl/llom/builder/SOAP12BuilderHelper.java
    webservices/axis/trunk/java/modules/xml/src/org/apache/axis2/soap/impl/llom/soap11/SOAP11BodyImpl.java
    webservices/axis/trunk/java/modules/xml/test/org/apache/axis2/attachments/ImageSampleTest.java
    webservices/axis/trunk/java/modules/xml/test/org/apache/axis2/om/IteratorTester.java
    webservices/axis/trunk/java/modules/xml/test/org/apache/axis2/om/OMTestCase.java
    webservices/axis/trunk/java/modules/xml/test/org/apache/axis2/om/OMTestUtils.java
    webservices/axis/trunk/java/modules/xml/test/org/apache/axis2/om/impl/traverse/OMChildrenWithSpecificAttributeIteratorTest.java
    webservices/axis/trunk/java/xdocs/mail-configuration.html
    webservices/axis/trunk/java/xdocs/mail-transport.html

Modified: webservices/axis/trunk/java/modules/addressing/test/org/apache/axis2/handlers/util/TestUtil.java
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/java/modules/addressing/test/org/apache/axis2/handlers/util/TestUtil.java?rev=231169&r1=231168&r2=231169&view=diff
==============================================================================
--- webservices/axis/trunk/java/modules/addressing/test/org/apache/axis2/handlers/util/TestUtil.java (original)
+++ webservices/axis/trunk/java/modules/addressing/test/org/apache/axis2/handlers/util/TestUtil.java Tue Aug  9 21:56:37 2005
@@ -35,7 +35,7 @@
 
 
     public StAXSOAPModelBuilder getOMBuilder(String fileName) throws Exception {
-        if (fileName == "" || fileName == null) {
+        if ("".equals(fileName) || fileName == null) {
             fileName = IN_FILE_NAME;
         }
         XMLStreamReader parser = XMLInputFactory.newInstance()

Modified: webservices/axis/trunk/java/modules/common/src/org/apache/axis2/i18n/Messages.java
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/java/modules/common/src/org/apache/axis2/i18n/Messages.java?rev=231169&r1=231168&r2=231169&view=diff
==============================================================================
--- webservices/axis/trunk/java/modules/common/src/org/apache/axis2/i18n/Messages.java (original)
+++ webservices/axis/trunk/java/modules/common/src/org/apache/axis2/i18n/Messages.java Tue Aug  9 21:56:37 2005
@@ -49,7 +49,7 @@
     private static final ClassLoader classLoader = thisClass.getClassLoader();
 
     private static final ResourceBundle parent =
-            (MessagesConstants.rootPackageName == packageName)
+            (MessagesConstants.rootPackageName.equals(packageName))
             ? null
             : MessagesConstants.rootBundle;
 

Modified: webservices/axis/trunk/java/modules/common/src/org/apache/axis2/i18n/ProjectResourceBundle.java
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/java/modules/common/src/org/apache/axis2/i18n/ProjectResourceBundle.java?rev=231169&r1=231168&r2=231169&view=diff
==============================================================================
--- webservices/axis/trunk/java/modules/common/src/org/apache/axis2/i18n/ProjectResourceBundle.java (original)
+++ webservices/axis/trunk/java/modules/common/src/org/apache/axis2/i18n/ProjectResourceBundle.java Tue Aug  9 21:56:37 2005
@@ -419,7 +419,7 @@
 
         ResourceBundle getParentBundle(String packageName) {
             ResourceBundle p;
-            if (packageName != _projectName) {
+            if (!packageName.equals(_projectName)) {
                 p = getBundle(this, getPackage(packageName));
             } else {
                 p = _parent;
@@ -446,7 +446,7 @@
             /* Ensure that project is a proper prefix of class.
              * Terminate project name with '.' to ensure proper match.
              */
-            if (packageName != _projectName && !packageName.startsWith(_projectName + '.')) {
+            if (!packageName.equals(_projectName) && !packageName.startsWith(_projectName + '.')) {
                 log.debug("Project not a prefix of Package");
                 throw new MissingResourceException("Project '" + _projectName
                         + "' must be a prefix of Package '"

Modified: webservices/axis/trunk/java/modules/core/src/org/apache/axis2/clientapi/Call.java
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/java/modules/core/src/org/apache/axis2/clientapi/Call.java?rev=231169&r1=231168&r2=231169&view=diff
==============================================================================
--- webservices/axis/trunk/java/modules/core/src/org/apache/axis2/clientapi/Call.java (original)
+++ webservices/axis/trunk/java/modules/core/src/org/apache/axis2/clientapi/Call.java Tue Aug  9 21:56:37 2005
@@ -173,9 +173,7 @@
         }
         axisService.addOperation(operationTemplate);
         sysContext.getAxisConfiguration().addService(axisService);
-        ServiceContext service =
-                sysContext.createServiceContext(assumedServiceName);
-        return service;
+        return sysContext.createServiceContext(assumedServiceName);
     }
 
     /**

Modified: webservices/axis/trunk/java/modules/core/src/org/apache/axis2/clientapi/InOutMEPClient.java
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/java/modules/core/src/org/apache/axis2/clientapi/InOutMEPClient.java?rev=231169&r1=231168&r2=231169&view=diff
==============================================================================
--- webservices/axis/trunk/java/modules/core/src/org/apache/axis2/clientapi/InOutMEPClient.java (original)
+++ webservices/axis/trunk/java/modules/core/src/org/apache/axis2/clientapi/InOutMEPClient.java Tue Aug  9 21:56:37 2005
@@ -302,7 +302,7 @@
         }
         
         //if seperate transport is used, start the required listeners
-        if (useSeparateListener == true) {
+        if (useSeparateListener) {
             if (!serviceContext
                     .getEngineContext()
                     .getAxisConfiguration()

Modified: webservices/axis/trunk/java/modules/core/src/org/apache/axis2/clientapi/MessageSender.java
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/java/modules/core/src/org/apache/axis2/clientapi/MessageSender.java?rev=231169&r1=231168&r2=231169&view=diff
==============================================================================
--- webservices/axis/trunk/java/modules/core/src/org/apache/axis2/clientapi/MessageSender.java (original)
+++ webservices/axis/trunk/java/modules/core/src/org/apache/axis2/clientapi/MessageSender.java Tue Aug  9 21:56:37 2005
@@ -79,8 +79,7 @@
         ServiceDescription axisService = new ServiceDescription(
                 assumedServiceName);
         sysContext.getAxisConfiguration().addService(axisService);
-        ServiceContext service = sysContext.createServiceContext(
+        return sysContext.createServiceContext(
                 assumedServiceName);
-        return service;
     }
 }

Modified: webservices/axis/trunk/java/modules/core/src/org/apache/axis2/clientapi/Stub.java
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/java/modules/core/src/org/apache/axis2/clientapi/Stub.java?rev=231169&r1=231168&r2=231169&view=diff
==============================================================================
--- webservices/axis/trunk/java/modules/core/src/org/apache/axis2/clientapi/Stub.java (original)
+++ webservices/axis/trunk/java/modules/core/src/org/apache/axis2/clientapi/Stub.java Tue Aug  9 21:56:37 2005
@@ -127,8 +127,7 @@
 
     //todo make this compliant with the SOAP12
     protected SOAPEnvelope createEnvelope() throws SOAPProcessingException {
-        SOAPEnvelope env = getFactory().getDefaultEnvelope();
-        return env;
+        return getFactory().getDefaultEnvelope();
     }
 
     protected void setValueRPC(SOAPEnvelope env,

Modified: webservices/axis/trunk/java/modules/core/src/org/apache/axis2/context/ConfigurationContext.java
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/java/modules/core/src/org/apache/axis2/context/ConfigurationContext.java?rev=231169&r1=231168&r2=231169&view=diff
==============================================================================
--- webservices/axis/trunk/java/modules/core/src/org/apache/axis2/context/ConfigurationContext.java (original)
+++ webservices/axis/trunk/java/modules/core/src/org/apache/axis2/context/ConfigurationContext.java Tue Aug  9 21:56:37 2005
@@ -140,8 +140,7 @@
         throws AxisFault {
         ServiceDescription service = axisConfiguration.getService(serviceName);
         if (service != null) {
-            ServiceContext serviceContext = new ServiceContext(service, this);
-            return serviceContext;
+            return new ServiceContext(service, this);
         } else {
             throw new AxisFault(
                 "Service not found service name = " + serviceName);

Modified: webservices/axis/trunk/java/modules/core/src/org/apache/axis2/deployment/DeploymentEngine.java
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/java/modules/core/src/org/apache/axis2/deployment/DeploymentEngine.java?rev=231169&r1=231168&r2=231169&view=diff
==============================================================================
--- webservices/axis/trunk/java/modules/core/src/org/apache/axis2/deployment/DeploymentEngine.java (original)
+++ webservices/axis/trunk/java/modules/core/src/org/apache/axis2/deployment/DeploymentEngine.java Tue Aug  9 21:56:37 2005
@@ -176,8 +176,8 @@
      */
     private void setDeploymentFeatures() {
         String value;
-        Parameter parahotdeployment = ((AxisConfigurationImpl) axisConfig).getParameter(HOTDEPLOYMENT);
-        Parameter parahotupdate = ((AxisConfigurationImpl) axisConfig).getParameter(HOTUPDATE);
+        Parameter parahotdeployment = axisConfig.getParameter(HOTDEPLOYMENT);
+        Parameter parahotupdate = axisConfig.getParameter(HOTUPDATE);
         if (parahotdeployment != null) {
             value = (String) parahotdeployment.getValue();
             if ("false".equals(value))
@@ -319,7 +319,7 @@
         // PhaseResolver resolver = new PhaseResolver(axisConfig);
         for (Iterator iterator = modulelist.iterator(); iterator.hasNext();) {
             QName name = (QName) iterator.next();
-            ((AxisConfigurationImpl) axisConfig).engageModule(name);
+            axisConfig.engageModule(name);
         }
     }
 
@@ -332,10 +332,10 @@
     private void validateSystemPredefinedPhases() throws DeploymentException {
         ArrayList inPhases = phasesinfo.getINPhases();
         //TODO condition checking should be otherway since null value can occur
-        if (!(((String) inPhases.get(0)).equals(PhaseMetadata.PHASE_TRANSPORTIN) &&
-                ((String) inPhases.get(1)).equals(PhaseMetadata.PHASE_PRE_DISPATCH) &&
-                ((String) inPhases.get(2)).equals(PhaseMetadata.PHASE_DISPATCH) &&
-                ((String) inPhases.get(3)).equals(PhaseMetadata.PHASE_POST_DISPATCH))) {
+        if (!(inPhases.get(0).equals(PhaseMetadata.PHASE_TRANSPORTIN) &&
+                inPhases.get(1).equals(PhaseMetadata.PHASE_PRE_DISPATCH) &&
+                inPhases.get(2).equals(PhaseMetadata.PHASE_DISPATCH) &&
+                inPhases.get(3).equals(PhaseMetadata.PHASE_POST_DISPATCH))) {
             throw new DeploymentException(Messages.getMessage(DeploymentErrorMsgs.IN_VALID_PHASE));
         }
         //  ArrayList outPhaes = tempdata.getOutphases();
@@ -344,8 +344,7 @@
     }
 
     public ModuleDescription getModule(QName moduleName) throws AxisFault {
-        ModuleDescription axisModule = axisConfig.getModule(moduleName);
-        return axisModule;
+        return axisConfig.getModule(moduleName);
     }
 
     /**
@@ -359,8 +358,7 @@
     }
 
     private AxisConfiguration createEngineConfig() {
-        AxisConfiguration newEngineConfig = new AxisConfigurationImpl();
-        return newEngineConfig;
+        return new AxisConfigurationImpl();
     }
 
 

Modified: webservices/axis/trunk/java/modules/core/src/org/apache/axis2/deployment/DeploymentParser.java
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/java/modules/core/src/org/apache/axis2/deployment/DeploymentParser.java?rev=231169&r1=231168&r2=231169&view=diff
==============================================================================
--- webservices/axis/trunk/java/modules/core/src/org/apache/axis2/deployment/DeploymentParser.java (original)
+++ webservices/axis/trunk/java/modules/core/src/org/apache/axis2/deployment/DeploymentParser.java Tue Aug  9 21:56:37 2005
@@ -101,7 +101,6 @@
     public void processGlobalConfig(AxisConfigurationImpl axisGlobal,
                                     String starttag)
             throws DeploymentException {
-        String START_TAG = starttag;
         try {
             boolean END_DOCUMENT = false;
             while (!END_DOCUMENT) {
@@ -112,7 +111,7 @@
                     break;
                 } else if (eventType == XMLStreamConstants.START_ELEMENT) {
                     String ST = pullparser.getLocalName(); //Staring tag name
-                    if (START_TAG.equals(ST)) {
+                    if (starttag.equals(ST)) {
                         //todo complete this to fill the names
                     } else if (PARAMETERST.equals(ST)) {
                         Parameter parameter = processParameter();
@@ -223,7 +222,7 @@
                     }
                 } else if (eventType == XMLStreamConstants.END_ELEMENT) {
                     String endtagname = pullparser.getLocalName();
-                    if (START_TAG.equals(endtagname)) {
+                    if (starttag.equals(endtagname)) {
                         END_DOCUMENT = true;
                         break;
                     }

Modified: webservices/axis/trunk/java/modules/core/src/org/apache/axis2/deployment/listener/RepositoryListenerImpl.java
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/java/modules/core/src/org/apache/axis2/deployment/listener/RepositoryListenerImpl.java?rev=231169&r1=231168&r2=231169&view=diff
==============================================================================
--- webservices/axis/trunk/java/modules/core/src/org/apache/axis2/deployment/listener/RepositoryListenerImpl.java (original)
+++ webservices/axis/trunk/java/modules/core/src/org/apache/axis2/deployment/listener/RepositoryListenerImpl.java Tue Aug  9 21:56:37 2005
@@ -165,17 +165,11 @@
      * @return
      */
     private boolean isServiceArchiveFile(String filename) {
-        if (filename.endsWith(".jar") | filename.endsWith(".aar")) {
-            return true;
-        }
-        return false;
+        return ((filename.endsWith(".jar")) | (filename.endsWith(".aar")));
     }
 
     private boolean isModuleArchiveFile(String filename) {
-        if (filename.endsWith(".jar") || filename.endsWith(".mar")) {
-            return true;
-        }
-        return false;
+        return ((filename.endsWith(".jar")) || (filename.endsWith(".mar")));
     }
 
 }

Modified: webservices/axis/trunk/java/modules/core/src/org/apache/axis2/deployment/repository/util/ArchiveReader.java
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/java/modules/core/src/org/apache/axis2/deployment/repository/util/ArchiveReader.java?rev=231169&r1=231168&r2=231169&view=diff
==============================================================================
--- webservices/axis/trunk/java/modules/core/src/org/apache/axis2/deployment/repository/util/ArchiveReader.java (original)
+++ webservices/axis/trunk/java/modules/core/src/org/apache/axis2/deployment/repository/util/ArchiveReader.java Tue Aug  9 21:56:37 2005
@@ -27,7 +27,6 @@
 import org.apache.commons.logging.Log;
 import org.apache.commons.logging.LogFactory;
 import org.apache.wsdl.WSDLDescription;
-import org.apache.wsdl.WSDLService;
 import org.apache.wsdl.impl.WSDLServiceImpl;
 
 import java.io.*;
@@ -127,10 +126,9 @@
                                    ServiceDescription service) throws DeploymentException {
         // get attribute values
         boolean foundServiceXML = false;
-        String strArchive = filename;
         ZipInputStream zin;
         try {
-            zin = new ZipInputStream(new FileInputStream(strArchive));
+            zin = new ZipInputStream(new FileInputStream(filename));
             ZipEntry entry;
             while ((entry = zin.getNextEntry()) != null) {
                 if (entry.getName().equals(SERVICEXML)) {
@@ -155,10 +153,9 @@
                                   ModuleDescription module) throws DeploymentException {
         // get attribute values
         boolean foundmoduleXML = false;
-        String strArchive = filename;
         ZipInputStream zin = null;
         try {
-            zin = new ZipInputStream(new FileInputStream(strArchive));
+            zin = new ZipInputStream(new FileInputStream(filename));
             ZipEntry entry;
             while ((entry = zin.getNextEntry()) != null) {
                 if (entry.getName().equals(MODULEXML)) {
@@ -171,7 +168,7 @@
             //  zin.closeEntry();
             zin.close();
             if (!foundmoduleXML) {
-                throw new DeploymentException(Messages.getMessage(DeploymentErrorMsgs.MODULEXML_NOT_FOUND_FOR_THE_MODULE, strArchive));
+                throw new DeploymentException(Messages.getMessage(DeploymentErrorMsgs.MODULEXML_NOT_FOUND_FOR_THE_MODULE, filename));
 //                        "module.xml not found  for the module :  " +
 //                        strArchive);
             }

Modified: webservices/axis/trunk/java/modules/core/src/org/apache/axis2/deployment/repository/util/WSInfoList.java
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/java/modules/core/src/org/apache/axis2/deployment/repository/util/WSInfoList.java?rev=231169&r1=231168&r2=231169&view=diff
==============================================================================
--- webservices/axis/trunk/java/modules/core/src/org/apache/axis2/deployment/repository/util/WSInfoList.java (original)
+++ webservices/axis/trunk/java/modules/core/src/org/apache/axis2/deployment/repository/util/WSInfoList.java Tue Aug  9 21:56:37 2005
@@ -152,10 +152,7 @@
      * @return
      */
     public boolean isModified(File file, WSInfo wsInfo) {
-        if (wsInfo.getLastmodifieddate() != file.lastModified()) {
-            return true;
-        }
-        return false;
+        return (wsInfo.getLastmodifieddate() != file.lastModified());
     }
 
     /**

Modified: webservices/axis/trunk/java/modules/core/src/org/apache/axis2/deployment/util/PhasesInfo.java
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/java/modules/core/src/org/apache/axis2/deployment/util/PhasesInfo.java?rev=231169&r1=231168&r2=231169&view=diff
==============================================================================
--- webservices/axis/trunk/java/modules/core/src/org/apache/axis2/deployment/util/PhasesInfo.java (original)
+++ webservices/axis/trunk/java/modules/core/src/org/apache/axis2/deployment/util/PhasesInfo.java Tue Aug  9 21:56:37 2005
@@ -82,7 +82,6 @@
                     PhaseMetadata.PHASE_PRE_DISPATCH.equals(phaseName) ||
                     PhaseMetadata.PHASE_DISPATCH.equals(phaseName) ||
                     PhaseMetadata.PHASE_POST_DISPATCH.equals(phaseName)) {
-                continue;
             } else {
                 oprationINPhases.add(new Phase(phaseName));
             }
@@ -95,7 +94,6 @@
         for (int i = 0; i < OUTPhases.size(); i++) {
             String phaseName = (String) OUTPhases.get(i);
             if (PhaseMetadata.PHASE_TRANSPORT_OUT.equals(phaseName)) {
-                continue;
             } else {
                 oprationOUTPhases.add(new Phase(phaseName));
             }

Modified: webservices/axis/trunk/java/modules/core/src/org/apache/axis2/description/OperationDescription.java
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/java/modules/core/src/org/apache/axis2/description/OperationDescription.java?rev=231169&r1=231168&r2=231169&view=diff
==============================================================================
--- webservices/axis/trunk/java/modules/core/src/org/apache/axis2/description/OperationDescription.java (original)
+++ webservices/axis/trunk/java/modules/core/src/org/apache/axis2/description/OperationDescription.java Tue Aug  9 21:56:37 2005
@@ -146,7 +146,7 @@
     public Parameter getParameter(String name) {
         ParameterIncludeImpl paramInclude = (ParameterIncludeImpl) this
                 .getComponentProperty(PARAMETER_KEY);
-        return (Parameter) paramInclude.getParameter(name);
+        return paramInclude.getParameter(name);
     }
 
     public ArrayList getParameters() {

Modified: webservices/axis/trunk/java/modules/core/src/org/apache/axis2/description/ServiceDescription.java
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/java/modules/core/src/org/apache/axis2/description/ServiceDescription.java?rev=231169&r1=231168&r2=231169&view=diff
==============================================================================
--- webservices/axis/trunk/java/modules/core/src/org/apache/axis2/description/ServiceDescription.java (original)
+++ webservices/axis/trunk/java/modules/core/src/org/apache/axis2/description/ServiceDescription.java Tue Aug  9 21:56:37 2005
@@ -338,7 +338,7 @@
     public Parameter getParameter(String name) {
         ParameterIncludeImpl paramInclude =
                 (ParameterIncludeImpl) this.getComponentProperty(PARAMETER_KEY);
-        return (Parameter) paramInclude.getParameter(name);
+        return paramInclude.getParameter(name);
     }
 
     public ArrayList getParameters() {
@@ -558,7 +558,7 @@
             // serviceContext);
         } else {
             serviceContext =
-                    (ServiceContext) msgContext.getSystemContext()
+                    msgContext.getSystemContext()
                     .getServiceContext(msgContext.getServiceInstanceID());
         }
 

Modified: webservices/axis/trunk/java/modules/core/src/org/apache/axis2/engine/AbstractDispatcher.java
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/java/modules/core/src/org/apache/axis2/engine/AbstractDispatcher.java?rev=231169&r1=231168&r2=231169&view=diff
==============================================================================
--- webservices/axis/trunk/java/modules/core/src/org/apache/axis2/engine/AbstractDispatcher.java (original)
+++ webservices/axis/trunk/java/modules/core/src/org/apache/axis2/engine/AbstractDispatcher.java Tue Aug  9 21:56:37 2005
@@ -15,6 +15,7 @@
 */
 package org.apache.axis2.engine;
 
+import org.apache.axis2.AxisFault;
 import org.apache.axis2.context.ConfigurationContext;
 import org.apache.axis2.context.MessageContext;
 import org.apache.axis2.context.OperationContext;
@@ -22,7 +23,6 @@
 import org.apache.axis2.description.OperationDescription;
 import org.apache.axis2.description.ServiceDescription;
 import org.apache.axis2.handlers.AbstractHandler;
-import org.apache.axis2.AxisFault;
 
 import javax.xml.namespace.QName;
 

Modified: webservices/axis/trunk/java/modules/core/src/org/apache/axis2/engine/AddressingBasedDispatcher.java
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/java/modules/core/src/org/apache/axis2/engine/AddressingBasedDispatcher.java?rev=231169&r1=231168&r2=231169&view=diff
==============================================================================
--- webservices/axis/trunk/java/modules/core/src/org/apache/axis2/engine/AddressingBasedDispatcher.java (original)
+++ webservices/axis/trunk/java/modules/core/src/org/apache/axis2/engine/AddressingBasedDispatcher.java Tue Aug  9 21:56:37 2005
@@ -43,11 +43,10 @@
                                               MessageContext messageContext)
             throws AxisFault {
 
-        String action = (String) messageContext.getWSAAction();
+        String action = messageContext.getWSAAction();
         if (action != null) {
             QName operationName = new QName(action);
-            OperationDescription op = service.getOperation(operationName);
-            return op;
+            return service.getOperation(operationName);
         }
         return null;
     }

Modified: webservices/axis/trunk/java/modules/core/src/org/apache/axis2/engine/RequestURIBasedDispatcher.java
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/java/modules/core/src/org/apache/axis2/engine/RequestURIBasedDispatcher.java?rev=231169&r1=231168&r2=231169&view=diff
==============================================================================
--- webservices/axis/trunk/java/modules/core/src/org/apache/axis2/engine/RequestURIBasedDispatcher.java (original)
+++ webservices/axis/trunk/java/modules/core/src/org/apache/axis2/engine/RequestURIBasedDispatcher.java Tue Aug  9 21:56:37 2005
@@ -49,8 +49,7 @@
                                               MessageContext messageContext)
             throws AxisFault {
         if (operationName != null) {
-            OperationDescription axisOp = service.getOperation(operationName);
-            return axisOp;
+            return service.getOperation(operationName);
         }
         return null;
 

Modified: webservices/axis/trunk/java/modules/core/src/org/apache/axis2/engine/SOAPActionBasedDispatcher.java
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/java/modules/core/src/org/apache/axis2/engine/SOAPActionBasedDispatcher.java?rev=231169&r1=231168&r2=231169&view=diff
==============================================================================
--- webservices/axis/trunk/java/modules/core/src/org/apache/axis2/engine/SOAPActionBasedDispatcher.java (original)
+++ webservices/axis/trunk/java/modules/core/src/org/apache/axis2/engine/SOAPActionBasedDispatcher.java Tue Aug  9 21:56:37 2005
@@ -42,7 +42,7 @@
                                               MessageContext messageContext)
             throws AxisFault {
 
-        String action = (String) messageContext.getSoapAction();
+        String action = messageContext.getSoapAction();
         if (action != null) {
             OperationDescription op = service.getOperationBySOAPAction(action);
             if (op == null) {

Modified: webservices/axis/trunk/java/modules/core/src/org/apache/axis2/engine/SOAPMessageBodyBasedDispatcher.java
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/java/modules/core/src/org/apache/axis2/engine/SOAPMessageBodyBasedDispatcher.java?rev=231169&r1=231168&r2=231169&view=diff
==============================================================================
--- webservices/axis/trunk/java/modules/core/src/org/apache/axis2/engine/SOAPMessageBodyBasedDispatcher.java (original)
+++ webservices/axis/trunk/java/modules/core/src/org/apache/axis2/engine/SOAPMessageBodyBasedDispatcher.java Tue Aug  9 21:56:37 2005
@@ -54,8 +54,7 @@
                 .getFirstElement();
         operationName = new QName(bodyFirstChild.getLocalName());
 
-        OperationDescription axisOp = service.getOperation(operationName);
-        return axisOp;
+        return service.getOperation(operationName);
     }
 
     /* (non-Javadoc)

Modified: webservices/axis/trunk/java/modules/core/src/org/apache/axis2/phaseresolver/PhaseResolver.java
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/java/modules/core/src/org/apache/axis2/phaseresolver/PhaseResolver.java?rev=231169&r1=231168&r2=231169&view=diff
==============================================================================
--- webservices/axis/trunk/java/modules/core/src/org/apache/axis2/phaseresolver/PhaseResolver.java (original)
+++ webservices/axis/trunk/java/modules/core/src/org/apache/axis2/phaseresolver/PhaseResolver.java Tue Aug  9 21:56:37 2005
@@ -116,7 +116,6 @@
      */
     private void buildExcutionChains(int type, OperationDescription operation)
             throws AxisFault, PhaseException {
-        int flowtype = type;
         ArrayList allHandlers = new ArrayList();
         ModuleDescription module;
         Flow flow = null;
@@ -127,7 +126,7 @@
             QName modulename = (QName) modulqnames.get(i);
             module = axisConfig.getModule(modulename);
             if (module != null) {
-                switch (flowtype) {
+                switch (type) {
                     case PhaseMetadata.IN_FLOW:
                         {
                             flow = module.getInFlow();
@@ -167,7 +166,6 @@
                          * are already added to global chain which run irrespective of the service
                          *
                          */
-                        continue;
                     }
                 }
             }
@@ -176,7 +174,7 @@
 
         ///////////////////////////////////////////////////////////////////////////////////////////
         ////////////////////////// SERVICE HANDLERS ///////////////////////////////////////////////
-        switch (flowtype) {
+        switch (type) {
             case PhaseMetadata.IN_FLOW:
                 {
                     flow = axisService.getInFlow();
@@ -210,7 +208,7 @@
                 allHandlers.add(metadata);
             }
         }
-        switch (flowtype) {
+        switch (type) {
             case PhaseMetadata.IN_FLOW:
                 {
                     phaseHolder =
@@ -296,7 +294,6 @@
                 }
                 new PhaseHolder().buildTransportHandlerChain(phase, handlers);
             } else {
-                continue;
             }
         }
     }
@@ -336,7 +333,6 @@
                 }
                 new PhaseHolder().buildTransportHandlerChain(phase, handlers);
             } else {
-                continue;
             }
         }
     }
@@ -438,8 +434,6 @@
                         HandlerDescription metadata = flow.getHandler(j);
                         if (!PhaseValidator.isSystemPhases(metadata.getRules().getPhaseName())) {
                             phaseHolder.addHandler(metadata);
-                        } else {
-                            continue;
                         }
                     }
                 }
@@ -456,7 +450,7 @@
                 case PhaseMetadata.IN_FLOW:
                     {
                         phaseHolder =
-                                new PhaseHolder(((AxisConfigurationImpl) axisConfig).
+                                new PhaseHolder(axisConfig.
                                 getInPhasesUptoAndIncludingPostDispatch());
                         break;
                     }
@@ -469,7 +463,7 @@
                 case PhaseMetadata.FAULT_IN_FLOW:
                     {
                         phaseHolder =
-                                new PhaseHolder(((AxisConfigurationImpl) axisConfig).getInFaultFlow());
+                                new PhaseHolder(axisConfig.getInFaultFlow());
                         break;
                     }
                 case PhaseMetadata.FAULT_OUT_FLOW:
@@ -516,7 +510,6 @@
                          * so global module can do that. here the global module are the module which are
                          * reffred by axis2.xml
                          */
-                        continue;
                     }
                 }
             }
@@ -551,32 +544,31 @@
 
     public void engageModuleToOperation(OperationDescription operation,
                                         ModuleDescription module) throws PhaseException {
-        OperationDescription opDesc = operation;
         Flow flow = null;
         for (int type = 1; type < 5; type++) {
             switch (type) {
                 case PhaseMetadata.IN_FLOW:
                     {
                         phaseHolder =
-                                new PhaseHolder(opDesc.getRemainingPhasesInFlow());
+                                new PhaseHolder(operation.getRemainingPhasesInFlow());
                         break;
                     }
                 case PhaseMetadata.OUT_FLOW:
                     {
                         phaseHolder =
-                                new PhaseHolder(opDesc.getPhasesOutFlow());
+                                new PhaseHolder(operation.getPhasesOutFlow());
                         break;
                     }
                 case PhaseMetadata.FAULT_IN_FLOW:
                     {
                         phaseHolder =
-                                new PhaseHolder(opDesc.getPhasesInFaultFlow());
+                                new PhaseHolder(operation.getPhasesInFaultFlow());
                         break;
                     }
                 case PhaseMetadata.FAULT_OUT_FLOW:
                     {
                         phaseHolder =
-                                new PhaseHolder(opDesc.getPhasesOutFaultFlow());
+                                new PhaseHolder(operation.getPhasesOutFaultFlow());
                         break;
                     }
             }

Modified: webservices/axis/trunk/java/modules/core/src/org/apache/axis2/phaseresolver/util/PhaseValidator.java
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/java/modules/core/src/org/apache/axis2/phaseresolver/util/PhaseValidator.java?rev=231169&r1=231168&r2=231169&view=diff
==============================================================================
--- webservices/axis/trunk/java/modules/core/src/org/apache/axis2/phaseresolver/util/PhaseValidator.java (original)
+++ webservices/axis/trunk/java/modules/core/src/org/apache/axis2/phaseresolver/util/PhaseValidator.java Tue Aug  9 21:56:37 2005
@@ -31,12 +31,9 @@
     public static int SERVICE_MODULE = 1;
 
     public static boolean isSystemPhases(String phaseName) {
-        if (PhaseMetadata.PHASE_TRANSPORTIN.equals(phaseName) ||
-                PhaseMetadata.PHASE_DISPATCH.equals(phaseName) ||
-                PhaseMetadata.PHASE_POST_DISPATCH.equals(phaseName) ||
-                PhaseMetadata.PHASE_PRE_DISPATCH.equals(phaseName)) {
-            return true;
-        }
-        return false;
+        return ((PhaseMetadata.PHASE_TRANSPORTIN.equals(phaseName)) ||
+                (PhaseMetadata.PHASE_DISPATCH.equals(phaseName)) ||
+                (PhaseMetadata.PHASE_POST_DISPATCH.equals(phaseName)) ||
+                (PhaseMetadata.PHASE_PRE_DISPATCH.equals(phaseName)));
     }
 }

Modified: webservices/axis/trunk/java/modules/core/src/org/apache/axis2/transport/http/AxisServlet.java
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/java/modules/core/src/org/apache/axis2/transport/http/AxisServlet.java?rev=231169&r1=231168&r2=231169&view=diff
==============================================================================
--- webservices/axis/trunk/java/modules/core/src/org/apache/axis2/transport/http/AxisServlet.java (original)
+++ webservices/axis/trunk/java/modules/core/src/org/apache/axis2/transport/http/AxisServlet.java Tue Aug  9 21:56:37 2005
@@ -184,9 +184,9 @@
                     msgContext.getOperationContext().getProperty(Constants.RESPONSE_WRITTEN);
             
             //Getting the 
-            res.setContentType("text/xml; charset="+ 
-            		(String) msgContext
-						.getProperty(MessageContext.CHARACTER_SET_ENCODING));
+            res.setContentType("text/xml; charset="+
+                    msgContext
+                        .getProperty(MessageContext.CHARACTER_SET_ENCODING));
             
             if (contextWritten == null
                     || !Constants.VALUE_TRUE.equals(contextWritten)) {

Modified: webservices/axis/trunk/java/modules/core/src/org/apache/axis2/transport/http/ChunkedInputStream.java
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/java/modules/core/src/org/apache/axis2/transport/http/ChunkedInputStream.java?rev=231169&r1=231168&r2=231169&view=diff
==============================================================================
--- webservices/axis/trunk/java/modules/core/src/org/apache/axis2/transport/http/ChunkedInputStream.java (original)
+++ webservices/axis/trunk/java/modules/core/src/org/apache/axis2/transport/http/ChunkedInputStream.java Tue Aug  9 21:56:37 2005
@@ -27,8 +27,7 @@
 public class ChunkedInputStream extends java.io.FilterInputStream {
     protected long chunkSize = 0l;
     protected volatile boolean closed = false;
-    private static final int maxCharLong = (Long.toHexString(Long.MAX_VALUE))
-            .toString().length();
+    private static final int maxCharLong = (Long.toHexString(Long.MAX_VALUE)).length();
 
     private ChunkedInputStream() {
         super(null);

Modified: webservices/axis/trunk/java/modules/core/src/org/apache/axis2/transport/http/CommonsHTTPTransportSender.java
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/java/modules/core/src/org/apache/axis2/transport/http/CommonsHTTPTransportSender.java?rev=231169&r1=231168&r2=231169&view=diff
==============================================================================
--- webservices/axis/trunk/java/modules/core/src/org/apache/axis2/transport/http/CommonsHTTPTransportSender.java (original)
+++ webservices/axis/trunk/java/modules/core/src/org/apache/axis2/transport/http/CommonsHTTPTransportSender.java Tue Aug  9 21:56:37 2005
@@ -366,7 +366,7 @@
 
         if (!httpVersion.equals(HTTPConstants.HEADER_PROTOCOL_10)
             && chuncked) {
-            ((PostMethod) postMethod).setContentChunked(true);
+            postMethod.setContentChunked(true);
         }
         postMethod.setRequestHeader(
             HTTPConstants.HEADER_USER_AGENT,

Modified: webservices/axis/trunk/java/modules/core/src/org/apache/axis2/transport/http/HTTPTransportUtils.java
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/java/modules/core/src/org/apache/axis2/transport/http/HTTPTransportUtils.java?rev=231169&r1=231168&r2=231169&view=diff
==============================================================================
--- webservices/axis/trunk/java/modules/core/src/org/apache/axis2/transport/http/HTTPTransportUtils.java (original)
+++ webservices/axis/trunk/java/modules/core/src/org/apache/axis2/transport/http/HTTPTransportUtils.java Tue Aug  9 21:56:37 2005
@@ -17,20 +17,6 @@
  */
 package org.apache.axis2.transport.http;
 
-import java.io.BufferedReader;
-import java.io.InputStream;
-import java.io.InputStreamReader;
-import java.io.OutputStream;
-import java.io.Reader;
-import java.io.UnsupportedEncodingException;
-import java.util.Iterator;
-import java.util.Map;
-
-import javax.xml.parsers.FactoryConfigurationError;
-import javax.xml.stream.XMLInputFactory;
-import javax.xml.stream.XMLStreamException;
-import javax.xml.stream.XMLStreamReader;
-
 import org.apache.axis2.AxisFault;
 import org.apache.axis2.Constants;
 import org.apache.axis2.addressing.EndpointReference;
@@ -38,25 +24,29 @@
 import org.apache.axis2.context.ConfigurationContext;
 import org.apache.axis2.context.MessageContext;
 import org.apache.axis2.engine.AxisEngine;
-import org.apache.axis2.om.OMElement;
-import org.apache.axis2.om.OMException;
-import org.apache.axis2.om.OMNamespace;
-import org.apache.axis2.om.OMNode;
-import org.apache.axis2.om.OMText;
+import org.apache.axis2.om.*;
+import org.apache.axis2.om.impl.MTOMConstants;
 import org.apache.axis2.om.impl.llom.OMNamespaceImpl;
 import org.apache.axis2.om.impl.llom.builder.StAXBuilder;
 import org.apache.axis2.om.impl.llom.builder.StAXOMBuilder;
 import org.apache.axis2.om.impl.llom.mtom.MTOMStAXSOAPModelBuilder;
-import org.apache.axis2.om.impl.MTOMConstants;
+import org.apache.axis2.soap.SOAP11Constants;
+import org.apache.axis2.soap.SOAP12Constants;
 import org.apache.axis2.soap.SOAPEnvelope;
 import org.apache.axis2.soap.SOAPFactory;
-import org.apache.axis2.soap.SOAP12Constants;
-import org.apache.axis2.soap.SOAP11Constants;
 import org.apache.axis2.soap.impl.llom.SOAPProcessingException;
 import org.apache.axis2.soap.impl.llom.builder.StAXSOAPModelBuilder;
 import org.apache.axis2.soap.impl.llom.soap11.SOAP11Factory;
 import org.apache.axis2.soap.impl.llom.soap12.SOAP12Factory;
 import org.apache.axis2.util.Utils;
+
+import javax.xml.parsers.FactoryConfigurationError;
+import javax.xml.stream.XMLInputFactory;
+import javax.xml.stream.XMLStreamException;
+import javax.xml.stream.XMLStreamReader;
+import java.io.*;
+import java.util.Iterator;
+import java.util.Map;
 
 public class HTTPTransportUtils {
 

Modified: webservices/axis/trunk/java/modules/core/src/org/apache/axis2/transport/http/ListingAgent.java
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/java/modules/core/src/org/apache/axis2/transport/http/ListingAgent.java?rev=231169&r1=231168&r2=231169&view=diff
==============================================================================
--- webservices/axis/trunk/java/modules/core/src/org/apache/axis2/transport/http/ListingAgent.java (original)
+++ webservices/axis/trunk/java/modules/core/src/org/apache/axis2/transport/http/ListingAgent.java Tue Aug  9 21:56:37 2005
@@ -161,7 +161,7 @@
             return;
         }
 
-        if (allowListServices && (filePart != null) &&
+        if ((filePart != null) &&
                 filePart.endsWith(Constants.LISTSERVICES)) {
             listServices(httpServletRequest, httpServletResponse);
             return;
@@ -222,11 +222,11 @@
             throw new AxisFault(Messages.getMessage("invaliduser"));
         }
         String adminUserName =
-                (String) ((AxisConfigurationImpl) configContext.getAxisConfiguration())
+                (String) configContext.getAxisConfiguration()
                 .getParameter(Constants.USER_NAME)
                 .getValue();
         String adminPassword =
-                (String) ((AxisConfigurationImpl) configContext.getAxisConfiguration())
+                (String) configContext.getAxisConfiguration()
                 .getParameter(Constants.PASSWORD)
                 .getValue();
         if (username != null
@@ -255,7 +255,7 @@
         HashMap modules =
                 ((AxisConfigurationImpl) configContext.getAxisConfiguration()).getModules();
         req.getSession().setAttribute(Constants.MODULE_MAP, modules);
-        String moduleName = (String) req.getParameter("modules");
+        String moduleName = req.getParameter("modules");
         req.getSession().setAttribute(Constants.ENGAGE_STATUS, null);
         if (moduleName != null) {
             try {
@@ -278,12 +278,12 @@
         HashMap modules =
                 ((AxisConfigurationImpl) configContext.getAxisConfiguration()).getModules();
         req.getSession().setAttribute(Constants.MODULE_MAP, modules);
-        String moduleName = (String) req.getParameter("modules");
+        String moduleName = req.getParameter("modules");
 
         req.getSession().setAttribute(Constants.ENGAGE_STATUS, null);
         req.getSession().setAttribute("modules", null);
 
-        String serviceName = (String) req.getParameter("service");
+        String serviceName = req.getParameter("service");
         if (serviceName != null) {
             req.getSession().setAttribute("service", serviceName);
         } else {
@@ -295,7 +295,7 @@
                 .getService(new QName(serviceName))
                 .getOperations());
         req.getSession().setAttribute(Constants.ENGAGE_STATUS, null);
-        String operationName = (String) req.getParameter("operation");
+        String operationName = req.getParameter("operation");
         if (serviceName != null && moduleName != null && operationName != null) {
             try {
                 OperationDescription od =
@@ -325,10 +325,10 @@
         req.getSession().setAttribute(Constants.MODULE_MAP, modules);
         HashMap services = configContext.getAxisConfiguration().getServices();
         req.getSession().setAttribute(Constants.SERVICE_MAP, services);
-        String moduleName = (String) req.getParameter("modules");
+        String moduleName = req.getParameter("modules");
         req.getSession().setAttribute(Constants.ENGAGE_STATUS, null);
         req.getSession().setAttribute("modules", null);
-        String serviceName = (String) req.getParameter("service");
+        String serviceName = req.getParameter("service");
         req.getSession().setAttribute(Constants.ENGAGE_STATUS, null);
         if (serviceName != null && moduleName != null) {
             try {
@@ -417,7 +417,7 @@
             return;
 
         }   else {
-            String service = (String) req.getParameter("service");
+            String service = req.getParameter("service");
             if (service != null) {
                 req.getSession().setAttribute(Constants.SERVICE,
                         configContext.getAxisConfiguration().getService(
@@ -477,7 +477,7 @@
     private void viewServiceHandlers(HttpServletRequest req,
                                      HttpServletResponse res)
             throws IOException {
-        String service = (String) req.getParameter("service");
+        String service = req.getParameter("service");
         if (service != null) {
             req.getSession().setAttribute(Constants.SERVICE_HANDLERS,
                     configContext.getAxisConfiguration().getService(

Modified: webservices/axis/trunk/java/modules/core/src/org/apache/axis2/transport/mail/server/POP3Worker.java
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/java/modules/core/src/org/apache/axis2/transport/mail/server/POP3Worker.java?rev=231169&r1=231168&r2=231169&view=diff
==============================================================================
--- webservices/axis/trunk/java/modules/core/src/org/apache/axis2/transport/mail/server/POP3Worker.java (original)
+++ webservices/axis/trunk/java/modules/core/src/org/apache/axis2/transport/mail/server/POP3Worker.java Tue Aug  9 21:56:37 2005
@@ -63,11 +63,11 @@
             while (stk.hasMoreTokens()) {
                 tokens.add(stk.nextToken());
             }
-            if (((String) tokens.get(0)).equals(MailConstants.USER)) {
+            if (tokens.get(0).equals(MailConstants.USER)) {
                 user = (String) tokens.get(1);
                 messages = st.popUserMails(user);
                 printWriter.println(MailConstants.OK);
-            } else if (((String) tokens.get(0)).equals(MailConstants.PASS)) {
+            } else if (tokens.get(0).equals(MailConstants.PASS)) {
                 printWriter.println(MailConstants.OK); // Passwords are not checked.
             } else if (input.equals(MailConstants.QUIT)) {
                 printWriter.println(
@@ -75,7 +75,7 @@
                 doneProcess = true;
             } else if (input.equals(MailConstants.STAT)) {
                 printWriter.println(MailConstants.OK + messages.size() + " 1"); // We take the maildrop size as one.
-            } else if (((String) tokens.get(0)).equals(MailConstants.LIST)) { // scan listing
+            } else if (tokens.get(0).equals(MailConstants.LIST)) { // scan listing
                 if (tokens.size() > 1) {
                     try {
                         int optArg = Integer.parseInt((String) tokens.get(1));
@@ -97,7 +97,7 @@
                         printWriter.println(
                                 MailConstants.ERR +
                                 "problem passing the index. Index submited was " +
-                                (String) tokens.get(1));
+                                tokens.get(1));
                     }
                 } else {
                     printWriter.println(MailConstants.OK + messages.size());
@@ -107,7 +107,7 @@
                     }
                     printWriter.println(".");
                 }
-            } else if (((String) tokens.get(0)).equals(MailConstants.RETR)) {
+            } else if (tokens.get(0).equals(MailConstants.RETR)) {
                 String i = (String) tokens.get(1);
                 try {
                     int index = Integer.parseInt(i);
@@ -128,7 +128,7 @@
                 } catch (MessagingException e2) {
                     printWriter.println(MailConstants.ERR);
                 }
-            } else if (((String) tokens.get(0)).equals(MailConstants.DELE)) {
+            } else if (tokens.get(0).equals(MailConstants.DELE)) {
                 String smIndex = (String) tokens.get(1);
                 try {
                     int mIndex = Integer.parseInt(smIndex) - 1 - numDeleted; // When one mail is deleted the index of the other mails will reduce. Asumed that the delete will occure from bottom up.
@@ -142,8 +142,8 @@
                 } catch (NumberFormatException e) {
                     printWriter.println(MailConstants.ERR);
                 }
-            } else if (((String) tokens.get(0)).equals(MailConstants.NOOP) ||
-                    ((String) tokens.get(0)).equals(MailConstants.RSET)) {
+            } else if (tokens.get(0).equals(MailConstants.NOOP) ||
+                    tokens.get(0).equals(MailConstants.RSET)) {
                 printWriter.println(MailConstants.OK);
             } else {
                 printWriter.println(MailConstants.ERR);

Modified: webservices/axis/trunk/java/modules/core/src/org/apache/axis2/transport/tcp/TCPServer.java
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/java/modules/core/src/org/apache/axis2/transport/tcp/TCPServer.java?rev=231169&r1=231168&r2=231169&view=diff
==============================================================================
--- webservices/axis/trunk/java/modules/core/src/org/apache/axis2/transport/tcp/TCPServer.java (original)
+++ webservices/axis/trunk/java/modules/core/src/org/apache/axis2/transport/tcp/TCPServer.java Tue Aug  9 21:56:37 2005
@@ -50,9 +50,8 @@
     public TCPServer(int port, String dir) throws AxisFault {
         try {
             ConfigurationContextFactory erfac = new ConfigurationContextFactory();
-            ConfigurationContext configContext = erfac.buildConfigurationContext(
+            this.configContext = erfac.buildConfigurationContext(
                     dir);
-            this.configContext = configContext;
             Thread.sleep(3000);
             serversocket = new ServerSocket(port);
         } catch (DeploymentException e1) {

Modified: webservices/axis/trunk/java/modules/core/test/org/apache/axis2/engine/MessageContextInjectionTest.java
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/java/modules/core/test/org/apache/axis2/engine/MessageContextInjectionTest.java?rev=231169&r1=231168&r2=231169&view=diff
==============================================================================
--- webservices/axis/trunk/java/modules/core/test/org/apache/axis2/engine/MessageContextInjectionTest.java (original)
+++ webservices/axis/trunk/java/modules/core/test/org/apache/axis2/engine/MessageContextInjectionTest.java Tue Aug  9 21:56:37 2005
@@ -67,9 +67,8 @@
     }
 
     protected void setUp() throws Exception {
-        ConfigurationContext configContext = new ConfigurationContext(
+        LocalTransportReceiver.CONFIG_CONTEXT = new ConfigurationContext(
                 new AxisConfigurationImpl());
-        LocalTransportReceiver.CONFIG_CONTEXT = configContext;
 
         ServiceDescription service = new ServiceDescription(serviceName);
         service.addParameter(

Modified: webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/engine/CharctersetEncodingTest.java
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/engine/CharctersetEncodingTest.java?rev=231169&r1=231168&r2=231169&view=diff
==============================================================================
--- webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/engine/CharctersetEncodingTest.java (original)
+++ webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/engine/CharctersetEncodingTest.java Tue Aug  9 21:56:37 2005
@@ -109,8 +109,8 @@
 					Constants.TRANSPORT_HTTP, false);
 
 
-			OMElement resultElem = (OMElement) call.invokeBlocking(operationName
-					.getLocalPart(), payload);
+			OMElement resultElem = call.invokeBlocking(operationName
+                    .getLocalPart(), payload);
 
 
 

Modified: webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/engine/CommonsHTTPEchoRawXMLTest.java
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/engine/CommonsHTTPEchoRawXMLTest.java?rev=231169&r1=231168&r2=231169&view=diff
==============================================================================
--- webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/engine/CommonsHTTPEchoRawXMLTest.java (original)
+++ webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/engine/CommonsHTTPEchoRawXMLTest.java Tue Aug  9 21:56:37 2005
@@ -139,7 +139,7 @@
                 false);
 
         OMElement result =
-                (OMElement) call.invokeBlocking(operationName.getLocalPart(),
+                call.invokeBlocking(operationName.getLocalPart(),
                         payload);
         TestingUtils.campareWithCreatedOMElement(result);
         call.close();

Modified: webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/engine/EchoRawXMLChunckedTest.java
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/engine/EchoRawXMLChunckedTest.java?rev=231169&r1=231168&r2=231169&view=diff
==============================================================================
--- webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/engine/EchoRawXMLChunckedTest.java (original)
+++ webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/engine/EchoRawXMLChunckedTest.java Tue Aug  9 21:56:37 2005
@@ -137,7 +137,7 @@
                 false);
 
         OMElement result =
-                (OMElement) call.invokeBlocking(operationName.getLocalPart(),
+                call.invokeBlocking(operationName.getLocalPart(),
                         payload);
         TestingUtils.campareWithCreatedOMElement(result);
         call.close();

Modified: webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/engine/EchoRawXMLLoadTest.java
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/engine/EchoRawXMLLoadTest.java?rev=231169&r1=231168&r2=231169&view=diff
==============================================================================
--- webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/engine/EchoRawXMLLoadTest.java (original)
+++ webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/engine/EchoRawXMLLoadTest.java Tue Aug  9 21:56:37 2005
@@ -135,11 +135,11 @@
                 false);
 
         OMElement result =
-                (OMElement) call.invokeBlocking(operationName.getLocalPart(),
+                call.invokeBlocking(operationName.getLocalPart(),
                         payload);
 
         OMElement result1 =
-                (OMElement) call.invokeBlocking(operationName.getLocalPart(),
+                call.invokeBlocking(operationName.getLocalPart(),
                         payload);
 
         TestingUtils.campareWithCreatedOMElement(result);

Modified: webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/engine/EchoRawXMLOnTwoChannelsSyncTest.java
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/engine/EchoRawXMLOnTwoChannelsSyncTest.java?rev=231169&r1=231168&r2=231169&view=diff
==============================================================================
--- webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/engine/EchoRawXMLOnTwoChannelsSyncTest.java (original)
+++ webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/engine/EchoRawXMLOnTwoChannelsSyncTest.java Tue Aug  9 21:56:37 2005
@@ -109,7 +109,7 @@
                 Constants.TRANSPORT_HTTP,
                 true);
 
-        OMElement result = (OMElement) call.invokeBlocking(
+        OMElement result = call.invokeBlocking(
                 operationName.getLocalPart(), method);
         TestingUtils.campareWithCreatedOMElement(result);
         call.close();

Modified: webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/engine/EchoRawXMLTest.java
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/engine/EchoRawXMLTest.java?rev=231169&r1=231168&r2=231169&view=diff
==============================================================================
--- webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/engine/EchoRawXMLTest.java (original)
+++ webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/engine/EchoRawXMLTest.java Tue Aug  9 21:56:37 2005
@@ -139,7 +139,7 @@
                 false);
 
         OMElement result =
-                (OMElement) call.invokeBlocking(operationName.getLocalPart(),
+                call.invokeBlocking(operationName.getLocalPart(),
                         payload);
         TestingUtils.campareWithCreatedOMElement(result);
         call.close();
@@ -156,7 +156,7 @@
                 Constants.TRANSPORT_HTTP,
                 false);
 
-        OMElement result = (OMElement) call.invokeBlocking(
+        OMElement result = call.invokeBlocking(
                 operationName.getLocalPart(), payload);
         TestingUtils.campareWithCreatedOMElement(result);
         call.close();

Modified: webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/engine/FaultHandlingTest.java
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/engine/FaultHandlingTest.java?rev=231169&r1=231168&r2=231169&view=diff
==============================================================================
--- webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/engine/FaultHandlingTest.java (original)
+++ webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/engine/FaultHandlingTest.java Tue Aug  9 21:56:37 2005
@@ -108,9 +108,7 @@
 
     private SOAPEnvelope getResponse(SOAPEnvelope inEnvelope) throws AxisFault {
             inOutMEPClient.setExceptionToBeThrownOnSOAPFault(false);
-            SOAPEnvelope result =
-                    inOutMEPClient.invokeBlockingWithEnvelopeOut(operationName.getLocalPart(), inEnvelope);
-            return result;
+            return inOutMEPClient.invokeBlockingWithEnvelopeOut(operationName.getLocalPart(), inEnvelope);
     }
 
     private SOAPEnvelope getTwoHeadersSOAPEnvelope(SOAPFactory fac) {

Modified: webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/engine/ServiceDispatchingTest.java
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/engine/ServiceDispatchingTest.java?rev=231169&r1=231168&r2=231169&view=diff
==============================================================================
--- webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/engine/ServiceDispatchingTest.java (original)
+++ webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/engine/ServiceDispatchingTest.java Tue Aug  9 21:56:37 2005
@@ -91,7 +91,7 @@
         call.setTransportInfo(Constants.TRANSPORT_HTTP,
                 Constants.TRANSPORT_HTTP,
                 false);
-        OMElement result = (OMElement) call.invokeBlocking(
+        OMElement result = call.invokeBlocking(
                 operationName.getLocalPart(), payload);
         TestingUtils.campareWithCreatedOMElement(result);
         call.close();
@@ -112,7 +112,7 @@
                 Constants.TRANSPORT_HTTP,
                 false);
         call.setSoapAction("echoOMElement");
-        OMElement result = (OMElement) call.invokeBlocking(
+        OMElement result = call.invokeBlocking(
                 operationName.getLocalPart(), payload);
         TestingUtils.campareWithCreatedOMElement(result);
         call.close();
@@ -136,7 +136,7 @@
         call.setTransportInfo(Constants.TRANSPORT_HTTP,
                 Constants.TRANSPORT_HTTP,
                 false);
-        OMElement result = (OMElement) call.invokeBlocking(
+        OMElement result = call.invokeBlocking(
                 operationName.getLocalPart(), payload);
         TestingUtils.campareWithCreatedOMElement(result);
         call.close();

Modified: webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/engine/util/MyInOutMEPClient.java
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/engine/util/MyInOutMEPClient.java?rev=231169&r1=231168&r2=231169&view=diff
==============================================================================
--- webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/engine/util/MyInOutMEPClient.java (original)
+++ webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/engine/util/MyInOutMEPClient.java Tue Aug  9 21:56:37 2005
@@ -54,8 +54,7 @@
 
         MessageContext responseContext = super.invokeBlocking(axisConfig,
                 msgctx);
-        SOAPEnvelope envelope = responseContext.getEnvelope();
-        return envelope;
+        return responseContext.getEnvelope();
     }
 
 
@@ -80,8 +79,7 @@
 
         MessageContext responseContext = super.invokeBlocking(axisConfig,
                 msgctx);
-        SOAPEnvelope envelope = responseContext.getEnvelope();
-        return envelope;
+        return responseContext.getEnvelope();
     }
 
     protected MessageContext getMessageContext(SOAPEnvelope envelope) throws AxisFault {

Modified: webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/groovy/GroovyServiceTest.java
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/groovy/GroovyServiceTest.java?rev=231169&r1=231168&r2=231169&view=diff
==============================================================================
--- webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/groovy/GroovyServiceTest.java (original)
+++ webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/groovy/GroovyServiceTest.java Tue Aug  9 21:56:37 2005
@@ -93,7 +93,7 @@
                 Constants.TRANSPORT_HTTP,
                 false);
 
-        OMElement result = (OMElement) call.invokeBlocking(operationName.getLocalPart(),
+        OMElement result = call.invokeBlocking(operationName.getLocalPart(),
                 payload);
         assertNotNull(result);
         OMElement person = (OMElement)result.getFirstChild();
@@ -120,7 +120,7 @@
         OMFactory fac = OMAbstractFactory.getOMFactory();
 
         StAXOMBuilder staxOMBuilder = new
-                StAXOMBuilder(fac,(XMLStreamReader) xmlReader);
+                StAXOMBuilder(fac,xmlReader);
         return   staxOMBuilder.getDocumentElement();
     }
 

Modified: webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/integration/UtilServer.java
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/integration/UtilServer.java?rev=231169&r1=231168&r2=231169&view=diff
==============================================================================
--- webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/integration/UtilServer.java (original)
+++ webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/integration/UtilServer.java Tue Aug  9 21:56:37 2005
@@ -120,9 +120,8 @@
 
         sysContext.getAxisConfiguration().addService(service);
         //Utils.resolvePhases(sysContext.getEngineConfig(), service);
-        ServiceContext serviceContext = sysContext.createServiceContext(
+        return sysContext.createServiceContext(
                 service.getName());
-        return serviceContext;
 
     }
 

Modified: webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/mtom/EchoRawMTOMTest.java
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/mtom/EchoRawMTOMTest.java?rev=231169&r1=231168&r2=231169&view=diff
==============================================================================
--- webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/mtom/EchoRawMTOMTest.java (original)
+++ webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/mtom/EchoRawMTOMTest.java Tue Aug  9 21:56:37 2005
@@ -114,7 +114,7 @@
                 Constants.TRANSPORT_HTTP, false);
         call.setSoapVersionURI(SOAP12Constants.SOAP_ENVELOPE_NAMESPACE_URI);
 
-        OMElement result = (OMElement) call.invokeBlocking(operationName
+        OMElement result = call.invokeBlocking(operationName
                 .getLocalPart(),
                 payload);
         // result.serializeWithCache(new

Modified: webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/rest/RESTBasedEchoRawXMLTest.java
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/rest/RESTBasedEchoRawXMLTest.java?rev=231169&r1=231168&r2=231169&view=diff
==============================================================================
--- webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/rest/RESTBasedEchoRawXMLTest.java (original)
+++ webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/rest/RESTBasedEchoRawXMLTest.java Tue Aug  9 21:56:37 2005
@@ -26,7 +26,6 @@
 import org.apache.axis2.description.ParameterImpl;
 import org.apache.axis2.description.ServiceDescription;
 import org.apache.axis2.engine.AxisConfiguration;
-import org.apache.axis2.engine.AxisConfigurationImpl;
 import org.apache.axis2.engine.Echo;
 import org.apache.axis2.integration.UtilServer;
 import org.apache.axis2.om.OMAbstractFactory;
@@ -79,8 +78,8 @@
         UtilServer.start();
         Parameter parameter = new ParameterImpl(
                 Constants.Configuration.ENABLE_REST, "true");
-        ((AxisConfigurationImpl) UtilServer.getConfigurationContext()
-                .getAxisConfiguration()).addParameter(parameter);
+        UtilServer.getConfigurationContext()
+                .getAxisConfiguration().addParameter(parameter);
         service =
                 Utils.createSimpleService(serviceName,
                         Echo.class.getName(),
@@ -165,7 +164,7 @@
                 false);
         call.setDoREST(true);
         OMElement result =
-                (OMElement) call.invokeBlocking(operationName.getLocalPart(),
+                call.invokeBlocking(operationName.getLocalPart(),
                         payload);
         result.serializeWithCache(XMLOutputFactory.newInstance().createXMLStreamWriter(
                                 System.out));

Modified: webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/swa/EchoSwA.java
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/swa/EchoSwA.java?rev=231169&r1=231168&r2=231169&view=diff
==============================================================================
--- webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/swa/EchoSwA.java (original)
+++ webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/swa/EchoSwA.java Tue Aug  9 21:56:37 2005
@@ -43,7 +43,7 @@
 
     public OMElement echoAttachment(OMElement omEle) {
         OMElement child  = (OMElement)omEle.getFirstChild();
-        OMAttribute attr = (OMAttribute)child.getFirstAttribute(new QName("href"));
+        OMAttribute attr = child.getFirstAttribute(new QName("href"));
         String contentID = attr.getValue();
         MIMEHelper attachment = (MIMEHelper)msgcts.getProperty(MTOMConstants.ATTACHMENTS);
         contentID = contentID.trim();

Modified: webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/tcp/TCPEchoRawXMLTest.java
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/tcp/TCPEchoRawXMLTest.java?rev=231169&r1=231168&r2=231169&view=diff
==============================================================================
--- webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/tcp/TCPEchoRawXMLTest.java (original)
+++ webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/tcp/TCPEchoRawXMLTest.java Tue Aug  9 21:56:37 2005
@@ -163,7 +163,7 @@
                 false);
 
         OMElement result =
-                (OMElement) call.invokeBlocking(operationName.getLocalPart(),
+                call.invokeBlocking(operationName.getLocalPart(),
                         payload);
         result.serializeWithCache(XMLOutputFactory.newInstance().createXMLStreamWriter(
                                 System.out));
@@ -192,7 +192,7 @@
                 Constants.TRANSPORT_TCP,
                 true);
 
-        OMElement result = (OMElement) call.invokeBlocking(
+        OMElement result = call.invokeBlocking(
                 operationName.getLocalPart(), method);
         result.serializeWithCache(XMLOutputFactory.newInstance().createXMLStreamWriter(
                                 System.out));

Modified: webservices/axis/trunk/java/modules/saaj/src/javax/xml/namespace/QName.java
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/java/modules/saaj/src/javax/xml/namespace/QName.java?rev=231169&r1=231168&r2=231169&view=diff
==============================================================================
--- webservices/axis/trunk/java/modules/saaj/src/javax/xml/namespace/QName.java (original)
+++ webservices/axis/trunk/java/modules/saaj/src/javax/xml/namespace/QName.java Tue Aug  9 21:56:37 2005
@@ -153,12 +153,9 @@
             return false;
         }
 
-        if ((namespaceURI == ((QName) obj).namespaceURI)
-                && (localPart == ((QName) obj).localPart)) {
-            return true;
-        }
+        return (namespaceURI.equals(((QName) obj).namespaceURI))
+                && (localPart.equals(((QName) obj).localPart));
 
-        return false;
     }
 
     /**

Modified: webservices/axis/trunk/java/modules/saaj/src/org/apache/axis2/saaj/MessageFactoryImpl.java
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/java/modules/saaj/src/org/apache/axis2/saaj/MessageFactoryImpl.java?rev=231169&r1=231168&r2=231169&view=diff
==============================================================================
--- webservices/axis/trunk/java/modules/saaj/src/org/apache/axis2/saaj/MessageFactoryImpl.java (original)
+++ webservices/axis/trunk/java/modules/saaj/src/org/apache/axis2/saaj/MessageFactoryImpl.java Tue Aug  9 21:56:37 2005
@@ -35,8 +35,7 @@
      */
     public SOAPMessage createMessage() throws SOAPException {
         SOAPEnvelopeImpl env = new SOAPEnvelopeImpl();
-        SOAPMessageImpl message = new SOAPMessageImpl(env);
-        return message;
+        return new SOAPMessageImpl(env);
     }
 
     /* (non-Javadoc)
@@ -45,11 +44,9 @@
     public SOAPMessage createMessage(MimeHeaders mimeheaders,
                                      InputStream inputstream) throws IOException,
             SOAPException {
-        // TODO Auto-generated method stub
-        SOAPMessageImpl message = new SOAPMessageImpl(inputstream,
+        return new SOAPMessageImpl(inputstream,
                 false,
                 mimeheaders);
-        return message;
     }
 
 }

Modified: webservices/axis/trunk/java/modules/saaj/src/org/apache/axis2/saaj/NodeImpl.java
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/java/modules/saaj/src/org/apache/axis2/saaj/NodeImpl.java?rev=231169&r1=231168&r2=231169&view=diff
==============================================================================
--- webservices/axis/trunk/java/modules/saaj/src/org/apache/axis2/saaj/NodeImpl.java (original)
+++ webservices/axis/trunk/java/modules/saaj/src/org/apache/axis2/saaj/NodeImpl.java Tue Aug  9 21:56:37 2005
@@ -168,7 +168,7 @@
 
         if (omNode.getType() == OMNode.TEXT_NODE) {
             OMElement parent = (OMElement) omNode.getParent();
-            ((OMText) omNode).discard();
+            omNode.discard();
             omNode =
                     org.apache.axis2.om.OMAbstractFactory.getOMFactory()
                     .createText(parent, value);
@@ -179,7 +179,7 @@
                         org.apache.axis2.om.OMAbstractFactory.getOMFactory()
                         .createText((OMElement) omNode, value);
             } else if (firstChild.getType() == OMNode.TEXT_NODE) {
-                ((OMText) firstChild).discard();
+                firstChild.discard();
                 firstChild =
                         org.apache.axis2.om.OMAbstractFactory.getOMFactory()
                         .createText((OMElement) omNode, value);
@@ -218,7 +218,7 @@
     public boolean hasAttributes() {
         if (omNode instanceof OMElement) {
             Iterator iter = ((OMElement) omNode).getAttributes();
-            return (iter.hasNext() ? true : false);
+            return (iter.hasNext());
         }
         return false;
     }
@@ -231,7 +231,7 @@
     public boolean hasChildNodes() {
         if (omNode instanceof OMElement) {
             Iterator iter = ((OMElement) omNode).getChildren();
-            return (iter.hasNext() ? true : false);
+            return (iter.hasNext());
         }
         return false;
     }
@@ -314,7 +314,7 @@
 
         if (omNode.getType() == OMNode.TEXT_NODE) {
             OMElement parent = (OMElement) omNode.getParent();
-            ((OMText) omNode).discard();
+            omNode.discard();
             omNode =
                     org.apache.axis2.om.OMAbstractFactory.getOMFactory()
                     .createText(parent, value);

Modified: webservices/axis/trunk/java/modules/saaj/src/org/apache/axis2/saaj/PrefixedQName.java
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/java/modules/saaj/src/org/apache/axis2/saaj/PrefixedQName.java?rev=231169&r1=231168&r2=231169&view=diff
==============================================================================
--- webservices/axis/trunk/java/modules/saaj/src/org/apache/axis2/saaj/PrefixedQName.java (original)
+++ webservices/axis/trunk/java/modules/saaj/src/org/apache/axis2/saaj/PrefixedQName.java Tue Aug  9 21:56:37 2005
@@ -79,7 +79,7 @@
      */
     public String getQualifiedName() {
         StringBuffer buf = new StringBuffer(prefix);
-        if (prefix != emptyString)
+        if (!prefix.equals(emptyString))
             buf.append(':');
         buf.append(qName.getLocalPart());
         return buf.toString();
@@ -119,10 +119,7 @@
         if (!qName.equals(((PrefixedQName) obj).qName)) {
             return false;
         }
-        if (prefix == ((PrefixedQName) obj).prefix) {
-            return true;
-        }
-        return false;
+        return prefix.equals(((PrefixedQName) obj).prefix);
     }
 
     /**

Modified: webservices/axis/trunk/java/modules/saaj/src/org/apache/axis2/saaj/SOAPDocumentImpl.java
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/java/modules/saaj/src/org/apache/axis2/saaj/SOAPDocumentImpl.java?rev=231169&r1=231168&r2=231169&view=diff
==============================================================================
--- webservices/axis/trunk/java/modules/saaj/src/org/apache/axis2/saaj/SOAPDocumentImpl.java (original)
+++ webservices/axis/trunk/java/modules/saaj/src/org/apache/axis2/saaj/SOAPDocumentImpl.java Tue Aug  9 21:56:37 2005
@@ -356,10 +356,7 @@
     private String version = "version 2.0";
 
     public boolean isSupported(String feature, String version) {
-        if (!version.equalsIgnoreCase(version))
-            return false;
-        else
-            return true;
+        return version.equalsIgnoreCase(version);
     }
 
     public Node appendChild(Node newChild) throws DOMException {

Modified: webservices/axis/trunk/java/modules/saaj/src/org/apache/axis2/saaj/SOAPElementImpl.java
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/java/modules/saaj/src/org/apache/axis2/saaj/SOAPElementImpl.java?rev=231169&r1=231168&r2=231169&view=diff
==============================================================================
--- webservices/axis/trunk/java/modules/saaj/src/org/apache/axis2/saaj/SOAPElementImpl.java (original)
+++ webservices/axis/trunk/java/modules/saaj/src/org/apache/axis2/saaj/SOAPElementImpl.java Tue Aug  9 21:56:37 2005
@@ -317,9 +317,9 @@
      */
     public Name getElementName() {
         QName qName = omElement.getQName();
-        return (Name) (new PrefixedQName(qName.getNamespaceURI(),
+        return new PrefixedQName(qName.getNamespaceURI(),
                 qName.getLocalPart(),
-                qName.getPrefix()));
+                qName.getPrefix());
     }
 
     /**
@@ -715,7 +715,7 @@
                 returnList.addNodeList(list);
             }
         }
-        return (NodeList) returnList;
+        return returnList;
     }
 
     private NodeList getElementsByTagNamePreOrder(SOAPElement child,
@@ -724,7 +724,7 @@
         //We are doing preorder, so see if root itself is a match and place it first in the order
         if (child.getLocalName().equals(localName)) {
             //so this must be first in the returnList
-            returnList.addNode((org.w3c.dom.Node) child);
+            returnList.addNode(child);
         }
         returnList.addNodeList(child.getElementsByTagName(localName));
         return returnList;
@@ -824,7 +824,7 @@
                 returnList.addNodeList(list);
             }
         }
-        return (NodeList) returnList;
+        return returnList;
     }
 
     private NodeList getElementsByTagNameNSPreOrder(SOAPElement child,
@@ -835,7 +835,7 @@
         if (child.getNamespaceURI().equals(namespaceURI) &&
                 child.getLocalName().equals(localName)) {
             //so this must be first in the returnList
-            returnList.addNode((org.w3c.dom.Node) child);
+            returnList.addNode(child);
         }
         returnList.addNodeList(
                 child.getElementsByTagNameNS(namespaceURI, localName));

Modified: webservices/axis/trunk/java/modules/saaj/src/org/apache/axis2/saaj/SOAPEnvelopeImpl.java
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/java/modules/saaj/src/org/apache/axis2/saaj/SOAPEnvelopeImpl.java?rev=231169&r1=231168&r2=231169&view=diff
==============================================================================
--- webservices/axis/trunk/java/modules/saaj/src/org/apache/axis2/saaj/SOAPEnvelopeImpl.java (original)
+++ webservices/axis/trunk/java/modules/saaj/src/org/apache/axis2/saaj/SOAPEnvelopeImpl.java Tue Aug  9 21:56:37 2005
@@ -106,7 +106,7 @@
         org.apache.axis2.soap.SOAPHeader omSOAPHeader;
         try {
             omSOAPHeader =
-                    (org.apache.axis2.soap.SOAPHeader) omSOAPEnvelope.getHeader();
+                    omSOAPEnvelope.getHeader();
         } catch (Exception e) {
             throw new SOAPException(e);
         }

Modified: webservices/axis/trunk/java/modules/saaj/src/org/apache/axis2/saaj/TextImpl.java
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/java/modules/saaj/src/org/apache/axis2/saaj/TextImpl.java?rev=231169&r1=231168&r2=231169&view=diff
==============================================================================
--- webservices/axis/trunk/java/modules/saaj/src/org/apache/axis2/saaj/TextImpl.java (original)
+++ webservices/axis/trunk/java/modules/saaj/src/org/apache/axis2/saaj/TextImpl.java Tue Aug  9 21:56:37 2005
@@ -80,9 +80,7 @@
     public boolean isComment() {
 
         String temp = omText.getText();
-        if (temp.startsWith("<!--") && temp.endsWith("-->"))
-            return true;
-        return false;
+        return temp.startsWith("<!--") && temp.endsWith("-->");
     }
 
     /**



Mime
View raw message