mirror of
https://github.com/fluencelabs/sqlite-wasm-connector
synced 2025-03-31 05:21:07 +00:00
Add kind to Value
This commit is contained in:
parent
f2e6ac7e03
commit
d88c091c50
11
src/lib.rs
11
src/lib.rs
@ -233,6 +233,17 @@ impl Value {
|
|||||||
}
|
}
|
||||||
None
|
None
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// Return the type.
|
||||||
|
pub fn kind(&self) -> Type {
|
||||||
|
match self {
|
||||||
|
&Value::Binary(_) => Type::Binary,
|
||||||
|
&Value::Float(_) => Type::Float,
|
||||||
|
&Value::Integer(_) => Type::Integer,
|
||||||
|
&Value::String(_) => Type::String,
|
||||||
|
&Value::Null => Type::Null,
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
mod connection;
|
mod connection;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user