Module: Google::Ads::AdManager::V1::AdUnitService::Paths
- Extended by:
- Paths
- Included in:
- Paths, Rest::Client
- Defined in:
- lib/google/ads/ad_manager/v1/ad_unit_service/paths.rb
Overview
Path helper methods for the AdUnitService API.
Instance Method Summary collapse
-
#ad_unit_path(network_code:, ad_unit:) ⇒ ::String
Create a fully-qualified AdUnit resource string.
-
#label_path(network_code:, label:) ⇒ ::String
Create a fully-qualified Label resource string.
-
#network_path(network_code:) ⇒ ::String
Create a fully-qualified Network resource string.
-
#team_path(network_code:, team:) ⇒ ::String
Create a fully-qualified Team resource string.
Instance Method Details
#ad_unit_path(network_code:, ad_unit:) ⇒ ::String
Create a fully-qualified AdUnit resource string.
The resource will be in the following format:
networks/{network_code}/adUnits/{ad_unit}
38 39 40 41 42 |
# File 'lib/google/ads/ad_manager/v1/ad_unit_service/paths.rb', line 38 def ad_unit_path network_code:, ad_unit: raise ::ArgumentError, "network_code cannot contain /" if network_code.to_s.include? "/" "networks/#{network_code}/adUnits/#{ad_unit}" end |
#label_path(network_code:, label:) ⇒ ::String
Create a fully-qualified Label resource string.
The resource will be in the following format:
networks/{network_code}/labels/{label}
55 56 57 58 59 |
# File 'lib/google/ads/ad_manager/v1/ad_unit_service/paths.rb', line 55 def label_path network_code:, label: raise ::ArgumentError, "network_code cannot contain /" if network_code.to_s.include? "/" "networks/#{network_code}/labels/#{label}" end |
#network_path(network_code:) ⇒ ::String
Create a fully-qualified Network resource string.
The resource will be in the following format:
networks/{network_code}
71 72 73 |
# File 'lib/google/ads/ad_manager/v1/ad_unit_service/paths.rb', line 71 def network_path network_code: "networks/#{network_code}" end |
#team_path(network_code:, team:) ⇒ ::String
Create a fully-qualified Team resource string.
The resource will be in the following format:
networks/{network_code}/teams/{team}
86 87 88 89 90 |
# File 'lib/google/ads/ad_manager/v1/ad_unit_service/paths.rb', line 86 def team_path network_code:, team: raise ::ArgumentError, "network_code cannot contain /" if network_code.to_s.include? "/" "networks/#{network_code}/teams/#{team}" end |