tf2-enum

Crates.iotf2-enum
lib.rstf2-enum
version0.9.3
sourcesrc
created_at2022-02-12 15:28:32.971748
updated_at2024-05-19 03:47:06.469446
descriptionProvides enumerated types for models related to the Team Fortress 2 item schema.
homepagehttps://github.com/juliarose/tf2-enum
repositoryhttps://github.com/juliarose/tf2-enum
max_upload_size
id531370
size55,651
Julia (juliarose)

documentation

README

tf2-enum

Provides enumerated types for models related to the Team Fortress 2 item schema.

Usage

use tf2_enum::{Quality, KillstreakTier};
use std::str::FromStr;

assert_eq!(
    "Unusual".parse::<Quality>().unwrap(),
    Quality::Unusual,
);
assert_eq!(
    Quality::Unusual as u32,
    5,
);
assert_eq!(
    KillstreakTier::Professional.to_string(),
    "Professional Killstreak",
);

License

MIT

Commit count: 41

cargo fmt