All Downloads are FREE. Search and download functionalities are using the official Maven repository.

software.amazon.awssdk.services.transcribe.model.MedicalScribeJobSummary Maven / Gradle / Ivy

Go to download

The AWS Java SDK for Transcribe module holds the client classes that are used for communicating with Transcribe.

There is a newer version: 2.29.39
Show newest version
/*
 * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
 * 
 * Licensed under the Apache License, Version 2.0 (the "License"). You may not use this file except in compliance with
 * the License. A copy of the License is located at
 * 
 * http://aws.amazon.com/apache2.0
 * 
 * or in the "license" file accompanying this file. This file is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
 * CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions
 * and limitations under the License.
 */

package software.amazon.awssdk.services.transcribe.model;

import java.io.Serializable;
import java.time.Instant;
import java.util.Arrays;
import java.util.Collections;
import java.util.List;
import java.util.Objects;
import java.util.Optional;
import java.util.function.BiConsumer;
import java.util.function.Function;
import software.amazon.awssdk.annotations.Generated;
import software.amazon.awssdk.core.SdkField;
import software.amazon.awssdk.core.SdkPojo;
import software.amazon.awssdk.core.protocol.MarshallLocation;
import software.amazon.awssdk.core.protocol.MarshallingType;
import software.amazon.awssdk.core.traits.LocationTrait;
import software.amazon.awssdk.utils.ToString;
import software.amazon.awssdk.utils.builder.CopyableBuilder;
import software.amazon.awssdk.utils.builder.ToCopyableBuilder;

