Struct aws_sdk_comprehend::client::Client

source ·
pub struct Client { /* private fields */ }
Expand description

Client for Amazon Comprehend

Client for invoking operations on Amazon Comprehend. Each operation on Amazon Comprehend is a method on this this struct. .send() MUST be invoked on the generated operations to dispatch the request to the service.

§Constructing a Client

A Config is required to construct a client. For most use cases, the aws-config crate should be used to automatically resolve this config using aws_config::load_from_env(), since this will resolve an SdkConfig which can be shared across multiple different AWS SDK clients. This config resolution process can be customized by calling aws_config::from_env() instead, which returns a ConfigLoader that uses the builder pattern to customize the default config.

In the simplest case, creating a client looks as follows:

let config = aws_config::load_from_env().await;
let client = aws_sdk_comprehend::Client::new(&config);

Occasionally, SDKs may have additional service-specific values that can be set on the Config that is absent from SdkConfig, or slightly different settings for a specific client may be desired. The Config struct implements From<&SdkConfig>, so setting these specific settings can be done as follows:

let sdk_config = ::aws_config::load_from_env().await;
let config = aws_sdk_comprehend::config::Builder::from(&sdk_config)
    .some_service_specific_setting("value")
    .build();

See the aws-config docs and Config for more information on customizing configuration.

Note: Client construction is expensive due to connection thread pool initialization, and should be done once at application start-up.

§Using the Client

A client has a function for every operation that can be performed by the service. For example, the BatchDetectEntities operation has a Client::batch_detect_entities, function which returns a builder for that operation. The fluent builder ultimately has a send() function that returns an async future that returns a result, as illustrated below:

let result = client.batch_detect_entities()
    .language_code("example")
    .send()
    .await;

The underlying HTTP requests that get made by this can be modified with the customize_operation function on the fluent builder. See the customize module for more information.

Implementations§

source§

impl Client

source

pub fn batch_detect_dominant_language( &self ) -> BatchDetectDominantLanguageFluentBuilder

Constructs a fluent builder for the BatchDetectDominantLanguage operation.

source§

impl Client

source

pub fn batch_detect_entities(&self) -> BatchDetectEntitiesFluentBuilder

Constructs a fluent builder for the BatchDetectEntities operation.

source§

impl Client

source

pub fn batch_detect_key_phrases(&self) -> BatchDetectKeyPhrasesFluentBuilder

Constructs a fluent builder for the BatchDetectKeyPhrases operation.

source§

impl Client

source

pub fn batch_detect_sentiment(&self) -> BatchDetectSentimentFluentBuilder

Constructs a fluent builder for the BatchDetectSentiment operation.

source§

impl Client

source

pub fn batch_detect_syntax(&self) -> BatchDetectSyntaxFluentBuilder

Constructs a fluent builder for the BatchDetectSyntax operation.

source§

impl Client

source

pub fn batch_detect_targeted_sentiment( &self ) -> BatchDetectTargetedSentimentFluentBuilder

Constructs a fluent builder for the BatchDetectTargetedSentiment operation.

source§

impl Client

source

pub fn classify_document(&self) -> ClassifyDocumentFluentBuilder

