Sha256: 81edecd907e9a0131f69b134de2d8af3512e5b414e9eca046856df8ba5b575fb

Contents?: true

Size: 688 Bytes

Versions: 143

Compression:

Stored size: 688 Bytes

Contents

module Fog
  module Parsers
    module AWS
      module S3

        class GetService < Fog::Parsers::Base

          def reset
            @bucket = {}
            @response = { 'Owner' => {}, 'Buckets' => [] }
          end

          def end_element(name)
            case name
            when 'Bucket'
              @response['Buckets'] << @bucket
              @bucket = {}
            when 'CreationDate'
              @bucket['CreationDate'] = Time.parse(@value)
            when 'DisplayName', 'ID'
              @response['Owner'][name] = @value
            when 'Name'
              @bucket[name] = @value
            end
          end

        end

      end
    end
  end
end

Version data entries

143 entries across 143 versions & 3 rubygems

Version Path
fog-0.0.85 lib/fog/aws/parsers/s3/get_service.rb
fog-0.0.84 lib/fog/aws/parsers/s3/get_service.rb
fog-0.0.83 lib/fog/aws/parsers/s3/get_service.rb
fog-0.0.82 lib/fog/aws/parsers/s3/get_service.rb
fog-0.0.81 lib/fog/aws/parsers/s3/get_service.rb
fog-0.0.80 lib/fog/aws/parsers/s3/get_service.rb
fog-0.0.79 lib/fog/aws/parsers/s3/get_service.rb
fog-0.0.78 lib/fog/aws/parsers/s3/get_service.rb
fog-0.0.77 lib/fog/aws/parsers/s3/get_service.rb
fog-0.0.76 lib/fog/aws/parsers/s3/get_service.rb
fog-0.0.75 lib/fog/aws/parsers/s3/get_service.rb
fog-0.0.74 lib/fog/aws/parsers/s3/get_service.rb
fog-0.0.73 lib/fog/aws/parsers/s3/get_service.rb
fog-0.0.72 lib/fog/aws/parsers/s3/get_service.rb
fog-0.0.71 lib/fog/aws/parsers/s3/get_service.rb
fog-0.0.70 lib/fog/aws/parsers/s3/get_service.rb
fog-0.0.69 lib/fog/aws/parsers/s3/get_service.rb
fog-0.0.68 lib/fog/aws/parsers/s3/get_service.rb
fog-0.0.67 lib/fog/aws/parsers/s3/get_service.rb
fog-0.0.66 lib/fog/aws/parsers/s3/get_service.rb