episko_derive 1.2.1

TBC: Project for University
Documentation

This crate contains the derive Macros for the [DatabaseObject] trait from [episko_lib].

Example

#[derive(DatabaseObject)]
#[db(table = "ExampleProperty")] // Required!
struct ExampleProperty {
    #[db(col = "id")] // Column with name "id" is required
    id: i32,
    #[db(col = "name")] // Any other columns are optional
    name: String,
    #[db(col = "version")]
    version: Option<String>
}

// Implementations for DatabaseObject will now be generated according
// to the specified attributes.