Add brute-force search
This commit is contained in:
parent
a345bf99c6
commit
ff378b1dd8
4 changed files with 135 additions and 31 deletions
|
|
@ -108,20 +108,44 @@ async fn main() -> Result<()> {
|
|||
// println!("{:?}", store);
|
||||
// println!("{:?}", store.read_all_bytes().await?);
|
||||
|
||||
let mut cursor = store.read_cursor().await.map_err(|e| e.to_io_or_panic())?;
|
||||
{
|
||||
let mut cursor = store.read_cursor().await.map_err(|e| e.to_io_or_panic())?;
|
||||
cursor.read_entries().await.map_err(|e| e.to_io_or_panic())?;
|
||||
// let x = cursor.next().await.map_err(|e| e.to_io_or_panic())?;
|
||||
// println!("{:?}", x);
|
||||
// let x = cursor.next().await.map_err(|e| e.to_io_or_panic())?;
|
||||
// println!("{:?}", x);
|
||||
// let x = cursor.next().await.map_err(|e| e.to_io_or_panic())?;
|
||||
// println!("{:?}", x);
|
||||
// let x = cursor.next().await.map_err(|e| e.to_io_or_panic())?;
|
||||
// println!("{:?}", x);
|
||||
// let x = cursor.next().await.map_err(|e| e.to_io_or_panic())?;
|
||||
// println!("{:?}", x);
|
||||
}
|
||||
|
||||
// let x = cursor.next().await.map_err(|e| e.to_io_or_panic())?;
|
||||
// println!("{:?}", x);
|
||||
// let x = cursor.next().await.map_err(|e| e.to_io_or_panic())?;
|
||||
// println!("{:?}", x);
|
||||
// let x = cursor.next().await.map_err(|e| e.to_io_or_panic())?;
|
||||
// println!("{:?}", x);
|
||||
// let x = cursor.next().await.map_err(|e| e.to_io_or_panic())?;
|
||||
// println!("{:?}", x);
|
||||
// let x = cursor.next().await.map_err(|e| e.to_io_or_panic())?;
|
||||
// println!("{:?}", x);
|
||||
{
|
||||
let mut cursor = store.read_cursor().await.map_err(|e| e.to_io_or_panic())?;
|
||||
let column = 2;
|
||||
let x = cursor.next_at_column(column).await.map_err(|e| e.to_io_or_panic())?;
|
||||
println!("{:?}", x);
|
||||
let x = cursor.next_at_column(column).await.map_err(|e| e.to_io_or_panic())?;
|
||||
println!("{:?}", x);
|
||||
let x = cursor.next_at_column(column).await.map_err(|e| e.to_io_or_panic())?;
|
||||
println!("{:?}", x);
|
||||
let x = cursor.next_at_column(column).await.map_err(|e| e.to_io_or_panic())?;
|
||||
println!("{:?}", x);
|
||||
let x = cursor.next_at_column(column).await.map_err(|e| e.to_io_or_panic())?;
|
||||
println!("{:?}", x);
|
||||
}
|
||||
|
||||
{
|
||||
let mut cursor = store.read_cursor().await.map_err(|e| e.to_io_or_panic())?;
|
||||
let column = 3;
|
||||
let t0 = 6;
|
||||
let x = cursor.find_first_eq_bruteforce(column, &t0).await.map_err(|e| e.to_io_or_panic())?;
|
||||
println!("{:?}", x);
|
||||
}
|
||||
|
||||
cursor.read_entries().await.map_err(|e| e.to_io_or_panic())?;
|
||||
|
||||
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue