Class: Dhl::Bcs::V2::Service

Inherits:
Object
  • Object
show all
Includes:
Buildable
Defined in:
lib/dhl/bcs/v2/service.rb

Constant Summary collapse

PROPERTIES =
i(name attributes children).freeze

Instance Method Summary collapse

Methods included from Buildable

included, #initialize

Instance Method Details

#to_soap_hashObject



9
10
11
12
13
# File 'lib/dhl/bcs/v2/service.rb', line 9

def to_soap_hash
  # make a self closing tag by appending "/" if no children
  tag_name = children ? name : "#{name}/"
  { tag_name => children, attributes!: { tag_name => attributes } }
end