axis-java-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dee...@apache.org
Subject svn commit: r383520 - in /webservices/axis2/trunk/java/modules: common/src/org/apache/axis2/i18n/ core/src/org/apache/axis2/description/ core/test/org/apache/axis2/deployment/
Date Mon, 06 Mar 2006 11:48:02 GMT
Author: deepal
Date: Mon Mar  6 03:47:57 2006
New Revision: 383520

URL: http://svn.apache.org/viewcvs?rev=383520&view=rev
Log:
-some more i18n

Modified:
    webservices/axis2/trunk/java/modules/common/src/org/apache/axis2/i18n/resource.properties
    webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/AxisDescription.java
    webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/AxisMessage.java
    webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/AxisModule.java
    webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/AxisOperation.java
    webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/AxisService.java
    webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/AxisService2WOM.java
    webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/AxisServiceGroup.java
    webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/ClientUtils.java
    webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/HandlerDescription.java
    webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/InOnlyAxisOperation.java
    webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/InOutAxisOperation.java
    webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/ModuleConfiguration.java
    webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/OutInAxisOperation.java
    webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/OutOnlyAxisOperation.java
    webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/PolicyInclude.java
    webservices/axis2/trunk/java/modules/core/test/org/apache/axis2/deployment/AxisObserverImpl.java

Modified: webservices/axis2/trunk/java/modules/common/src/org/apache/axis2/i18n/resource.properties
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/common/src/org/apache/axis2/i18n/resource.properties?rev=383520&r1=383519&r2=383520&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/common/src/org/apache/axis2/i18n/resource.properties
(original)
+++ webservices/axis2/trunk/java/modules/common/src/org/apache/axis2/i18n/resource.properties
Mon Mar  6 03:47:57 2006
@@ -168,6 +168,28 @@
 confdirnotfound=conf directory not found , and no axis2.xml file is given ! System will continue
using default_axis2.xml
 noaxis2xmlfound=axis2.xml file not found in conf directory , system will continue using default_axis2.xml
 messagelabelcannotfound=message lebel can not be null
+paramterlockedbyparent=Parameter: {0} is already locked, hence value cannot be overridden
+modulealredyengaged={0}  module has already engaged to the operation operation terminated
!!!
+mepmappingerror=Could not Map the MEP URI to a axis2 MEP constant value
+mepnotyetimplemented="The MEP you are using  {0} has not implemented createClient().
+modulealredyengagetoservice=Trying to engage a module which is already engege: {0}
+invalidoperation=invalid operation : {0}
+noschemafound=no scheam found for the service
+modulenotavailble=Trying to engage a module which is not available : {0}
+modulealredyengagedtoservicegroup={0} module has already been engaged on the service Group.
Operation terminated !!!
+servicenotfoundinwsdl=Service {0} not found in the wsdl
+noservicefoundinwsdl=No servoce found in the given wsdl
+noporttypefoundfor=No port found for the given port name : {0}
+noporttypefound=no port found in the service element
+modulenf=Module not found
+mepcompleted=Invalid message addition , operation context completed
+invalidacess=In valid acess
+mepiscomplted=MEP is already completed- need to reset() before re-executing.
+outmsgctxnull=Out message context is null please set the out message context before calling
this method
+cannotreset=MEP is not yet complete: cannot reset
+cannotaddmsgctx=Can't add message context again until client has been executed
+#Policy
+emptypolicy=Policy Id is either null or empty
 #outMessageNull=Out message is null
 malformedURLException00=MalformedURLException:
 exception00=Exception:

Modified: webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/AxisDescription.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/AxisDescription.java?rev=383520&r1=383519&r2=383520&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/AxisDescription.java
(original)
+++ webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/AxisDescription.java
Mon Mar  6 03:47:57 2006
@@ -1,6 +1,7 @@
 package org.apache.axis2.description;
 
 import org.apache.axis2.AxisFault;
+import org.apache.axis2.i18n.Messages;
 import org.apache.ws.commons.om.OMElement;
 
 import java.util.ArrayList;