Constructs a fluent builder for the ClassifyDocument operation.

  • The fluent builder is configurable:
  • On success, responds with ClassifyDocumentOutput with field(s):
    • classes(Option<Vec::<DocumentClass>>):

      The classes used by the document being analyzed. These are used for models trained in multi-class mode. Individual classes are mutually exclusive and each document is expected to have only a single class assigned to it. For example, an animal can be a dog or a cat, but not both at the same time.

      For prompt safety classification, the response includes only two classes (SAFE_PROMPT and UNSAFE_PROMPT), along with a confidence score for each class. The value range of the score is zero to one, where one is the highest confidence.

    • labels(Option<Vec::<DocumentLabel>>):

      The labels used in the document being analyzed. These are used for multi-label trained models. Individual labels represent different categories that are related in some manner and are not mutually exclusive. For example, a movie can be just an action movie, or it can be an action movie, a science fiction movie, and a comedy, all at the same time.

    • document_metadata(Option<DocumentMetadata>):

      Extraction information about the document. This field is present in the response only if your request includes the Byte parameter.

    • document_type(Option<Vec::<DocumentTypeListItem>>):

      The document type for each page in the input document. This field is present in the response only if your request includes the Byte parameter.

    • errors(Option<Vec::<ErrorsListItem>>):

      Page-level errors that the system detected while processing the input document. The field is empty if the system encountered no errors.

    • warnings(Option<Vec::<WarningsListItem>>):

      Warnings detected while processing the input document. The response includes a warning if there is a mismatch between the input document type and the model type associated with the endpoint that you specified. The response can also include warnings for individual pages that have a mismatch.

      The field is empty if the system generated no warnings.

  • On failure, responds with SdkError<ClassifyDocumentError>
source§

impl Client

source

pub fn contains_pii_entities(&self) -> ContainsPiiEntitiesFluentBuilder

Constructs a fluent builder for the ContainsPiiEntities operation.

source§

impl Client

source

pub fn create_dataset(&self) -> CreateDatasetFluentBuilder

Constructs a fluent builder for the CreateDataset operation.

source§

impl Client

source

pub fn create_document_classifier( &self ) -> CreateDocumentClassifierFluentBuilder

Constructs a fluent builder for the CreateDocumentClassifier operation.

source§

impl Client

source

pub fn create_endpoint(&self) -> CreateEndpointFluentBuilder

Constructs a fluent builder for the CreateEndpoint operation.

source§

impl Client

source

pub fn create_entity_recognizer(&self) -> CreateEntityRecognizerFluentBuilder

Constructs a fluent builder for the CreateEntityRecognizer operation.

  • The fluent builder is configurable:
    • recognizer_name(impl Into<String>) / set_recognizer_name(Option<String>):
      required: true

      The name given to the newly created recognizer. Recognizer names can be a maximum of 256 characters. Alphanumeric characters, hyphens (-) and underscores (_) are allowed. The name must be unique in the account/Region.


    • version_name(impl Into<String>) / set_version_name(Option<String>):
      required: false

      The version name given to the newly created recognizer. Version names can be a maximum of 256 characters. Alphanumeric characters, hyphens (-) and underscores (_) are allowed. The version name must be unique among all models with the same recognizer name in the account/Region.


    • data_access_role_arn(impl Into<String>) / set_data_access_role_arn(Option<String>):
      required: true

      The Amazon Resource Name (ARN) of the IAM role that grants Amazon Comprehend read access to your input data.


    • tags(Tag) / set_tags(Option<Vec::<Tag>>):
      required: false

      Tags to associate with the entity recognizer. A tag is a key-value pair that adds as a metadata to a resource used by Amazon Comprehend. For example, a tag with “Sales” as the key might be added to a resource to indicate its use by the sales department.


    • input_data_config(EntityRecognizerInputDataConfig) / set_input_data_config(Option<EntityRecognizerInputDataConfig>):
      required: true

      Specifies the format and location of the input data. The S3 bucket containing the input data must be located in the same Region as the entity recognizer being created.


    • client_request_token(impl Into<String>) / set_client_request_token(Option<String>):
      required: false

      A unique identifier for the request. If you don’t set the client request token, Amazon Comprehend generates one.


    • language_code(LanguageCode) / set_language_code(Option<LanguageCode>):
      required: true

      You can specify any of the following languages: English (“en”), Spanish (“es”), French (“fr”), Italian (“it”), German (“de”), or Portuguese (“pt”). If you plan to use this entity recognizer with PDF, Word, or image input files, you must specify English as the language. All training documents must be in the same language.


    • volume_kms_key_id(impl Into<String>) / set_volume_kms_key_id(Option<String>):
      required: false

      ID for the Amazon Web Services Key Management Service (KMS) key that Amazon Comprehend uses to encrypt data on the storage volume attached to the ML compute instance(s) that process the analysis job. The VolumeKmsKeyId can be either of the following formats:

      • KMS Key ID: “1234abcd-12ab-34cd-56ef-1234567890ab”

      • Amazon Resource Name (ARN) of a KMS Key: “arn:aws:kms:us-west-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab”


    • vpc_config(VpcConfig) / set_vpc_config(Option<VpcConfig>):
      required: false

      Configuration parameters for an optional private Virtual Private Cloud (VPC) containing the resources you are using for your custom entity recognizer. For more information, see Amazon VPC.


    • model_kms_key_id(impl Into<String>) / set_model_kms_key_id(Option<String>):
      required: false

      ID for the KMS key that Amazon Comprehend uses to encrypt trained custom models. The ModelKmsKeyId can be either of the following formats:

      • KMS Key ID: “1234abcd-12ab-34cd-56ef-1234567890ab”

      • Amazon Resource Name (ARN) of a KMS Key: “arn:aws:kms:us-west-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab”


    • model_policy(impl Into<String>) / set_model_policy(Option<String>):
      required: false

      The JSON resource-based policy to attach to your custom entity recognizer model. You can use this policy to allow another Amazon Web Services account to import your custom model.

      Provide your JSON as a UTF-8 encoded string without line breaks. To provide valid JSON for your policy, enclose the attribute names and values in double quotes. If the JSON body is also enclosed in double quotes, then you must escape the double quotes that are inside the policy:

      “{"attribute": "value", "attribute": ["value"]}”

      To avoid escaping quotes, you can use single quotes to enclose the policy and double quotes to enclose the JSON names and values:

      ‘{“attribute”: “value”, “attribute”: [“value”]}’


  • On success, responds with CreateEntityRecognizerOutput with field(s):
  • On failure, responds with SdkError<CreateEntityRecognizerError>
