Module: Savon::Model::ClassMethods
- Defined in:
- lib/savon/model.rb
Class Method Summary collapse
Instance Method Summary collapse
-
#actions(*actions) ⇒ Object
Accepts one or more SOAP actions and generates both class and instance methods named after the given actions.
- #init_savon_model ⇒ Object
Class Method Details
.extend_object(base) ⇒ Object
20 21 22 23 |
# File 'lib/savon/model.rb', line 20 def self.extend_object(base) super base.init_savon_model end |
Instance Method Details
#actions(*actions) ⇒ Object
Accepts one or more SOAP actions and generates both class and instance methods named after the given actions. Each generated method accepts an optional SOAP body Hash and a block to be passed to Savon::Client#request
and executes a SOAP request.
33 34 35 36 37 38 |
# File 'lib/savon/model.rb', line 33 def actions(*actions) actions.each do |action| define_class_action action define_instance_action action end end |
#init_savon_model ⇒ Object
25 26 27 28 |
# File 'lib/savon/model.rb', line 25 def init_savon_model class_action_module instance_action_module end |