-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
perf(backend): use
Small String Optimization
- Loading branch information
1 parent
73a85fe
commit 7460726
Showing
27 changed files
with
274 additions
and
140 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,18 +1,22 @@ | ||
use super::ConditionSet; | ||
use compact_str::CompactString; | ||
use serde::{Deserialize, Serialize}; | ||
|
||
/// Each animation root config.json | ||
#[derive(Debug, Clone, Default, PartialEq, Serialize, Deserialize)] | ||
pub struct ConditionsConfig { | ||
/// # NOTE | ||
/// An arbitrary name given by the user (value in the mapping table) will probably exceed 24bytes. | ||
/// Therefore, it should not be a [CompactString]. | ||
#[serde(default)] | ||
pub name: String, | ||
#[serde(default)] | ||
pub description: String, | ||
pub description: CompactString, | ||
#[serde(default)] | ||
pub priority: i32, | ||
#[serde(skip_serializing_if = "Option::is_none")] | ||
#[serde(rename = "overrideAnimationsFolder")] | ||
pub override_animations_folder: Option<String>, | ||
pub override_animations_folder: Option<CompactString>, | ||
#[serde(default)] | ||
pub conditions: Vec<ConditionSet>, | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.