Changeset 66
- Timestamp:
- 04/20/01 21:33:37 (8 years ago)
- Files:
-
- trunk/lib/soap/streamHandler.rb (modified) (4 diffs)
- trunk/lib/soap/streamHandler_wo_http-access.rb (modified) (5 diffs)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
trunk/lib/soap/streamHandler.rb
r49 r66 50 50 end 51 51 52 def send( methodNamespace, methodName, soapString)52 def send( soapString, soapAction = nil ) 53 53 begin 54 s = sendPOST( methodNamespace, methodName, soapString)54 s = sendPOST( soapString, soapAction ) 55 55 rescue PostUnavailableError 56 56 begin 57 s = sendMPOST( methodNamespace, methodName, soapString)57 s = sendMPOST( soapString, soapAction ) 58 58 rescue MPostUnavailableError 59 59 raise HTTPStreamError.new( $! ) … … 64 64 private 65 65 66 def sendPOST( methodNamespace, methodName, soapString)66 def sendPOST( soapString, soapAction ) 67 67 retryNo = NofRetry 68 68 drv = nil … … 77 77 raise 78 78 end 79 action = methodNamespace.dup << '#' << methodName79 action = "\"#{ soapAction }\"" 80 80 requestHeaders = { 'SOAPAction' => action, 'Content-Type' => MediaType } 81 81 … … 129 129 end 130 130 131 def sendMPOST( methodNamespace, methodName, soapString)131 def sendMPOST( soapString, soapAction ) 132 132 raise NotImplementError.new() 133 133 trunk/lib/soap/streamHandler_wo_http-access.rb
r31 r66 49 49 end 50 50 51 def send( methodNamespace, methodName, soapString)51 def send( soapString, soapAction = nil ) 52 52 begin 53 s = sendPOST( methodNamespace, methodName, soapString)53 s = sendPOST( soapString, soapAction ) 54 54 rescue PostUnavailableError 55 55 begin 56 s = sendMPOST( methodNamespace, methodName, soapString)56 s = sendMPOST( soapString, soapAction ) 57 57 rescue MPostUnavailableError 58 58 raise HTTPStreamError.new( $! ) … … 63 63 private 64 64 65 def sendPOST( methodNamespace, methodName, soapString)65 def sendPOST( soapString, soapAction ) 66 66 server = URI.create( @server ) 67 67 … … 89 89 absPath << '?' << server.query if server.query 90 90 end 91 action = methodNamespace.dup << '#' << methodName92 91 93 92 header = {} … … 100 99 Content-Length: #{ soapString.size } 101 100 Content-Type: #{ MediaType } 102 SOAPAction: #{ action }101 SOAPAction: "#{ soapAction }" 103 102 104 103 EOS … … 172 171 end 173 172 174 def sendMPOST( methodNamespace, methodName, soapString)173 def sendMPOST( soapString, soapAction ) 175 174 raise NotImplementError.new() 176 175