#[non_exhaustive]pub enum Role {
Show 13 variants
Heading,
Title,
Subtitle,
SlideTitle,
Header,
Footer,
Footnote,
Endnote,
Notes,
Comment,
Caption,
SheetName,
Other,
}Expand description
A unit’s structural role (UnitContext::role). JSON: the lowercase name. A value this release does not know
(written by a newer one) reads as Role::Other.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Heading
A heading; UnitContext::level holds its level.
Title
The document title.
Subtitle
The document subtitle.
SlideTitle
A slide’s title.
Header
Page header text.
Page footer text.
Footnote
Footnote text.
Endnote
Endnote text.
Notes
Speaker notes.
Comment
Comment (annotation) text.
Caption
A table or figure caption.
SheetName
A sheet’s name.
Other
A role from a newer release, or one without a name here.
Implementations§
Trait Implementations§
impl Copy for Role
Source§impl<'de> Deserialize<'de> for Role
impl<'de> Deserialize<'de> for Role
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl Eq for Role
impl StructuralPartialEq for Role
Auto Trait Implementations§
impl Forget for Role
impl Freeze for Role
impl Move for Role
impl RefUnwindSafe for Role
impl Send for Role
impl Sync for Role
impl Unpin for Role
impl UnsafeUnpin for Role
impl UnwindSafe for Role
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