Sha256: d81f30a52fb49f7ab0f22b7110682471ac3c582088c63d79cee6f5544a813d08

Contents?: true

Size: 782 Bytes

Versions: 3

Compression:

Stored size: 782 Bytes

Contents

module Fog
  module Parsers
    module Vcloud

      class GetOrganization < Fog::Parsers::Vcloud::Base
        #
        # Based off of:
        # http://support.theenterprisecloud.com/kb/default.asp?id=540&Lang=1&SID=
        # 
        # vCloud API Guide v0.9 - Page 26
        #

        def reset
          @response = Struct::VcloudOrganization.new([])
        end

        def start_element(name, attributes=[])
          super
          case name
          when 'Link'
            @response.links << generate_link(attributes)
          when 'Org'
            handle_root(attributes)
          end
        end

        def end_element(name)
          if name == 'Description'
            @response.description = @value
          end
        end

      end

    end
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
fog-0.2.0 lib/fog/vcloud/parsers/get_organization.rb
fog-0.1.10 lib/fog/vcloud/parsers/get_organization.rb
fog-0.1.9 lib/fog/vcloud/parsers/get_organization.rb