mirror of
https://codeberg.org/icewind/tf-log-parser.git
synced 2026-11-30 04:40:47 +01:00
event rework wip
This commit is contained in:
parent
e83f7928aa
commit
b2d169601c
10 changed files with 240 additions and 63 deletions
|
|
@ -1,5 +1,5 @@
|
|||
use crate::raw_event::RawSubject;
|
||||
use serde::Serialize;
|
||||
use serde::{Serialize, Serializer};
|
||||
use std::convert::TryFrom;
|
||||
use std::fmt::{Display, Formatter};
|
||||
use std::str::FromStr;
|
||||
|
|
@ -135,3 +135,12 @@ impl TryFrom<&RawSubject<'_>> for SubjectData {
|
|||
/// Steam id formatted as steamid3 when serialized
|
||||
#[derive(Debug, Hash, Eq, PartialEq)]
|
||||
pub struct SteamId3(pub SteamID);
|
||||
|
||||
impl Serialize for SteamId3 {
|
||||
fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
|
||||
where
|
||||
S: Serializer,
|
||||
{
|
||||
self.0.steam3().serialize(serializer)
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue