Class: Fog::TrafficManager::AzureRM::TrafficManagerProfiles

Inherits:
Collection
  • Object
show all
Defined in:
lib/fog/azurerm/models/traffic_manager/traffic_manager_profiles.rb

Overview

Traffic Manager Profile Collection for TrafficManager Service

Instance Method Summary collapse

Instance Method Details

#allObject



9
10
11
12
13
# File 'lib/fog/azurerm/models/traffic_manager/traffic_manager_profiles.rb', line 9

def all
  requires :resource_group
  traffic_manager_profiles = service.list_traffic_manager_profiles(resource_group).map { |profile| Fog::TrafficManager::AzureRM::TrafficManagerProfile.parse(profile) }
  load(traffic_manager_profiles)
end

#check_traffic_manager_profile_exists(resource_group, traffic_manager_profile_name) ⇒ Object



21
22
23
# File 'lib/fog/azurerm/models/traffic_manager/traffic_manager_profiles.rb', line 21

def check_traffic_manager_profile_exists(resource_group, traffic_manager_profile_name)
  service.check_traffic_manager_profile_exists(resource_group, traffic_manager_profile_name)
end

#get(resource_group, traffic_manager_profile_name) ⇒ Object



15
16
17
18
19
# File 'lib/fog/azurerm/models/traffic_manager/traffic_manager_profiles.rb', line 15

def get(resource_group, traffic_manager_profile_name)
  profile = service.get_traffic_manager_profile(resource_group, traffic_manager_profile_name)
  profile_fog = Fog::TrafficManager::AzureRM::TrafficManagerProfile.new(service: service)
  profile_fog.merge_attributes(Fog::TrafficManager::AzureRM::TrafficManagerProfile.parse(profile))
end