/**
 * 

* Provides detailed information about a specific Medical Scribe job. *

*/ @Generated("software.amazon.awssdk:codegen") public final class MedicalScribeJobSummary implements SdkPojo, Serializable, ToCopyableBuilder { private static final SdkField MEDICAL_SCRIBE_JOB_NAME_FIELD = SdkField. builder(MarshallingType.STRING) .memberName("MedicalScribeJobName").getter(getter(MedicalScribeJobSummary::medicalScribeJobName)) .setter(setter(Builder::medicalScribeJobName)) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("MedicalScribeJobName").build()) .build(); private static final SdkField CREATION_TIME_FIELD = SdkField. builder(MarshallingType.INSTANT) .memberName("CreationTime").getter(getter(MedicalScribeJobSummary::creationTime)) .setter(setter(Builder::creationTime)) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("CreationTime").build()).build(); private static final SdkField START_TIME_FIELD = SdkField. builder(MarshallingType.INSTANT) .memberName("StartTime").getter(getter(MedicalScribeJobSummary::startTime)).setter(setter(Builder::startTime)) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("StartTime").build()).build(); private static final SdkField COMPLETION_TIME_FIELD = SdkField. builder(MarshallingType.INSTANT) .memberName("CompletionTime").getter(getter(MedicalScribeJobSummary::completionTime)) .setter(setter(Builder::completionTime)) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("CompletionTime").build()).build(); private static final SdkField LANGUAGE_CODE_FIELD = SdkField. builder(MarshallingType.STRING) .memberName("LanguageCode").getter(getter(MedicalScribeJobSummary::languageCodeAsString)) .setter(setter(Builder::languageCode)) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("LanguageCode").build()).build(); private static final SdkField MEDICAL_SCRIBE_JOB_STATUS_FIELD = SdkField. builder(MarshallingType.STRING) .memberName("MedicalScribeJobStatus").getter(getter(MedicalScribeJobSummary::medicalScribeJobStatusAsString)) .setter(setter(Builder::medicalScribeJobStatus)) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("MedicalScribeJobStatus").build()) .build(); private static final SdkField FAILURE_REASON_FIELD = SdkField. builder(MarshallingType.STRING) .memberName("FailureReason").getter(getter(MedicalScribeJobSummary::failureReason)) .setter(setter(Builder::failureReason)) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("FailureReason").build()).build(); private static final List> SDK_FIELDS = Collections.unmodifiableList(Arrays.asList(MEDICAL_SCRIBE_JOB_NAME_FIELD, CREATION_TIME_FIELD, START_TIME_FIELD, COMPLETION_TIME_FIELD, LANGUAGE_CODE_FIELD, MEDICAL_SCRIBE_JOB_STATUS_FIELD, FAILURE_REASON_FIELD)); private static final long serialVersionUID = 1L; private final String medicalScribeJobName; private final Instant creationTime; private final Instant startTime; private final Instant completionTime; private final String languageCode; private final String medicalScribeJobStatus; private final String failureReason; private MedicalScribeJobSummary(BuilderImpl builder) { this.medicalScribeJobName = builder.medicalScribeJobName; this.creationTime = builder.creationTime; this.startTime = builder.startTime; this.completionTime = builder.completionTime; this.languageCode = builder.languageCode; this.medicalScribeJobStatus = builder.medicalScribeJobStatus; this.failureReason = builder.failureReason; } /** *

* The name of the Medical Scribe job. Job names are case sensitive and must be unique within an Amazon Web Services * account. *

* * @return The name of the Medical Scribe job. Job names are case sensitive and must be unique within an Amazon Web * Services account. */ public final String medicalScribeJobName() { return medicalScribeJobName; } /** *

* The date and time the specified Medical Scribe job request was made. *

*

* Timestamps are in the format YYYY-MM-DD'T'HH:MM:SS.SSSSSS-UTC. For example, * 2022-05-04T12:32:58.761000-07:00 represents a Medical Scribe job that started processing at 12:32 PM * UTC-7 on May 4, 2022. *

* * @return The date and time the specified Medical Scribe job request was made.

*

* Timestamps are in the format YYYY-MM-DD'T'HH:MM:SS.SSSSSS-UTC. For example, * 2022-05-04T12:32:58.761000-07:00 represents a Medical Scribe job that started processing at * 12:32 PM UTC-7 on May 4, 2022. */ public final Instant creationTime() { return creationTime; } /** *

* The date and time your Medical Scribe job began processing. *

*

* Timestamps are in the format YYYY-MM-DD'T'HH:MM:SS.SSSSSS-UTC. For example, * 2022-05-04T12:32:58.789000-07:00 represents a Medical Scribe job that started processing at 12:32 PM * UTC-7 on May 4, 2022. *

* * @return The date and time your Medical Scribe job began processing.

*

* Timestamps are in the format YYYY-MM-DD'T'HH:MM:SS.SSSSSS-UTC. For example, * 2022-05-04T12:32:58.789000-07:00 represents a Medical Scribe job that started processing at * 12:32 PM UTC-7 on May 4, 2022. */ public final Instant startTime() { return startTime; } /** *

* The date and time the specified Medical Scribe job finished processing. *

*

* Timestamps are in the format YYYY-MM-DD'T'HH:MM:SS.SSSSSS-UTC. For example, * 2022-05-04T12:32:58.761000-07:00 represents a Medical Scribe job that finished processing at 12:32 * PM UTC-7 on May 4, 2022. *

* * @return The date and time the specified Medical Scribe job finished processing.

*

* Timestamps are in the format YYYY-MM-DD'T'HH:MM:SS.SSSSSS-UTC. For example, * 2022-05-04T12:32:58.761000-07:00 represents a Medical Scribe job that finished processing at * 12:32 PM UTC-7 on May 4, 2022. */ public final Instant completionTime() { return completionTime; } /** *

* The language code used to create your Medical Scribe job. US English (en-US) is the only supported * language for Medical Scribe jobs. *

*

* If the service returns an enum value that is not available in the current SDK version, {@link #languageCode} will * return {@link MedicalScribeLanguageCode#UNKNOWN_TO_SDK_VERSION}. The raw value returned by the service is * available from {@link #languageCodeAsString}. *

* * @return The language code used to create your Medical Scribe job. US English (en-US) is the only * supported language for Medical Scribe jobs. * @see MedicalScribeLanguageCode */ public final MedicalScribeLanguageCode languageCode() { return MedicalScribeLanguageCode.fromValue(languageCode); } /** *

* The language code used to create your Medical Scribe job. US English (en-US) is the only supported * language for Medical Scribe jobs. *

*

* If the service returns an enum value that is not available in the current SDK version, {@link #languageCode} will * return {@link MedicalScribeLanguageCode#UNKNOWN_TO_SDK_VERSION}. The raw value returned by the service is * available from {@link #languageCodeAsString}. *

* * @return The language code used to create your Medical Scribe job. US English (en-US) is the only * supported language for Medical Scribe jobs. * @see MedicalScribeLanguageCode */ public final String languageCodeAsString() { return languageCode; } /** *

* Provides the status of the specified Medical Scribe job. *

*

* If the status is COMPLETED, the job is finished and you can find the results at the location * specified in MedicalScribeOutput If the status is FAILED, FailureReason * provides details on why your Medical Scribe job failed. *

*

* If the service returns an enum value that is not available in the current SDK version, * {@link #medicalScribeJobStatus} will return {@link MedicalScribeJobStatus#UNKNOWN_TO_SDK_VERSION}. The raw value * returned by the service is available from {@link #medicalScribeJobStatusAsString}. *

* * @return Provides the status of the specified Medical Scribe job.

*

* If the status is COMPLETED, the job is finished and you can find the results at the location * specified in MedicalScribeOutput If the status is FAILED, * FailureReason provides details on why your Medical Scribe job failed. * @see MedicalScribeJobStatus */ public final MedicalScribeJobStatus medicalScribeJobStatus() { return MedicalScribeJobStatus.fromValue(medicalScribeJobStatus); } /** *

* Provides the status of the specified Medical Scribe job. *

*

* If the status is COMPLETED, the job is finished and you can find the results at the location * specified in MedicalScribeOutput If the status is FAILED, FailureReason * provides details on why your Medical Scribe job failed. *

*

* If the service returns an enum value that is not available in the current SDK version, * {@link #medicalScribeJobStatus} will return {@link MedicalScribeJobStatus#UNKNOWN_TO_SDK_VERSION}. The raw value * returned by the service is available from {@link #medicalScribeJobStatusAsString}. *

* * @return Provides the status of the specified Medical Scribe job.

*

* If the status is COMPLETED, the job is finished and you can find the results at the location * specified in MedicalScribeOutput If the status is FAILED, * FailureReason provides details on why your Medical Scribe job failed. * @see MedicalScribeJobStatus */ public final String medicalScribeJobStatusAsString() { return medicalScribeJobStatus; } /** *

* If MedicalScribeJobStatus is FAILED, FailureReason contains information * about why the transcription job failed. See also: Common Errors. *

* * @return If MedicalScribeJobStatus is FAILED, FailureReason contains * information about why the transcription job failed. See also: Common Errors. */ public final String failureReason() { return failureReason; } @Override public Builder toBuilder() { return new BuilderImpl(this); } public static Builder builder() { return new BuilderImpl(); } public static Class serializableBuilderClass() { return BuilderImpl.class; } @Override public final int hashCode() { int hashCode = 1; hashCode = 31 * hashCode + Objects.hashCode(medicalScribeJobName()); hashCode = 31 * hashCode + Objects.hashCode(creationTime()); hashCode = 31 * hashCode + Objects.hashCode(startTime()); hashCode = 31 * hashCode + Objects.hashCode(completionTime()); hashCode = 31 * hashCode + Objects.hashCode(languageCodeAsString()); hashCode = 31 * hashCode + Objects.hashCode(medicalScribeJobStatusAsString()); hashCode = 31 * hashCode + Objects.hashCode(failureReason()); return hashCode; } @Override public final boolean equals(Object obj) { return equalsBySdkFields(obj); } @Override public final boolean equalsBySdkFields(Object obj) { if (this == obj) { return true; } if (obj == null) { return false; } if (!(obj instanceof MedicalScribeJobSummary)) { return false; } MedicalScribeJobSummary other = (MedicalScribeJobSummary) obj; return Objects.equals(medicalScribeJobName(), other.medicalScribeJobName()) && Objects.equals(creationTime(), other.creationTime()) && Objects.equals(startTime(), other.startTime()) && Objects.equals(completionTime(), other.completionTime()) && Objects.equals(languageCodeAsString(), other.languageCodeAsString()) && Objects.equals(medicalScribeJobStatusAsString(), other.medicalScribeJobStatusAsString()) && Objects.equals(failureReason(), other.failureReason()); } /** * Returns a string representation of this object. This is useful for testing and debugging. Sensitive data will be * redacted from this string using a placeholder value. */ @Override public final String toString() { return ToString.builder("MedicalScribeJobSummary").add("MedicalScribeJobName", medicalScribeJobName()) .add("CreationTime", creationTime()).add("StartTime", startTime()).add("CompletionTime", completionTime()) .add("LanguageCode", languageCodeAsString()).add("MedicalScribeJobStatus", medicalScribeJobStatusAsString()) .add("FailureReason", failureReason()).build(); } public final Optional getValueForField(String fieldName, Class clazz) { switch (fieldName) { case "MedicalScribeJobName": return Optional.ofNullable(clazz.cast(medicalScribeJobName())); case "CreationTime": return Optional.ofNullable(clazz.cast(creationTime())); case "StartTime": return Optional.ofNullable(clazz.cast(startTime())); case "CompletionTime": return Optional.ofNullable(clazz.cast(completionTime())); case "LanguageCode": return Optional.ofNullable(clazz.cast(languageCodeAsString())); case "MedicalScribeJobStatus": return Optional.ofNullable(clazz.cast(medicalScribeJobStatusAsString())); case "FailureReason": return Optional.ofNullable(clazz.cast(failureReason())); default: return Optional.empty(); } } @Override public final List> sdkFields() { return SDK_FIELDS; } private static Function getter(Function g) { return obj -> g.apply((MedicalScribeJobSummary) obj); } private static BiConsumer setter(BiConsumer s) { return (obj, val) -> s.accept((Builder) obj, val); } public interface Builder extends SdkPojo, CopyableBuilder { /** *

* The name of the Medical Scribe job. Job names are case sensitive and must be unique within an Amazon Web * Services account. *

* * @param medicalScribeJobName * The name of the Medical Scribe job. Job names are case sensitive and must be unique within an Amazon * Web Services account. * @return Returns a reference to this object so that method calls can be chained together. */ Builder medicalScribeJobName(String medicalScribeJobName); /** *

* The date and time the specified Medical Scribe job request was made. *

*

* Timestamps are in the format YYYY-MM-DD'T'HH:MM:SS.SSSSSS-UTC. For example, * 2022-05-04T12:32:58.761000-07:00 represents a Medical Scribe job that started processing at * 12:32 PM UTC-7 on May 4, 2022. *

* * @param creationTime * The date and time the specified Medical Scribe job request was made.

*

* Timestamps are in the format YYYY-MM-DD'T'HH:MM:SS.SSSSSS-UTC. For example, * 2022-05-04T12:32:58.761000-07:00 represents a Medical Scribe job that started processing * at 12:32 PM UTC-7 on May 4, 2022. * @return Returns a reference to this object so that method calls can be chained together. */ Builder creationTime(Instant creationTime); /** *

* The date and time your Medical Scribe job began processing. *

*

* Timestamps are in the format YYYY-MM-DD'T'HH:MM:SS.SSSSSS-UTC. For example, * 2022-05-04T12:32:58.789000-07:00 represents a Medical Scribe job that started processing at * 12:32 PM UTC-7 on May 4, 2022. *

* * @param startTime * The date and time your Medical Scribe job began processing.

*

* Timestamps are in the format YYYY-MM-DD'T'HH:MM:SS.SSSSSS-UTC. For example, * 2022-05-04T12:32:58.789000-07:00 represents a Medical Scribe job that started processing * at 12:32 PM UTC-7 on May 4, 2022. * @return Returns a reference to this object so that method calls can be chained together. */ Builder startTime(Instant startTime); /** *

* The date and time the specified Medical Scribe job finished processing. *

*

* Timestamps are in the format YYYY-MM-DD'T'HH:MM:SS.SSSSSS-UTC. For example, * 2022-05-04T12:32:58.761000-07:00 represents a Medical Scribe job that finished processing at * 12:32 PM UTC-7 on May 4, 2022. *

* * @param completionTime * The date and time the specified Medical Scribe job finished processing.

*

* Timestamps are in the format YYYY-MM-DD'T'HH:MM:SS.SSSSSS-UTC. For example, * 2022-05-04T12:32:58.761000-07:00 represents a Medical Scribe job that finished processing * at 12:32 PM UTC-7 on May 4, 2022. * @return Returns a reference to this object so that method calls can be chained together. */ Builder completionTime(Instant completionTime); /** *

* The language code used to create your Medical Scribe job. US English (en-US) is the only * supported language for Medical Scribe jobs. *

* * @param languageCode * The language code used to create your Medical Scribe job. US English (en-US) is the only * supported language for Medical Scribe jobs. * @see MedicalScribeLanguageCode * @return Returns a reference to this object so that method calls can be chained together. * @see MedicalScribeLanguageCode */ Builder languageCode(String languageCode); /** *

* The language code used to create your Medical Scribe job. US English (en-US) is the only * supported language for Medical Scribe jobs. *

* * @param languageCode * The language code used to create your Medical Scribe job. US English (en-US) is the only * supported language for Medical Scribe jobs. * @see MedicalScribeLanguageCode * @return Returns a reference to this object so that method calls can be chained together. * @see MedicalScribeLanguageCode */ Builder languageCode(MedicalScribeLanguageCode languageCode); /** *

* Provides the status of the specified Medical Scribe job. *

*

* If the status is COMPLETED, the job is finished and you can find the results at the location * specified in MedicalScribeOutput If the status is FAILED, * FailureReason provides details on why your Medical Scribe job failed. *

* * @param medicalScribeJobStatus * Provides the status of the specified Medical Scribe job.

*

* If the status is COMPLETED, the job is finished and you can find the results at the * location specified in MedicalScribeOutput If the status is FAILED, * FailureReason provides details on why your Medical Scribe job failed. * @see MedicalScribeJobStatus * @return Returns a reference to this object so that method calls can be chained together. * @see MedicalScribeJobStatus */ Builder medicalScribeJobStatus(String medicalScribeJobStatus); /** *

* Provides the status of the specified Medical Scribe job. *

*

* If the status is COMPLETED, the job is finished and you can find the results at the location * specified in MedicalScribeOutput If the status is FAILED, * FailureReason provides details on why your Medical Scribe job failed. *

* * @param medicalScribeJobStatus * Provides the status of the specified Medical Scribe job.

*

* If the status is COMPLETED, the job is finished and you can find the results at the * location specified in MedicalScribeOutput If the status is FAILED, * FailureReason provides details on why your Medical Scribe job failed. * @see MedicalScribeJobStatus * @return Returns a reference to this object so that method calls can be chained together. * @see MedicalScribeJobStatus */ Builder medicalScribeJobStatus(MedicalScribeJobStatus medicalScribeJobStatus); /** *

* If MedicalScribeJobStatus is FAILED, FailureReason contains * information about why the transcription job failed. See also: Common Errors. *

* * @param failureReason * If MedicalScribeJobStatus is FAILED, FailureReason contains * information about why the transcription job failed. See also: Common Errors. * @return Returns a reference to this object so that method calls can be chained together. */ Builder failureReason(String failureReason); } static final class BuilderImpl implements Builder { private String medicalScribeJobName; private Instant creationTime; private Instant startTime; private Instant completionTime; private String languageCode; private String medicalScribeJobStatus; private String failureReason; private BuilderImpl() { } private BuilderImpl(MedicalScribeJobSummary model) { medicalScribeJobName(model.medicalScribeJobName); creationTime(model.creationTime); startTime(model.startTime); completionTime(model.completionTime); languageCode(model.languageCode); medicalScribeJobStatus(model.medicalScribeJobStatus); failureReason(model.failureReason); } public final String getMedicalScribeJobName() { return medicalScribeJobName; } public final void setMedicalScribeJobName(String medicalScribeJobName) { this.medicalScribeJobName = medicalScribeJobName; } @Override public final Builder medicalScribeJobName(String medicalScribeJobName) { this.medicalScribeJobName = medicalScribeJobName; return this; } public final Instant getCreationTime() { return creationTime; } public final void setCreationTime(Instant creationTime) { this.creationTime = creationTime; } @Override public final Builder creationTime(Instant creationTime) { this.creationTime = creationTime; return this; } public final Instant getStartTime() { return startTime; } public final void setStartTime(Instant startTime) { this.startTime = startTime; } @Override public final Builder startTime(Instant startTime) { this.startTime = startTime; return this; } public final Instant getCompletionTime() { return completionTime; } public final void setCompletionTime(Instant completionTime) { this.completionTime = completionTime; } @Override public final Builder completionTime(Instant completionTime) { this.completionTime = completionTime; return this; } public final String getLanguageCode() { return languageCode; } public final void setLanguageCode(String languageCode) { this.languageCode = languageCode; } @Override public final Builder languageCode(String languageCode) { this.languageCode = languageCode; return this; } @Override public final Builder languageCode(MedicalScribeLanguageCode languageCode) { this.languageCode(languageCode == null ? null : languageCode.toString()); return this; } public final String getMedicalScribeJobStatus() { return medicalScribeJobStatus; } public final void setMedicalScribeJobStatus(String medicalScribeJobStatus) { this.medicalScribeJobStatus = medicalScribeJobStatus; } @Override public final Builder medicalScribeJobStatus(String medicalScribeJobStatus) { this.medicalScribeJobStatus = medicalScribeJobStatus; return this; } @Override public final Builder medicalScribeJobStatus(MedicalScribeJobStatus medicalScribeJobStatus) { this.medicalScribeJobStatus(medicalScribeJobStatus == null ? null : medicalScribeJobStatus.toString()); return this; } public final String getFailureReason() { return failureReason; } public final void setFailureReason(String failureReason) { this.failureReason = failureReason; } @Override public final Builder failureReason(String failureReason) { this.failureReason = failureReason; return this; } @Override public MedicalScribeJobSummary build() { return new MedicalScribeJobSummary(this); } @Override public List> sdkFields() { return SDK_FIELDS; } } }




© 2015 - 2025 Weber Informatics LLC | Privacy Policy