source§

impl Client

source

pub fn create_flywheel(&self) -> CreateFlywheelFluentBuilder

Constructs a fluent builder for the CreateFlywheel operation.

source§

impl Client

source

pub fn delete_document_classifier( &self ) -> DeleteDocumentClassifierFluentBuilder

Constructs a fluent builder for the DeleteDocumentClassifier operation.

source§

impl Client

source

pub fn delete_endpoint(&self) -> DeleteEndpointFluentBuilder

Constructs a fluent builder for the DeleteEndpoint operation.

source§

impl Client

source

pub fn delete_entity_recognizer(&self) -> DeleteEntityRecognizerFluentBuilder

Constructs a fluent builder for the DeleteEntityRecognizer operation.

source§

impl Client

source

pub fn delete_flywheel(&self) -> DeleteFlywheelFluentBuilder

Constructs a fluent builder for the DeleteFlywheel operation.

source§

impl Client

source

pub fn delete_resource_policy(&self) -> DeleteResourcePolicyFluentBuilder

Constructs a fluent builder for the DeleteResourcePolicy operation.

source§

impl Client

source

pub fn describe_dataset(&self) -> DescribeDatasetFluentBuilder

Constructs a fluent builder for the DescribeDataset operation.

source§

impl Client

source

pub fn describe_document_classification_job( &self ) -> DescribeDocumentClassificationJobFluentBuilder

Constructs a fluent builder for the DescribeDocumentClassificationJob operation.

source§

impl Client

source

pub fn describe_document_classifier( &self ) -> DescribeDocumentClassifierFluentBuilder

Constructs a fluent builder for the DescribeDocumentClassifier operation.

source§

impl Client

source

pub fn describe_dominant_language_detection_job( &self ) -> DescribeDominantLanguageDetectionJobFluentBuilder

Constructs a fluent builder for the DescribeDominantLanguageDetectionJob operation.

source§

impl Client

source

pub fn describe_endpoint(&self) -> DescribeEndpointFluentBuilder

Constructs a fluent builder for the DescribeEndpoint operation.

source§

impl Client

source

pub fn describe_entities_detection_job( &self ) -> DescribeEntitiesDetectionJobFluentBuilder

Constructs a fluent builder for the DescribeEntitiesDetectionJob operation.

source§

impl Client

source

pub fn describe_entity_recognizer( &self ) -> DescribeEntityRecognizerFluentBuilder

Constructs a fluent builder for the DescribeEntityRecognizer operation.

source§

impl Client

source

pub fn describe_events_detection_job( &self ) -> DescribeEventsDetectionJobFluentBuilder

Constructs a fluent builder for the DescribeEventsDetectionJob operation.

source§

impl Client

source

pub fn describe_flywheel(&self) -> DescribeFlywheelFluentBuilder

Constructs a fluent builder for the DescribeFlywheel operation.

source§

impl Client

source

pub fn describe_flywheel_iteration( &self ) -> DescribeFlywheelIterationFluentBuilder

Constructs a fluent builder for the DescribeFlywheelIteration operation.

source§

impl Client

source

pub fn describe_key_phrases_detection_job( &self ) -> DescribeKeyPhrasesDetectionJobFluentBuilder

Constructs a fluent builder for the DescribeKeyPhrasesDetectionJob operation.

source§

impl Client

source

pub fn describe_pii_entities_detection_job( &self ) -> DescribePiiEntitiesDetectionJobFluentBuilder

Constructs a fluent builder for the DescribePiiEntitiesDetectionJob operation.

source§

impl Client

source

pub fn describe_resource_policy(&self) -> DescribeResourcePolicyFluentBuilder

Constructs a fluent builder for the DescribeResourcePolicy operation.

source§

impl Client

source

pub fn describe_sentiment_detection_job( &self ) -> DescribeSentimentDetectionJobFluentBuilder

Constructs a fluent builder for the DescribeSentimentDetectionJob operation.

source§

impl Client

source

pub fn describe_targeted_sentiment_detection_job( &self ) -> DescribeTargetedSentimentDetectionJobFluentBuilder

Constructs a fluent builder for the DescribeTargetedSentimentDetectionJob operation.

source§

impl Client

source

pub fn describe_topics_detection_job( &self ) -> DescribeTopicsDetectionJobFluentBuilder

Constructs a fluent builder for the DescribeTopicsDetectionJob operation.

source§

impl Client

source

pub fn detect_dominant_language(&self) -> DetectDominantLanguageFluentBuilder

Constructs a fluent builder for the DetectDominantLanguage operation.

source§

impl Client

source

pub fn detect_entities(&self) -> DetectEntitiesFluentBuilder

Constructs a fluent builder for the DetectEntities operation.

  • The fluent builder is configurable:
    • text(impl Into<String>) / set_text(Option<String>):
      required: false

      A UTF-8 text string. The maximum string size is 100 KB. If you enter text using this parameter, do not use the Bytes parameter.


    • language_code(LanguageCode) / set_language_code(Option<LanguageCode>):
      required: false

      The language of the input documents. You can specify any of the primary languages supported by Amazon Comprehend. If your request includes the endpoint for a custom entity recognition model, Amazon Comprehend uses the language of your custom model, and it ignores any language code that you specify here.

      All input documents must be in the same language.


    • endpoint_arn(impl Into<String>) / set_endpoint_arn(Option<String>):
      required: false

      The Amazon Resource Name of an endpoint that is associated with a custom entity recognition model. Provide an endpoint if you want to detect entities by using your own custom model instead of the default model that is used by Amazon Comprehend.

      If you specify an endpoint, Amazon Comprehend uses the language of your custom model, and it ignores any language code that you provide in your request.

      For information about endpoints, see Managing endpoints.


    • bytes(Blob) / set_bytes(Option<Blob>):
      required: false

      This field applies only when you use a custom entity recognition model that was trained with PDF annotations. For other cases, enter your text input in the Text field.

      Use the Bytes parameter to input a text, PDF, Word or image file. Using a plain-text file in the Bytes parameter is equivelent to using the Text parameter (the Entities field in the response is identical).

      You can also use the Bytes parameter to input an Amazon Textract DetectDocumentText or AnalyzeDocument output file.

      Provide the input document as a sequence of base64-encoded bytes. If your code uses an Amazon Web Services SDK to detect entities, the SDK may encode the document file bytes for you.

      The maximum length of this field depends on the input document type. For details, see Inputs for real-time custom analysis in the Comprehend Developer Guide.

      If you use the Bytes parameter, do not use the Text parameter.


    • document_reader_config(DocumentReaderConfig) / set_document_reader_config(Option<DocumentReaderConfig>):
      required: false

      Provides configuration parameters to override the default actions for extracting text from PDF documents and image files.


  • On success, responds with DetectEntitiesOutput with field(s):
    • entities(Option<Vec::<Entity>>):

      A collection of entities identified in the input text. For each entity, the response provides the entity text, entity type, where the entity text begins and ends, and the level of confidence that Amazon Comprehend has in the detection.

      If your request uses a custom entity recognition model, Amazon Comprehend detects the entities that the model is trained to recognize. Otherwise, it detects the default entity types. For a list of default entity types, see Entities in the Comprehend Developer Guide.

    • document_metadata(Option<DocumentMetadata>):

      Information about the document, discovered during text extraction. This field is present in the response only if your request used the Byte parameter.

    • document_type(Option<Vec::<DocumentTypeListItem>>):

      The document type for each page in the input document. This field is present in the response only if your request used the Byte parameter.

    • blocks(Option<Vec::<Block>>):

      Information about each block of text in the input document. Blocks are nested. A page block contains a block for each line of text, which contains a block for each word.

      The Block content for a Word input document does not include a Geometry field.

      The Block field is not present in the response for plain-text inputs.

    • errors(Option<Vec::<ErrorsListItem>>):

      Page-level errors that the system detected while processing the input document. The field is empty if the system encountered no errors.

  • On failure, responds with SdkError<DetectEntitiesError>
source§

impl Client

source

pub fn detect_key_phrases(&self) -> DetectKeyPhrasesFluentBuilder

Constructs a fluent builder for the DetectKeyPhrases operation.

source§

impl Client

source

pub fn detect_pii_entities(&self) -> DetectPiiEntitiesFluentBuilder

Constructs a fluent builder for the DetectPiiEntities operation.

source§

impl Client

source

pub fn detect_sentiment(&self) -> DetectSentimentFluentBuilder

Constructs a fluent builder for the DetectSentiment operation.

source§

impl Client

source

pub fn detect_syntax(&self) -> DetectSyntaxFluentBuilder

Constructs a fluent builder for the DetectSyntax operation.

source§

impl Client

source

pub fn detect_targeted_sentiment(&self) -> DetectTargetedSentimentFluentBuilder

Constructs a fluent builder for the DetectTargetedSentiment operation.

source§

impl Client

source

pub fn detect_toxic_content(&self) -> DetectToxicContentFluentBuilder

Constructs a fluent builder for the DetectToxicContent operation.

source§

impl Client

source

pub fn import_model(&self) -> ImportModelFluentBuilder

Constructs a fluent builder for the ImportModel operation.

source§

impl Client

source

pub fn list_datasets(&self) -> ListDatasetsFluentBuilder

Constructs a fluent builder for the ListDatasets operation. This operation supports pagination; See into_paginator().

source§

impl Client

source

pub fn list_document_classification_jobs( &self ) -> ListDocumentClassificationJobsFluentBuilder

Constructs a fluent builder for the ListDocumentClassificationJobs operation. This operation supports pagination; See into_paginator().

source§

impl Client

source

pub fn list_document_classifier_summaries( &self ) -> ListDocumentClassifierSummariesFluentBuilder

Constructs a fluent builder for the ListDocumentClassifierSummaries operation. This operation supports pagination; See into_paginator().

source§

impl Client

source

pub fn list_document_classifiers(&self) -> ListDocumentClassifiersFluentBuilder

Constructs a fluent builder for the ListDocumentClassifiers operation. This operation supports pagination; See into_paginator().

source§

impl Client

source

pub fn list_dominant_language_detection_jobs( &self ) -> ListDominantLanguageDetectionJobsFluentBuilder

Constructs a fluent builder for the ListDominantLanguageDetectionJobs operation. This operation supports pagination; See into_paginator().

source§

impl Client

source

pub fn list_endpoints(&self) -> ListEndpointsFluentBuilder

Constructs a fluent builder for the ListEndpoints operation. This operation supports pagination; See into_paginator().

source§

impl Client

source

pub fn list_entities_detection_jobs( &self ) -> ListEntitiesDetectionJobsFluentBuilder

Constructs a fluent builder for the ListEntitiesDetectionJobs operation. This operation supports pagination; See into_paginator().

source§

impl Client

source

pub fn list_entity_recognizer_summaries( &self ) -> ListEntityRecognizerSummariesFluentBuilder

Constructs a fluent builder for the ListEntityRecognizerSummaries operation. This operation supports pagination; See into_paginator().

source§

impl Client

source

pub fn list_entity_recognizers(&self) -> ListEntityRecognizersFluentBuilder

Constructs a fluent builder for the ListEntityRecognizers operation. This operation supports pagination; See into_paginator().

source§

impl Client

source

pub fn list_events_detection_jobs(&self) -> ListEventsDetectionJobsFluentBuilder

Constructs a fluent builder for the ListEventsDetectionJobs operation. This operation supports pagination; See into_paginator().

source§

impl Client

source

pub fn list_flywheel_iteration_history( &self ) -> ListFlywheelIterationHistoryFluentBuilder

Constructs a fluent builder for the ListFlywheelIterationHistory operation. This operation supports pagination; See into_paginator().

source§

impl Client

source

pub fn list_flywheels(&self) -> ListFlywheelsFluentBuilder

Constructs a fluent builder for the ListFlywheels operation. This operation supports pagination; See into_paginator().

source§

impl Client

source

pub fn list_key_phrases_detection_jobs( &self ) -> ListKeyPhrasesDetectionJobsFluentBuilder

Constructs a fluent builder for the ListKeyPhrasesDetectionJobs operation. This operation supports pagination; See into_paginator().

source§

impl Client

source

pub fn list_pii_entities_detection_jobs( &self ) -> ListPiiEntitiesDetectionJobsFluentBuilder

Constructs a fluent builder for the ListPiiEntitiesDetectionJobs operation. This operation supports pagination; See into_paginator().

source§

impl Client

source

pub fn list_sentiment_detection_jobs( &self ) -> ListSentimentDetectionJobsFluentBuilder

Constructs a fluent builder for the ListSentimentDetectionJobs operation. This operation supports pagination; See into_paginator().

source§

impl Client

source

pub fn list_tags_for_resource(&self) -> ListTagsForResourceFluentBuilder

Constructs a fluent builder for the ListTagsForResource operation.

source§

impl Client

source

pub fn list_targeted_sentiment_detection_jobs( &self ) -> ListTargetedSentimentDetectionJobsFluentBuilder

Constructs a fluent builder for the ListTargetedSentimentDetectionJobs operation. This operation supports pagination; See into_paginator().

source§

impl Client

source

pub fn list_topics_detection_jobs(&self) -> ListTopicsDetectionJobsFluentBuilder

Constructs a fluent builder for the ListTopicsDetectionJobs operation. This operation supports pagination; See into_paginator().

source§

impl Client

source

pub fn put_resource_policy(&self) -> PutResourcePolicyFluentBuilder

Constructs a fluent builder for the PutResourcePolicy operation.

  • The fluent builder is configurable:
    • resource_arn(impl Into<String>) / set_resource_arn(Option<String>):
      required: true

      The Amazon Resource Name (ARN) of the custom model to attach the policy to.


    • resource_policy(impl Into<String>) / set_resource_policy(Option<String>):
      required: true

      The JSON resource-based policy to attach to your custom model. Provide your JSON as a UTF-8 encoded string without line breaks. To provide valid JSON for your policy, enclose the attribute names and values in double quotes. If the JSON body is also enclosed in double quotes, then you must escape the double quotes that are inside the policy:

      “{"attribute": "value", "attribute": ["value"]}”

      To avoid escaping quotes, you can use single quotes to enclose the policy and double quotes to enclose the JSON names and values:

      ‘{“attribute”: “value”, “attribute”: [“value”]}’


    • policy_revision_id(impl Into<String>) / set_policy_revision_id(Option<String>):
      required: false

      The revision ID that Amazon Comprehend assigned to the policy that you are updating. If you are creating a new policy that has no prior version, don’t use this parameter. Amazon Comprehend creates the revision ID for you.


  • On success, responds with PutResourcePolicyOutput with field(s):
    • policy_revision_id(Option<String>):

      The revision ID of the policy. Each time you modify a policy, Amazon Comprehend assigns a new revision ID, and it deletes the prior version of the policy.

  • On failure, responds with SdkError<PutResourcePolicyError>
source§

impl Client

source

pub fn start_document_classification_job( &self ) -> StartDocumentClassificationJobFluentBuilder

Constructs a fluent builder for the StartDocumentClassificationJob operation.

source§

impl Client

source

pub fn start_dominant_language_detection_job( &self ) -> StartDominantLanguageDetectionJobFluentBuilder

Constructs a fluent builder for the StartDominantLanguageDetectionJob operation.

source§

impl Client

source

pub fn start_entities_detection_job( &self ) -> StartEntitiesDetectionJobFluentBuilder

Constructs a fluent builder for the StartEntitiesDetectionJob operation.

source§

impl Client

source

pub fn start_events_detection_job(&self) -> StartEventsDetectionJobFluentBuilder

Constructs a fluent builder for the StartEventsDetectionJob operation.

source§

impl Client

source

pub fn start_flywheel_iteration(&self) -> StartFlywheelIterationFluentBuilder

Constructs a fluent builder for the StartFlywheelIteration operation.

source§

impl Client

source

pub fn start_key_phrases_detection_job( &self ) -> StartKeyPhrasesDetectionJobFluentBuilder

Constructs a fluent builder for the StartKeyPhrasesDetectionJob operation.

source§

impl Client

source

pub fn start_pii_entities_detection_job( &self ) -> StartPiiEntitiesDetectionJobFluentBuilder

Constructs a fluent builder for the StartPiiEntitiesDetectionJob operation.

source§

impl Client

source

pub fn start_sentiment_detection_job( &self ) -> StartSentimentDetectionJobFluentBuilder

Constructs a fluent builder for the StartSentimentDetectionJob operation.

source§

impl Client

source

pub fn start_targeted_sentiment_detection_job( &self ) -> StartTargetedSentimentDetectionJobFluentBuilder

Constructs a fluent builder for the StartTargetedSentimentDetectionJob operation.

source§

impl Client

source

pub fn start_topics_detection_job(&self) -> StartTopicsDetectionJobFluentBuilder

Constructs a fluent builder for the StartTopicsDetectionJob operation.

source§

impl Client

source

pub fn stop_dominant_language_detection_job( &self ) -> StopDominantLanguageDetectionJobFluentBuilder

Constructs a fluent builder for the StopDominantLanguageDetectionJob operation.

source§

impl Client

source

pub fn stop_entities_detection_job( &self ) -> StopEntitiesDetectionJobFluentBuilder

Constructs a fluent builder for the StopEntitiesDetectionJob operation.

source§

impl Client

source

pub fn stop_events_detection_job(&self) -> StopEventsDetectionJobFluentBuilder

Constructs a fluent builder for the StopEventsDetectionJob operation.

source§

impl Client

source

pub fn stop_key_phrases_detection_job( &self ) -> StopKeyPhrasesDetectionJobFluentBuilder

Constructs a fluent builder for the StopKeyPhrasesDetectionJob operation.

source§

impl Client

source

pub fn stop_pii_entities_detection_job( &self ) -> StopPiiEntitiesDetectionJobFluentBuilder

Constructs a fluent builder for the StopPiiEntitiesDetectionJob operation.

source§

impl Client

source

pub fn stop_sentiment_detection_job( &self ) -> StopSentimentDetectionJobFluentBuilder

Constructs a fluent builder for the StopSentimentDetectionJob operation.

source§

impl Client

source

pub fn stop_targeted_sentiment_detection_job( &self ) -> StopTargetedSentimentDetectionJobFluentBuilder

Constructs a fluent builder for the StopTargetedSentimentDetectionJob operation.

source§

impl Client

source

pub fn stop_training_document_classifier( &self ) -> StopTrainingDocumentClassifierFluentBuilder

Constructs a fluent builder for the StopTrainingDocumentClassifier operation.

source§

impl Client

source

pub fn stop_training_entity_recognizer( &self ) -> StopTrainingEntityRecognizerFluentBuilder

Constructs a fluent builder for the StopTrainingEntityRecognizer operation.

source§

impl Client

source

pub fn tag_resource(&self) -> TagResourceFluentBuilder

Constructs a fluent builder for the TagResource operation.

source§

impl Client

source

pub fn untag_resource(&self) -> UntagResourceFluentBuilder

Constructs a fluent builder for the UntagResource operation.

source§

impl Client

source

pub fn update_endpoint(&self) -> UpdateEndpointFluentBuilder

Constructs a fluent builder for the UpdateEndpoint operation.

source§

impl Client

source

pub fn update_flywheel(&self) -> UpdateFlywheelFluentBuilder

Constructs a fluent builder for the UpdateFlywheel operation.

source§

impl Client

source

pub fn from_conf(conf: Config) -> Self

Creates a new client from the service Config.

§Panics

This method will panic in the following cases:

  • Retries or timeouts are enabled without a sleep_impl configured.
  • Identity caching is enabled without a sleep_impl and time_source configured.
  • No behavior_version is provided.

The panic message for each of these will have instructions on how to resolve them.

source

pub fn config(&self) -> &Config

Returns the client’s configuration.

source§

impl Client

source

pub fn new(sdk_config: &SdkConfig) -> Self

Creates a new client from an SDK Config.

§Panics
  • This method will panic if the sdk_config is missing an async sleep implementation. If you experience this panic, set the sleep_impl on the Config passed into this function to fix it.
  • This method will panic if the sdk_config is missing an HTTP connector. If you experience this panic, set the http_connector on the Config passed into this function to fix it.
  • This method will panic if no BehaviorVersion is provided. If you experience this panic, set behavior_version on the Config or enable the behavior-version-latest Cargo feature.

Trait Implementations§

source§

impl Clone for Client

source§

fn clone(&self) -> Client

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for Client

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more

Auto Trait Implementations§

§

impl Freeze for Client

§

impl !RefUnwindSafe for Client

§

impl Send for Client

§

impl Sync for Client

§

impl Unpin for Client

§

impl !UnwindSafe for Client

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

impl<T> Instrument for T

source§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
source§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
source§

impl<T, U> Into<U> for T
where U: From<T>,

source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

source§

impl<T> IntoEither for T

source§

fn into_either(self, into_left: bool) -> Either<Self, Self>

Converts 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 more
source§

fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
where F: FnOnce(&Self) -> bool,

Converts 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 more
source§

impl<Unshared, Shared> IntoShared<Shared> for Unshared
where Shared: FromUnshared<Unshared>,

source§

fn into_shared(self) -> Shared

Creates a shared type from an unshared type.
source§

impl<T> Same for T

§

type Output = T

Should always be Self
source§

impl<T> ToOwned for T
where T: Clone,

§

type Owned = T

The resulting type after obtaining ownership.
source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
source§

impl<T> WithSubscriber for T

source§

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
source§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more