You are viewing a plain text version of this content. The canonical link for it is here.
Posted to axis-cvs@ws.apache.org by am...@apache.org on 2006/12/15 15:51:19 UTC
svn commit: r487574 -
/webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/codegen/emitter/AxisServiceBasedMultiLanguageEmitter.java
Author: amilas
Date: Fri Dec 15 06:51:18 2006
New Revision: 487574
URL: http://svn.apache.org/viewvc?view=rev&rev=487574
Log:
Revert the last change to AxisServiceBasedMultiLanguageEmitter.java
Modified:
webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/codegen/emitter/AxisServiceBasedMultiLanguageEmitter.java
Modified: webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/codegen/emitter/AxisServiceBasedMultiLanguageEmitter.java
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/codegen/emitter/AxisServiceBasedMultiLanguageEmitter.java?view=diff&rev=487574&r1=487573&r2=487574
==============================================================================
--- webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/codegen/emitter/AxisServiceBasedMultiLanguageEmitter.java (original)
+++ webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/codegen/emitter/AxisServiceBasedMultiLanguageEmitter.java Fri Dec 15 06:51:18 2006
@@ -656,96 +656,6 @@
return rootElement;
}
-
- /**
- * add the qNames of the operation fault message names to faultMessages Mep
- *
- * @param operationFaultMessages
- * @param faultMessagesToMep
- */
-
- private void addFaultMessages(List operationFaultMessages, Set faultMessagesToMep) {
-
- AxisMessage faultMessage;
- for (Iterator iter = operationFaultMessages.iterator(); iter.hasNext();) {
- faultMessage = (AxisMessage) iter.next();
- faultMessagesToMep.add(faultMessage.getElementQName());
- }
-
- }
-
- /**
- * A util method that returns a unique list of faults for a given mep
- *
- * @param doc
- * @return DOM element
- */
- protected Element getUniqueListofFaultsofMep(Document doc, String mep) {
-
- // list to keep fault message qnames for this mep
- Set faultListForMep = new HashSet();
-
- Iterator iter = this.axisService.getOperations();
- AxisOperation axisOperation;
-
- for (; iter.hasNext();) {
- axisOperation = (AxisOperation) iter.next();
- if (mep == null) {
- // add the fault messages
- addFaultMessages(axisOperation.getFaultMessages(),faultListForMep);
- } else {
- if (mep.equals(axisOperation.getMessageExchangePattern())){
- // add the fault messages
- addFaultMessages(axisOperation.getFaultMessages(),faultListForMep);
- }
- }
- }
-
- Element rootElement = doc.createElement("fault-list");
- Element faultElement;
- QName key;
- Iterator iterator = faultListForMep.iterator();
- while (iterator.hasNext()) {
- faultElement = doc.createElement("fault");
- key = (QName) iterator.next();
-
- //as for the name of a fault, we generate an exception
- addAttribute(doc, "name",
- (String) fullyQualifiedFaultClassNameMap.get(key),
- faultElement);
- addAttribute(doc, "shortName",
- (String) faultClassNameMap.get(key),
- faultElement);
-
- //the type represents the type that will be wrapped by this
- //name
- String typeMapping =
- this.mapper.getTypeMappingName(key);
- addAttribute(doc, "type", (typeMapping == null)
- ? ""
- : typeMapping, faultElement);
- String attribValue = (String) instantiatableMessageClassNames.
- get(key);
-
- addAttribute(doc, "instantiatableType",
- attribValue == null ? "" : attribValue,
- faultElement);
-
- // add an extra attribute to say whether the type mapping is
- // the default
- if (mapper.getDefaultMappingName().equals(typeMapping)) {
- addAttribute(doc, "default", "yes", faultElement);
- }
- addAttribute(doc, "value", getParamInitializer(typeMapping),
- faultElement);
-
-
- rootElement.appendChild(faultElement);
- }
- return rootElement;
- }
-
-
/**
* Adds the endpoint to the document.
*
@@ -1684,7 +1594,7 @@
loadOperations(doc, rootElement, null);
//attach a list of faults
- rootElement.appendChild(getUniqueListofFaultsofMep(doc,mep));
+ rootElement.appendChild(getUniqueListofFaults(doc));
doc.appendChild(rootElement);
return doc;
---------------------------------------------------------------------
To unsubscribe, e-mail: axis-cvs-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-cvs-help@ws.apache.org