mirror of
https://github.com/fluencelabs/sqlite-wasm-connector
synced 2025-03-15 06:20:50 +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
|
||||
}
|
||||
|
||||
/// 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;
|
||||
|
Loading…
x
Reference in New Issue
Block a user