auto-builder

Crates.ioauto-builder
lib.rsauto-builder
version0.2.0
sourcesrc
created_at2024-01-20 16:27:05.267187
updated_at2024-01-21 22:17:54.508051
descriptionA derive macro to implement the builder pattern for any struct
homepage
repositoryhttps://github.com/hollg/auto-builder
max_upload_size
id1106591
size3,754
Gary Holland (hollg)

documentation

https://github.com/hollg/auto-builder

README

auto-builder

This crate provides a derive macro that implements the builder pattern for any struct.

#[derive(Builder)]
struct Foo {           
    a: i32,
    b: Option<i32>,
 }

let foo = FooBuilder::new().a(1).b(Some(2)).build();
assert!(foo.is_ok());

Commit count: 0

cargo fmt