Enum tantivy::schema::Value
[−]
[src]
pub enum Value { Str(String), U64(u64), I64(i64), Facet(Facet), }
Value represents the value of a any field. It is an enum over all over all of the possible field type.
Variants
Str(String)
The str type is used for any text information.
U64(u64)
Unsigned 64-bits Integer u64
I64(i64)
Signed 64-bits Integer i64
Facet(Facet)
Hierarchical Facet
Methods
impl Value
[src]
pub fn text(&self) -> &str
[src]
Returns the text value, provided the value is of the Str
type.
Panics
If the value is not of type Str
pub fn u64_value(&self) -> u64
[src]
Returns the u64-value, provided the value is of the U64
type.
Panics
If the value is not of type U64
pub fn i64_value(&self) -> i64
[src]
Returns the i64-value, provided the value is of the I64
type.
Panics
If the value is not of type I64
Trait Implementations
impl Debug for Value
[src]
fn fmt(&self, __arg_0: &mut Formatter) -> Result
[src]
Formats the value using the given formatter. Read more
impl Clone for Value
[src]
fn clone(&self) -> Value
[src]
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0[src]
Performs copy-assignment from source
. Read more
impl Eq for Value
[src]
impl PartialEq for Value
[src]
fn eq(&self, __arg_0: &Value) -> bool
[src]
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, __arg_0: &Value) -> bool
[src]
This method tests for !=
.
impl Ord for Value
[src]
fn cmp(&self, __arg_0: &Value) -> Ordering
[src]
This method returns an Ordering
between self
and other
. Read more
fn max(self, other: Self) -> Self
1.21.0[src]
Compares and returns the maximum of two values. Read more
fn min(self, other: Self) -> Self
1.21.0[src]
Compares and returns the minimum of two values. Read more
impl PartialOrd for Value
[src]
fn partial_cmp(&self, __arg_0: &Value) -> Option<Ordering>
[src]
This method returns an ordering between self
and other
values if one exists. Read more
fn lt(&self, __arg_0: &Value) -> bool
[src]
This method tests less than (for self
and other
) and is used by the <
operator. Read more
fn le(&self, __arg_0: &Value) -> bool
[src]
This method tests less than or equal to (for self
and other
) and is used by the <=
operator. Read more
fn gt(&self, __arg_0: &Value) -> bool
[src]
This method tests greater than (for self
and other
) and is used by the >
operator. Read more
fn ge(&self, __arg_0: &Value) -> bool
[src]
This method tests greater than or equal to (for self
and other
) and is used by the >=
operator. Read more
impl Serialize for Value
[src]
fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error> where
S: Serializer,
[src]
S: Serializer,
Serialize this value into the given Serde serializer. Read more
impl<'de> Deserialize<'de> for Value
[src]
fn deserialize<D>(deserializer: D) -> Result<Self, D::Error> where
D: Deserializer<'de>,
[src]
D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more