Class: Zimbra::HandsoapService

Inherits:
Handsoap::Service
  • Object
show all
Extended by:
HandsoapUriOverrides
Includes:
HandsoapErrors, HandsoapNamespaces
Defined in:
lib/zimbra/handsoap_service.rb

Instance Method Summary collapse

Methods included from HandsoapUriOverrides

envelope_namespace, request_content_type, uri

Methods included from HandsoapNamespaces

#request_namespaces, #response_namespaces

Methods included from HandsoapErrors

#http_error?, #http_not_found?, #on_after_create_http_request, #on_http_error, #report_error, #soap_fault_not_found?

Instance Method Details

#on_create_document(doc) ⇒ Object



63
64
65
66
67
68
69
70
# File 'lib/zimbra/handsoap_service.rb', line 63

def on_create_document(doc)
  request_namespaces(doc)
  header = doc.find("Header")
  header.add "n1:context" do |s|
    s.set_attr "env:mustUnderstand", "0"
    s.add "n1:authToken", Zimbra.auth_token
  end
end

#on_response_document(doc) ⇒ Object



71
72
73
# File 'lib/zimbra/handsoap_service.rb', line 71

def on_response_document(doc)
  response_namespaces(doc)
end