Sha256: 6b83acb93d1fbdf4b2cde482c653f1fc53d6d22c3b1b9ab6e7b3da3c7589f0af

Contents?: true

Size: 872 Bytes

Versions: 28

Compression:

Stored size: 872 Bytes

Contents

require 'fog/vcloud_director/generators/compute/compose_common'

module Fog
  module Generators
    module Compute
      module VcloudDirector
        # @see http://pubs.vmware.com/vcd-51/index.jsp#types/RecomposeVAppParamsType.html
        class RecomposeVapp

          include ComposeCommon

          def generate_xml
            Nokogiri::XML::Builder.new do |xml|
              xml.RecomposeVAppParams(vapp_attrs) {
                if has_source_items?
                  build_vapp_instantiation_params(xml)
                  build_source_items(xml)
                end
                build_delete_items(xml)
              }
            end.to_xml
          end

          private

          def build_delete_items(xml)
             @configuration[:vms_to_delete].each { |vm| xml.DeleteItem(:href => vm.href) }
          end

        end
      end
    end
  end
end

Version data entries

28 entries across 26 versions & 4 rubygems

Version Path
fog-2.3.0 lib/fog/vcloud_director/generators/compute/recompose_vapp.rb
fog-ifeel-2.2.0 lib/fog/vcloud_director/generators/compute/recompose_vapp.rb
fog-2.2.0 lib/fog/vcloud_director/generators/compute/recompose_vapp.rb
fog-2.1.0 lib/fog/vcloud_director/generators/compute/recompose_vapp.rb
vagrant-packet-0.1.1 vendor/bundle/ruby/2.5.0/gems/fog-1.42.1/lib/fog/vcloud_director/generators/compute/recompose_vapp.rb
vagrant-packet-0.1.1 vendor/bundle/ruby/2.4.0/gems/fog-1.42.1/lib/fog/vcloud_director/generators/compute/recompose_vapp.rb
vagrant-packet-0.1.1 vendor/bundle/ruby/2.3.0/gems/fog-1.42.1/lib/fog/vcloud_director/generators/compute/recompose_vapp.rb
fog-1.42.1 lib/fog/vcloud_director/generators/compute/recompose_vapp.rb
fog-vcloud-director-0.2.2 lib/fog/vcloud_director/generators/compute/recompose_vapp.rb
fog-vcloud-director-0.2.1 lib/fog/vcloud_director/generators/compute/recompose_vapp.rb
fog-vcloud-director-0.2.0 lib/fog/vcloud_director/generators/compute/recompose_vapp.rb
fog-vcloud-director-0.1.10 lib/fog/vcloud_director/generators/compute/recompose_vapp.rb
fog-vcloud-director-0.1.9 lib/fog/vcloud_director/generators/compute/recompose_vapp.rb
fog-2.0.0 lib/fog/vcloud_director/generators/compute/recompose_vapp.rb
fog-1.42.0 lib/fog/vcloud_director/generators/compute/recompose_vapp.rb
fog-1.41.0 lib/fog/vcloud_director/generators/compute/recompose_vapp.rb
fog-1.40.0 lib/fog/vcloud_director/generators/compute/recompose_vapp.rb
fog-1.39.0 lib/fog/vcloud_director/generators/compute/recompose_vapp.rb
fog-vcloud-director-0.1.8 lib/fog/vcloud_director/generators/compute/recompose_vapp.rb
fog-vcloud-director-0.1.7 lib/fog/vcloud_director/generators/compute/recompose_vapp.rb