Module: Google::Cloud::AIPlatform::V1::FeatureRegistryService::Paths
- Extended by:
- Paths
- Included in:
- Client, Paths, Rest::Client
- Defined in:
- lib/google/cloud/ai_platform/v1/feature_registry_service/paths.rb
Overview
Path helper methods for the FeatureRegistryService API.
Instance Method Summary collapse
-
#entity_type_path(project:, location:, featurestore:, entity_type:) ⇒ ::String
Create a fully-qualified EntityType resource string.
-
#feature_group_path(project:, location:, feature_group:) ⇒ ::String
Create a fully-qualified FeatureGroup resource string.
-
#feature_path(**args) ⇒ ::String
Create a fully-qualified Feature resource string.
-
#location_path(project:, location:) ⇒ ::String
Create a fully-qualified Location resource string.
Instance Method Details
#entity_type_path(project:, location:, featurestore:, entity_type:) ⇒ ::String
Create a fully-qualified EntityType resource string.
The resource will be in the following format:
projects/{project}/locations/{location}/featurestores/{featurestore}/entityTypes/{entity_type}
40 41 42 43 44 45 46 |
# File 'lib/google/cloud/ai_platform/v1/feature_registry_service/paths.rb', line 40 def entity_type_path project:, location:, featurestore:, entity_type: raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/" raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/" raise ::ArgumentError, "featurestore cannot contain /" if featurestore.to_s.include? "/" "projects/#{project}/locations/#{location}/featurestores/#{featurestore}/entityTypes/#{entity_type}" end |
#feature_group_path(project:, location:, feature_group:) ⇒ ::String
Create a fully-qualified FeatureGroup resource string.
The resource will be in the following format:
projects/{project}/locations/{location}/featureGroups/{feature_group}
109 110 111 112 113 114 |
# File 'lib/google/cloud/ai_platform/v1/feature_registry_service/paths.rb', line 109 def feature_group_path project:, location:, feature_group: raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/" raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/" "projects/#{project}/locations/#{location}/featureGroups/#{feature_group}" end |
#feature_path(project: , location: , featurestore: , entity_type: , feature: ) ⇒ ::String #feature_path(project: , location: , feature_group: , feature: ) ⇒ ::String
Create a fully-qualified Feature resource string.
73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 |
# File 'lib/google/cloud/ai_platform/v1/feature_registry_service/paths.rb', line 73 def feature_path **args resources = { "entity_type:feature:featurestore:location:project" => (proc do |project:, location:, featurestore:, entity_type:, feature:| raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/" raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/" raise ::ArgumentError, "featurestore cannot contain /" if featurestore.to_s.include? "/" raise ::ArgumentError, "entity_type cannot contain /" if entity_type.to_s.include? "/" "projects/#{project}/locations/#{location}/featurestores/#{featurestore}/entityTypes/#{entity_type}/features/#{feature}" end), "feature:feature_group:location:project" => (proc do |project:, location:, feature_group:, feature:| raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/" raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/" raise ::ArgumentError, "feature_group cannot contain /" if feature_group.to_s.include? "/" "projects/#{project}/locations/#{location}/featureGroups/#{feature_group}/features/#{feature}" end) } resource = resources[args.keys.sort.join(":")] raise ::ArgumentError, "no resource found for values #{args.keys}" if resource.nil? resource.call(**args) end |
#location_path(project:, location:) ⇒ ::String
Create a fully-qualified Location resource string.
The resource will be in the following format:
projects/{project}/locations/{location}
127 128 129 130 131 |
# File 'lib/google/cloud/ai_platform/v1/feature_registry_service/paths.rb', line 127 def location_path project:, location: raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/" "projects/#{project}/locations/#{location}" end |