#[non_exhaustive]pub enum InlineSegment {
Plain(String),
Tab(InlineTabAttr),
}Expand description
One typed segment inside an InlineText.
Marked #[non_exhaustive] so future inline elements (ruby, hyphen
hints, etc.) can be added without breaking existing matches.
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.
Plain(String)
Plain text. May contain \n, U+00A0 (NBSP), U+001F (fwSpace)
— those are still handled as character-level sentinels by the
HWPX encoder, matching the Text(String) behavior.
Tab(InlineTabAttr)
An inline tab with explicit per-occurrence attributes.
Trait Implementations§
Source§impl Clone for InlineSegment
impl Clone for InlineSegment
Source§fn clone(&self) -> InlineSegment
fn clone(&self) -> InlineSegment
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 InlineSegment
impl Debug for InlineSegment
Source§impl<'de> Deserialize<'de> for InlineSegment
impl<'de> Deserialize<'de> for InlineSegment
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
Source§impl JsonSchema for InlineSegment
impl JsonSchema for InlineSegment
Source§fn schema_id() -> Cow<'static, str>
fn schema_id() -> Cow<'static, str>
Returns a string that uniquely identifies the schema produced by this type. Read more
Source§fn json_schema(generator: &mut SchemaGenerator) -> Schema
fn json_schema(generator: &mut SchemaGenerator) -> Schema
Generates a JSON Schema for this type. Read more
Source§fn inline_schema() -> bool
fn inline_schema() -> bool
Whether JSON Schemas generated for this type should be included directly in parent schemas,
rather than being re-used where possible using the
$ref keyword. Read moreSource§impl PartialEq for InlineSegment
impl PartialEq for InlineSegment
Source§fn eq(&self, other: &InlineSegment) -> bool
fn eq(&self, other: &InlineSegment) -> bool
Tests for
self and other values to be equal, and is used by ==.Source§impl Serialize for InlineSegment
impl Serialize for InlineSegment
impl StructuralPartialEq for InlineSegment
Auto Trait Implementations§
impl Freeze for InlineSegment
impl RefUnwindSafe for InlineSegment
impl Send for InlineSegment
impl Sync for InlineSegment
impl Unpin for InlineSegment
impl UnsafeUnpin for InlineSegment
impl UnwindSafe for InlineSegment
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