Sha256: 684c0b654bd3089b51fca57721e17e3c40e1585faf2beaa2bf8341662e6a8b0b

Contents?: true

Size: 832 Bytes

Versions: 4

Compression:

Stored size: 832 Bytes

Contents

module Fog
  module SharedFileSystem
    class HuaweiCloud
      class Real
        # For older versions v1.0-2.8 the export locations are responsed as an attribute of share (export_locations). 
        # For newer API versions (>= 2.9) it is available in separate APIs.
        # This method returns a list of the export locations.
        def list_share_export_locations(share_id)
          request(
            :expects => 200,
            :method  => 'GET',
            :path    => "shares/#{share_id}/export_locations"
          )
        end
      end

      class Mock
        def list_share_export_locations(share_id)
          response = Excon::Response.new
          response.status = 200
          response.body = {'export_locations' => data[:export_locations]}
          response
        end
      end
    end
  end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
fog-huaweicloud-0.0.3 lib/fog/shared_file_system/huaweicloud/requests/list_share_export_locations.rb
fog-huaweicloud-0.0.2 lib/fog/shared_file_system/huaweicloud/requests/list_share_export_locations.rb
fog-huaweicloud-0.1.3 lib/fog/shared_file_system/huaweicloud/requests/list_share_export_locations.rb
fog-huaweicloud-0.1.2 lib/fog/shared_file_system/huaweicloud/requests/list_share_export_locations.rb