cherry 0.2.0

A lightweight asynchronous ORM, which is build on top of SQLx.
1
2
3
4
5
6
7
8
9
10
11
12
13
use crate::types::{Arguments, Result, Row};

pub trait Cherry: Sized + Send + Unpin {

    fn table() -> &'static str;

    fn columns() -> Vec<&'static str>;

    fn arguments<'a>(&'a self, arguments: &mut Arguments<'a>);
    
    fn from_row(row: &Row) -> Result<Self>;

}