#[non_exhaustive]pub enum FlowValidationDetails {
Show 26 variants
CyclicConnection(CyclicConnectionFlowValidationDetails),
DuplicateConditionExpression(DuplicateConditionExpressionFlowValidationDetails),
DuplicateConnections(DuplicateConnectionsFlowValidationDetails),
IncompatibleConnectionDataType(IncompatibleConnectionDataTypeFlowValidationDetails),
MalformedConditionExpression(MalformedConditionExpressionFlowValidationDetails),
MalformedNodeInputExpression(MalformedNodeInputExpressionFlowValidationDetails),
MismatchedNodeInputType(MismatchedNodeInputTypeFlowValidationDetails),
MismatchedNodeOutputType(MismatchedNodeOutputTypeFlowValidationDetails),
MissingConnectionConfiguration(MissingConnectionConfigurationFlowValidationDetails),
MissingDefaultCondition(MissingDefaultConditionFlowValidationDetails),
MissingEndingNodes(MissingEndingNodesFlowValidationDetails),
MissingNodeConfiguration(MissingNodeConfigurationFlowValidationDetails),
MissingNodeInput(MissingNodeInputFlowValidationDetails),
MissingNodeOutput(MissingNodeOutputFlowValidationDetails),
MissingStartingNodes(MissingStartingNodesFlowValidationDetails),
MultipleNodeInputConnections(MultipleNodeInputConnectionsFlowValidationDetails),
UnfulfilledNodeInput(UnfulfilledNodeInputFlowValidationDetails),
UnknownConnectionCondition(UnknownConnectionConditionFlowValidationDetails),
UnknownConnectionSource(UnknownConnectionSourceFlowValidationDetails),
UnknownConnectionSourceOutput(UnknownConnectionSourceOutputFlowValidationDetails),
UnknownConnectionTarget(UnknownConnectionTargetFlowValidationDetails),
UnknownConnectionTargetInput(UnknownConnectionTargetInputFlowValidationDetails),
UnreachableNode(UnreachableNodeFlowValidationDetails),
UnsatisfiedConnectionConditions(UnsatisfiedConnectionConditionsFlowValidationDetails),
Unspecified(UnspecifiedFlowValidationDetails),
Unknown,
}Expand description
A union type containing various possible validation issues in the flow.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
CyclicConnection(CyclicConnectionFlowValidationDetails)
Details about a cyclic connection in the flow.
DuplicateConditionExpression(DuplicateConditionExpressionFlowValidationDetails)
Details about duplicate condition expressions in a node.
DuplicateConnections(DuplicateConnectionsFlowValidationDetails)
Details about duplicate connections between nodes.
IncompatibleConnectionDataType(IncompatibleConnectionDataTypeFlowValidationDetails)
Details about incompatible data types in a connection.
MalformedConditionExpression(MalformedConditionExpressionFlowValidationDetails)
Details about a malformed condition expression in a node.
MalformedNodeInputExpression(MalformedNodeInputExpressionFlowValidationDetails)
Details about a malformed input expression in a node.
MismatchedNodeInputType(MismatchedNodeInputTypeFlowValidationDetails)
Details about mismatched input data types in a node.
MismatchedNodeOutputType(MismatchedNodeOutputTypeFlowValidationDetails)
Details about mismatched output data types in a node.
MissingConnectionConfiguration(MissingConnectionConfigurationFlowValidationDetails)
Details about missing configuration for a connection.
MissingDefaultCondition(MissingDefaultConditionFlowValidationDetails)
Details about a missing default condition in a conditional node.
MissingEndingNodes(MissingEndingNodesFlowValidationDetails)
Details about missing ending nodes in the flow.
MissingNodeConfiguration(MissingNodeConfigurationFlowValidationDetails)
Details about missing configuration for a node.
MissingNodeInput(MissingNodeInputFlowValidationDetails)
Details about a missing required input in a node.
MissingNodeOutput(MissingNodeOutputFlowValidationDetails)
Details about a missing required output in a node.
MissingStartingNodes(MissingStartingNodesFlowValidationDetails)
Details about missing starting nodes in the flow.
MultipleNodeInputConnections(MultipleNodeInputConnectionsFlowValidationDetails)
Details about multiple connections to a single node input.
UnfulfilledNodeInput(UnfulfilledNodeInputFlowValidationDetails)
Details about an unfulfilled node input with no valid connections.
UnknownConnectionCondition(UnknownConnectionConditionFlowValidationDetails)
Details about an unknown condition for a connection.
UnknownConnectionSource(UnknownConnectionSourceFlowValidationDetails)
Details about an unknown source node for a connection.
UnknownConnectionSourceOutput(UnknownConnectionSourceOutputFlowValidationDetails)
Details about an unknown source output for a connection.
UnknownConnectionTarget(UnknownConnectionTargetFlowValidationDetails)
Details about an unknown target node for a connection.
UnknownConnectionTargetInput(UnknownConnectionTargetInputFlowValidationDetails)
Details about an unknown target input for a connection.
UnreachableNode(UnreachableNodeFlowValidationDetails)
Details about an unreachable node in the flow.
UnsatisfiedConnectionConditions(UnsatisfiedConnectionConditionsFlowValidationDetails)
Details about unsatisfied conditions for a connection.
Unspecified(UnspecifiedFlowValidationDetails)
Details about an unspecified validation.
Unknown
The Unknown variant represents cases where new union variant was received. Consider upgrading the SDK to the latest available version.
An unknown enum variant
Note: If you encounter this error, consider upgrading your SDK to the latest version.
The Unknown variant represents cases where the server sent a value that wasn’t recognized
by the client. This can happen when the server adds new functionality, but the client has not been updated.
To investigate this, consider turning on debug logging to print the raw HTTP response.
Implementations§
Source§impl FlowValidationDetails
impl FlowValidationDetails
Sourcepub fn as_cyclic_connection(
&self,
) -> Result<&CyclicConnectionFlowValidationDetails, &Self>
pub fn as_cyclic_connection( &self, ) -> Result<&CyclicConnectionFlowValidationDetails, &Self>
Tries to convert the enum instance into CyclicConnection, extracting the inner CyclicConnectionFlowValidationDetails.
Returns Err(&Self) if it can’t be converted.
Sourcepub fn is_cyclic_connection(&self) -> bool
pub fn is_cyclic_connection(&self) -> bool
Returns true if this is a CyclicConnection.
Sourcepub fn as_duplicate_condition_expression(
&self,
) -> Result<&DuplicateConditionExpressionFlowValidationDetails, &Self>
pub fn as_duplicate_condition_expression( &self, ) -> Result<&DuplicateConditionExpressionFlowValidationDetails, &Self>
Tries to convert the enum instance into DuplicateConditionExpression, extracting the inner DuplicateConditionExpressionFlowValidationDetails.
Returns Err(&Self) if it can’t be converted.
Sourcepub fn is_duplicate_condition_expression(&self) -> bool
pub fn is_duplicate_condition_expression(&self) -> bool
Returns true if this is a DuplicateConditionExpression.
Sourcepub fn as_duplicate_connections(
&self,
) -> Result<&DuplicateConnectionsFlowValidationDetails, &Self>
pub fn as_duplicate_connections( &self, ) -> Result<&DuplicateConnectionsFlowValidationDetails, &Self>
Tries to convert the enum instance into DuplicateConnections, extracting the inner DuplicateConnectionsFlowValidationDetails.
Returns Err(&Self) if it can’t be converted.
Sourcepub fn is_duplicate_connections(&self) -> bool
pub fn is_duplicate_connections(&self) -> bool
Returns true if this is a DuplicateConnections.
Sourcepub fn as_incompatible_connection_data_type(
&self,
) -> Result<&IncompatibleConnectionDataTypeFlowValidationDetails, &Self>
pub fn as_incompatible_connection_data_type( &self, ) -> Result<&IncompatibleConnectionDataTypeFlowValidationDetails, &Self>
Tries to convert the enum instance into IncompatibleConnectionDataType, extracting the inner IncompatibleConnectionDataTypeFlowValidationDetails.
Returns Err(&Self) if it can’t be converted.
Sourcepub fn is_incompatible_connection_data_type(&self) -> bool
pub fn is_incompatible_connection_data_type(&self) -> bool
Returns true if this is a IncompatibleConnectionDataType.
Sourcepub fn as_malformed_condition_expression(
&self,
) -> Result<&MalformedConditionExpressionFlowValidationDetails, &Self>
pub fn as_malformed_condition_expression( &self, ) -> Result<&MalformedConditionExpressionFlowValidationDetails, &Self>
Tries to convert the enum instance into MalformedConditionExpression, extracting the inner MalformedConditionExpressionFlowValidationDetails.
Returns Err(&Self) if it can’t be converted.
Sourcepub fn is_malformed_condition_expression(&self) -> bool
pub fn is_malformed_condition_expression(&self) -> bool
Returns true if this is a MalformedConditionExpression.
Sourcepub fn as_malformed_node_input_expression(
&self,
) -> Result<&MalformedNodeInputExpressionFlowValidationDetails, &Self>
pub fn as_malformed_node_input_expression( &self, ) -> Result<&MalformedNodeInputExpressionFlowValidationDetails, &Self>
Tries to convert the enum instance into MalformedNodeInputExpression, extracting the inner MalformedNodeInputExpressionFlowValidationDetails.
Returns Err(&Self) if it can’t be converted.
Sourcepub fn is_malformed_node_input_expression(&self) -> bool
pub fn is_malformed_node_input_expression(&self) -> bool
Returns true if this is a MalformedNodeInputExpression.
Sourcepub fn as_mismatched_node_input_type(
&self,
) -> Result<&MismatchedNodeInputTypeFlowValidationDetails, &Self>
pub fn as_mismatched_node_input_type( &self, ) -> Result<&MismatchedNodeInputTypeFlowValidationDetails, &Self>
Tries to convert the enum instance into MismatchedNodeInputType, extracting the inner MismatchedNodeInputTypeFlowValidationDetails.
Returns Err(&Self) if it can’t be converted.
Sourcepub fn is_mismatched_node_input_type(&self) -> bool
pub fn is_mismatched_node_input_type(&self) -> bool
Returns true if this is a MismatchedNodeInputType.
Sourcepub fn as_mismatched_node_output_type(
&self,
) -> Result<&MismatchedNodeOutputTypeFlowValidationDetails, &Self>
pub fn as_mismatched_node_output_type( &self, ) -> Result<&MismatchedNodeOutputTypeFlowValidationDetails, &Self>
Tries to convert the enum instance into MismatchedNodeOutputType, extracting the inner MismatchedNodeOutputTypeFlowValidationDetails.
Returns Err(&Self) if it can’t be converted.
Sourcepub fn is_mismatched_node_output_type(&self) -> bool
pub fn is_mismatched_node_output_type(&self) -> bool
Returns true if this is a MismatchedNodeOutputType.
Sourcepub fn as_missing_connection_configuration(
&self,
) -> Result<&MissingConnectionConfigurationFlowValidationDetails, &Self>
pub fn as_missing_connection_configuration( &self, ) -> Result<&MissingConnectionConfigurationFlowValidationDetails, &Self>
Tries to convert the enum instance into MissingConnectionConfiguration, extracting the inner MissingConnectionConfigurationFlowValidationDetails.
Returns Err(&Self) if it can’t be converted.
Sourcepub fn is_missing_connection_configuration(&self) -> bool
pub fn is_missing_connection_configuration(&self) -> bool
Returns true if this is a MissingConnectionConfiguration.
Sourcepub fn as_missing_default_condition(
&self,
) -> Result<&MissingDefaultConditionFlowValidationDetails, &Self>
pub fn as_missing_default_condition( &self, ) -> Result<&MissingDefaultConditionFlowValidationDetails, &Self>
Tries to convert the enum instance into MissingDefaultCondition, extracting the inner MissingDefaultConditionFlowValidationDetails.
Returns Err(&Self) if it can’t be converted.
Sourcepub fn is_missing_default_condition(&self) -> bool
pub fn is_missing_default_condition(&self) -> bool
Returns true if this is a MissingDefaultCondition.
Sourcepub fn as_missing_ending_nodes(
&self,
) -> Result<&MissingEndingNodesFlowValidationDetails, &Self>
pub fn as_missing_ending_nodes( &self, ) -> Result<&MissingEndingNodesFlowValidationDetails, &Self>
Tries to convert the enum instance into MissingEndingNodes, extracting the inner MissingEndingNodesFlowValidationDetails.
Returns Err(&Self) if it can’t be converted.
Sourcepub fn is_missing_ending_nodes(&self) -> bool
pub fn is_missing_ending_nodes(&self) -> bool
Returns true if this is a MissingEndingNodes.
Sourcepub fn as_missing_node_configuration(
&self,
) -> Result<&MissingNodeConfigurationFlowValidationDetails, &Self>
pub fn as_missing_node_configuration( &self, ) -> Result<&MissingNodeConfigurationFlowValidationDetails, &Self>
Tries to convert the enum instance into MissingNodeConfiguration, extracting the inner MissingNodeConfigurationFlowValidationDetails.
Returns Err(&Self) if it can’t be converted.
Sourcepub fn is_missing_node_configuration(&self) -> bool
pub fn is_missing_node_configuration(&self) -> bool
Returns true if this is a MissingNodeConfiguration.
Sourcepub fn as_missing_node_input(
&self,
) -> Result<&MissingNodeInputFlowValidationDetails, &Self>
pub fn as_missing_node_input( &self, ) -> Result<&MissingNodeInputFlowValidationDetails, &Self>
Tries to convert the enum instance into MissingNodeInput, extracting the inner MissingNodeInputFlowValidationDetails.
Returns Err(&Self) if it can’t be converted.
Sourcepub fn is_missing_node_input(&self) -> bool
pub fn is_missing_node_input(&self) -> bool
Returns true if this is a MissingNodeInput.
Sourcepub fn as_missing_node_output(
&self,
) -> Result<&MissingNodeOutputFlowValidationDetails, &Self>
pub fn as_missing_node_output( &self, ) -> Result<&MissingNodeOutputFlowValidationDetails, &Self>
Tries to convert the enum instance into MissingNodeOutput, extracting the inner MissingNodeOutputFlowValidationDetails.
Returns Err(&Self) if it can’t be converted.
Sourcepub fn is_missing_node_output(&self) -> bool
pub fn is_missing_node_output(&self) -> bool
Returns true if this is a MissingNodeOutput.
Sourcepub fn as_missing_starting_nodes(
&self,
) -> Result<&MissingStartingNodesFlowValidationDetails, &Self>
pub fn as_missing_starting_nodes( &self, ) -> Result<&MissingStartingNodesFlowValidationDetails, &Self>
Tries to convert the enum instance into MissingStartingNodes, extracting the inner MissingStartingNodesFlowValidationDetails.
Returns Err(&Self) if it can’t be converted.
Sourcepub fn is_missing_starting_nodes(&self) -> bool
pub fn is_missing_starting_nodes(&self) -> bool
Returns true if this is a MissingStartingNodes.
Sourcepub fn as_multiple_node_input_connections(
&self,
) -> Result<&MultipleNodeInputConnectionsFlowValidationDetails, &Self>
pub fn as_multiple_node_input_connections( &self, ) -> Result<&MultipleNodeInputConnectionsFlowValidationDetails, &Self>
Tries to convert the enum instance into MultipleNodeInputConnections, extracting the inner MultipleNodeInputConnectionsFlowValidationDetails.
Returns Err(&Self) if it can’t be converted.
Sourcepub fn is_multiple_node_input_connections(&self) -> bool
pub fn is_multiple_node_input_connections(&self) -> bool
Returns true if this is a MultipleNodeInputConnections.
Sourcepub fn as_unfulfilled_node_input(
&self,
) -> Result<&UnfulfilledNodeInputFlowValidationDetails, &Self>
pub fn as_unfulfilled_node_input( &self, ) -> Result<&UnfulfilledNodeInputFlowValidationDetails, &Self>
Tries to convert the enum instance into UnfulfilledNodeInput, extracting the inner UnfulfilledNodeInputFlowValidationDetails.
Returns Err(&Self) if it can’t be converted.
Sourcepub fn is_unfulfilled_node_input(&self) -> bool
pub fn is_unfulfilled_node_input(&self) -> bool
Returns true if this is a UnfulfilledNodeInput.
Sourcepub fn as_unknown_connection_condition(
&self,
) -> Result<&UnknownConnectionConditionFlowValidationDetails, &Self>
pub fn as_unknown_connection_condition( &self, ) -> Result<&UnknownConnectionConditionFlowValidationDetails, &Self>
Tries to convert the enum instance into UnknownConnectionCondition, extracting the inner UnknownConnectionConditionFlowValidationDetails.
Returns Err(&Self) if it can’t be converted.
Sourcepub fn is_unknown_connection_condition(&self) -> bool
pub fn is_unknown_connection_condition(&self) -> bool
Returns true if this is a UnknownConnectionCondition.
Sourcepub fn as_unknown_connection_source(
&self,
) -> Result<&UnknownConnectionSourceFlowValidationDetails, &Self>
pub fn as_unknown_connection_source( &self, ) -> Result<&UnknownConnectionSourceFlowValidationDetails, &Self>
Tries to convert the enum instance into UnknownConnectionSource, extracting the inner UnknownConnectionSourceFlowValidationDetails.
Returns Err(&Self) if it can’t be converted.
Sourcepub fn is_unknown_connection_source(&self) -> bool
pub fn is_unknown_connection_source(&self) -> bool
Returns true if this is a UnknownConnectionSource.
Sourcepub fn as_unknown_connection_source_output(
&self,
) -> Result<&UnknownConnectionSourceOutputFlowValidationDetails, &Self>
pub fn as_unknown_connection_source_output( &self, ) -> Result<&UnknownConnectionSourceOutputFlowValidationDetails, &Self>
Tries to convert the enum instance into UnknownConnectionSourceOutput, extracting the inner UnknownConnectionSourceOutputFlowValidationDetails.
Returns Err(&Self) if it can’t be converted.
Sourcepub fn is_unknown_connection_source_output(&self) -> bool
pub fn is_unknown_connection_source_output(&self) -> bool
Returns true if this is a UnknownConnectionSourceOutput.
Sourcepub fn as_unknown_connection_target(
&self,
) -> Result<&UnknownConnectionTargetFlowValidationDetails, &Self>
pub fn as_unknown_connection_target( &self, ) -> Result<&UnknownConnectionTargetFlowValidationDetails, &Self>
Tries to convert the enum instance into UnknownConnectionTarget, extracting the inner UnknownConnectionTargetFlowValidationDetails.
Returns Err(&Self) if it can’t be converted.
Sourcepub fn is_unknown_connection_target(&self) -> bool
pub fn is_unknown_connection_target(&self) -> bool
Returns true if this is a UnknownConnectionTarget.
Sourcepub fn as_unknown_connection_target_input(
&self,
) -> Result<&UnknownConnectionTargetInputFlowValidationDetails, &Self>
pub fn as_unknown_connection_target_input( &self, ) -> Result<&UnknownConnectionTargetInputFlowValidationDetails, &Self>
Tries to convert the enum instance into UnknownConnectionTargetInput, extracting the inner UnknownConnectionTargetInputFlowValidationDetails.
Returns Err(&Self) if it can’t be converted.
Sourcepub fn is_unknown_connection_target_input(&self) -> bool
pub fn is_unknown_connection_target_input(&self) -> bool
Returns true if this is a UnknownConnectionTargetInput.
Sourcepub fn as_unreachable_node(
&self,
) -> Result<&UnreachableNodeFlowValidationDetails, &Self>
pub fn as_unreachable_node( &self, ) -> Result<&UnreachableNodeFlowValidationDetails, &Self>
Tries to convert the enum instance into UnreachableNode, extracting the inner UnreachableNodeFlowValidationDetails.
Returns Err(&Self) if it can’t be converted.
Sourcepub fn is_unreachable_node(&self) -> bool
pub fn is_unreachable_node(&self) -> bool
Returns true if this is a UnreachableNode.
Sourcepub fn as_unsatisfied_connection_conditions(
&self,
) -> Result<&UnsatisfiedConnectionConditionsFlowValidationDetails, &Self>
pub fn as_unsatisfied_connection_conditions( &self, ) -> Result<&UnsatisfiedConnectionConditionsFlowValidationDetails, &Self>
Tries to convert the enum instance into UnsatisfiedConnectionConditions, extracting the inner UnsatisfiedConnectionConditionsFlowValidationDetails.
Returns Err(&Self) if it can’t be converted.
Sourcepub fn is_unsatisfied_connection_conditions(&self) -> bool
pub fn is_unsatisfied_connection_conditions(&self) -> bool
Returns true if this is a UnsatisfiedConnectionConditions.
Sourcepub fn as_unspecified(&self) -> Result<&UnspecifiedFlowValidationDetails, &Self>
pub fn as_unspecified(&self) -> Result<&UnspecifiedFlowValidationDetails, &Self>
Tries to convert the enum instance into Unspecified, extracting the inner UnspecifiedFlowValidationDetails.
Returns Err(&Self) if it can’t be converted.
Sourcepub fn is_unspecified(&self) -> bool
pub fn is_unspecified(&self) -> bool
Returns true if this is a Unspecified.
Sourcepub fn is_unknown(&self) -> bool
pub fn is_unknown(&self) -> bool
Returns true if the enum instance is the Unknown variant.
Trait Implementations§
Source§impl Clone for FlowValidationDetails
impl Clone for FlowValidationDetails
Source§fn clone(&self) -> FlowValidationDetails
fn clone(&self) -> FlowValidationDetails
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for FlowValidationDetails
impl Debug for FlowValidationDetails
Source§impl PartialEq for FlowValidationDetails
impl PartialEq for FlowValidationDetails
impl StructuralPartialEq for FlowValidationDetails
Auto Trait Implementations§
impl Freeze for FlowValidationDetails
impl RefUnwindSafe for FlowValidationDetails
impl Send for FlowValidationDetails
impl Sync for FlowValidationDetails
impl Unpin for FlowValidationDetails
impl UnwindSafe for FlowValidationDetails
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
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> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§impl<T> Paint for Twhere
T: ?Sized,
impl<T> Paint for Twhere
T: ?Sized,
Source§fn fg(&self, value: Color) -> Painted<&T>
fn fg(&self, value: Color) -> Painted<&T>
Returns a styled value derived from self with the foreground set to
value.
This method should be used rarely. Instead, prefer to use color-specific
builder methods like red() and
green(), which have the same functionality but are
pithier.
§Example
Set foreground color to white using fg():
use yansi::{Paint, Color};
painted.fg(Color::White);Set foreground color to white using white().
use yansi::Paint;
painted.white();Source§fn bright_black(&self) -> Painted<&T>
fn bright_black(&self) -> Painted<&T>
Returns self with the
fg()
set to
Color::BrightBlack.
§Example
println!("{}", value.bright_black());Source§fn bright_red(&self) -> Painted<&T>
fn bright_red(&self) -> Painted<&T>
Source§fn bright_green(&self) -> Painted<&T>
fn bright_green(&self) -> Painted<&T>
Returns self with the
fg()
set to
Color::BrightGreen.
§Example
println!("{}", value.bright_green());Source§fn bright_yellow(&self) -> Painted<&T>
fn bright_yellow(&self) -> Painted<&T>
Returns self with the
fg()
set to
Color::BrightYellow.
§Example
println!("{}", value.bright_yellow());Source§fn bright_blue(&self) -> Painted<&T>
fn bright_blue(&self) -> Painted<&T>
Source§fn bright_magenta(&self) -> Painted<&T>
fn bright_magenta(&self) -> Painted<&T>
Returns self with the
fg()
set to
Color::BrightMagenta.
§Example
println!("{}", value.bright_magenta());Source§fn bright_cyan(&self) -> Painted<&T>
fn bright_cyan(&self) -> Painted<&T>
Source§fn bright_white(&self) -> Painted<&T>
fn bright_white(&self) -> Painted<&T>
Returns self with the
fg()
set to
Color::BrightWhite.
§Example
println!("{}", value.bright_white());Source§fn bg(&self, value: Color) -> Painted<&T>
fn bg(&self, value: Color) -> Painted<&T>
Returns a styled value derived from self with the background set to
value.
This method should be used rarely. Instead, prefer to use color-specific
builder methods like on_red() and
on_green(), which have the same functionality but
are pithier.
§Example
Set background color to red using fg():
use yansi::{Paint, Color};
painted.bg(Color::Red);Set background color to red using on_red().
use yansi::Paint;
painted.on_red();Source§fn on_primary(&self) -> Painted<&T>
fn on_primary(&self) -> Painted<&T>
Source§fn on_magenta(&self) -> Painted<&T>
fn on_magenta(&self) -> Painted<&T>
Source§fn on_bright_black(&self) -> Painted<&T>
fn on_bright_black(&self) -> Painted<&T>
Returns self with the
bg()
set to
Color::BrightBlack.
§Example
println!("{}", value.on_bright_black());Source§fn on_bright_red(&self) -> Painted<&T>
fn on_bright_red(&self) -> Painted<&T>
Source§fn on_bright_green(&self) -> Painted<&T>
fn on_bright_green(&self) -> Painted<&T>
Returns self with the
bg()
set to
Color::BrightGreen.
§Example
println!("{}", value.on_bright_green());Source§fn on_bright_yellow(&self) -> Painted<&T>
fn on_bright_yellow(&self) -> Painted<&T>
Returns self with the
bg()
set to
Color::BrightYellow.
§Example
println!("{}", value.on_bright_yellow());Source§fn on_bright_blue(&self) -> Painted<&T>
fn on_bright_blue(&self) -> Painted<&T>
Returns self with the
bg()
set to
Color::BrightBlue.
§Example
println!("{}", value.on_bright_blue());Source§fn on_bright_magenta(&self) -> Painted<&T>
fn on_bright_magenta(&self) -> Painted<&T>
Returns self with the
bg()
set to
Color::BrightMagenta.
§Example
println!("{}", value.on_bright_magenta());Source§fn on_bright_cyan(&self) -> Painted<&T>
fn on_bright_cyan(&self) -> Painted<&T>
Returns self with the
bg()
set to
Color::BrightCyan.
§Example
println!("{}", value.on_bright_cyan());Source§fn on_bright_white(&self) -> Painted<&T>
fn on_bright_white(&self) -> Painted<&T>
Returns self with the
bg()
set to
Color::BrightWhite.
§Example
println!("{}", value.on_bright_white());Source§fn attr(&self, value: Attribute) -> Painted<&T>
fn attr(&self, value: Attribute) -> Painted<&T>
Enables the styling Attribute value.
This method should be used rarely. Instead, prefer to use
attribute-specific builder methods like bold() and
underline(), which have the same functionality
but are pithier.
§Example
Make text bold using attr():
use yansi::{Paint, Attribute};
painted.attr(Attribute::Bold);Make text bold using using bold().
use yansi::Paint;
painted.bold();Source§fn underline(&self) -> Painted<&T>
fn underline(&self) -> Painted<&T>
Returns self with the
attr()
set to
Attribute::Underline.
§Example
println!("{}", value.underline());Source§fn rapid_blink(&self) -> Painted<&T>
fn rapid_blink(&self) -> Painted<&T>
Returns self with the
attr()
set to
Attribute::RapidBlink.
§Example
println!("{}", value.rapid_blink());Source§fn quirk(&self, value: Quirk) -> Painted<&T>
fn quirk(&self, value: Quirk) -> Painted<&T>
Enables the yansi Quirk value.
This method should be used rarely. Instead, prefer to use quirk-specific
builder methods like mask() and
wrap(), which have the same functionality but are
pithier.
§Example
Enable wrapping using .quirk():
use yansi::{Paint, Quirk};
painted.quirk(Quirk::Wrap);Enable wrapping using wrap().
use yansi::Paint;
painted.wrap();Source§fn clear(&self) -> Painted<&T>
👎Deprecated since 1.0.1: renamed to resetting() due to conflicts with Vec::clear().
The clear() method will be removed in a future release.
fn clear(&self) -> Painted<&T>
resetting() due to conflicts with Vec::clear().
The clear() method will be removed in a future release.Source§fn whenever(&self, value: Condition) -> Painted<&T>
fn whenever(&self, value: Condition) -> Painted<&T>
Conditionally enable styling based on whether the Condition value
applies. Replaces any previous condition.
See the crate level docs for more details.
§Example
Enable styling painted only when both stdout and stderr are TTYs:
use yansi::{Paint, Condition};
painted.red().on_yellow().whenever(Condition::STDOUTERR_ARE_TTY);