Enum params::Value
[−]
[src]
pub enum Value { Null, Boolean(bool), I64(i64), U64(u64), F64(f64), String(String), File(File), Array(Vec<Value>), Map(Map), }
A representation of all possible types of request parameters.
Variants
Null
A null
from the request's JSON body.
Boolean(bool)
A true
or false
from the request's JSON body.
I64(i64)
A signed integer from the request's JSON body.
U64(u64)
An unsigned integer from the request's JSON body.
F64(f64)
A floating point number from the request's JSON body.
String(String)
Either a string from the request's JSON body or a plain text value from the request's URL
(GET) parameters, application/x-www-form-urlencoded
parameters, or multipart/form-data
parameters.
File(File)
A temporary file processed from a multipart/form-data
request.
Array(Vec<Value>)
Either an array of JSON values or an amalgamation of URL (GET) parameters,
application/x-www-form-urlencoded
parameters, or multipart/form-data
parameters. Such
parameters should be in the form my_list[]=1&my_list[]=2
to be processed into this
variant.
Map(Map)
Either an object of JSON keys and values or an amalgamation of URL (GET) parameters,
application/x-www-form-urlencoded
parameters, or multipart/form-data
parameters. Such
parameters should be in the form my_map[x]=1&my_map[y]=2
to be processed into this
variant.
Trait Implementations
impl FromValue for Value
[src]
fn from_value(value: &Value) -> Option<Self>
Returns Some
if the conversion was successful, None
otherwise.
impl PartialEq for Value
[src]
fn eq(&self, __arg_0: &Value) -> bool
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, __arg_0: &Value) -> bool
This method tests for !=
.
impl Clone for Value
[src]
fn clone(&self) -> Value
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0
Performs copy-assignment from source
. Read more