@@ -31,8 +32,7 @@
         }
 
         if (isParameterLocked(param.getName())) {
-            throw new AxisFault("Parameter:" + param.getName()
-                    + " is already locked, hence value cannot be overridden");
+            throw new AxisFault(Messages.getMessage("paramterlockedbyparent", param.getName()));
         }
 
         parameterInclude.addParameter(param);

Modified: webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/AxisMessage.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/AxisMessage.java?rev=383520&r1=383519&r2=383520&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/AxisMessage.java
(original)
+++ webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/AxisMessage.java
Mon Mar  6 03:47:57 2006
@@ -37,7 +37,7 @@
     // such as SchemaElementName , direction etc.
     private MessageReference messageReference;
 
-    private PolicyInclude policyInclude;
+    // private PolicyInclude policyInclude;
 
 
     public AxisMessage() {

Modified: webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/AxisModule.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/AxisModule.java?rev=383520&r1=383519&r2=383520&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/AxisModule.java
(original)
+++ webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/AxisModule.java
Mon Mar  6 03:47:57 2006
@@ -19,6 +19,7 @@
 
 import org.apache.axis2.AxisFault;
 import org.apache.axis2.engine.AxisConfiguration;
+import org.apache.axis2.i18n.Messages;
 import org.apache.axis2.modules.Module;
 import org.apache.ws.commons.om.OMElement;
 
@@ -97,7 +98,7 @@
      */
     public void addParameter(Parameter param) throws AxisFault {
         if (isParameterLocked(param.getName())) {
-            throw new AxisFault("Parmter is locked can not overide: " + param.getName());
+            throw new AxisFault(Messages.getMessage("paramterlockedbyparent", param.getName()));
         } else {
             parameters.addParameter(param);
         }

Modified: webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/AxisOperation.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/AxisOperation.java?rev=383520&r1=383519&r2=383520&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/AxisOperation.java
(original)
+++ webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/AxisOperation.java
Mon Mar  6 03:47:57 2006
@@ -48,7 +48,6 @@
     // To store deploytime module refs
     private ArrayList modulerefs;
 
-    // todo need to change name to String
     private QName name;
 
     private ArrayList wsamappingList;
@@ -116,9 +115,8 @@
             AxisModule module = (AxisModule) module_itr.next();
 
             if (module.getName().equals(moduleref.getName())) {
-                log.debug(moduleref.getName().getLocalPart()
-                        + " module has already engaged to the operation"
-                        + "  operation terminated !!!");
+                log.debug(Messages.getMessage("modulealredyengaged",
+                        moduleref.getName().getLocalPart()));
                 needToadd = false;
             }
         }
@@ -355,7 +353,7 @@
         }
 
         if (temp == MEP_CONSTANT_INVALID) {
-            throw new AxisError("Could not Map the MEP URI to a axis2 MEP constant value");
+            throw new AxisError(Messages.getMessage("mepmappingerror"));
         }
 
         this.mep = temp;
