Sha256: 3c1c76c87cc27a6d6f8d04c9904d4b0e001a97d00ca4b619f13109300e0f3c31

Contents?: true

Size: 1.83 KB

Versions: 53

Compression:

Stored size: 1.83 KB

Contents

# frozen_string_literal: true

# Copyright 2020 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
#     https://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

# Auto-generated by gapic-generator-ruby. DO NOT EDIT!


module Google
  module Cloud
    module PubSub
      module V1
        module SchemaService
          # Path helper methods for the SchemaService API.
          module Paths
            ##
            # Create a fully-qualified Project resource string.
            #
            # The resource will be in the following format:
            #
            # `projects/{project}`
            #
            # @param project [String]
            #
            # @return [::String]
            def project_path project:
              "projects/#{project}"
            end

            ##
            # Create a fully-qualified Schema resource string.
            #
            # The resource will be in the following format:
            #
            # `projects/{project}/schemas/{schema}`
            #
            # @param project [String]
            # @param schema [String]
            #
            # @return [::String]
            def schema_path project:, schema:
              raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/"

              "projects/#{project}/schemas/#{schema}"
            end

            extend self
          end
        end
      end
    end
  end
end

Version data entries

53 entries across 53 versions & 1 rubygems

Version Path
google-cloud-pubsub-v1-1.7.0 lib/google/cloud/pubsub/v1/schema_service/paths.rb
google-cloud-pubsub-v1-1.6.0 lib/google/cloud/pubsub/v1/schema_service/paths.rb
google-cloud-pubsub-v1-1.5.0 lib/google/cloud/pubsub/v1/schema_service/paths.rb
google-cloud-pubsub-v1-1.4.0 lib/google/cloud/pubsub/v1/schema_service/paths.rb
google-cloud-pubsub-v1-1.3.0 lib/google/cloud/pubsub/v1/schema_service/paths.rb
google-cloud-pubsub-v1-1.2.0 lib/google/cloud/pubsub/v1/schema_service/paths.rb
google-cloud-pubsub-v1-1.1.2 lib/google/cloud/pubsub/v1/schema_service/paths.rb
google-cloud-pubsub-v1-1.1.1 lib/google/cloud/pubsub/v1/schema_service/paths.rb
google-cloud-pubsub-v1-1.1.0 lib/google/cloud/pubsub/v1/schema_service/paths.rb
google-cloud-pubsub-v1-1.0.0 lib/google/cloud/pubsub/v1/schema_service/paths.rb
google-cloud-pubsub-v1-0.25.0 lib/google/cloud/pubsub/v1/schema_service/paths.rb
google-cloud-pubsub-v1-0.24.0 lib/google/cloud/pubsub/v1/schema_service/paths.rb
google-cloud-pubsub-v1-0.23.0 lib/google/cloud/pubsub/v1/schema_service/paths.rb
google-cloud-pubsub-v1-0.22.0 lib/google/cloud/pubsub/v1/schema_service/paths.rb
google-cloud-pubsub-v1-0.21.2 lib/google/cloud/pubsub/v1/schema_service/paths.rb
google-cloud-pubsub-v1-0.21.1 lib/google/cloud/pubsub/v1/schema_service/paths.rb
google-cloud-pubsub-v1-0.21.0 lib/google/cloud/pubsub/v1/schema_service/paths.rb
google-cloud-pubsub-v1-0.20.2 lib/google/cloud/pubsub/v1/schema_service/paths.rb
google-cloud-pubsub-v1-0.20.1 lib/google/cloud/pubsub/v1/schema_service/paths.rb
google-cloud-pubsub-v1-0.20.0 lib/google/cloud/pubsub/v1/schema_service/paths.rb