Module: ActionService::Router::Wsdl::InstanceMethods

Defined in:
lib/action_service/router/wsdl.rb

Overview

:nodoc:

Constant Summary collapse

XsdNs =
'http://www.w3.org/2001/XMLSchema'
WsdlNs =
'http://schemas.xmlsoap.org/wsdl/'
SoapNs =
'http://schemas.xmlsoap.org/wsdl/soap/'
SoapEncodingNs =
'http://schemas.xmlsoap.org/soap/encoding/'
SoapHttpTransport =
'http://schemas.xmlsoap.org/soap/http'

Instance Method Summary collapse

Instance Method Details

#wsdlObject



15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
# File 'lib/action_service/router/wsdl.rb', line 15

def wsdl
  case @request.method
  when :get
    begin
      host_name = @request.env['HTTP_HOST']||@request.env['SERVER_NAME']
      uri = "http://#{host_name}/#{controller_name}/"
      soap_action_base = "/#{controller_name}"
      xml = to_wsdl(self, uri, soap_action_base)
      send_data(xml, :type => 'text/xml', :disposition => 'inline')
    rescue Exception => e
      log_error e unless logger.nil?
      render_text('', "500 #{e.message}")
    end
  when :post
    render_text('', "500 POST not supported")
  end
end