@@ -473,7 +471,7 @@
      * 
      */
     public OperationClient createClient(ServiceContext sc, Options options) {
-        throw new UnsupportedOperationException("The MEP you are using (" + mepURI + ") has
not implemented createClient().");
+        throw new UnsupportedOperationException(Messages.getMessage("mepnotyetimplemented",
mepURI));
     }
 
     public Object getKey() {

Modified: webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/AxisService.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/AxisService.java?rev=383520&r1=383519&r2=383520&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/AxisService.java
(original)
+++ webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/AxisService.java
Mon Mar  6 03:47:57 2006
@@ -23,6 +23,7 @@
 import org.apache.axis2.Constants;
 import org.apache.axis2.engine.AxisConfiguration;
 import org.apache.axis2.engine.MessageReceiver;
+import org.apache.axis2.i18n.Messages;
 import org.apache.axis2.modules.Module;
 import org.apache.axis2.phaseresolver.PhaseResolver;
 import org.apache.axis2.transport.TransportListener;
@@ -200,8 +201,8 @@
                 }
                 axisOperation.engageModule(module, axisConfig);
             } catch (AxisFault axisFault) {
-                log.info("Trying to engage a module which is already engege:"
-                        + module.getName().getLocalPart());
+                log.info(Messages.getMessage(
+                        "modulealredyengagetoservice", module.getName().getLocalPart()));
             }
         }
         if (axisOperation.getMessageReceiver() == null) {
@@ -270,12 +271,12 @@
     /**
      * Engages a module. It is required to use this method.
      *
-     * @param moduleref
+     * @param axisModule
      */
-    public void engageModule(AxisModule moduleref, AxisConfiguration axisConfig)
+    public void engageModule(AxisModule axisModule, AxisConfiguration axisConfig)
             throws AxisFault {
-        if (moduleref == null) {
-            throw new AxisFault("Module not found ");
+        if (axisModule == null) {
+            throw new AxisFault(Messages.getMessage("modulenf"));
         }
         boolean needToadd = true;
         Iterator itr_engageModules = engagedModules.iterator();
@@ -283,21 +284,20 @@
         while (itr_engageModules.hasNext()) {
             AxisModule module = (AxisModule) itr_engageModules.next();
 
-            if (module.getName().equals(moduleref.getName())) {
-                log.debug(moduleref.getName().getLocalPart()
-                        + " module has already been engaged on the service. "
-                        + " Operation terminated !!!");
+            if (module.getName().equals(axisModule.getName())) {
+                log.debug(Messages.getMessage("modulealredyengagetoservice",
+                        axisModule.getName().getLocalPart()));
                 needToadd = false;
             }
         }
 
-        Module moduleImpl = moduleref.getModule();
+        Module moduleImpl = axisModule.getModule();
         if (moduleImpl != null) {
             // notyfying module for service engagement
             moduleImpl.engageNotify(this);
         }
         // adding module operations
-        addModuleOperations(moduleref, axisConfig);
+        addModuleOperations(axisModule, axisConfig);
 
         Iterator operations = getOperations();
 
@@ -307,11 +307,11 @@
                 // notyfying module for service engagement
                 moduleImpl.engageNotify(axisOperation);
             }
-            axisOperation.engageModule(moduleref, axisConfig);
+            axisOperation.engageModule(axisModule, axisConfig);
         }
 
         if (needToadd) {
-            engagedModules.add(moduleref);
+            engagedModules.add(axisModule);
         }
     }
 
@@ -339,7 +339,8 @@
     public void printPolicy(OutputStream out, String operationName) throws AxisFault {
         AxisOperation axisOperation = getOperation(new QName(operationName));
         if (axisOperation == null) {
-            throw new AxisFault("invalid operation : " + operationName);
+            throw new AxisFault(Messages.getMessage("invalidoperation",
+              operationName));
         }
         PolicyUtil.writePolicy(axisOperation.getPolicyInclude(), out);
     }

Modified: webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/AxisService2WOM.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/AxisService2WOM.java?rev=383520&r1=383519&r2=383520&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/AxisService2WOM.java
(original)
+++ webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/AxisService2WOM.java
Mon Mar  6 03:47:57 2006
@@ -1,6 +1,7 @@
 package org.apache.axis2.description;
 
 import org.apache.axis2.Constants;
+import org.apache.axis2.i18n.Messages;
 import org.apache.axis2.wsdl.builder.SchemaGenerator;
 import org.apache.axis2.wsdl.builder.WSDLComponentFactory;
 import org.apache.ws.commons.schema.XmlSchema;
@@ -82,7 +83,7 @@
         DocumentBuilder domBuilder = domFactory.newDocumentBuilder();
         StringWriter writer = new StringWriter();
         if (schema == null) {
-            throw new Exception("no scheam found for the service");
+            throw new Exception(Messages.getMessage("noschemafound"));
         }
         schema.write(writer);
         writer.flush();

Modified: webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/AxisServiceGroup.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/AxisServiceGroup.java?rev=383520&r1=383519&r2=383520&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/AxisServiceGroup.java
(original)
+++ webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/AxisServiceGroup.java
Mon Mar  6 03:47:57 2006
@@ -20,6 +20,7 @@
 import org.apache.axis2.AxisFault;
 import org.apache.axis2.engine.AxisConfiguration;
 import org.apache.axis2.engine.AxisEvent;
+import org.apache.axis2.i18n.Messages;
 import org.apache.axis2.modules.Module;
 import org.apache.commons.logging.Log;
 import org.apache.commons.logging.LogFactory;
@@ -100,14 +101,13 @@
                     }
                     service.engageModule(axisModule, axisConfig);
                 } else {
-                    throw new AxisFault("Trying to engage a module which is not " + "available
: "
-                            + moduleName.getLocalPart());
+                    throw new AxisFault(Messages.getMessage(
+                            "modulenotavailble", moduleName.getLocalPart()));
                 }
             }
         }
 
         service.setLastupdate();
