Rust Entity Framework (lref)
An EFCore-inspired ORM for Rust, bringing the familiar DbContext/DbSet/EntityType patterns to the Rust ecosystem.
Example
use *;
An EFCore-inspired ORM for Rust, bringing the familiar DbContext/DbSet/EntityType patterns to the Rust ecosystem.
use lref::prelude::*;
#[derive(EntityType)]
#[table("blogs")]
pub struct Blog {
#[primary_key]
#[auto_increment]
pub blog_id: i32,
#[required]
#[max_length(200)]
pub url: String,
pub rating: i32,
#[navigation]
pub posts: HasMany<Post>,
}