Author: keith Date: Wed Jul 9 20:36:00 2008 New Revision: 19057 URL: http://wso2.org/svn/browse/wso2?view=rev&revision=19057
Log: Fixing Prt 2 of Mashup-916. Picking the policy off the binding hierarchy instead of the description hierarchy Modified: trunk/mashup/java/modules/hostobjects/src/org/wso2/mashup/hostobjects/wsrequest/WSRequestHostImpl.java Modified: trunk/mashup/java/modules/hostobjects/src/org/wso2/mashup/hostobjects/wsrequest/WSRequestHostImpl.java URL: http://wso2.org/svn/browse/wso2/trunk/mashup/java/modules/hostobjects/src/org/wso2/mashup/hostobjects/wsrequest/WSRequestHostImpl.java?rev=19057&r1=19056&r2=19057&view=diff ============================================================================== --- trunk/mashup/java/modules/hostobjects/src/org/wso2/mashup/hostobjects/wsrequest/WSRequestHostImpl.java (original) +++ trunk/mashup/java/modules/hostobjects/src/org/wso2/mashup/hostobjects/wsrequest/WSRequestHostImpl.java Wed Jul 9 20:36:00 2008 @@ -31,6 +31,10 @@ import org.apache.axis2.context.ConfigurationContextFactory; import org.apache.axis2.description.AxisOperation; import org.apache.axis2.description.WSDL2Constants; +import org.apache.axis2.description.AxisService; +import org.apache.axis2.description.AxisEndpoint; +import org.apache.axis2.description.AxisDescription; +import org.apache.axis2.description.AxisBindingMessage; import org.apache.axis2.transport.http.HTTPConstants; import org.apache.axis2.transport.http.HttpTransportProperties; import org.apache.axis2.transport.http.HttpTransportProperties.Authenticator; @@ -667,11 +671,13 @@ // TODO do we need to call onreadystatechange here too if (wsRequest.wsdlMode) { boolean needRampart = false; - AxisOperation axisOperation = - (AxisOperation) wsRequest.sender.getAxisService() - .getChild(operationName); - Policy policy = axisOperation.getMessage( - WSDLConstants.MESSAGE_LABEL_IN_VALUE).getEffectivePolicy(); + AxisService axisService = wsRequest.sender.getAxisService(); + AxisEndpoint axisEndpoint = + axisService.getEndpoint(axisService.getEndpointName()); + AxisBindingMessage axisBindingMessage = (AxisBindingMessage) axisEndpoint + .getBinding().getChild(operationName) + .getChild(WSDLConstants.MESSAGE_LABEL_IN_VALUE); + Policy policy = axisBindingMessage.getEffectivePolicy(); if (policy != null) { List it = (List) policy.getAlternatives().next(); _______________________________________________ Mashup-dev mailing list [email protected] http://wso2.org/cgi-bin/mailman/listinfo/mashup-dev
