Skip to content

Library API Improvements #17

@nloding

Description

@nloding

Problem

Several library API improvements could enhance usability:

  1. Batch operations: Add multiple games efficiently

    db.add_games(&[game1, game2, game3])?;
  2. Async support: For large database operations

    async fn get_game(&mut self, game_num: u32) -> Result<Game>;
  3. Streaming PGN writer: Avoid building entire output in memory

    fn write_pgn_to<W: Write>(&self, writer: &mut W) -> Result<()>;
  4. Game validation: Legal move verification before encoding

    game.validate()?; // Check moves are legal

Priority

Low - future enhancements

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or requesthelp wantedExtra attention is needed

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions