Struct aws_sdk_mturk::input::CreateHitInput
source · [−]#[non_exhaustive]pub struct CreateHitInput {Show 16 fields
pub max_assignments: Option<i32>,
pub auto_approval_delay_in_seconds: Option<i64>,
pub lifetime_in_seconds: Option<i64>,
pub assignment_duration_in_seconds: Option<i64>,
pub reward: Option<String>,
pub title: Option<String>,
pub keywords: Option<String>,
pub description: Option<String>,
pub question: Option<String>,
pub requester_annotation: Option<String>,
pub qualification_requirements: Option<Vec<QualificationRequirement>>,
pub unique_request_token: Option<String>,
pub assignment_review_policy: Option<ReviewPolicy>,
pub hit_review_policy: Option<ReviewPolicy>,
pub hit_layout_id: Option<String>,
pub hit_layout_parameters: Option<Vec<HitLayoutParameter>>,
}
Fields (Non-exhaustive)
This struct is marked as non-exhaustive
Struct { .. }
syntax; cannot be matched against without a wildcard ..
; and struct update syntax will not work.max_assignments: Option<i32>
The number of times the HIT can be accepted and completed before the HIT becomes unavailable.
auto_approval_delay_in_seconds: Option<i64>
The number of seconds after an assignment for the HIT has been submitted, after which the assignment is considered Approved automatically unless the Requester explicitly rejects it.
lifetime_in_seconds: Option<i64>
An amount of time, in seconds, after which the HIT is no longer available for users to accept. After the lifetime of the HIT elapses, the HIT no longer appears in HIT searches, even if not all of the assignments for the HIT have been accepted.
assignment_duration_in_seconds: Option<i64>
The amount of time, in seconds, that a Worker has to complete the HIT after accepting it. If a Worker does not complete the assignment within the specified duration, the assignment is considered abandoned. If the HIT is still active (that is, its lifetime has not elapsed), the assignment becomes available for other users to find and accept.
reward: Option<String>
The amount of money the Requester will pay a Worker for successfully completing the HIT.
title: Option<String>
The title of the HIT. A title should be short and descriptive about the kind of task the HIT contains. On the Amazon Mechanical Turk web site, the HIT title appears in search results, and everywhere the HIT is mentioned.
keywords: Option<String>
One or more words or phrases that describe the HIT, separated by commas. These words are used in searches to find HITs.
description: Option<String>
A general description of the HIT. A description includes detailed information about the kind of task the HIT contains. On the Amazon Mechanical Turk web site, the HIT description appears in the expanded view of search results, and in the HIT and assignment screens. A good description gives the user enough information to evaluate the HIT before accepting it.
question: Option<String>
The data the person completing the HIT uses to produce the results.
Constraints: Must be a QuestionForm data structure, an ExternalQuestion data structure, or an HTMLQuestion data structure. The XML question data must not be larger than 64 kilobytes (65,535 bytes) in size, including whitespace.
Either a Question parameter or a HITLayoutId parameter must be provided.
requester_annotation: Option<String>
An arbitrary data field. The RequesterAnnotation parameter lets your application attach arbitrary data to the HIT for tracking purposes. For example, this parameter could be an identifier internal to the Requester's application that corresponds with the HIT.
The RequesterAnnotation parameter for a HIT is only visible to the Requester who created the HIT. It is not shown to the Worker, or any other Requester.
The RequesterAnnotation parameter may be different for each HIT you submit. It does not affect how your HITs are grouped.
qualification_requirements: Option<Vec<QualificationRequirement>>
Conditions that a Worker's Qualifications must meet in order to accept the HIT. A HIT can have between zero and ten Qualification requirements. All requirements must be met in order for a Worker to accept the HIT. Additionally, other actions can be restricted using the ActionsGuarded
field on each QualificationRequirement
structure.
unique_request_token: Option<String>
A unique identifier for this request which allows you to retry the call on error without creating duplicate HITs. This is useful in cases such as network timeouts where it is unclear whether or not the call succeeded on the server. If the HIT already exists in the system from a previous call using the same UniqueRequestToken, subsequent calls will return a AWS.MechanicalTurk.HitAlreadyExists error with a message containing the HITId.
Note: It is your responsibility to ensure uniqueness of the token. The unique token expires after 24 hours. Subsequent calls using the same UniqueRequestToken made after the 24 hour limit could create duplicate HITs.
assignment_review_policy: Option<ReviewPolicy>
The Assignment-level Review Policy applies to the assignments under the HIT. You can specify for Mechanical Turk to take various actions based on the policy.
hit_review_policy: Option<ReviewPolicy>
The HIT-level Review Policy applies to the HIT. You can specify for Mechanical Turk to take various actions based on the policy.
hit_layout_id: Option<String>
The HITLayoutId allows you to use a pre-existing HIT design with placeholder values and create an additional HIT by providing those values as HITLayoutParameters.
Constraints: Either a Question parameter or a HITLayoutId parameter must be provided.
hit_layout_parameters: Option<Vec<HitLayoutParameter>>
If the HITLayoutId is provided, any placeholder values must be filled in with values using the HITLayoutParameter structure. For more information, see HITLayout.
Implementations
sourceimpl CreateHitInput
impl CreateHitInput
sourcepub async fn make_operation(
&self,
_config: &Config
) -> Result<Operation<CreateHIT, AwsErrorRetryPolicy>, BuildError>
pub async fn make_operation(
&self,
_config: &Config
) -> Result<Operation<CreateHIT, AwsErrorRetryPolicy>, BuildError>
Consumes the builder and constructs an Operation<CreateHIT
>
sourcepub fn builder() -> Builder
pub fn builder() -> Builder
Creates a new builder-style object to manufacture CreateHitInput
sourceimpl CreateHitInput
impl CreateHitInput
sourcepub fn max_assignments(&self) -> Option<i32>
pub fn max_assignments(&self) -> Option<i32>
The number of times the HIT can be accepted and completed before the HIT becomes unavailable.
sourcepub fn auto_approval_delay_in_seconds(&self) -> Option<i64>
pub fn auto_approval_delay_in_seconds(&self) -> Option<i64>
The number of seconds after an assignment for the HIT has been submitted, after which the assignment is considered Approved automatically unless the Requester explicitly rejects it.
sourcepub fn lifetime_in_seconds(&self) -> Option<i64>
pub fn lifetime_in_seconds(&self) -> Option<i64>
An amount of time, in seconds, after which the HIT is no longer available for users to accept. After the lifetime of the HIT elapses, the HIT no longer appears in HIT searches, even if not all of the assignments for the HIT have been accepted.
sourcepub fn assignment_duration_in_seconds(&self) -> Option<i64>
pub fn assignment_duration_in_seconds(&self) -> Option<i64>
The amount of time, in seconds, that a Worker has to complete the HIT after accepting it. If a Worker does not complete the assignment within the specified duration, the assignment is considered abandoned. If the HIT is still active (that is, its lifetime has not elapsed), the assignment becomes available for other users to find and accept.
sourcepub fn reward(&self) -> Option<&str>
pub fn reward(&self) -> Option<&str>
The amount of money the Requester will pay a Worker for successfully completing the HIT.
sourcepub fn title(&self) -> Option<&str>
pub fn title(&self) -> Option<&str>
The title of the HIT. A title should be short and descriptive about the kind of task the HIT contains. On the Amazon Mechanical Turk web site, the HIT title appears in search results, and everywhere the HIT is mentioned.
sourcepub fn keywords(&self) -> Option<&str>
pub fn keywords(&self) -> Option<&str>
One or more words or phrases that describe the HIT, separated by commas. These words are used in searches to find HITs.
sourcepub fn description(&self) -> Option<&str>
pub fn description(&self) -> Option<&str>
A general description of the HIT. A description includes detailed information about the kind of task the HIT contains. On the Amazon Mechanical Turk web site, the HIT description appears in the expanded view of search results, and in the HIT and assignment screens. A good description gives the user enough information to evaluate the HIT before accepting it.
sourcepub fn question(&self) -> Option<&str>
pub fn question(&self) -> Option<&str>
The data the person completing the HIT uses to produce the results.
Constraints: Must be a QuestionForm data structure, an ExternalQuestion data structure, or an HTMLQuestion data structure. The XML question data must not be larger than 64 kilobytes (65,535 bytes) in size, including whitespace.
Either a Question parameter or a HITLayoutId parameter must be provided.
sourcepub fn requester_annotation(&self) -> Option<&str>
pub fn requester_annotation(&self) -> Option<&str>
An arbitrary data field. The RequesterAnnotation parameter lets your application attach arbitrary data to the HIT for tracking purposes. For example, this parameter could be an identifier internal to the Requester's application that corresponds with the HIT.
The RequesterAnnotation parameter for a HIT is only visible to the Requester who created the HIT. It is not shown to the Worker, or any other Requester.
The RequesterAnnotation parameter may be different for each HIT you submit. It does not affect how your HITs are grouped.
sourcepub fn qualification_requirements(&self) -> Option<&[QualificationRequirement]>
pub fn qualification_requirements(&self) -> Option<&[QualificationRequirement]>
Conditions that a Worker's Qualifications must meet in order to accept the HIT. A HIT can have between zero and ten Qualification requirements. All requirements must be met in order for a Worker to accept the HIT. Additionally, other actions can be restricted using the ActionsGuarded
field on each QualificationRequirement
structure.
sourcepub fn unique_request_token(&self) -> Option<&str>
pub fn unique_request_token(&self) -> Option<&str>
A unique identifier for this request which allows you to retry the call on error without creating duplicate HITs. This is useful in cases such as network timeouts where it is unclear whether or not the call succeeded on the server. If the HIT already exists in the system from a previous call using the same UniqueRequestToken, subsequent calls will return a AWS.MechanicalTurk.HitAlreadyExists error with a message containing the HITId.
Note: It is your responsibility to ensure uniqueness of the token. The unique token expires after 24 hours. Subsequent calls using the same UniqueRequestToken made after the 24 hour limit could create duplicate HITs.
sourcepub fn assignment_review_policy(&self) -> Option<&ReviewPolicy>
pub fn assignment_review_policy(&self) -> Option<&ReviewPolicy>
The Assignment-level Review Policy applies to the assignments under the HIT. You can specify for Mechanical Turk to take various actions based on the policy.
sourcepub fn hit_review_policy(&self) -> Option<&ReviewPolicy>
pub fn hit_review_policy(&self) -> Option<&ReviewPolicy>
The HIT-level Review Policy applies to the HIT. You can specify for Mechanical Turk to take various actions based on the policy.
sourcepub fn hit_layout_id(&self) -> Option<&str>
pub fn hit_layout_id(&self) -> Option<&str>
The HITLayoutId allows you to use a pre-existing HIT design with placeholder values and create an additional HIT by providing those values as HITLayoutParameters.
Constraints: Either a Question parameter or a HITLayoutId parameter must be provided.
sourcepub fn hit_layout_parameters(&self) -> Option<&[HitLayoutParameter]>
pub fn hit_layout_parameters(&self) -> Option<&[HitLayoutParameter]>
If the HITLayoutId is provided, any placeholder values must be filled in with values using the HITLayoutParameter structure. For more information, see HITLayout.
Trait Implementations
sourceimpl Clone for CreateHitInput
impl Clone for CreateHitInput
sourcefn clone(&self) -> CreateHitInput
fn clone(&self) -> CreateHitInput
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
sourceimpl Debug for CreateHitInput
impl Debug for CreateHitInput
sourceimpl PartialEq<CreateHitInput> for CreateHitInput
impl PartialEq<CreateHitInput> for CreateHitInput
sourcefn eq(&self, other: &CreateHitInput) -> bool
fn eq(&self, other: &CreateHitInput) -> bool
This method tests for self
and other
values to be equal, and is used
by ==
. Read more
sourcefn ne(&self, other: &CreateHitInput) -> bool
fn ne(&self, other: &CreateHitInput) -> bool
This method tests for !=
.
impl StructuralPartialEq for CreateHitInput
Auto Trait Implementations
impl RefUnwindSafe for CreateHitInput
impl Send for CreateHitInput
impl Sync for CreateHitInput
impl Unpin for CreateHitInput
impl UnwindSafe for CreateHitInput
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcepub fn borrow_mut(&mut self) -> &mut T
pub fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> Instrument for T
impl<T> Instrument for T
sourcefn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
sourcefn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
sourceimpl<T> ToOwned for T where
T: Clone,
impl<T> ToOwned for T where
T: Clone,
type Owned = T
type Owned = T
The resulting type after obtaining ownership.
sourcepub fn to_owned(&self) -> T
pub fn to_owned(&self) -> T
Creates owned data from borrowed data, usually by cloning. Read more
sourcepub fn clone_into(&self, target: &mut T)
pub fn clone_into(&self, target: &mut T)
toowned_clone_into
)Uses borrowed data to replace owned data, usually by cloning. Read more
sourceimpl<T> WithSubscriber for T
impl<T> WithSubscriber for T
sourcefn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> where
S: Into<Dispatch>,
fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> where
S: Into<Dispatch>,
Attaches the provided Subscriber
to this type, returning a
WithDispatch
wrapper. Read more
sourcefn with_current_subscriber(self) -> WithDispatch<Self>
fn with_current_subscriber(self) -> WithDispatch<Self>
Attaches the current default Subscriber
to this type, returning a
WithDispatch
wrapper. Read more