pub struct BookCategory {
pub id: String,
pub name: String,
pub description: Option<String>,
pub icon: Option<String>,
pub icon_svg: Option<String>,
pub sortnum: i32,
}Expand description
Represents a book category tab (e.g. “Basics”, “Patterns”).
Fields§
§id: String§name: String§description: Option<String>§icon: Option<String>MC texture path for the category icon (e.g. "minecraft:textures/item/book.png").
icon_svg: Option<String>Raw SVG string for the category icon (takes priority over icon).
sortnum: i32Sort priority (lower = first).
Implementations§
Trait Implementations§
Source§impl Clone for BookCategory
impl Clone for BookCategory
Source§fn clone(&self) -> BookCategory
fn clone(&self) -> BookCategory
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for BookCategory
impl Debug for BookCategory
Source§impl<'de> Deserialize<'de> for BookCategory
impl<'de> Deserialize<'de> for BookCategory
Source§fn deserialize<__D>(
__deserializer: __D,
) -> Result<BookCategory, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D,
) -> Result<BookCategory, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl Serialize for BookCategory
impl Serialize for BookCategory
Source§fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
Serialize this value into the given Serde serializer. Read more
Auto Trait Implementations§
impl Freeze for BookCategory
impl RefUnwindSafe for BookCategory
impl Send for BookCategory
impl Sync for BookCategory
impl Unpin for BookCategory
impl UnsafeUnpin for BookCategory
impl UnwindSafe for BookCategory
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more