pub struct RestMethod {
Show 15 fields pub scopes: Option<Vec<String>>, pub description: Option<String>, pub parameters: Option<HashMap<String, JsonSchema>>, pub supports_media_upload: Option<bool>, pub etag_required: Option<bool>, pub media_upload: Option<RestMethodMediaUpload>, pub request: Option<RestMethodRequest>, pub use_media_download_service: Option<bool>, pub http_method: Option<String>, pub supports_subscription: Option<bool>, pub parameter_order: Option<Vec<String>>, pub id: Option<String>, pub path: Option<String>, pub response: Option<RestMethodResponse>, pub supports_media_download: Option<bool>,
}
Expand description

There is no detailed description.

This type is not used in any activity, and only used as part of another schema.

Fields§

§scopes: Option<Vec<String>>

OAuth 2.0 scopes applicable to this method.

§description: Option<String>

Description of this method.

§parameters: Option<HashMap<String, JsonSchema>>

Details for all parameters in this method.

§supports_media_upload: Option<bool>

Whether this method supports media uploads.

§etag_required: Option<bool>

Whether this method requires an ETag to be specified. The ETag is sent as an HTTP If-Match or If-None-Match header.

§media_upload: Option<RestMethodMediaUpload>

Media upload parameters.

§request: Option<RestMethodRequest>

The schema for the request.

§use_media_download_service: Option<bool>

Indicates that downloads from this method should use the download service URL (i.e. “/download”). Only applies if the method supports media download.

§http_method: Option<String>

HTTP method used by this method.

§supports_subscription: Option<bool>

Whether this method supports subscriptions.

§parameter_order: Option<Vec<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.

§id: Option<String>

A unique ID for this method. This property can be used to match methods between different versions of Discovery.

§path: Option<String>

The URI path of this REST method. Should be used in conjunction with the basePath property at the api-level.

§response: Option<RestMethodResponse>

The schema for the response.

§supports_media_download: Option<bool>

Whether this method supports media downloads.

Trait Implementations§

source§

impl Clone for RestMethod

source§

fn clone(&self) -> RestMethod

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for RestMethod

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Default for RestMethod

source§

fn default() -> RestMethod

Returns the “default value” for a type. Read more
source§

impl<'de> Deserialize<'de> for RestMethod

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Serialize for RestMethod

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl Part for RestMethod

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for Twhere T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for Twhere T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for Twhere T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

impl<T, U> Into<U> for Twhere U: From<T>,

source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

source§

impl<T> ToOwned for Twhere T: Clone,

§

type Owned = T

The resulting type after obtaining ownership.
source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
source§

impl<T, U> TryFrom<U> for Twhere U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T, U> TryInto<U> for Twhere U: TryFrom<T>,

§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
§

impl<T> Typeable for Twhere T: Any,

§

fn get_type(&self) -> TypeId

Get the TypeId of this object.
source§

impl<T> DeserializeOwned for Twhere T: for<'de> Deserialize<'de>,