#[non_exhaustive]pub struct GetTaskOutputBuilder { /* private fields */ }Expand description
A builder for GetTaskOutput.
Implementations§
Source§impl GetTaskOutputBuilder
impl GetTaskOutputBuilder
Sourcepub fn id(self, input: impl Into<String>) -> Self
pub fn id(self, input: impl Into<String>) -> Self
The ID of the task. Pass it as taskId to GetTask or CancelTask.
Sourcepub fn set_id(self, input: Option<String>) -> Self
pub fn set_id(self, input: Option<String>) -> Self
The ID of the task. Pass it as taskId to GetTask or CancelTask.
Sourcepub fn get_id(&self) -> &Option<String>
pub fn get_id(&self) -> &Option<String>
The ID of the task. Pass it as taskId to GetTask or CancelTask.
Sourcepub fn arn(self, input: impl Into<String>) -> Self
pub fn arn(self, input: impl Into<String>) -> Self
The Amazon Resource Name (ARN) of the task.
This field is required.Sourcepub fn set_arn(self, input: Option<String>) -> Self
pub fn set_arn(self, input: Option<String>) -> Self
The Amazon Resource Name (ARN) of the task.
Sourcepub fn agent_context_id(self, input: impl Into<String>) -> Self
pub fn agent_context_id(self, input: impl Into<String>) -> Self
The agent context's ID.
This field is required.Sourcepub fn set_agent_context_id(self, input: Option<String>) -> Self
pub fn set_agent_context_id(self, input: Option<String>) -> Self
The agent context's ID.
Sourcepub fn get_agent_context_id(&self) -> &Option<String>
pub fn get_agent_context_id(&self) -> &Option<String>
The agent context's ID.
Sourcepub fn type(self, input: TaskType) -> Self
pub fn type(self, input: TaskType) -> Self
The type of the task. It is set by the inputConfiguration member that the task was started with: IMPORT_DATA_DICTIONARY, IMPORT_VERIFIED_QUERIES, or IMPORT_ONTOLOGY.
Sourcepub fn set_type(self, input: Option<TaskType>) -> Self
pub fn set_type(self, input: Option<TaskType>) -> Self
The type of the task. It is set by the inputConfiguration member that the task was started with: IMPORT_DATA_DICTIONARY, IMPORT_VERIFIED_QUERIES, or IMPORT_ONTOLOGY.
Sourcepub fn get_type(&self) -> &Option<TaskType>
pub fn get_type(&self) -> &Option<TaskType>
The type of the task. It is set by the inputConfiguration member that the task was started with: IMPORT_DATA_DICTIONARY, IMPORT_VERIFIED_QUERIES, or IMPORT_ONTOLOGY.
Sourcepub fn status(self, input: TaskStatus) -> Self
pub fn status(self, input: TaskStatus) -> Self
The status of the task. A task moves from PENDING to IN_PROGRESS and ends COMPLETED, FAILED, or CANCELLED. After CancelTask, it is CANCELLING until it stops.
Sourcepub fn set_status(self, input: Option<TaskStatus>) -> Self
pub fn set_status(self, input: Option<TaskStatus>) -> Self
The status of the task. A task moves from PENDING to IN_PROGRESS and ends COMPLETED, FAILED, or CANCELLED. After CancelTask, it is CANCELLING until it stops.
Sourcepub fn get_status(&self) -> &Option<TaskStatus>
pub fn get_status(&self) -> &Option<TaskStatus>
The status of the task. A task moves from PENDING to IN_PROGRESS and ends COMPLETED, FAILED, or CANCELLED. After CancelTask, it is CANCELLING until it stops.
Sourcepub fn description(self, input: impl Into<String>) -> Self
pub fn description(self, input: impl Into<String>) -> Self
The description of the task, as given to StartTask.
Sourcepub fn set_description(self, input: Option<String>) -> Self
pub fn set_description(self, input: Option<String>) -> Self
The description of the task, as given to StartTask.
Sourcepub fn get_description(&self) -> &Option<String>
pub fn get_description(&self) -> &Option<String>
The description of the task, as given to StartTask.
Sourcepub fn created_at(self, input: DateTime) -> Self
pub fn created_at(self, input: DateTime) -> Self
The date and time when the task was created.
This field is required.Sourcepub fn set_created_at(self, input: Option<DateTime>) -> Self
pub fn set_created_at(self, input: Option<DateTime>) -> Self
The date and time when the task was created.
Sourcepub fn get_created_at(&self) -> &Option<DateTime>
pub fn get_created_at(&self) -> &Option<DateTime>
The date and time when the task was created.
Sourcepub fn updated_at(self, input: DateTime) -> Self
pub fn updated_at(self, input: DateTime) -> Self
The date and time when the task was last updated, such as when its status changed. Equal to createdAt until the task first changes.
Sourcepub fn set_updated_at(self, input: Option<DateTime>) -> Self
pub fn set_updated_at(self, input: Option<DateTime>) -> Self
The date and time when the task was last updated, such as when its status changed. Equal to createdAt until the task first changes.
Sourcepub fn get_updated_at(&self) -> &Option<DateTime>
pub fn get_updated_at(&self) -> &Option<DateTime>
The date and time when the task was last updated, such as when its status changed. Equal to createdAt until the task first changes.
Sourcepub fn status_reason_code(self, input: TaskStatusReasonCode) -> Self
pub fn status_reason_code(self, input: TaskStatusReasonCode) -> Self
The code for why the task failed. Present only when status is FAILED.
Valid values:
-
GRAPH_NOT_ACTIVE- The agent context was deleted, or was not yet available, while the task ran. -
ONTOLOGY_INVALID- An ontology is missing, has no loadable source, or its source is unsafe or too large. -
ONTOLOGY_IMPORT_UNAVAILABLE- An ontology couldn't be imported because of a temporary problem. Start a new task. -
ONTOLOGY_ALREADY_IMPORTED- This ontology version is already imported into the agent context.
Sourcepub fn set_status_reason_code(self, input: Option<TaskStatusReasonCode>) -> Self
pub fn set_status_reason_code(self, input: Option<TaskStatusReasonCode>) -> Self
The code for why the task failed. Present only when status is FAILED.
Valid values:
-
GRAPH_NOT_ACTIVE- The agent context was deleted, or was not yet available, while the task ran. -
ONTOLOGY_INVALID- An ontology is missing, has no loadable source, or its source is unsafe or too large. -
ONTOLOGY_IMPORT_UNAVAILABLE- An ontology couldn't be imported because of a temporary problem. Start a new task. -
ONTOLOGY_ALREADY_IMPORTED- This ontology version is already imported into the agent context.
Sourcepub fn get_status_reason_code(&self) -> &Option<TaskStatusReasonCode>
pub fn get_status_reason_code(&self) -> &Option<TaskStatusReasonCode>
The code for why the task failed. Present only when status is FAILED.
Valid values:
-
GRAPH_NOT_ACTIVE- The agent context was deleted, or was not yet available, while the task ran. -
ONTOLOGY_INVALID- An ontology is missing, has no loadable source, or its source is unsafe or too large. -
ONTOLOGY_IMPORT_UNAVAILABLE- An ontology couldn't be imported because of a temporary problem. Start a new task. -
ONTOLOGY_ALREADY_IMPORTED- This ontology version is already imported into the agent context.
Sourcepub fn status_message(self, input: impl Into<String>) -> Self
pub fn status_message(self, input: impl Into<String>) -> Self
The reason the task failed. Present only when status is FAILED.
Sourcepub fn set_status_message(self, input: Option<String>) -> Self
pub fn set_status_message(self, input: Option<String>) -> Self
The reason the task failed. Present only when status is FAILED.
Sourcepub fn get_status_message(&self) -> &Option<String>
pub fn get_status_message(&self) -> &Option<String>
The reason the task failed. Present only when status is FAILED.
Sourcepub fn statistics(self, input: TaskStatistics) -> Self
pub fn statistics(self, input: TaskStatistics) -> Self
Counts of the documents that the task analyzed and the change sets that it created. The counts are final once the task is COMPLETED, FAILED, or CANCELLED.
Sourcepub fn set_statistics(self, input: Option<TaskStatistics>) -> Self
pub fn set_statistics(self, input: Option<TaskStatistics>) -> Self
Counts of the documents that the task analyzed and the change sets that it created. The counts are final once the task is COMPLETED, FAILED, or CANCELLED.
Sourcepub fn get_statistics(&self) -> &Option<TaskStatistics>
pub fn get_statistics(&self) -> &Option<TaskStatistics>
Counts of the documents that the task analyzed and the change sets that it created. The counts are final once the task is COMPLETED, FAILED, or CANCELLED.
Sourcepub fn input_configuration(self, input: TaskInputConfigurationSummary) -> Self
pub fn input_configuration(self, input: TaskInputConfigurationSummary) -> Self
A summary of the input that the task was started with. Each document is returned as its name, size, and content type, not its content, and each ontology is returned as its ARN and, if set, its version.
This field is required.Sourcepub fn set_input_configuration(
self,
input: Option<TaskInputConfigurationSummary>,
) -> Self
pub fn set_input_configuration( self, input: Option<TaskInputConfigurationSummary>, ) -> Self
A summary of the input that the task was started with. Each document is returned as its name, size, and content type, not its content, and each ontology is returned as its ARN and, if set, its version.
Sourcepub fn get_input_configuration(&self) -> &Option<TaskInputConfigurationSummary>
pub fn get_input_configuration(&self) -> &Option<TaskInputConfigurationSummary>
A summary of the input that the task was started with. Each document is returned as its name, size, and content type, not its content, and each ontology is returned as its ARN and, if set, its version.
Sourcepub fn outputs(self, input: TaskOutput) -> Self
pub fn outputs(self, input: TaskOutput) -> Self
Appends an item to outputs.
To override the contents of this collection use set_outputs.
What the task created, in creation order. Set when it finishes.
Sourcepub fn set_outputs(self, input: Option<Vec<TaskOutput>>) -> Self
pub fn set_outputs(self, input: Option<Vec<TaskOutput>>) -> Self
What the task created, in creation order. Set when it finishes.
Sourcepub fn get_outputs(&self) -> &Option<Vec<TaskOutput>>
pub fn get_outputs(&self) -> &Option<Vec<TaskOutput>>
What the task created, in creation order. Set when it finishes.
Sourcepub fn build(self) -> Result<GetTaskOutput, BuildError>
pub fn build(self) -> Result<GetTaskOutput, BuildError>
Consumes the builder and constructs a GetTaskOutput.
This method will fail if any of the following fields are not set:
Trait Implementations§
Source§impl Clone for GetTaskOutputBuilder
impl Clone for GetTaskOutputBuilder
Source§impl Debug for GetTaskOutputBuilder
impl Debug for GetTaskOutputBuilder
Source§impl Default for GetTaskOutputBuilder
impl Default for GetTaskOutputBuilder
Source§impl PartialEq for GetTaskOutputBuilder
impl PartialEq for GetTaskOutputBuilder
impl StructuralPartialEq for GetTaskOutputBuilder
Auto Trait Implementations§
impl Forget for GetTaskOutputBuilder
impl Freeze for GetTaskOutputBuilderwhere
*const u8 is !null: Freeze,
PhantomData<u8>: Freeze,
PhantomData<TaskDocument>: Freeze,
PhantomData<OntologyReferenceSummary>: Freeze,
PhantomData<TaskOutput>: Freeze,
impl Move for GetTaskOutputBuilder
impl RefUnwindSafe for GetTaskOutputBuilder
impl Send for GetTaskOutputBuilderwhere
RawVecInner: Send,
impl Sync for GetTaskOutputBuilderwhere
RawVecInner: Sync,
impl Unpin for GetTaskOutputBuilder
impl UnsafeUnpin for GetTaskOutputBuilderwhere
*const u8 is !null: UnsafeUnpin,
PhantomData<u8>: UnsafeUnpin,
PhantomData<TaskDocument>: UnsafeUnpin,
PhantomData<OntologyReferenceSummary>: UnsafeUnpin,
PhantomData<TaskOutput>: UnsafeUnpin,
impl UnwindSafe for GetTaskOutputBuilderwhere
RawVecInner: UnwindSafe,
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
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>
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>
Source§fn bright_yellow(&self) -> Painted<&T>
fn bright_yellow(&self) -> Painted<&T>
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>
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>
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>
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>
Source§fn on_bright_yellow(&self) -> Painted<&T>
fn on_bright_yellow(&self) -> Painted<&T>
Source§fn on_bright_blue(&self) -> Painted<&T>
fn on_bright_blue(&self) -> Painted<&T>
Source§fn on_bright_magenta(&self) -> Painted<&T>
fn on_bright_magenta(&self) -> Painted<&T>
Source§fn on_bright_cyan(&self) -> Painted<&T>
fn on_bright_cyan(&self) -> Painted<&T>
Source§fn on_bright_white(&self) -> Painted<&T>
fn on_bright_white(&self) -> Painted<&T>
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 rapid_blink(&self) -> Painted<&T>
fn rapid_blink(&self) -> Painted<&T>
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>
renamed to 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);