Anki/rslib/src/prelude.rs
RumovZ 20bd207f00 Give deck.name the newtype NativeDeckName
The deck name must be constructed by calling associated functions of
NativeDeckName, unless the name is guaranteed to be valid machine
name (like "Default").
NativeDeckName exposes methods to mutate the deck name and return
the human name.
The storage routines take &strs, but those should be slices of
NativeDeckNames to ensure machine form and normalization.
2021-04-17 22:47:04 +02:00

20 lines
628 B
Rust

// Copyright: Ankitects Pty Ltd and contributors
// License: GNU AGPL, version 3 or later; http://www.gnu.org/licenses/agpl.html
pub(crate) use crate::types::IntoNewtypeVec;
pub use crate::{
card::{Card, CardId},
collection::Collection,
config::BoolKey,
deckconf::{DeckConf, DeckConfId},
decks::{Deck, DeckId, DeckKind, NativeDeckName},
error::{AnkiError, Result},
i18n::I18n,
notes::{Note, NoteId},
notetype::{Notetype, NotetypeId},
ops::{Op, OpChanges, OpOutput},
revlog::RevlogId,
timestamp::{TimestampMillis, TimestampSecs},
types::Usn,
};
pub use slog::{debug, Logger};