pub enum RichTextError {
InvalidXml(String),
RootMustBeBody(String),
UnsupportedTag {
tag: String,
context: RichTextContext,
},
DisallowedAttribute {
tag: String,
attr: String,
},
InvalidDataAsanaType(String),
InvalidNesting {
parent: String,
child: String,
},
}Expand description
Errors from rich text preparation.
Variants§
InvalidXml(String)
Content failed XML well-formedness parsing.
RootMustBeBody(String)
Root element was not <body>.
UnsupportedTag
Tag is not on Asana’s whitelist for this context.
DisallowedAttribute
Attribute appeared on a tag that does not accept attributes.
InvalidDataAsanaType(String)
data-asana-type carried a value outside the documented enum.
InvalidNesting
Nesting violates Asana’s structural rules.
Trait Implementations§
Source§impl Debug for RichTextError
impl Debug for RichTextError
Source§impl Display for RichTextError
impl Display for RichTextError
impl Eq for RichTextError
Source§impl Error for RichTextError
impl Error for RichTextError
1.30.0 · Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
Returns the lower-level source of this error, if any. Read more
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0:
use the Display impl or to_string()
Source§impl From<RichTextError> for Error
impl From<RichTextError> for Error
Source§fn from(source: RichTextError) -> Self
fn from(source: RichTextError) -> Self
Converts to this type from the input type.
Source§impl From<RichTextError> for StoryValidationError
impl From<RichTextError> for StoryValidationError
Source§fn from(source: RichTextError) -> Self
fn from(source: RichTextError) -> Self
Converts to this type from the input type.
Source§impl From<RichTextError> for TaskValidationError
impl From<RichTextError> for TaskValidationError
Source§fn from(source: RichTextError) -> Self
fn from(source: RichTextError) -> Self
Converts to this type from the input type.
Source§impl PartialEq for RichTextError
impl PartialEq for RichTextError
impl StructuralPartialEq for RichTextError
Auto Trait Implementations§
impl Freeze for RichTextError
impl RefUnwindSafe for RichTextError
impl Send for RichTextError
impl Sync for RichTextError
impl Unpin for RichTextError
impl UnsafeUnpin for RichTextError
impl UnwindSafe for RichTextError
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
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> PolicyExt for Twhere
T: ?Sized,
impl<T> PolicyExt for Twhere
T: ?Sized,
Source§impl<T> ToStringFallible for Twhere
T: Display,
impl<T> ToStringFallible for Twhere
T: Display,
Source§fn try_to_string(&self) -> Result<String, TryReserveError>
fn try_to_string(&self) -> Result<String, TryReserveError>
ToString::to_string, but without panic on OOM.