Implement the structures in Rust