-//        services.put(service.getName(), service);
         addChild(service);
     }
 
@@ -122,9 +122,8 @@
             QName modu = (QName) iterator.next();
 
             if (modu.getLocalPart().equals(moduleName.getLocalPart())) {
-                log.debug(moduleName.getLocalPart()
-                        + " module has already been engaged on the service Group. "
-                        + " Operation terminated !!!");
+                log.debug(Messages.getMessage(
+                        "modulealredyengagedtoservicegroup", moduleName.getLocalPart()));
                 needToadd = false;
             }
         }

Modified: webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/ClientUtils.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/ClientUtils.java?rev=383520&r1=383519&r2=383520&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/ClientUtils.java
(original)
+++ webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/ClientUtils.java
Mon Mar  6 03:47:57 2006
@@ -118,7 +118,9 @@
             if (wsdlServiceName != null) {
                 wsdlService = wsdlDefinition.getService(wsdlServiceName);
                 if (wsdlService == null) {
-                    throw new AxisFault("Service" + wsdlServiceName + " not found in the
wsdl ");
+                    throw new AxisFault(
+                            Messages.getMessage("servicenotfoundinwsdl",
+                                    wsdlServiceName.getLocalPart()));
                 }
 
             } else {
@@ -126,10 +128,10 @@
                 if (col != null && col.size() > 0) {
                     wsdlService = (Service) col.iterator().next();
                     if (wsdlService == null) {
-                        throw new AxisFault("No servoce found in the given wsdl");
+                        throw new AxisFault(Messages.getMessage("noservicefoundinwsdl"));
                     }
                 } else {
-                    throw new AxisFault("No servoce found in the given wsdl");
+                    throw new AxisFault(Messages.getMessage("noservicefoundinwsdl"));
                 }
             }
             axisService.setName(wsdlService.getQName().getLocalPart());
@@ -138,17 +140,17 @@
             if (portName != null) {
                 port = wsdlService.getPort(portName);
                 if (port == null) {
-                    throw new AxisFault("No port found for the given port name : " + portName);
+                    throw new AxisFault(Messages.getMessage("noporttypefoundfor", portName));
                 }
             } else {
                 Collection ports = wsdlService.getPorts().values();
                 if (ports != null && ports.size() > 0) {
                     port = (Port) ports.iterator().next();
                     if (port == null) {
-                        throw new AxisFault("no port found in the service element");
+                        throw new AxisFault(Messages.getMessage("noporttypefound"));
                     }
                 } else {
-                    throw new AxisFault("no port found in the service element");
+                    throw new AxisFault(Messages.getMessage("noporttypefound"));
                 }
             }
             List exteElemts = port.getExtensibilityElements();

Modified: webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/HandlerDescription.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/HandlerDescription.java?rev=383520&r1=383519&r2=383520&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/HandlerDescription.java
(original)
+++ webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/HandlerDescription.java
Mon Mar  6 03:47:57 2006
@@ -18,6 +18,7 @@
 package org.apache.axis2.description;
 
 import org.apache.axis2.AxisFault;
+import org.apache.axis2.i18n.Messages;
 import org.apache.axis2.engine.Handler;
 import org.apache.ws.commons.om.OMElement;
 
@@ -78,7 +79,7 @@
      */
     public void addParameter(Parameter param) throws AxisFault {
         if (isParameterLocked(param.getName())) {
-            throw new AxisFault("Parmter is locked can not overide: " + param.getName());
+            throw new AxisFault(Messages.getMessage("paramterlockedbyparent",param.getName()));
         } else {
             parameterInclude.addParameter(param);
         }

Modified: webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/InOnlyAxisOperation.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/InOnlyAxisOperation.java?rev=383520&r1=383519&r2=383520&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/InOnlyAxisOperation.java
(original)
+++ webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/InOnlyAxisOperation.java
Mon Mar  6 03:47:57 2006
@@ -1,6 +1,7 @@
 package org.apache.axis2.description;
 
 import org.apache.axis2.AxisFault;
+import org.apache.axis2.i18n.Messages;
 import org.apache.axis2.context.MessageContext;
 import org.apache.axis2.context.OperationContext;
 import org.apache.wsdl.WSDLConstants;
@@ -49,16 +50,15 @@
             opContext.getMessageContexts().put(MESSAGE_LABEL_IN_VALUE, msgContext);
             opContext.setComplete(true);
         } else {
-            throw new AxisFault("Invalid message addition , operation context completed");
+            throw new AxisFault(Messages.getMessage("mepcompleted"));
         }
     }
 
     public void addFaultMessageContext(MessageContext msgContext, OperationContext opContext)
