[][src]Struct prost_types::Method

pub struct Method {
    pub name: String,
    pub request_type_url: String,
    pub request_streaming: bool,
    pub response_type_url: String,
    pub response_streaming: bool,
    pub options: Vec<Option>,
    pub syntax: i32,
}

Method represents a method of an API interface.

Fields

name: String

The simple name of this method.

request_type_url: String

A URL of the input message type.

request_streaming: bool

If true, the request is streamed.

response_type_url: String

The URL of the output message type.

response_streaming: bool

If true, the response is streamed.

options: Vec<Option>

Any metadata attached to the method.

syntax: i32

The source syntax of this method.

Implementations

impl Method[src]

pub fn syntax(&self) -> Syntax[src]

Returns the enum value of syntax, or the default if the field is set to an invalid enum value.

pub fn set_syntax(&mut self, value: Syntax)[src]

Sets syntax to the provided enum value.

Trait Implementations

impl Clone for Method[src]

impl Debug for Method[src]

impl Default for Method[src]

impl Message for Method[src]

impl PartialEq<Method> for Method[src]

impl StructuralPartialEq for Method[src]

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

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

The type returned in the event of a conversion error.