@@ -354,6 +354,86 @@ def stop_channel request_pb, options = nil
354354 end
355355 end
356356
357+ ##
358+ # Baseline implementation for the start_distribution REST call
359+ #
360+ # @param request_pb [::Google::Cloud::Video::LiveStream::V1::StartDistributionRequest]
361+ # A request object representing the call parameters. Required.
362+ # @param options [::Gapic::CallOptions]
363+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
364+ #
365+ # @yield [result, operation] Access the result along with the TransportOperation object
366+ # @yieldparam result [::Google::Longrunning::Operation]
367+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
368+ #
369+ # @return [::Google::Longrunning::Operation]
370+ # A result object deserialized from the server's reply
371+ def start_distribution request_pb , options = nil
372+ raise ::ArgumentError , "request must be provided" if request_pb . nil?
373+
374+ verb , uri , query_string_params , body = ServiceStub . transcode_start_distribution_request request_pb
375+ query_string_params = if query_string_params . any?
376+ query_string_params . to_h { |p | p . split "=" , 2 }
377+ else
378+ { }
379+ end
380+
381+ response = @client_stub . make_http_request (
382+ verb ,
383+ uri : uri ,
384+ body : body || "" ,
385+ params : query_string_params ,
386+ method_name : "start_distribution" ,
387+ options : options
388+ )
389+ operation = ::Gapic ::Rest ::TransportOperation . new response
390+ result = ::Google ::Longrunning ::Operation . decode_json response . body , ignore_unknown_fields : true
391+ catch :response do
392+ yield result , operation if block_given?
393+ result
394+ end
395+ end
396+
397+ ##
398+ # Baseline implementation for the stop_distribution REST call
399+ #
400+ # @param request_pb [::Google::Cloud::Video::LiveStream::V1::StopDistributionRequest]
401+ # A request object representing the call parameters. Required.
402+ # @param options [::Gapic::CallOptions]
403+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
404+ #
405+ # @yield [result, operation] Access the result along with the TransportOperation object
406+ # @yieldparam result [::Google::Longrunning::Operation]
407+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
408+ #
409+ # @return [::Google::Longrunning::Operation]
410+ # A result object deserialized from the server's reply
411+ def stop_distribution request_pb , options = nil
412+ raise ::ArgumentError , "request must be provided" if request_pb . nil?
413+
414+ verb , uri , query_string_params , body = ServiceStub . transcode_stop_distribution_request request_pb
415+ query_string_params = if query_string_params . any?
416+ query_string_params . to_h { |p | p . split "=" , 2 }
417+ else
418+ { }
419+ end
420+
421+ response = @client_stub . make_http_request (
422+ verb ,
423+ uri : uri ,
424+ body : body || "" ,
425+ params : query_string_params ,
426+ method_name : "stop_distribution" ,
427+ options : options
428+ )
429+ operation = ::Gapic ::Rest ::TransportOperation . new response
430+ result = ::Google ::Longrunning ::Operation . decode_json response . body , ignore_unknown_fields : true
431+ catch :response do
432+ yield result , operation if block_given?
433+ result
434+ end
435+ end
436+
357437 ##
358438 # Baseline implementation for the create_input REST call
359439 #
@@ -554,6 +634,46 @@ def update_input request_pb, options = nil
554634 end
555635 end
556636
637+ ##
638+ # Baseline implementation for the preview_input REST call
639+ #
640+ # @param request_pb [::Google::Cloud::Video::LiveStream::V1::PreviewInputRequest]
641+ # A request object representing the call parameters. Required.
642+ # @param options [::Gapic::CallOptions]
643+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
644+ #
645+ # @yield [result, operation] Access the result along with the TransportOperation object
646+ # @yieldparam result [::Google::Cloud::Video::LiveStream::V1::PreviewInputResponse]
647+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
648+ #
649+ # @return [::Google::Cloud::Video::LiveStream::V1::PreviewInputResponse]
650+ # A result object deserialized from the server's reply
651+ def preview_input request_pb , options = nil
652+ raise ::ArgumentError , "request must be provided" if request_pb . nil?
653+
654+ verb , uri , query_string_params , body = ServiceStub . transcode_preview_input_request request_pb
655+ query_string_params = if query_string_params . any?
656+ query_string_params . to_h { |p | p . split "=" , 2 }
657+ else
658+ { }
659+ end
660+
661+ response = @client_stub . make_http_request (
662+ verb ,
663+ uri : uri ,
664+ body : body || "" ,
665+ params : query_string_params ,
666+ method_name : "preview_input" ,
667+ options : options
668+ )
669+ operation = ::Gapic ::Rest ::TransportOperation . new response
670+ result = ::Google ::Cloud ::Video ::LiveStream ::V1 ::PreviewInputResponse . decode_json response . body , ignore_unknown_fields : true
671+ catch :response do
672+ yield result , operation if block_given?
673+ result
674+ end
675+ end
676+
557677 ##
558678 # Baseline implementation for the create_event REST call
559679 #
@@ -1465,6 +1585,50 @@ def self.transcode_stop_channel_request request_pb
14651585 transcoder . transcode request_pb
14661586 end
14671587
1588+ ##
1589+ # @private
1590+ #
1591+ # GRPC transcoding helper method for the start_distribution REST call
1592+ #
1593+ # @param request_pb [::Google::Cloud::Video::LiveStream::V1::StartDistributionRequest]
1594+ # A request object representing the call parameters. Required.
1595+ # @return [Array(String, [String, nil], Hash{String => String})]
1596+ # Uri, Body, Query string parameters
1597+ def self . transcode_start_distribution_request request_pb
1598+ transcoder = Gapic ::Rest ::GrpcTranscoder . new
1599+ . with_bindings (
1600+ uri_method : :post ,
1601+ uri_template : "/v1/{name}:startdistribution" ,
1602+ body : "*" ,
1603+ matches : [
1604+ [ "name" , %r{^projects/[^/]+/locations/[^/]+/channels/[^/]+/?$} , false ]
1605+ ]
1606+ )
1607+ transcoder . transcode request_pb
1608+ end
1609+
1610+ ##
1611+ # @private
1612+ #
1613+ # GRPC transcoding helper method for the stop_distribution REST call
1614+ #
1615+ # @param request_pb [::Google::Cloud::Video::LiveStream::V1::StopDistributionRequest]
1616+ # A request object representing the call parameters. Required.
1617+ # @return [Array(String, [String, nil], Hash{String => String})]
1618+ # Uri, Body, Query string parameters
1619+ def self . transcode_stop_distribution_request request_pb
1620+ transcoder = Gapic ::Rest ::GrpcTranscoder . new
1621+ . with_bindings (
1622+ uri_method : :post ,
1623+ uri_template : "/v1/{name}:stopdistribution" ,
1624+ body : "*" ,
1625+ matches : [
1626+ [ "name" , %r{^projects/[^/]+/locations/[^/]+/channels/[^/]+/?$} , false ]
1627+ ]
1628+ )
1629+ transcoder . transcode request_pb
1630+ end
1631+
14681632 ##
14691633 # @private
14701634 #
@@ -1572,6 +1736,28 @@ def self.transcode_update_input_request request_pb
15721736 transcoder . transcode request_pb
15731737 end
15741738
1739+ ##
1740+ # @private
1741+ #
1742+ # GRPC transcoding helper method for the preview_input REST call
1743+ #
1744+ # @param request_pb [::Google::Cloud::Video::LiveStream::V1::PreviewInputRequest]
1745+ # A request object representing the call parameters. Required.
1746+ # @return [Array(String, [String, nil], Hash{String => String})]
1747+ # Uri, Body, Query string parameters
1748+ def self . transcode_preview_input_request request_pb
1749+ transcoder = Gapic ::Rest ::GrpcTranscoder . new
1750+ . with_bindings (
1751+ uri_method : :post ,
1752+ uri_template : "/v1/{name}:preview" ,
1753+ body : "*" ,
1754+ matches : [
1755+ [ "name" , %r{^projects/[^/]+/locations/[^/]+/inputs/[^/]+/?$} , false ]
1756+ ]
1757+ )
1758+ transcoder . transcode request_pb
1759+ end
1760+
15751761 ##
15761762 # @private
15771763 #
0 commit comments