Class: Google::Apis::DiscoveryV1::RestMethod
- Inherits:
-
Object
- Object
- Google::Apis::DiscoveryV1::RestMethod
- Includes:
- Core::Hashable, Core::JsonObjectSupport
- Defined in:
- lib/google/apis/discovery_v1/classes.rb,
lib/google/apis/discovery_v1/representations.rb,
lib/google/apis/discovery_v1/representations.rb
Defined Under Namespace
Classes: MediaUpload, Request, Response
Instance Attribute Summary collapse
-
#api_version ⇒ String
The API Version of this method, as passed in via the
X-Goog-Api-Version
header or$apiVersion
query parameter. -
#deprecated ⇒ Boolean
(also: #deprecated?)
Whether this method is deprecated.
-
#description ⇒ String
Description of this method.
-
#etag_required ⇒ Boolean
(also: #etag_required?)
Whether this method requires an ETag to be specified.
-
#flat_path ⇒ String
The URI path of this REST method in (RFC 6570) format without level 2 features (
+var
). -
#http_method ⇒ String
HTTP method used by this method.
-
#id ⇒ String
A unique ID for this method.
-
#media_upload ⇒ Google::Apis::DiscoveryV1::RestMethod::MediaUpload
Media upload parameters.
-
#parameter_order ⇒ Array<String>
Ordered list of required parameters, serves as a hint to clients on how to structure their method signatures.
-
#parameters ⇒ Hash<String,Google::Apis::DiscoveryV1::JsonSchema>
Details for all parameters in this method.
-
#path ⇒ String
The URI path of this REST method.
-
#request ⇒ Google::Apis::DiscoveryV1::RestMethod::Request
The schema for the request.
-
#response ⇒ Google::Apis::DiscoveryV1::RestMethod::Response
The schema for the response.
-
#scopes ⇒ Array<String>
OAuth 2.0 scopes applicable to this method.
-
#supports_media_download ⇒ Boolean
(also: #supports_media_download?)
Whether this method supports media downloads.
-
#supports_media_upload ⇒ Boolean
(also: #supports_media_upload?)
Whether this method supports media uploads.
-
#supports_subscription ⇒ Boolean
(also: #supports_subscription?)
Whether this method supports subscriptions.
-
#use_media_download_service ⇒ Boolean
(also: #use_media_download_service?)
Indicates that downloads from this method should use the download service URL ( i.e. "/download").
Instance Method Summary collapse
-
#initialize(**args) ⇒ RestMethod
constructor
A new instance of RestMethod.
-
#update!(**args) ⇒ Object
Update properties of this object.
Constructor Details
#initialize(**args) ⇒ RestMethod
Returns a new instance of RestMethod.
834 835 836 |
# File 'lib/google/apis/discovery_v1/classes.rb', line 834 def initialize(**args) update!(**args) end |
Instance Attribute Details
#api_version ⇒ String
The API Version of this method, as passed in via the X-Goog-Api-Version
header or $apiVersion
query parameter.
Corresponds to the JSON property apiVersion
734 735 736 |
# File 'lib/google/apis/discovery_v1/classes.rb', line 734 def api_version @api_version end |
#deprecated ⇒ Boolean Also known as: deprecated?
Whether this method is deprecated.
Corresponds to the JSON property deprecated
739 740 741 |
# File 'lib/google/apis/discovery_v1/classes.rb', line 739 def deprecated @deprecated end |
#description ⇒ String
Description of this method.
Corresponds to the JSON property description
745 746 747 |
# File 'lib/google/apis/discovery_v1/classes.rb', line 745 def description @description end |
#etag_required ⇒ Boolean Also known as: etag_required?
Whether this method requires an ETag to be specified. The ETag is sent as an
HTTP If-Match or If-None-Match header.
Corresponds to the JSON property etagRequired
751 752 753 |
# File 'lib/google/apis/discovery_v1/classes.rb', line 751 def etag_required @etag_required end |
#flat_path ⇒ String
The URI path of this REST method in (RFC 6570) format without level 2 features
(+var
). Supplementary to the path property.
Corresponds to the JSON property flatPath
758 759 760 |
# File 'lib/google/apis/discovery_v1/classes.rb', line 758 def flat_path @flat_path end |
#http_method ⇒ String
HTTP method used by this method.
Corresponds to the JSON property httpMethod
763 764 765 |
# File 'lib/google/apis/discovery_v1/classes.rb', line 763 def http_method @http_method end |
#id ⇒ String
A unique ID for this method. This property can be used to match methods
between different versions of Discovery.
Corresponds to the JSON property id
769 770 771 |
# File 'lib/google/apis/discovery_v1/classes.rb', line 769 def id @id end |
#media_upload ⇒ Google::Apis::DiscoveryV1::RestMethod::MediaUpload
Media upload parameters.
Corresponds to the JSON property mediaUpload
774 775 776 |
# File 'lib/google/apis/discovery_v1/classes.rb', line 774 def media_upload @media_upload end |
#parameter_order ⇒ Array<String>
Ordered list of required parameters, serves as a hint to clients on how to
structure their method signatures. The array is ordered such that the "most-
significant" parameter appears first.
Corresponds to the JSON property parameterOrder
781 782 783 |
# File 'lib/google/apis/discovery_v1/classes.rb', line 781 def parameter_order @parameter_order end |
#parameters ⇒ Hash<String,Google::Apis::DiscoveryV1::JsonSchema>
Details for all parameters in this method.
Corresponds to the JSON property parameters
786 787 788 |
# File 'lib/google/apis/discovery_v1/classes.rb', line 786 def parameters @parameters end |
#path ⇒ String
The URI path of this REST method. Should be used in conjunction with the
basePath property at the api-level.
Corresponds to the JSON property path
792 793 794 |
# File 'lib/google/apis/discovery_v1/classes.rb', line 792 def path @path end |
#request ⇒ Google::Apis::DiscoveryV1::RestMethod::Request
The schema for the request.
Corresponds to the JSON property request
797 798 799 |
# File 'lib/google/apis/discovery_v1/classes.rb', line 797 def request @request end |
#response ⇒ Google::Apis::DiscoveryV1::RestMethod::Response
The schema for the response.
Corresponds to the JSON property response
802 803 804 |
# File 'lib/google/apis/discovery_v1/classes.rb', line 802 def response @response end |
#scopes ⇒ Array<String>
OAuth 2.0 scopes applicable to this method.
Corresponds to the JSON property scopes
807 808 809 |
# File 'lib/google/apis/discovery_v1/classes.rb', line 807 def scopes @scopes end |
#supports_media_download ⇒ Boolean Also known as: supports_media_download?
Whether this method supports media downloads.
Corresponds to the JSON property supportsMediaDownload
812 813 814 |
# File 'lib/google/apis/discovery_v1/classes.rb', line 812 def supports_media_download @supports_media_download end |
#supports_media_upload ⇒ Boolean Also known as: supports_media_upload?
Whether this method supports media uploads.
Corresponds to the JSON property supportsMediaUpload
818 819 820 |
# File 'lib/google/apis/discovery_v1/classes.rb', line 818 def supports_media_upload @supports_media_upload end |
#supports_subscription ⇒ Boolean Also known as: supports_subscription?
Whether this method supports subscriptions.
Corresponds to the JSON property supportsSubscription
824 825 826 |
# File 'lib/google/apis/discovery_v1/classes.rb', line 824 def supports_subscription @supports_subscription end |
#use_media_download_service ⇒ Boolean Also known as: use_media_download_service?
Indicates that downloads from this method should use the download service URL (
i.e. "/download"). Only applies if the method supports media download.
Corresponds to the JSON property useMediaDownloadService
831 832 833 |
# File 'lib/google/apis/discovery_v1/classes.rb', line 831 def use_media_download_service @use_media_download_service end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
839 840 841 842 843 844 845 846 847 848 849 850 851 852 853 854 855 856 857 858 |
# File 'lib/google/apis/discovery_v1/classes.rb', line 839 def update!(**args) @api_version = args[:api_version] if args.key?(:api_version) @deprecated = args[:deprecated] if args.key?(:deprecated) @description = args[:description] if args.key?(:description) @etag_required = args[:etag_required] if args.key?(:etag_required) @flat_path = args[:flat_path] if args.key?(:flat_path) @http_method = args[:http_method] if args.key?(:http_method) @id = args[:id] if args.key?(:id) @media_upload = args[:media_upload] if args.key?(:media_upload) @parameter_order = args[:parameter_order] if args.key?(:parameter_order) @parameters = args[:parameters] if args.key?(:parameters) @path = args[:path] if args.key?(:path) @request = args[:request] if args.key?(:request) @response = args[:response] if args.key?(:response) @scopes = args[:scopes] if args.key?(:scopes) @supports_media_download = args[:supports_media_download] if args.key?(:supports_media_download) @supports_media_upload = args[:supports_media_upload] if args.key?(:supports_media_upload) @supports_subscription = args[:supports_subscription] if args.key?(:supports_subscription) @use_media_download_service = args[:use_media_download_service] if args.key?(:use_media_download_service) end |