throws AxisFault {
         HashMap mep = opContext.getMessageContexts();
         MessageContext faultMessageCtxt = (MessageContext) mep.get(MESSAGE_LABEL_FAULT_VALUE);
-
         if (faultMessageCtxt != null) {
-            throw new AxisFault("Invalid message addition , operation context completed");
+            throw new AxisFault(Messages.getMessage("mepcompleted"));
         } else {
             mep.put(MESSAGE_LABEL_FAULT_VALUE, msgContext);
             opContext.setComplete(true);
@@ -67,9 +67,6 @@
     }
 
     private void createMessage() {
-//        inMessage = new AxisMessage();
-//        inMessage.setDirection(WSDLConstants.WSDL_MESSAGE_DIRECTION_IN);
-//        inMessage.setParent(this);
         AxisMessage inMessage = new AxisMessage();
         inMessage.setDirection(WSDLConstants.WSDL_MESSAGE_DIRECTION_IN);
         inMessage.setParent(this);
@@ -87,10 +84,9 @@
 
     public AxisMessage getMessage(String label) {
         if (WSDLConstants.MESSAGE_LABEL_IN_VALUE.equals(label)) {
-//            return inMessage;
             return (AxisMessage) getChild("inMessage");
         } else {
-            throw new UnsupportedOperationException("In valid acess");
+            throw new UnsupportedOperationException(Messages.getMessage("invalidacess"));
         }
     }
 

Modified: webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/InOutAxisOperation.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/InOutAxisOperation.java?rev=383520&r1=383519&r2=383520&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/InOutAxisOperation.java
(original)
+++ webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/InOutAxisOperation.java
Mon Mar  6 03:47:57 2006
@@ -1,6 +1,7 @@
 package org.apache.axis2.description;
 
 import org.apache.axis2.AxisFault;
+import org.apache.axis2.i18n.Messages;
 import org.apache.axis2.context.MessageContext;
 import org.apache.axis2.context.OperationContext;
 import org.apache.wsdl.WSDLConstants;
@@ -49,7 +50,7 @@
         MessageContext outmsgContext = (MessageContext) mep.get(MESSAGE_LABEL_OUT_VALUE);
 
         if ((inMsgContext != null) && (outmsgContext != null)) {
-            throw new AxisFault("Invalid message addition , operation context completed");
+            throw new AxisFault(Messages.getMessage("mepcompleted"));
         }
 
         if (inMsgContext == null) {
@@ -66,7 +67,7 @@
         MessageContext faultMessageCtxt = (MessageContext) mep.get(MESSAGE_LABEL_FAULT_VALUE);
 
         if (faultMessageCtxt != null) {
-            throw new AxisFault("Invalid message addition , operation context completed");
+             throw new AxisFault(Messages.getMessage("mepcompleted"));
         } else {
             mep.put(MESSAGE_LABEL_FAULT_VALUE, msgContext);
             opContext.setComplete(true);

Modified: webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/ModuleConfiguration.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/ModuleConfiguration.java?rev=383520&r1=383519&r2=383520&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/ModuleConfiguration.java
(original)
+++ webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/ModuleConfiguration.java
Mon Mar  6 03:47:57 2006
@@ -18,6 +18,7 @@
 package org.apache.axis2.description;
 
 import org.apache.axis2.AxisFault;
+import org.apache.axis2.i18n.Messages;
 import org.apache.ws.commons.om.OMElement;
 
 import javax.xml.namespace.QName;
@@ -46,7 +47,7 @@
 
     public void addParameter(Parameter param) throws AxisFault {
         if (isParameterLocked(param.getName())) {
-            throw new AxisFault("Parmter is locked can not overide: " + param.getName());
+           throw new AxisFault(Messages.getMessage("paramterlockedbyparent",param.getName()));
         } else {
             parameterinclude.addParameter(param);
         }

Modified: webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/OutInAxisOperation.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/OutInAxisOperation.java?rev=383520&r1=383519&r2=383520&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/OutInAxisOperation.java
(original)
+++ webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/OutInAxisOperation.java
Mon Mar  6 03:47:57 2006
@@ -49,8 +49,7 @@
                 .get(MESSAGE_LABEL_OUT_VALUE);
 
         if ((immsgContext != null) && (outmsgContext != null)) {
-            throw new AxisFault(
-                    "Invalid message addition , operation context completed");
+            throw new AxisFault(Messages.getMessage("mepcompleted"));
         }
 
         if (outmsgContext == null) {
@@ -205,8 +204,7 @@
      */
     public void execute(boolean block) throws AxisFault {
         if (completed) {
-            throw new AxisFault(
-                    "MEP is already completed- need to reset() before re-executing.");
+            throw new AxisFault(Messages.getMessage("mepiscomplted"));
         }
         ConfigurationContext cc = sc.getConfigurationContext();
 
@@ -214,9 +212,7 @@
         MessageContext mc = oc
                 .getMessageContext(WSDLConstants.MESSAGE_LABEL_OUT_VALUE);
         if (mc == null) {
-            throw new AxisFault(
-                    "Out message context is null ,"
-                            + " please set the out message context before calling this method");
+            throw new AxisFault(Messages.getMessage("outmsgctxnull"));
         }
 
         mc.setOptions(options);
@@ -378,7 +374,7 @@
      */
     public void reset() throws AxisFault {
         if (!completed) {
-            throw new AxisFault("MEP is not yet complete: cannot reset");
+            throw new AxisFault(Messages.getMessage("cannotreset"));
         }
         oc = null;
         completed = false;

Modified: webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/OutOnlyAxisOperation.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/OutOnlyAxisOperation.java?rev=383520&r1=383519&r2=383520&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/OutOnlyAxisOperation.java
(original)
+++ webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/OutOnlyAxisOperation.java
Mon Mar  6 03:47:57 2006
@@ -11,6 +11,7 @@
 import org.apache.axis2.context.ServiceContext;
 import org.apache.axis2.engine.AxisEngine;
 import org.apache.axis2.engine.ListenerManager;
+import org.apache.axis2.i18n.Messages;
 import org.apache.axis2.util.UUIDGenerator;
 import org.apache.ws.commons.om.OMElement;
 import org.apache.wsdl.WSDLConstants;
@@ -59,8 +60,7 @@
                     msgContext);
             opContext.setComplete(true);
         } else {
-            throw new AxisFault(
-                    "Invalid message addition , operation context completed");
+            throw new AxisFault(Messages.getMessage("mepcompleted"));
         }
     }
 
@@ -69,7 +69,7 @@
         MessageContext faultMessageCtxt = (MessageContext) mep.get(MESSAGE_LABEL_FAULT_VALUE);
 
         if (faultMessageCtxt != null) {
-            throw new AxisFault("Invalid message addition , operation context completed");
+            throw new AxisFault(Messages.getMessage("mepcompleted"));
         } else {
             mep.put(MESSAGE_LABEL_FAULT_VALUE, msgContext);
             opContext.setComplete(true);
@@ -205,8 +205,7 @@
      */
     public void addMessageContext(MessageContext mc) throws AxisFault {
         if (this.mc != null) {
-            throw new AxisFault(
-                    "Can't add message context again until client has been executed");
+            throw new AxisFault(Messages.getMessage("cannotaddmsgctx"));
         }
         this.mc = mc;
         if (mc.getMessageID() == null) {
@@ -230,7 +229,7 @@
         if (messageLabel.equals(WSDLConstants.MESSAGE_LABEL_OUT_VALUE)) {
             return mc;
         }
-        throw new AxisFault("Unknown message label: '" + messageLabel + "'");
+        throw new AxisFault(Messages.getMessage("unknownMsgLabel", messageLabel));
     }
 
     /**
@@ -302,8 +301,7 @@
      */
     public void execute(boolean block) throws AxisFault {
         if (completed) {
-            throw new AxisFault(
-                    "MEP is already completed- need to reset() before re-executing.");
+            throw new AxisFault(Messages.getMessage("mepiscomplted"));
         }
         ConfigurationContext cc = sc.getConfigurationContext();
 
@@ -352,7 +350,7 @@
      */
     public void reset() throws AxisFault {
         if (!completed) {
-            throw new AxisFault("MEP is not yet complete: cannot reset");
+            throw new AxisFault(Messages.getMessage("cannotreset"));
         }
         mc = null;
         completed = false;

Modified: webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/PolicyInclude.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/PolicyInclude.java?rev=383520&r1=383519&r2=383520&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/PolicyInclude.java
(original)
+++ webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/description/PolicyInclude.java
Mon Mar  6 03:47:57 2006
@@ -20,6 +20,7 @@
 import org.apache.ws.policy.Policy;
 import org.apache.ws.policy.PolicyReference;
 import org.apache.ws.policy.util.PolicyRegistry;
+import org.apache.axis2.i18n.Messages;
 
 import java.util.ArrayList;
 import java.util.Hashtable;
@@ -116,8 +117,8 @@
 	public void updatePolicy(Policy policy) {
 		String policyURI = policy.getPolicyURI();
 		
-		if (policyURI == null && policyURI.equals("")) {
-			throw new RuntimeException("Policy Id is either null or empty");
+		if (policyURI == null && "".equals(policyURI)) {
+			throw new RuntimeException(Messages.getMessage("emptypolicy"));
 		}
 		
 		Wrapper wrapper = (Wrapper) wrapperElements.get(policyURI);
@@ -175,7 +176,7 @@
 	}
 
 	private void calculateEffectivePolicy() {
-		Policy result = null;
+		Policy result ;
 		
 		if (getParent() != null) {
 			Policy parentPolicy = getParent().getEffectivePolicy();
@@ -253,7 +254,6 @@
 	}
 
 	public void addPolicyElement(int type, Policy policy) {
-		String u = policy.getPolicyURI();
 		if (policy.getPolicyURI() == null || policy.getPolicyURI().equals("")) {
 			policy.setId(UUIDGenerator.getUUID());
 		}

Modified: webservices/axis2/trunk/java/modules/core/test/org/apache/axis2/deployment/AxisObserverImpl.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/core/test/org/apache/axis2/deployment/AxisObserverImpl.java?rev=383520&r1=383519&r2=383520&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/core/test/org/apache/axis2/deployment/AxisObserverImpl.java
(original)
+++ webservices/axis2/trunk/java/modules/core/test/org/apache/axis2/deployment/AxisObserverImpl.java
Mon Mar  6 03:47:57 2006
@@ -17,10 +17,7 @@
 package org.apache.axis2.deployment;
 
 import org.apache.axis2.AxisFault;
-import org.apache.axis2.description.AxisModule;
-import org.apache.axis2.description.AxisService;
-import org.apache.axis2.description.Parameter;
-import org.apache.axis2.description.ParameterIncludeImpl;
+import org.apache.axis2.description.*;
 import org.apache.axis2.engine.AxisConfiguration;
 import org.apache.axis2.engine.AxisEvent;
 import org.apache.axis2.engine.AxisObserver;
@@ -30,7 +27,7 @@
 
 public class AxisObserverImpl implements AxisObserver {
 
-    ParameterIncludeImpl parameterimpl;
+    ParameterInclude parameterimpl;
 
     // The initilization code will go here
     public void init(AxisConfiguration axisConfig) {



Mime
View raw message