aboutsummaryrefslogtreecommitdiffstats
path: root/actionwebservice/lib/action_web_service/dispatcher/abstract.rb
diff options
context:
space:
mode:
authorLeon Breedt <bitserf@gmail.com>2005-04-05 21:37:48 +0000
committerLeon Breedt <bitserf@gmail.com>2005-04-05 21:37:48 +0000
commit1155ea0aa3c25b4683c6343162cd49dbe0fec094 (patch)
tree3f51d6a8bb7d64cc71c8546055ca03c906cd3d7a /actionwebservice/lib/action_web_service/dispatcher/abstract.rb
parent81014da84c9ae4dacb70287ff6f509d7a40cc0ae (diff)
downloadrails-1155ea0aa3c25b4683c6343162cd49dbe0fec094.tar.gz
rails-1155ea0aa3c25b4683c6343162cd49dbe0fec094.tar.bz2
rails-1155ea0aa3c25b4683c6343162cd49dbe0fec094.zip
initial go at making :layered dispatching generate WSDL for SOAP, and have
:layered process SOAP method calls correctly as well, may be unstable git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1097 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
Diffstat (limited to 'actionwebservice/lib/action_web_service/dispatcher/abstract.rb')
-rw-r--r--actionwebservice/lib/action_web_service/dispatcher/abstract.rb14
1 files changed, 11 insertions, 3 deletions
diff --git a/actionwebservice/lib/action_web_service/dispatcher/abstract.rb b/actionwebservice/lib/action_web_service/dispatcher/abstract.rb
index 975120212f..1d8715a8f7 100644
--- a/actionwebservice/lib/action_web_service/dispatcher/abstract.rb
+++ b/actionwebservice/lib/action_web_service/dispatcher/abstract.rb
@@ -52,9 +52,17 @@ module ActionWebService # :nodoc:
invocation.protocol = request.protocol
invocation.service_name = request.service_name
if web_service_dispatching_mode == :layered
- if request.method_name =~ /^([^\.]+)\.(.*)$/
- public_method_name = $2
- invocation.service_name = $1
+ case invocation.protocol
+ when Protocol::Soap::SoapProtocol
+ soap_action = request.protocol_options[:soap_action]
+ if soap_action && soap_action =~ /^\/\w+\/(\w+)\//
+ invocation.service_name = $1
+ end
+ when Protocol::XmlRpc::XmlRpcProtocol
+ if request.method_name =~ /^([^\.]+)\.(.*)$/
+ public_method_name = $2
+ invocation.service_name = $1
+ end
end
end
case web_service_dispatching_mode