Enum cataclysm::http::Method [−][src]
pub enum Method {
Get,
Post,
Put,
Head,
Delete,
Patch,
Options,
}
Expand description
Available methods for HTTP Requests
Variants
Get method
Post method
Put method
Head method
Delete method
Patch method
Options method
Implementations
Turns the Method into a MethodHandler, which is a short for a tuple Method - Handler
Casts a method from a string.
assert_eq!(Some(Method::Get), Method::from_str("GET"));
Retrieves the str
representation of a method (all caps).
assert_eq!("GET", Method::Get.to_str());
Makes a MultipleMethod
In case you want a function to reply to more than one method, you can put as many as you want with the and
method.
let mul = Method::Get.and(Method::Post);
Trait Implementations
Auto Trait Implementations
impl RefUnwindSafe for Method
impl UnwindSafe for Method
Blanket Implementations
Mutably borrows from an owned value. Read more