Sha256: 6eacbc78c15f3abd195dbcff82b24b88f4a9b90ef9d2a316adb8154d78c57fbd

Contents?: true

Size: 866 Bytes

Versions: 3

Compression:

Stored size: 866 Bytes

Contents

module Fog
  module Network
    class AzureRM
      # Probe model for Network Service
      class Probe < Fog::Model
        identity :name
        attribute :id
        attribute :protocol
        attribute :port
        attribute :request_path
        attribute :interval_in_seconds
        attribute :number_of_probes

        def self.parse(probe)
          probe_prop = probe['properties']
          hash = {}
          hash['id'] = probe['id']
          hash['name'] = probe['name']
          hash['protocol'] = probe_prop['protocol']
          hash['port'] = probe_prop['port']
          hash['request_path'] = probe_prop['requestPath']
          hash['interval_in_seconds'] = probe_prop['intervalInSeconds']
          hash['number_of_probes'] = probe_prop['numberOfProbes']
          hash
        end
      end
    end
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
fog-azure-rm-0.0.4 lib/fog/azurerm/models/network/probe.rb
fog-azure-rm-0.0.3 lib/fog/azurerm/models/network/probe.rb
fog-azure-rm-0.0.2 lib/fog/azurerm/models/network/probe.rb