From b94bd32f3116b469b48400382dbc964bf17994d1 Mon Sep 17 00:00:00 2001 From: Leon Breedt Date: Tue, 29 Mar 2005 12:31:39 +0000 Subject: first pass of web service scaffolding. add ability to quickly generate an action pack request for a protocol, add missing log_error when we fail to parse protocol messages. add RDoc for scaffolding and functional testing. git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1037 5ecf4fe2-1ee6-0310-87b1-e25e094e27de --- actionwebservice/lib/action_web_service/protocol/soap_protocol.rb | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'actionwebservice/lib/action_web_service/protocol/soap_protocol.rb') diff --git a/actionwebservice/lib/action_web_service/protocol/soap_protocol.rb b/actionwebservice/lib/action_web_service/protocol/soap_protocol.rb index 253812b5e2..5e56748ae3 100644 --- a/actionwebservice/lib/action_web_service/protocol/soap_protocol.rb +++ b/actionwebservice/lib/action_web_service/protocol/soap_protocol.rb @@ -20,11 +20,17 @@ module ActionWebService # :nodoc: Request.new(self, method_name, params, service_name) end - def protocol_client(api, protocol_name, endpoint_uri, options) + def protocol_client(api, protocol_name, endpoint_uri, options={}) return nil unless protocol_name == :soap ActionWebService::Client::Soap.new(api, endpoint_uri, options) end + def create_action_pack_request(service_name, public_method_name, raw_body, options={}) + request = super + request.env['HTTP_SOAPACTION'] = '/soap/%s/%s' % [service_name, public_method_name] + request + end + private def has_valid_soap_action?(request) return nil unless request.method == :post -- cgit v1.2.3