From bb1c499a8d70a6583011e14d201b62ce78ac6169 Mon Sep 17 00:00:00 2001 From: SDKAuto Date: Tue, 16 Jan 2024 13:16:08 +0000 Subject: [PATCH] CodeGen from PR 27223 in Azure/azure-rest-api-specs Merge 93661832503baf981495c319c795977c43256924 into 05c4049bc22f0ec65acc18f9835132397049cb9e --- eng/versioning/version_client.txt | 1 + .../CHANGELOG.md | 13 + .../README.md | 65 + .../assets.json | 6 + .../pom.xml | 94 + .../AzureHealthInsightsServiceVersion.java | 40 + .../PatientTimelineAsyncClient.java | 312 +++ .../PatientTimelineClient.java | 312 +++ .../PatientTimelineClientBuilder.java | 322 +++ .../PatientTimelineClientImpl.java | 1739 +++++++++++++++++ .../implementation/package-info.java | 12 + .../patienttimeline/models/Annotation.java | 124 ++ .../models/ClinicalDocumentType.java | 95 + .../models/CodeableConcept.java | 102 + .../patienttimeline/models/Coding.java | 160 ++ .../patienttimeline/models/Condition.java | 680 +++++++ .../models/ConditionStage.java | 81 + .../patienttimeline/models/ContactDetail.java | 101 + .../patienttimeline/models/ContactPoint.java | 169 ++ .../models/ContactPointSystem.java | 90 + .../models/ContactPointUse.java | 78 + .../DocumentAdministrativeMetadata.java | 81 + .../models/DocumentAuthor.java | 80 + .../models/DocumentContent.java | 68 + .../models/DocumentContentSourceType.java | 61 + .../patienttimeline/models/DocumentType.java | 71 + .../models/DomainResource.java | 203 ++ .../patienttimeline/models/Element.java | 82 + .../patienttimeline/models/Encounter.java | 108 + .../models/EncounterClass.java | 91 + .../patienttimeline/models/Extendible.java | 52 + .../patienttimeline/models/Extension.java | 414 ++++ .../patienttimeline/models/Identifier.java | 218 +++ .../insights/patienttimeline/models/Meta.java | 223 +++ .../patienttimeline/models/Narrative.java | 87 + .../patienttimeline/models/Observation.java | 923 +++++++++ .../models/ObservationComponent.java | 501 +++++ .../models/ObservationReferenceRange.java | 198 ++ .../models/ObservationStatusCodeType.java | 99 + .../models/OrderedProcedure.java | 91 + .../models/PatientDocument.java | 261 +++ .../patienttimeline/models/PatientInfo.java | 111 ++ .../models/PatientInfoSex.java | 65 + .../patienttimeline/models/PatientRecord.java | 135 ++ .../models/PatientTimelineData.java | 74 + .../models/PatientTimelineInference.java | 119 ++ .../PatientTimelineInferenceResult.java | 66 + .../models/PatientTimelineInferenceType.java | 59 + .../PatientTimelineModelConfiguration.java | 82 + .../models/PatientTimelinePatientResult.java | 65 + .../patienttimeline/models/PeriodModel.java | 102 + .../patienttimeline/models/Quantity.java | 190 ++ .../patienttimeline/models/Range.java | 102 + .../patienttimeline/models/Ratio.java | 102 + .../patienttimeline/models/Reference.java | 160 ++ .../patienttimeline/models/ResearchStudy.java | 741 +++++++ .../models/ResearchStudyArm.java | 102 + .../models/ResearchStudyObjective.java | 73 + .../models/ResearchStudyStatusCodeType.java | 120 ++ .../patienttimeline/models/Resource.java | 212 ++ .../patienttimeline/models/SampledData.java | 222 +++ .../patienttimeline/models/SpecialtyType.java | 59 + .../patienttimeline/models/TimePeriod.java | 81 + .../patienttimeline/models/package-info.java | 12 + .../patienttimeline/package-info.java | 12 + .../src/main/java/module-info.java | 13 + ...health-insights-patienttimeline.properties | 2 + .../patienttimeline/ReadmeSamples.java | 12 + .../PatientTimelineClientTestBase.java | 37 + .../tsp-location.yaml | 7 + sdk/healthinsights/ci.yml | 6 +- sdk/healthinsights/pom.xml | 5 +- 72 files changed, 11652 insertions(+), 4 deletions(-) create mode 100644 sdk/healthinsights/azure-healthinsights-patienttimeline/CHANGELOG.md create mode 100644 sdk/healthinsights/azure-healthinsights-patienttimeline/README.md create mode 100644 sdk/healthinsights/azure-healthinsights-patienttimeline/assets.json create mode 100644 sdk/healthinsights/azure-healthinsights-patienttimeline/pom.xml create mode 100644 sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/AzureHealthInsightsServiceVersion.java create mode 100644 sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/PatientTimelineAsyncClient.java create mode 100644 sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/PatientTimelineClient.java create mode 100644 sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/PatientTimelineClientBuilder.java create mode 100644 sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/implementation/PatientTimelineClientImpl.java create mode 100644 sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/implementation/package-info.java create mode 100644 sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/Annotation.java create mode 100644 sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/ClinicalDocumentType.java create mode 100644 sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/CodeableConcept.java create mode 100644 sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/Coding.java create mode 100644 sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/Condition.java create mode 100644 sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/ConditionStage.java create mode 100644 sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/ContactDetail.java create mode 100644 sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/ContactPoint.java create mode 100644 sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/ContactPointSystem.java create mode 100644 sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/ContactPointUse.java create mode 100644 sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/DocumentAdministrativeMetadata.java create mode 100644 sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/DocumentAuthor.java create mode 100644 sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/DocumentContent.java create mode 100644 sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/DocumentContentSourceType.java create mode 100644 sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/DocumentType.java create mode 100644 sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/DomainResource.java create mode 100644 sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/Element.java create mode 100644 sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/Encounter.java create mode 100644 sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/EncounterClass.java create mode 100644 sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/Extendible.java create mode 100644 sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/Extension.java create mode 100644 sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/Identifier.java create mode 100644 sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/Meta.java create mode 100644 sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/Narrative.java create mode 100644 sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/Observation.java create mode 100644 sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/ObservationComponent.java create mode 100644 sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/ObservationReferenceRange.java create mode 100644 sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/ObservationStatusCodeType.java create mode 100644 sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/OrderedProcedure.java create mode 100644 sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/PatientDocument.java create mode 100644 sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/PatientInfo.java create mode 100644 sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/PatientInfoSex.java create mode 100644 sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/PatientRecord.java create mode 100644 sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/PatientTimelineData.java create mode 100644 sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/PatientTimelineInference.java create mode 100644 sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/PatientTimelineInferenceResult.java create mode 100644 sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/PatientTimelineInferenceType.java create mode 100644 sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/PatientTimelineModelConfiguration.java create mode 100644 sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/PatientTimelinePatientResult.java create mode 100644 sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/PeriodModel.java create mode 100644 sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/Quantity.java create mode 100644 sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/Range.java create mode 100644 sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/Ratio.java create mode 100644 sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/Reference.java create mode 100644 sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/ResearchStudy.java create mode 100644 sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/ResearchStudyArm.java create mode 100644 sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/ResearchStudyObjective.java create mode 100644 sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/ResearchStudyStatusCodeType.java create mode 100644 sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/Resource.java create mode 100644 sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/SampledData.java create mode 100644 sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/SpecialtyType.java create mode 100644 sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/TimePeriod.java create mode 100644 sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/package-info.java create mode 100644 sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/package-info.java create mode 100644 sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/module-info.java create mode 100644 sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/resources/azure-health-insights-patienttimeline.properties create mode 100644 sdk/healthinsights/azure-healthinsights-patienttimeline/src/samples/java/com/azure/health/insights/patienttimeline/ReadmeSamples.java create mode 100644 sdk/healthinsights/azure-healthinsights-patienttimeline/src/test/java/com/azure/health/insights/patienttimeline/generated/PatientTimelineClientTestBase.java create mode 100644 sdk/healthinsights/azure-healthinsights-patienttimeline/tsp-location.yaml diff --git a/eng/versioning/version_client.txt b/eng/versioning/version_client.txt index 37112ad978359..b1fd84b098d63 100644 --- a/eng/versioning/version_client.txt +++ b/eng/versioning/version_client.txt @@ -197,6 +197,7 @@ com.azure:azure-verticals-agrifood-farming;1.0.0-beta.3;1.0.0-beta.4 com.azure:azure-xml;1.0.0-beta.2;1.0.0-beta.3 com.azure:perf-test-core;1.0.0-beta.1;1.0.0-beta.1 com.azure:azure-ai-vision-imageanalysis;1.0.0-beta.1;1.0.0-beta.1 +com.azure:azure-healthinsights-patienttimeline;1.0.0-beta.1;1.0.0-beta.1 com.azure.spring:azure-monitor-spring-native;1.0.0-beta.1;1.0.0-beta.1 com.azure.spring:azure-monitor-spring-native-test;1.0.0-beta.1;1.0.0-beta.1 com.azure.spring:spring-cloud-azure-appconfiguration-config-web;4.14.0;4.15.0-beta.1 diff --git a/sdk/healthinsights/azure-healthinsights-patienttimeline/CHANGELOG.md b/sdk/healthinsights/azure-healthinsights-patienttimeline/CHANGELOG.md new file mode 100644 index 0000000000000..f887f194c985e --- /dev/null +++ b/sdk/healthinsights/azure-healthinsights-patienttimeline/CHANGELOG.md @@ -0,0 +1,13 @@ +# Release History + +## 1.0.0-beta.1 (Unreleased) + +- Azure AzureHealthInsights client library for Java. This package contains Microsoft Azure AzureHealthInsights client library. + +### Features Added + +### Breaking Changes + +### Bugs Fixed + +### Other Changes diff --git a/sdk/healthinsights/azure-healthinsights-patienttimeline/README.md b/sdk/healthinsights/azure-healthinsights-patienttimeline/README.md new file mode 100644 index 0000000000000..dc1337048829c --- /dev/null +++ b/sdk/healthinsights/azure-healthinsights-patienttimeline/README.md @@ -0,0 +1,65 @@ +# Azure AzureHealthInsights client library for Java + +Azure AzureHealthInsights client library for Java. + +This package contains Microsoft Azure AzureHealthInsights client library. + +## Documentation + +Various documentation is available to help you get started + +- [API reference documentation][docs] +- [Product documentation][product_documentation] + +## Getting started + +### Prerequisites + +- [Java Development Kit (JDK)][jdk] with version 8 or above +- [Azure Subscription][azure_subscription] + +### Adding the package to your product + +[//]: # ({x-version-update-start;com.azure:azure-health-insights-patienttimeline;current}) +```xml + + com.azure + azure-health-insights-patienttimeline + 1.0.0-beta.1 + +``` +[//]: # ({x-version-update-end}) + +### Authentication + +[Azure Identity][azure_identity] package provides the default implementation for authenticating the client. + +## Key concepts + +## Examples + +```java com.azure.health.insights.patienttimeline.readme +``` + +## Troubleshooting + +## Next steps + +## Contributing + +For details on contributing to this repository, see the [contributing guide](https://github.com/Azure/azure-sdk-for-java/blob/main/CONTRIBUTING.md). + +1. Fork it +1. Create your feature branch (`git checkout -b my-new-feature`) +1. Commit your changes (`git commit -am 'Add some feature'`) +1. Push to the branch (`git push origin my-new-feature`) +1. Create new Pull Request + + +[product_documentation]: https://azure.microsoft.com/services/ +[docs]: https://azure.github.io/azure-sdk-for-java/ +[jdk]: https://learn.microsoft.com/azure/developer/java/fundamentals/ +[azure_subscription]: https://azure.microsoft.com/free/ +[azure_identity]: https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/identity/azure-identity + +![Impressions](https://azure-sdk-impressions.azurewebsites.net/api/impressions/azure-sdk-for-java%2Fsdk%2Fhealthinsights%2Fazure-healthinsights-patienttimeline%2FREADME.png) diff --git a/sdk/healthinsights/azure-healthinsights-patienttimeline/assets.json b/sdk/healthinsights/azure-healthinsights-patienttimeline/assets.json new file mode 100644 index 0000000000000..597062658ce84 --- /dev/null +++ b/sdk/healthinsights/azure-healthinsights-patienttimeline/assets.json @@ -0,0 +1,6 @@ +{ + "AssetsRepo" : "Azure/azure-sdk-assets", + "AssetsRepoPrefixPath" : "java", + "TagPrefix" : "java/healthinsights/azure-health-insights-patienttimeline", + "Tag" : "" +} \ No newline at end of file diff --git a/sdk/healthinsights/azure-healthinsights-patienttimeline/pom.xml b/sdk/healthinsights/azure-healthinsights-patienttimeline/pom.xml new file mode 100644 index 0000000000000..d7ee18b194478 --- /dev/null +++ b/sdk/healthinsights/azure-healthinsights-patienttimeline/pom.xml @@ -0,0 +1,94 @@ + + + 4.0.0 + + com.azure + azure-client-sdk-parent + 1.7.0 + ../../parents/azure-client-sdk-parent + + + com.azure + azure-health-insights-patienttimeline + 1.0.0-beta.1 + jar + + Microsoft Azure SDK for AzureHealthInsights + This package contains Microsoft Azure AzureHealthInsights client library. + https://github.com/Azure/azure-sdk-for-java + + + + The MIT License (MIT) + http://opensource.org/licenses/MIT + repo + + + + + https://github.com/Azure/azure-sdk-for-java + scm:git:git@github.com:Azure/azure-sdk-for-java.git + scm:git:git@github.com:Azure/azure-sdk-for-java.git + HEAD + + + + microsoft + Microsoft + + + + UTF-8 + + + + com.azure + azure-core + 1.45.1 + + + com.azure + azure-core-http-netty + 1.13.11 + + + org.junit.jupiter + junit-jupiter-api + 5.9.3 + test + + + org.junit.jupiter + junit-jupiter-engine + 5.9.3 + test + + + com.azure + azure-core-test + 1.22.1 + test + + + com.azure + azure-identity + 1.11.1 + test + + + org.slf4j + slf4j-simple + 1.7.36 + test + + + com.azure + azure-core-experimental + 1.0.0-beta.46 + + + diff --git a/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/AzureHealthInsightsServiceVersion.java b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/AzureHealthInsightsServiceVersion.java new file mode 100644 index 0000000000000..f67c3d3928aae --- /dev/null +++ b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/AzureHealthInsightsServiceVersion.java @@ -0,0 +1,40 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) TypeSpec Code Generator. + +package com.azure.health.insights.patienttimeline; + +import com.azure.core.util.ServiceVersion; + +/** + * Service version of AzureHealthInsightsClient. + */ +public enum AzureHealthInsightsServiceVersion implements ServiceVersion { + /** + * Enum value 2023-09-01-preview. + */ + V2023_09_01_PREVIEW("2023-09-01-preview"); + + private final String version; + + AzureHealthInsightsServiceVersion(String version) { + this.version = version; + } + + /** + * {@inheritDoc} + */ + @Override + public String getVersion() { + return this.version; + } + + /** + * Gets the latest service version supported by this client library. + * + * @return The latest {@link AzureHealthInsightsServiceVersion}. + */ + public static AzureHealthInsightsServiceVersion getLatest() { + return V2023_09_01_PREVIEW; + } +} diff --git a/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/PatientTimelineAsyncClient.java b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/PatientTimelineAsyncClient.java new file mode 100644 index 0000000000000..b6152cd2262d3 --- /dev/null +++ b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/PatientTimelineAsyncClient.java @@ -0,0 +1,312 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) TypeSpec Code Generator. + +package com.azure.health.insights.patienttimeline; + +import com.azure.core.annotation.Generated; +import com.azure.core.annotation.ReturnType; +import com.azure.core.annotation.ServiceClient; +import com.azure.core.annotation.ServiceMethod; +import com.azure.core.exception.ClientAuthenticationException; +import com.azure.core.exception.HttpResponseException; +import com.azure.core.exception.ResourceModifiedException; +import com.azure.core.exception.ResourceNotFoundException; +import com.azure.core.http.rest.RequestOptions; +import com.azure.core.util.BinaryData; +import com.azure.core.util.polling.PollOperationDetails; +import com.azure.core.util.polling.PollerFlux; +import com.azure.health.insights.patienttimeline.implementation.PatientTimelineClientImpl; +import com.azure.health.insights.patienttimeline.models.PatientTimelineData; +import com.azure.health.insights.patienttimeline.models.PatientTimelineInferenceResult; + +/** + * Initializes a new instance of the asynchronous PatientTimelineClient type. + */ +@ServiceClient(builder = PatientTimelineClientBuilder.class, isAsync = true) +public final class PatientTimelineAsyncClient { + @Generated + private final PatientTimelineClientImpl serviceClient; + + /** + * Initializes an instance of PatientTimelineAsyncClient class. + * + * @param serviceClient the service client implementation. + */ + @Generated + PatientTimelineAsyncClient(PatientTimelineClientImpl serviceClient) { + this.serviceClient = serviceClient; + } + + /** + * Create Patient Timeline job + * + * Creates a Patient Timeline job with the given request body. + *

+ * Header Parameters + *

+ * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + *
Header Parameters
NameTypeRequiredDescription
repeatability-request-idStringNoRepeatability request ID header
repeatability-first-sentStringNoRepeatability first sent header as HTTP-date
+ * You can add these to a request with {@link RequestOptions#addHeader} + *

+ * Request Body Schema + *

+ *
{@code
+     * {
+     *     patients (Required): [
+     *          (Required){
+     *             id: String (Required)
+     *             info (Optional): {
+     *                 sex: String(female/male/unspecified) (Optional)
+     *                 birthDate: LocalDate (Optional)
+     *                 clinicalInfo (Optional): [
+     *                      (Optional){
+     *                         resourceType: String (Required)
+     *                         id: String (Optional)
+     *                         meta (Optional): {
+     *                             versionId: String (Optional)
+     *                             lastUpdated: String (Optional)
+     *                             source: String (Optional)
+     *                             profile (Optional): [
+     *                                 String (Optional)
+     *                             ]
+     *                             security (Optional): [
+     *                                  (Optional){
+     *                                     id: String (Optional)
+     *                                     extension (Optional): [
+     *                                          (Optional){
+     *                                             id: String (Optional)
+     *                                             extension (Optional): [
+     *                                                 (recursive schema, see above)
+     *                                             ]
+     *                                             url: String (Required)
+     *                                             valueQuantity (Optional): {
+     *                                                 id: String (Optional)
+     *                                                 extension (Optional): [
+     *                                                     (recursive schema, see above)
+     *                                                 ]
+     *                                                 value: BigDecimal (Optional)
+     *                                                 comparator: String (Optional)
+     *                                                 unit: String (Optional)
+     *                                                 system: String (Optional)
+     *                                                 code: String (Optional)
+     *                                             }
+     *                                             valueCodeableConcept (Optional): {
+     *                                                 id: String (Optional)
+     *                                                 extension (Optional): [
+     *                                                     (recursive schema, see above)
+     *                                                 ]
+     *                                                 coding (Optional): [
+     *                                                     (recursive schema, see above)
+     *                                                 ]
+     *                                                 text: String (Optional)
+     *                                             }
+     *                                             valueString: String (Optional)
+     *                                             valueBoolean: Boolean (Optional)
+     *                                             valueInteger: Integer (Optional)
+     *                                             valueRange (Optional): {
+     *                                                 id: String (Optional)
+     *                                                 extension (Optional): [
+     *                                                     (recursive schema, see above)
+     *                                                 ]
+     *                                                 low (Optional): (recursive schema, see low above)
+     *                                                 high (Optional): (recursive schema, see high above)
+     *                                             }
+     *                                             valueRatio (Optional): {
+     *                                                 id: String (Optional)
+     *                                                 extension (Optional): [
+     *                                                     (recursive schema, see above)
+     *                                                 ]
+     *                                                 numerator (Optional): (recursive schema, see numerator above)
+     *                                                 denominator (Optional): (recursive schema, see denominator above)
+     *                                             }
+     *                                             valueSampledData (Optional): {
+     *                                                 id: String (Optional)
+     *                                                 extension (Optional): [
+     *                                                     (recursive schema, see above)
+     *                                                 ]
+     *                                                 origin (Required): (recursive schema, see origin above)
+     *                                                 period: BigDecimal (Required)
+     *                                                 factor: BigDecimal (Optional)
+     *                                                 lowerLimit: BigDecimal (Optional)
+     *                                                 upperLimit: BigDecimal (Optional)
+     *                                                 dimensions: int (Required)
+     *                                                 data: String (Optional)
+     *                                             }
+     *                                             valueTime: String (Optional)
+     *                                             valueDateTime: String (Optional)
+     *                                             valuePeriod (Optional): {
+     *                                                 id: String (Optional)
+     *                                                 extension (Optional): [
+     *                                                     (recursive schema, see above)
+     *                                                 ]
+     *                                                 start: String (Optional)
+     *                                                 end: String (Optional)
+     *                                             }
+     *                                             valueReference (Optional): {
+     *                                                 id: String (Optional)
+     *                                                 extension (Optional): [
+     *                                                     (recursive schema, see above)
+     *                                                 ]
+     *                                                 reference: String (Optional)
+     *                                                 type: String (Optional)
+     *                                                 identifier (Optional): {
+     *                                                     id: String (Optional)
+     *                                                     extension (Optional): [
+     *                                                         (recursive schema, see above)
+     *                                                     ]
+     *                                                     use: String (Optional)
+     *                                                     type (Optional): (recursive schema, see type above)
+     *                                                     system: String (Optional)
+     *                                                     value: String (Optional)
+     *                                                     period (Optional): (recursive schema, see period above)
+     *                                                     assigner (Optional): (recursive schema, see assigner above)
+     *                                                 }
+     *                                                 display: String (Optional)
+     *                                             }
+     *                                         }
+     *                                     ]
+     *                                     system: String (Optional)
+     *                                     version: String (Optional)
+     *                                     code: String (Optional)
+     *                                     display: String (Optional)
+     *                                 }
+     *                             ]
+     *                             tag (Optional): [
+     *                                 (recursive schema, see above)
+     *                             ]
+     *                         }
+     *                         implicitRules: String (Optional)
+     *                         language: String (Optional)
+     *                          (Optional): {
+     *                             String: Object (Required)
+     *                         }
+     *                     }
+     *                 ]
+     *             }
+     *             encounters (Optional): [
+     *                  (Optional){
+     *                     id: String (Required)
+     *                     period (Optional): {
+     *                         start: OffsetDateTime (Optional)
+     *                         end: OffsetDateTime (Optional)
+     *                     }
+     *                     class: String(inpatient/ambulatory/observation/emergency/virtual/healthHome) (Optional)
+     *                 }
+     *             ]
+     *             patientDocuments (Optional): [
+     *                  (Optional){
+     *                     type: String(note/fhirBundle/dicom/genomicSequencing) (Required)
+     *                     clinicalType: String(consultation/dischargeSummary/historyAndPhysical/radiologyReport/procedure/progress/laboratory/pathologyReport) (Optional)
+     *                     id: String (Required)
+     *                     language: String (Optional)
+     *                     createdDateTime: OffsetDateTime (Optional)
+     *                     authors (Optional): [
+     *                          (Optional){
+     *                             id: String (Optional)
+     *                             fullName: String (Optional)
+     *                         }
+     *                     ]
+     *                     specialtyType: String(pathology/radiology) (Optional)
+     *                     administrativeMetadata (Optional): {
+     *                         orderedProcedures (Optional): [
+     *                              (Optional){
+     *                                 extension (Optional): [
+     *                                     (recursive schema, see above)
+     *                                 ]
+     *                                 code (Optional): (recursive schema, see code above)
+     *                                 description: String (Optional)
+     *                             }
+     *                         ]
+     *                         encounterId: String (Optional)
+     *                     }
+     *                     content (Required): {
+     *                         sourceType: String(inline/reference) (Required)
+     *                         value: String (Required)
+     *                     }
+     *                 }
+     *             ]
+     *         }
+     *     ]
+     *     configuration (Optional): {
+     *         verbose: Boolean (Optional)
+     *         includeEvidence: Boolean (Optional)
+     *     }
+     * }
+     * }
+ *

+ * Response Body Schema + *

+ *
{@code
+     * {
+     *     id: String (Required)
+     *     status: String (Required)
+     *     error (Optional): {
+     *         code: String (Required)
+     *         message: String (Required)
+     *         target: String (Optional)
+     *         details (Optional): [
+     *             (recursive schema, see above)
+     *         ]
+     *     }
+     * }
+     * }
+ * + * @param patientTimelineData The body of the Patient Timeline request. + * @param requestOptions The options to configure the HTTP request before HTTP client sends it. + * @throws HttpResponseException thrown if the request is rejected by server. + * @throws ClientAuthenticationException thrown if the request is rejected by server on status code 401. + * @throws ResourceNotFoundException thrown if the request is rejected by server on status code 404. + * @throws ResourceModifiedException thrown if the request is rejected by server on status code 409. + * @return the {@link PollerFlux} for polling of status details for long running operations. + */ + @Generated + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) + public PollerFlux beginInferPatientTimeline(BinaryData patientTimelineData, + RequestOptions requestOptions) { + return this.serviceClient.beginInferPatientTimelineAsync(patientTimelineData, requestOptions); + } + + /** + * Create Patient Timeline job + * + * Creates a Patient Timeline job with the given request body. + * + * @param patientTimelineData The body of the Patient Timeline request. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws HttpResponseException thrown if the request is rejected by server. + * @throws ClientAuthenticationException thrown if the request is rejected by server on status code 401. + * @throws ResourceNotFoundException thrown if the request is rejected by server on status code 404. + * @throws ResourceModifiedException thrown if the request is rejected by server on status code 409. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the {@link PollerFlux} for polling of status details for long running operations. + */ + @Generated + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) + public PollerFlux + beginInferPatientTimeline(PatientTimelineData patientTimelineData) { + // Generated convenience method for beginInferPatientTimelineWithModel + RequestOptions requestOptions = new RequestOptions(); + return serviceClient.beginInferPatientTimelineWithModelAsync(BinaryData.fromObject(patientTimelineData), + requestOptions); + } +} diff --git a/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/PatientTimelineClient.java b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/PatientTimelineClient.java new file mode 100644 index 0000000000000..294e9d0853af3 --- /dev/null +++ b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/PatientTimelineClient.java @@ -0,0 +1,312 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) TypeSpec Code Generator. + +package com.azure.health.insights.patienttimeline; + +import com.azure.core.annotation.Generated; +import com.azure.core.annotation.ReturnType; +import com.azure.core.annotation.ServiceClient; +import com.azure.core.annotation.ServiceMethod; +import com.azure.core.exception.ClientAuthenticationException; +import com.azure.core.exception.HttpResponseException; +import com.azure.core.exception.ResourceModifiedException; +import com.azure.core.exception.ResourceNotFoundException; +import com.azure.core.http.rest.RequestOptions; +import com.azure.core.util.BinaryData; +import com.azure.core.util.polling.PollOperationDetails; +import com.azure.core.util.polling.SyncPoller; +import com.azure.health.insights.patienttimeline.implementation.PatientTimelineClientImpl; +import com.azure.health.insights.patienttimeline.models.PatientTimelineData; +import com.azure.health.insights.patienttimeline.models.PatientTimelineInferenceResult; + +/** + * Initializes a new instance of the synchronous PatientTimelineClient type. + */ +@ServiceClient(builder = PatientTimelineClientBuilder.class) +public final class PatientTimelineClient { + @Generated + private final PatientTimelineClientImpl serviceClient; + + /** + * Initializes an instance of PatientTimelineClient class. + * + * @param serviceClient the service client implementation. + */ + @Generated + PatientTimelineClient(PatientTimelineClientImpl serviceClient) { + this.serviceClient = serviceClient; + } + + /** + * Create Patient Timeline job + * + * Creates a Patient Timeline job with the given request body. + *

+ * Header Parameters + *

+ * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + *
Header Parameters
NameTypeRequiredDescription
repeatability-request-idStringNoRepeatability request ID header
repeatability-first-sentStringNoRepeatability first sent header as HTTP-date
+ * You can add these to a request with {@link RequestOptions#addHeader} + *

+ * Request Body Schema + *

+ *
{@code
+     * {
+     *     patients (Required): [
+     *          (Required){
+     *             id: String (Required)
+     *             info (Optional): {
+     *                 sex: String(female/male/unspecified) (Optional)
+     *                 birthDate: LocalDate (Optional)
+     *                 clinicalInfo (Optional): [
+     *                      (Optional){
+     *                         resourceType: String (Required)
+     *                         id: String (Optional)
+     *                         meta (Optional): {
+     *                             versionId: String (Optional)
+     *                             lastUpdated: String (Optional)
+     *                             source: String (Optional)
+     *                             profile (Optional): [
+     *                                 String (Optional)
+     *                             ]
+     *                             security (Optional): [
+     *                                  (Optional){
+     *                                     id: String (Optional)
+     *                                     extension (Optional): [
+     *                                          (Optional){
+     *                                             id: String (Optional)
+     *                                             extension (Optional): [
+     *                                                 (recursive schema, see above)
+     *                                             ]
+     *                                             url: String (Required)
+     *                                             valueQuantity (Optional): {
+     *                                                 id: String (Optional)
+     *                                                 extension (Optional): [
+     *                                                     (recursive schema, see above)
+     *                                                 ]
+     *                                                 value: BigDecimal (Optional)
+     *                                                 comparator: String (Optional)
+     *                                                 unit: String (Optional)
+     *                                                 system: String (Optional)
+     *                                                 code: String (Optional)
+     *                                             }
+     *                                             valueCodeableConcept (Optional): {
+     *                                                 id: String (Optional)
+     *                                                 extension (Optional): [
+     *                                                     (recursive schema, see above)
+     *                                                 ]
+     *                                                 coding (Optional): [
+     *                                                     (recursive schema, see above)
+     *                                                 ]
+     *                                                 text: String (Optional)
+     *                                             }
+     *                                             valueString: String (Optional)
+     *                                             valueBoolean: Boolean (Optional)
+     *                                             valueInteger: Integer (Optional)
+     *                                             valueRange (Optional): {
+     *                                                 id: String (Optional)
+     *                                                 extension (Optional): [
+     *                                                     (recursive schema, see above)
+     *                                                 ]
+     *                                                 low (Optional): (recursive schema, see low above)
+     *                                                 high (Optional): (recursive schema, see high above)
+     *                                             }
+     *                                             valueRatio (Optional): {
+     *                                                 id: String (Optional)
+     *                                                 extension (Optional): [
+     *                                                     (recursive schema, see above)
+     *                                                 ]
+     *                                                 numerator (Optional): (recursive schema, see numerator above)
+     *                                                 denominator (Optional): (recursive schema, see denominator above)
+     *                                             }
+     *                                             valueSampledData (Optional): {
+     *                                                 id: String (Optional)
+     *                                                 extension (Optional): [
+     *                                                     (recursive schema, see above)
+     *                                                 ]
+     *                                                 origin (Required): (recursive schema, see origin above)
+     *                                                 period: BigDecimal (Required)
+     *                                                 factor: BigDecimal (Optional)
+     *                                                 lowerLimit: BigDecimal (Optional)
+     *                                                 upperLimit: BigDecimal (Optional)
+     *                                                 dimensions: int (Required)
+     *                                                 data: String (Optional)
+     *                                             }
+     *                                             valueTime: String (Optional)
+     *                                             valueDateTime: String (Optional)
+     *                                             valuePeriod (Optional): {
+     *                                                 id: String (Optional)
+     *                                                 extension (Optional): [
+     *                                                     (recursive schema, see above)
+     *                                                 ]
+     *                                                 start: String (Optional)
+     *                                                 end: String (Optional)
+     *                                             }
+     *                                             valueReference (Optional): {
+     *                                                 id: String (Optional)
+     *                                                 extension (Optional): [
+     *                                                     (recursive schema, see above)
+     *                                                 ]
+     *                                                 reference: String (Optional)
+     *                                                 type: String (Optional)
+     *                                                 identifier (Optional): {
+     *                                                     id: String (Optional)
+     *                                                     extension (Optional): [
+     *                                                         (recursive schema, see above)
+     *                                                     ]
+     *                                                     use: String (Optional)
+     *                                                     type (Optional): (recursive schema, see type above)
+     *                                                     system: String (Optional)
+     *                                                     value: String (Optional)
+     *                                                     period (Optional): (recursive schema, see period above)
+     *                                                     assigner (Optional): (recursive schema, see assigner above)
+     *                                                 }
+     *                                                 display: String (Optional)
+     *                                             }
+     *                                         }
+     *                                     ]
+     *                                     system: String (Optional)
+     *                                     version: String (Optional)
+     *                                     code: String (Optional)
+     *                                     display: String (Optional)
+     *                                 }
+     *                             ]
+     *                             tag (Optional): [
+     *                                 (recursive schema, see above)
+     *                             ]
+     *                         }
+     *                         implicitRules: String (Optional)
+     *                         language: String (Optional)
+     *                          (Optional): {
+     *                             String: Object (Required)
+     *                         }
+     *                     }
+     *                 ]
+     *             }
+     *             encounters (Optional): [
+     *                  (Optional){
+     *                     id: String (Required)
+     *                     period (Optional): {
+     *                         start: OffsetDateTime (Optional)
+     *                         end: OffsetDateTime (Optional)
+     *                     }
+     *                     class: String(inpatient/ambulatory/observation/emergency/virtual/healthHome) (Optional)
+     *                 }
+     *             ]
+     *             patientDocuments (Optional): [
+     *                  (Optional){
+     *                     type: String(note/fhirBundle/dicom/genomicSequencing) (Required)
+     *                     clinicalType: String(consultation/dischargeSummary/historyAndPhysical/radiologyReport/procedure/progress/laboratory/pathologyReport) (Optional)
+     *                     id: String (Required)
+     *                     language: String (Optional)
+     *                     createdDateTime: OffsetDateTime (Optional)
+     *                     authors (Optional): [
+     *                          (Optional){
+     *                             id: String (Optional)
+     *                             fullName: String (Optional)
+     *                         }
+     *                     ]
+     *                     specialtyType: String(pathology/radiology) (Optional)
+     *                     administrativeMetadata (Optional): {
+     *                         orderedProcedures (Optional): [
+     *                              (Optional){
+     *                                 extension (Optional): [
+     *                                     (recursive schema, see above)
+     *                                 ]
+     *                                 code (Optional): (recursive schema, see code above)
+     *                                 description: String (Optional)
+     *                             }
+     *                         ]
+     *                         encounterId: String (Optional)
+     *                     }
+     *                     content (Required): {
+     *                         sourceType: String(inline/reference) (Required)
+     *                         value: String (Required)
+     *                     }
+     *                 }
+     *             ]
+     *         }
+     *     ]
+     *     configuration (Optional): {
+     *         verbose: Boolean (Optional)
+     *         includeEvidence: Boolean (Optional)
+     *     }
+     * }
+     * }
+ *

+ * Response Body Schema + *

+ *
{@code
+     * {
+     *     id: String (Required)
+     *     status: String (Required)
+     *     error (Optional): {
+     *         code: String (Required)
+     *         message: String (Required)
+     *         target: String (Optional)
+     *         details (Optional): [
+     *             (recursive schema, see above)
+     *         ]
+     *     }
+     * }
+     * }
+ * + * @param patientTimelineData The body of the Patient Timeline request. + * @param requestOptions The options to configure the HTTP request before HTTP client sends it. + * @throws HttpResponseException thrown if the request is rejected by server. + * @throws ClientAuthenticationException thrown if the request is rejected by server on status code 401. + * @throws ResourceNotFoundException thrown if the request is rejected by server on status code 404. + * @throws ResourceModifiedException thrown if the request is rejected by server on status code 409. + * @return the {@link SyncPoller} for polling of status details for long running operations. + */ + @Generated + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) + public SyncPoller beginInferPatientTimeline(BinaryData patientTimelineData, + RequestOptions requestOptions) { + return this.serviceClient.beginInferPatientTimeline(patientTimelineData, requestOptions); + } + + /** + * Create Patient Timeline job + * + * Creates a Patient Timeline job with the given request body. + * + * @param patientTimelineData The body of the Patient Timeline request. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws HttpResponseException thrown if the request is rejected by server. + * @throws ClientAuthenticationException thrown if the request is rejected by server on status code 401. + * @throws ResourceNotFoundException thrown if the request is rejected by server on status code 404. + * @throws ResourceModifiedException thrown if the request is rejected by server on status code 409. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the {@link SyncPoller} for polling of status details for long running operations. + */ + @Generated + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) + public SyncPoller + beginInferPatientTimeline(PatientTimelineData patientTimelineData) { + // Generated convenience method for beginInferPatientTimelineWithModel + RequestOptions requestOptions = new RequestOptions(); + return serviceClient.beginInferPatientTimelineWithModel(BinaryData.fromObject(patientTimelineData), + requestOptions); + } +} diff --git a/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/PatientTimelineClientBuilder.java b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/PatientTimelineClientBuilder.java new file mode 100644 index 0000000000000..9274d3b7c4dda --- /dev/null +++ b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/PatientTimelineClientBuilder.java @@ -0,0 +1,322 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) TypeSpec Code Generator. + +package com.azure.health.insights.patienttimeline; + +import com.azure.core.annotation.Generated; +import com.azure.core.annotation.ServiceClientBuilder; +import com.azure.core.client.traits.ConfigurationTrait; +import com.azure.core.client.traits.EndpointTrait; +import com.azure.core.client.traits.HttpTrait; +import com.azure.core.client.traits.KeyCredentialTrait; +import com.azure.core.credential.KeyCredential; +import com.azure.core.http.HttpClient; +import com.azure.core.http.HttpHeaderName; +import com.azure.core.http.HttpHeaders; +import com.azure.core.http.HttpPipeline; +import com.azure.core.http.HttpPipelineBuilder; +import com.azure.core.http.HttpPipelinePosition; +import com.azure.core.http.policy.AddDatePolicy; +import com.azure.core.http.policy.AddHeadersFromContextPolicy; +import com.azure.core.http.policy.AddHeadersPolicy; +import com.azure.core.http.policy.HttpLogOptions; +import com.azure.core.http.policy.HttpLoggingPolicy; +import com.azure.core.http.policy.HttpPipelinePolicy; +import com.azure.core.http.policy.HttpPolicyProviders; +import com.azure.core.http.policy.KeyCredentialPolicy; +import com.azure.core.http.policy.RequestIdPolicy; +import com.azure.core.http.policy.RetryOptions; +import com.azure.core.http.policy.RetryPolicy; +import com.azure.core.http.policy.UserAgentPolicy; +import com.azure.core.util.ClientOptions; +import com.azure.core.util.Configuration; +import com.azure.core.util.CoreUtils; +import com.azure.core.util.builder.ClientBuilderUtil; +import com.azure.core.util.logging.ClientLogger; +import com.azure.core.util.serializer.JacksonAdapter; +import com.azure.health.insights.patienttimeline.implementation.PatientTimelineClientImpl; +import java.util.ArrayList; +import java.util.List; +import java.util.Map; +import java.util.Objects; + +/** + * A builder for creating a new instance of the PatientTimelineClient type. + */ +@ServiceClientBuilder(serviceClients = { PatientTimelineClient.class, PatientTimelineAsyncClient.class }) +public final class PatientTimelineClientBuilder + implements HttpTrait, ConfigurationTrait, + KeyCredentialTrait, EndpointTrait { + @Generated + private static final String SDK_NAME = "name"; + + @Generated + private static final String SDK_VERSION = "version"; + + @Generated + private static final Map PROPERTIES + = CoreUtils.getProperties("azure-health-insights-patienttimeline.properties"); + + @Generated + private final List pipelinePolicies; + + /** + * Create an instance of the PatientTimelineClientBuilder. + */ + @Generated + public PatientTimelineClientBuilder() { + this.pipelinePolicies = new ArrayList<>(); + } + + /* + * The HTTP pipeline to send requests through. + */ + @Generated + private HttpPipeline pipeline; + + /** + * {@inheritDoc}. + */ + @Generated + @Override + public PatientTimelineClientBuilder pipeline(HttpPipeline pipeline) { + if (this.pipeline != null && pipeline == null) { + LOGGER.info("HttpPipeline is being set to 'null' when it was previously configured."); + } + this.pipeline = pipeline; + return this; + } + + /* + * The HTTP client used to send the request. + */ + @Generated + private HttpClient httpClient; + + /** + * {@inheritDoc}. + */ + @Generated + @Override + public PatientTimelineClientBuilder httpClient(HttpClient httpClient) { + this.httpClient = httpClient; + return this; + } + + /* + * The logging configuration for HTTP requests and responses. + */ + @Generated + private HttpLogOptions httpLogOptions; + + /** + * {@inheritDoc}. + */ + @Generated + @Override + public PatientTimelineClientBuilder httpLogOptions(HttpLogOptions httpLogOptions) { + this.httpLogOptions = httpLogOptions; + return this; + } + + /* + * The client options such as application ID and custom headers to set on a request. + */ + @Generated + private ClientOptions clientOptions; + + /** + * {@inheritDoc}. + */ + @Generated + @Override + public PatientTimelineClientBuilder clientOptions(ClientOptions clientOptions) { + this.clientOptions = clientOptions; + return this; + } + + /* + * The retry options to configure retry policy for failed requests. + */ + @Generated + private RetryOptions retryOptions; + + /** + * {@inheritDoc}. + */ + @Generated + @Override + public PatientTimelineClientBuilder retryOptions(RetryOptions retryOptions) { + this.retryOptions = retryOptions; + return this; + } + + /** + * {@inheritDoc}. + */ + @Generated + @Override + public PatientTimelineClientBuilder addPolicy(HttpPipelinePolicy customPolicy) { + Objects.requireNonNull(customPolicy, "'customPolicy' cannot be null."); + pipelinePolicies.add(customPolicy); + return this; + } + + /* + * The configuration store that is used during construction of the service client. + */ + @Generated + private Configuration configuration; + + /** + * {@inheritDoc}. + */ + @Generated + @Override + public PatientTimelineClientBuilder configuration(Configuration configuration) { + this.configuration = configuration; + return this; + } + + /* + * The KeyCredential used for authentication. + */ + @Generated + private KeyCredential keyCredential; + + /** + * {@inheritDoc}. + */ + @Generated + @Override + public PatientTimelineClientBuilder credential(KeyCredential keyCredential) { + this.keyCredential = keyCredential; + return this; + } + + /* + * The service endpoint + */ + @Generated + private String endpoint; + + /** + * {@inheritDoc}. + */ + @Generated + @Override + public PatientTimelineClientBuilder endpoint(String endpoint) { + this.endpoint = endpoint; + return this; + } + + /* + * Service version + */ + @Generated + private AzureHealthInsightsServiceVersion serviceVersion; + + /** + * Sets Service version. + * + * @param serviceVersion the serviceVersion value. + * @return the PatientTimelineClientBuilder. + */ + @Generated + public PatientTimelineClientBuilder serviceVersion(AzureHealthInsightsServiceVersion serviceVersion) { + this.serviceVersion = serviceVersion; + return this; + } + + /* + * The retry policy that will attempt to retry failed requests, if applicable. + */ + @Generated + private RetryPolicy retryPolicy; + + /** + * Sets The retry policy that will attempt to retry failed requests, if applicable. + * + * @param retryPolicy the retryPolicy value. + * @return the PatientTimelineClientBuilder. + */ + @Generated + public PatientTimelineClientBuilder retryPolicy(RetryPolicy retryPolicy) { + this.retryPolicy = retryPolicy; + return this; + } + + /** + * Builds an instance of PatientTimelineClientImpl with the provided parameters. + * + * @return an instance of PatientTimelineClientImpl. + */ + @Generated + private PatientTimelineClientImpl buildInnerClient() { + HttpPipeline localPipeline = (pipeline != null) ? pipeline : createHttpPipeline(); + AzureHealthInsightsServiceVersion localServiceVersion + = (serviceVersion != null) ? serviceVersion : AzureHealthInsightsServiceVersion.getLatest(); + PatientTimelineClientImpl client = new PatientTimelineClientImpl(localPipeline, + JacksonAdapter.createDefaultSerializerAdapter(), this.endpoint, localServiceVersion); + return client; + } + + @Generated + private HttpPipeline createHttpPipeline() { + Configuration buildConfiguration + = (configuration == null) ? Configuration.getGlobalConfiguration() : configuration; + HttpLogOptions localHttpLogOptions = this.httpLogOptions == null ? new HttpLogOptions() : this.httpLogOptions; + ClientOptions localClientOptions = this.clientOptions == null ? new ClientOptions() : this.clientOptions; + List policies = new ArrayList<>(); + String clientName = PROPERTIES.getOrDefault(SDK_NAME, "UnknownName"); + String clientVersion = PROPERTIES.getOrDefault(SDK_VERSION, "UnknownVersion"); + String applicationId = CoreUtils.getApplicationId(localClientOptions, localHttpLogOptions); + policies.add(new UserAgentPolicy(applicationId, clientName, clientVersion, buildConfiguration)); + policies.add(new RequestIdPolicy()); + policies.add(new AddHeadersFromContextPolicy()); + HttpHeaders headers = new HttpHeaders(); + localClientOptions.getHeaders() + .forEach(header -> headers.set(HttpHeaderName.fromString(header.getName()), header.getValue())); + if (headers.getSize() > 0) { + policies.add(new AddHeadersPolicy(headers)); + } + this.pipelinePolicies.stream().filter(p -> p.getPipelinePosition() == HttpPipelinePosition.PER_CALL) + .forEach(p -> policies.add(p)); + HttpPolicyProviders.addBeforeRetryPolicies(policies); + policies.add(ClientBuilderUtil.validateAndGetRetryPolicy(retryPolicy, retryOptions, new RetryPolicy())); + policies.add(new AddDatePolicy()); + if (keyCredential != null) { + policies.add(new KeyCredentialPolicy("Ocp-Apim-Subscription-Key", keyCredential)); + } + this.pipelinePolicies.stream().filter(p -> p.getPipelinePosition() == HttpPipelinePosition.PER_RETRY) + .forEach(p -> policies.add(p)); + HttpPolicyProviders.addAfterRetryPolicies(policies); + policies.add(new HttpLoggingPolicy(localHttpLogOptions)); + HttpPipeline httpPipeline = new HttpPipelineBuilder().policies(policies.toArray(new HttpPipelinePolicy[0])) + .httpClient(httpClient).clientOptions(localClientOptions).build(); + return httpPipeline; + } + + /** + * Builds an instance of PatientTimelineAsyncClient class. + * + * @return an instance of PatientTimelineAsyncClient. + */ + @Generated + public PatientTimelineAsyncClient buildAsyncClient() { + return new PatientTimelineAsyncClient(buildInnerClient()); + } + + /** + * Builds an instance of PatientTimelineClient class. + * + * @return an instance of PatientTimelineClient. + */ + @Generated + public PatientTimelineClient buildClient() { + return new PatientTimelineClient(buildInnerClient()); + } + + private static final ClientLogger LOGGER = new ClientLogger(PatientTimelineClientBuilder.class); +} diff --git a/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/implementation/PatientTimelineClientImpl.java b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/implementation/PatientTimelineClientImpl.java new file mode 100644 index 0000000000000..308b3de19f00c --- /dev/null +++ b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/implementation/PatientTimelineClientImpl.java @@ -0,0 +1,1739 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) TypeSpec Code Generator. + +package com.azure.health.insights.patienttimeline.implementation; + +import com.azure.core.annotation.BodyParam; +import com.azure.core.annotation.ExpectedResponses; +import com.azure.core.annotation.HeaderParam; +import com.azure.core.annotation.Host; +import com.azure.core.annotation.HostParam; +import com.azure.core.annotation.Post; +import com.azure.core.annotation.QueryParam; +import com.azure.core.annotation.ReturnType; +import com.azure.core.annotation.ServiceInterface; +import com.azure.core.annotation.ServiceMethod; +import com.azure.core.annotation.UnexpectedResponseExceptionType; +import com.azure.core.exception.ClientAuthenticationException; +import com.azure.core.exception.HttpResponseException; +import com.azure.core.exception.ResourceModifiedException; +import com.azure.core.exception.ResourceNotFoundException; +import com.azure.core.http.HttpHeaderName; +import com.azure.core.http.HttpPipeline; +import com.azure.core.http.HttpPipelineBuilder; +import com.azure.core.http.policy.RetryPolicy; +import com.azure.core.http.policy.UserAgentPolicy; +import com.azure.core.http.rest.RequestOptions; +import com.azure.core.http.rest.Response; +import com.azure.core.http.rest.RestProxy; +import com.azure.core.util.BinaryData; +import com.azure.core.util.Context; +import com.azure.core.util.DateTimeRfc1123; +import com.azure.core.util.FluxUtil; +import com.azure.core.util.polling.PollOperationDetails; +import com.azure.core.util.polling.PollerFlux; +import com.azure.core.util.polling.PollingStrategyOptions; +import com.azure.core.util.polling.SyncPoller; +import com.azure.core.util.serializer.JacksonAdapter; +import com.azure.core.util.serializer.SerializerAdapter; +import com.azure.core.util.serializer.TypeReference; +import com.azure.health.insights.patienttimeline.AzureHealthInsightsServiceVersion; +import com.azure.health.insights.patienttimeline.models.PatientTimelineInferenceResult; +import java.time.Duration; +import java.time.OffsetDateTime; +import java.util.UUID; +import reactor.core.publisher.Mono; + +/** + * Initializes a new instance of the PatientTimelineClient type. + */ +public final class PatientTimelineClientImpl { + /** + * The proxy service used to perform REST calls. + */ + private final PatientTimelineClientService service; + + /** + * Supported Cognitive Services endpoints (protocol and hostname, for example: + * https://westus2.api.cognitive.microsoft.com). + */ + private final String endpoint; + + /** + * Gets Supported Cognitive Services endpoints (protocol and hostname, for example: + * https://westus2.api.cognitive.microsoft.com). + * + * @return the endpoint value. + */ + public String getEndpoint() { + return this.endpoint; + } + + /** + * Service version. + */ + private final AzureHealthInsightsServiceVersion serviceVersion; + + /** + * Gets Service version. + * + * @return the serviceVersion value. + */ + public AzureHealthInsightsServiceVersion getServiceVersion() { + return this.serviceVersion; + } + + /** + * The HTTP pipeline to send requests through. + */ + private final HttpPipeline httpPipeline; + + /** + * Gets The HTTP pipeline to send requests through. + * + * @return the httpPipeline value. + */ + public HttpPipeline getHttpPipeline() { + return this.httpPipeline; + } + + /** + * The serializer to serialize an object into a string. + */ + private final SerializerAdapter serializerAdapter; + + /** + * Gets The serializer to serialize an object into a string. + * + * @return the serializerAdapter value. + */ + public SerializerAdapter getSerializerAdapter() { + return this.serializerAdapter; + } + + /** + * Initializes an instance of PatientTimelineClient client. + * + * @param endpoint Supported Cognitive Services endpoints (protocol and hostname, for example: + * https://westus2.api.cognitive.microsoft.com). + * @param serviceVersion Service version. + */ + public PatientTimelineClientImpl(String endpoint, AzureHealthInsightsServiceVersion serviceVersion) { + this(new HttpPipelineBuilder().policies(new UserAgentPolicy(), new RetryPolicy()).build(), + JacksonAdapter.createDefaultSerializerAdapter(), endpoint, serviceVersion); + } + + /** + * Initializes an instance of PatientTimelineClient client. + * + * @param httpPipeline The HTTP pipeline to send requests through. + * @param endpoint Supported Cognitive Services endpoints (protocol and hostname, for example: + * https://westus2.api.cognitive.microsoft.com). + * @param serviceVersion Service version. + */ + public PatientTimelineClientImpl(HttpPipeline httpPipeline, String endpoint, + AzureHealthInsightsServiceVersion serviceVersion) { + this(httpPipeline, JacksonAdapter.createDefaultSerializerAdapter(), endpoint, serviceVersion); + } + + /** + * Initializes an instance of PatientTimelineClient client. + * + * @param httpPipeline The HTTP pipeline to send requests through. + * @param serializerAdapter The serializer to serialize an object into a string. + * @param endpoint Supported Cognitive Services endpoints (protocol and hostname, for example: + * https://westus2.api.cognitive.microsoft.com). + * @param serviceVersion Service version. + */ + public PatientTimelineClientImpl(HttpPipeline httpPipeline, SerializerAdapter serializerAdapter, String endpoint, + AzureHealthInsightsServiceVersion serviceVersion) { + this.httpPipeline = httpPipeline; + this.serializerAdapter = serializerAdapter; + this.endpoint = endpoint; + this.serviceVersion = serviceVersion; + this.service + = RestProxy.create(PatientTimelineClientService.class, this.httpPipeline, this.getSerializerAdapter()); + } + + /** + * The interface defining all the services for PatientTimelineClient to be used by the proxy service to perform + * REST calls. + */ + @Host("{endpoint}/health-insights") + @ServiceInterface(name = "PatientTimelineClien") + public interface PatientTimelineClientService { + @Post("/patient-timeline/jobs") + @ExpectedResponses({ 202 }) + @UnexpectedResponseExceptionType(value = ClientAuthenticationException.class, code = { 401 }) + @UnexpectedResponseExceptionType(value = ResourceNotFoundException.class, code = { 404 }) + @UnexpectedResponseExceptionType(value = ResourceModifiedException.class, code = { 409 }) + @UnexpectedResponseExceptionType(HttpResponseException.class) + Mono> inferPatientTimeline(@HostParam("endpoint") String endpoint, + @QueryParam("api-version") String apiVersion, @HeaderParam("accept") String accept, + @BodyParam("application/json") BinaryData patientTimelineData, RequestOptions requestOptions, + Context context); + + @Post("/patient-timeline/jobs") + @ExpectedResponses({ 202 }) + @UnexpectedResponseExceptionType(value = ClientAuthenticationException.class, code = { 401 }) + @UnexpectedResponseExceptionType(value = ResourceNotFoundException.class, code = { 404 }) + @UnexpectedResponseExceptionType(value = ResourceModifiedException.class, code = { 409 }) + @UnexpectedResponseExceptionType(HttpResponseException.class) + Response inferPatientTimelineSync(@HostParam("endpoint") String endpoint, + @QueryParam("api-version") String apiVersion, @HeaderParam("accept") String accept, + @BodyParam("application/json") BinaryData patientTimelineData, RequestOptions requestOptions, + Context context); + } + + /** + * Create Patient Timeline job + * + * Creates a Patient Timeline job with the given request body. + *

+ * Header Parameters + *

+ * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + *
Header Parameters
NameTypeRequiredDescription
repeatability-request-idStringNoRepeatability request ID header
repeatability-first-sentStringNoRepeatability first sent header as HTTP-date
+ * You can add these to a request with {@link RequestOptions#addHeader} + *

+ * Request Body Schema + *

+ *
{@code
+     * {
+     *     patients (Required): [
+     *          (Required){
+     *             id: String (Required)
+     *             info (Optional): {
+     *                 sex: String(female/male/unspecified) (Optional)
+     *                 birthDate: LocalDate (Optional)
+     *                 clinicalInfo (Optional): [
+     *                      (Optional){
+     *                         resourceType: String (Required)
+     *                         id: String (Optional)
+     *                         meta (Optional): {
+     *                             versionId: String (Optional)
+     *                             lastUpdated: String (Optional)
+     *                             source: String (Optional)
+     *                             profile (Optional): [
+     *                                 String (Optional)
+     *                             ]
+     *                             security (Optional): [
+     *                                  (Optional){
+     *                                     id: String (Optional)
+     *                                     extension (Optional): [
+     *                                          (Optional){
+     *                                             id: String (Optional)
+     *                                             extension (Optional): [
+     *                                                 (recursive schema, see above)
+     *                                             ]
+     *                                             url: String (Required)
+     *                                             valueQuantity (Optional): {
+     *                                                 id: String (Optional)
+     *                                                 extension (Optional): [
+     *                                                     (recursive schema, see above)
+     *                                                 ]
+     *                                                 value: BigDecimal (Optional)
+     *                                                 comparator: String (Optional)
+     *                                                 unit: String (Optional)
+     *                                                 system: String (Optional)
+     *                                                 code: String (Optional)
+     *                                             }
+     *                                             valueCodeableConcept (Optional): {
+     *                                                 id: String (Optional)
+     *                                                 extension (Optional): [
+     *                                                     (recursive schema, see above)
+     *                                                 ]
+     *                                                 coding (Optional): [
+     *                                                     (recursive schema, see above)
+     *                                                 ]
+     *                                                 text: String (Optional)
+     *                                             }
+     *                                             valueString: String (Optional)
+     *                                             valueBoolean: Boolean (Optional)
+     *                                             valueInteger: Integer (Optional)
+     *                                             valueRange (Optional): {
+     *                                                 id: String (Optional)
+     *                                                 extension (Optional): [
+     *                                                     (recursive schema, see above)
+     *                                                 ]
+     *                                                 low (Optional): (recursive schema, see low above)
+     *                                                 high (Optional): (recursive schema, see high above)
+     *                                             }
+     *                                             valueRatio (Optional): {
+     *                                                 id: String (Optional)
+     *                                                 extension (Optional): [
+     *                                                     (recursive schema, see above)
+     *                                                 ]
+     *                                                 numerator (Optional): (recursive schema, see numerator above)
+     *                                                 denominator (Optional): (recursive schema, see denominator above)
+     *                                             }
+     *                                             valueSampledData (Optional): {
+     *                                                 id: String (Optional)
+     *                                                 extension (Optional): [
+     *                                                     (recursive schema, see above)
+     *                                                 ]
+     *                                                 origin (Required): (recursive schema, see origin above)
+     *                                                 period: BigDecimal (Required)
+     *                                                 factor: BigDecimal (Optional)
+     *                                                 lowerLimit: BigDecimal (Optional)
+     *                                                 upperLimit: BigDecimal (Optional)
+     *                                                 dimensions: int (Required)
+     *                                                 data: String (Optional)
+     *                                             }
+     *                                             valueTime: String (Optional)
+     *                                             valueDateTime: String (Optional)
+     *                                             valuePeriod (Optional): {
+     *                                                 id: String (Optional)
+     *                                                 extension (Optional): [
+     *                                                     (recursive schema, see above)
+     *                                                 ]
+     *                                                 start: String (Optional)
+     *                                                 end: String (Optional)
+     *                                             }
+     *                                             valueReference (Optional): {
+     *                                                 id: String (Optional)
+     *                                                 extension (Optional): [
+     *                                                     (recursive schema, see above)
+     *                                                 ]
+     *                                                 reference: String (Optional)
+     *                                                 type: String (Optional)
+     *                                                 identifier (Optional): {
+     *                                                     id: String (Optional)
+     *                                                     extension (Optional): [
+     *                                                         (recursive schema, see above)
+     *                                                     ]
+     *                                                     use: String (Optional)
+     *                                                     type (Optional): (recursive schema, see type above)
+     *                                                     system: String (Optional)
+     *                                                     value: String (Optional)
+     *                                                     period (Optional): (recursive schema, see period above)
+     *                                                     assigner (Optional): (recursive schema, see assigner above)
+     *                                                 }
+     *                                                 display: String (Optional)
+     *                                             }
+     *                                         }
+     *                                     ]
+     *                                     system: String (Optional)
+     *                                     version: String (Optional)
+     *                                     code: String (Optional)
+     *                                     display: String (Optional)
+     *                                 }
+     *                             ]
+     *                             tag (Optional): [
+     *                                 (recursive schema, see above)
+     *                             ]
+     *                         }
+     *                         implicitRules: String (Optional)
+     *                         language: String (Optional)
+     *                          (Optional): {
+     *                             String: Object (Required)
+     *                         }
+     *                     }
+     *                 ]
+     *             }
+     *             encounters (Optional): [
+     *                  (Optional){
+     *                     id: String (Required)
+     *                     period (Optional): {
+     *                         start: OffsetDateTime (Optional)
+     *                         end: OffsetDateTime (Optional)
+     *                     }
+     *                     class: String(inpatient/ambulatory/observation/emergency/virtual/healthHome) (Optional)
+     *                 }
+     *             ]
+     *             patientDocuments (Optional): [
+     *                  (Optional){
+     *                     type: String(note/fhirBundle/dicom/genomicSequencing) (Required)
+     *                     clinicalType: String(consultation/dischargeSummary/historyAndPhysical/radiologyReport/procedure/progress/laboratory/pathologyReport) (Optional)
+     *                     id: String (Required)
+     *                     language: String (Optional)
+     *                     createdDateTime: OffsetDateTime (Optional)
+     *                     authors (Optional): [
+     *                          (Optional){
+     *                             id: String (Optional)
+     *                             fullName: String (Optional)
+     *                         }
+     *                     ]
+     *                     specialtyType: String(pathology/radiology) (Optional)
+     *                     administrativeMetadata (Optional): {
+     *                         orderedProcedures (Optional): [
+     *                              (Optional){
+     *                                 extension (Optional): [
+     *                                     (recursive schema, see above)
+     *                                 ]
+     *                                 code (Optional): (recursive schema, see code above)
+     *                                 description: String (Optional)
+     *                             }
+     *                         ]
+     *                         encounterId: String (Optional)
+     *                     }
+     *                     content (Required): {
+     *                         sourceType: String(inline/reference) (Required)
+     *                         value: String (Required)
+     *                     }
+     *                 }
+     *             ]
+     *         }
+     *     ]
+     *     configuration (Optional): {
+     *         verbose: Boolean (Optional)
+     *         includeEvidence: Boolean (Optional)
+     *     }
+     * }
+     * }
+ *

+ * Response Body Schema + *

+ *
{@code
+     * {
+     *     id: String (Required)
+     *     status: String (Required)
+     *     error (Optional): {
+     *         code: String (Required)
+     *         message: String (Required)
+     *         target: String (Optional)
+     *         details (Optional): [
+     *             (recursive schema, see above)
+     *         ]
+     *     }
+     * }
+     * }
+ * + * @param patientTimelineData The body of the Patient Timeline request. + * @param requestOptions The options to configure the HTTP request before HTTP client sends it. + * @throws HttpResponseException thrown if the request is rejected by server. + * @throws ClientAuthenticationException thrown if the request is rejected by server on status code 401. + * @throws ResourceNotFoundException thrown if the request is rejected by server on status code 404. + * @throws ResourceModifiedException thrown if the request is rejected by server on status code 409. + * @return status details for long running operations along with {@link Response} on successful completion of + * {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + private Mono> inferPatientTimelineWithResponseAsync(BinaryData patientTimelineData, + RequestOptions requestOptions) { + final String accept = "application/json"; + RequestOptions requestOptionsLocal = requestOptions == null ? new RequestOptions() : requestOptions; + String repeatabilityRequestId = UUID.randomUUID().toString(); + String repeatabilityFirstSent = DateTimeRfc1123.toRfc1123String(OffsetDateTime.now()); + requestOptionsLocal.addRequestCallback(requestLocal -> { + if (requestLocal.getHeaders().get(HttpHeaderName.fromString("repeatability-request-id")) == null) { + requestLocal.getHeaders().set(HttpHeaderName.fromString("repeatability-request-id"), + repeatabilityRequestId); + } + }); + requestOptionsLocal.addRequestCallback(requestLocal -> { + if (requestLocal.getHeaders().get(HttpHeaderName.fromString("repeatability-first-sent")) == null) { + requestLocal.getHeaders().set(HttpHeaderName.fromString("repeatability-first-sent"), + repeatabilityFirstSent); + } + }); + return FluxUtil.withContext(context -> service.inferPatientTimeline(this.getEndpoint(), + this.getServiceVersion().getVersion(), accept, patientTimelineData, requestOptionsLocal, context)); + } + + /** + * Create Patient Timeline job + * + * Creates a Patient Timeline job with the given request body. + *

+ * Header Parameters + *

+ * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + *
Header Parameters
NameTypeRequiredDescription
repeatability-request-idStringNoRepeatability request ID header
repeatability-first-sentStringNoRepeatability first sent header as HTTP-date
+ * You can add these to a request with {@link RequestOptions#addHeader} + *

+ * Request Body Schema + *

+ *
{@code
+     * {
+     *     patients (Required): [
+     *          (Required){
+     *             id: String (Required)
+     *             info (Optional): {
+     *                 sex: String(female/male/unspecified) (Optional)
+     *                 birthDate: LocalDate (Optional)
+     *                 clinicalInfo (Optional): [
+     *                      (Optional){
+     *                         resourceType: String (Required)
+     *                         id: String (Optional)
+     *                         meta (Optional): {
+     *                             versionId: String (Optional)
+     *                             lastUpdated: String (Optional)
+     *                             source: String (Optional)
+     *                             profile (Optional): [
+     *                                 String (Optional)
+     *                             ]
+     *                             security (Optional): [
+     *                                  (Optional){
+     *                                     id: String (Optional)
+     *                                     extension (Optional): [
+     *                                          (Optional){
+     *                                             id: String (Optional)
+     *                                             extension (Optional): [
+     *                                                 (recursive schema, see above)
+     *                                             ]
+     *                                             url: String (Required)
+     *                                             valueQuantity (Optional): {
+     *                                                 id: String (Optional)
+     *                                                 extension (Optional): [
+     *                                                     (recursive schema, see above)
+     *                                                 ]
+     *                                                 value: BigDecimal (Optional)
+     *                                                 comparator: String (Optional)
+     *                                                 unit: String (Optional)
+     *                                                 system: String (Optional)
+     *                                                 code: String (Optional)
+     *                                             }
+     *                                             valueCodeableConcept (Optional): {
+     *                                                 id: String (Optional)
+     *                                                 extension (Optional): [
+     *                                                     (recursive schema, see above)
+     *                                                 ]
+     *                                                 coding (Optional): [
+     *                                                     (recursive schema, see above)
+     *                                                 ]
+     *                                                 text: String (Optional)
+     *                                             }
+     *                                             valueString: String (Optional)
+     *                                             valueBoolean: Boolean (Optional)
+     *                                             valueInteger: Integer (Optional)
+     *                                             valueRange (Optional): {
+     *                                                 id: String (Optional)
+     *                                                 extension (Optional): [
+     *                                                     (recursive schema, see above)
+     *                                                 ]
+     *                                                 low (Optional): (recursive schema, see low above)
+     *                                                 high (Optional): (recursive schema, see high above)
+     *                                             }
+     *                                             valueRatio (Optional): {
+     *                                                 id: String (Optional)
+     *                                                 extension (Optional): [
+     *                                                     (recursive schema, see above)
+     *                                                 ]
+     *                                                 numerator (Optional): (recursive schema, see numerator above)
+     *                                                 denominator (Optional): (recursive schema, see denominator above)
+     *                                             }
+     *                                             valueSampledData (Optional): {
+     *                                                 id: String (Optional)
+     *                                                 extension (Optional): [
+     *                                                     (recursive schema, see above)
+     *                                                 ]
+     *                                                 origin (Required): (recursive schema, see origin above)
+     *                                                 period: BigDecimal (Required)
+     *                                                 factor: BigDecimal (Optional)
+     *                                                 lowerLimit: BigDecimal (Optional)
+     *                                                 upperLimit: BigDecimal (Optional)
+     *                                                 dimensions: int (Required)
+     *                                                 data: String (Optional)
+     *                                             }
+     *                                             valueTime: String (Optional)
+     *                                             valueDateTime: String (Optional)
+     *                                             valuePeriod (Optional): {
+     *                                                 id: String (Optional)
+     *                                                 extension (Optional): [
+     *                                                     (recursive schema, see above)
+     *                                                 ]
+     *                                                 start: String (Optional)
+     *                                                 end: String (Optional)
+     *                                             }
+     *                                             valueReference (Optional): {
+     *                                                 id: String (Optional)
+     *                                                 extension (Optional): [
+     *                                                     (recursive schema, see above)
+     *                                                 ]
+     *                                                 reference: String (Optional)
+     *                                                 type: String (Optional)
+     *                                                 identifier (Optional): {
+     *                                                     id: String (Optional)
+     *                                                     extension (Optional): [
+     *                                                         (recursive schema, see above)
+     *                                                     ]
+     *                                                     use: String (Optional)
+     *                                                     type (Optional): (recursive schema, see type above)
+     *                                                     system: String (Optional)
+     *                                                     value: String (Optional)
+     *                                                     period (Optional): (recursive schema, see period above)
+     *                                                     assigner (Optional): (recursive schema, see assigner above)
+     *                                                 }
+     *                                                 display: String (Optional)
+     *                                             }
+     *                                         }
+     *                                     ]
+     *                                     system: String (Optional)
+     *                                     version: String (Optional)
+     *                                     code: String (Optional)
+     *                                     display: String (Optional)
+     *                                 }
+     *                             ]
+     *                             tag (Optional): [
+     *                                 (recursive schema, see above)
+     *                             ]
+     *                         }
+     *                         implicitRules: String (Optional)
+     *                         language: String (Optional)
+     *                          (Optional): {
+     *                             String: Object (Required)
+     *                         }
+     *                     }
+     *                 ]
+     *             }
+     *             encounters (Optional): [
+     *                  (Optional){
+     *                     id: String (Required)
+     *                     period (Optional): {
+     *                         start: OffsetDateTime (Optional)
+     *                         end: OffsetDateTime (Optional)
+     *                     }
+     *                     class: String(inpatient/ambulatory/observation/emergency/virtual/healthHome) (Optional)
+     *                 }
+     *             ]
+     *             patientDocuments (Optional): [
+     *                  (Optional){
+     *                     type: String(note/fhirBundle/dicom/genomicSequencing) (Required)
+     *                     clinicalType: String(consultation/dischargeSummary/historyAndPhysical/radiologyReport/procedure/progress/laboratory/pathologyReport) (Optional)
+     *                     id: String (Required)
+     *                     language: String (Optional)
+     *                     createdDateTime: OffsetDateTime (Optional)
+     *                     authors (Optional): [
+     *                          (Optional){
+     *                             id: String (Optional)
+     *                             fullName: String (Optional)
+     *                         }
+     *                     ]
+     *                     specialtyType: String(pathology/radiology) (Optional)
+     *                     administrativeMetadata (Optional): {
+     *                         orderedProcedures (Optional): [
+     *                              (Optional){
+     *                                 extension (Optional): [
+     *                                     (recursive schema, see above)
+     *                                 ]
+     *                                 code (Optional): (recursive schema, see code above)
+     *                                 description: String (Optional)
+     *                             }
+     *                         ]
+     *                         encounterId: String (Optional)
+     *                     }
+     *                     content (Required): {
+     *                         sourceType: String(inline/reference) (Required)
+     *                         value: String (Required)
+     *                     }
+     *                 }
+     *             ]
+     *         }
+     *     ]
+     *     configuration (Optional): {
+     *         verbose: Boolean (Optional)
+     *         includeEvidence: Boolean (Optional)
+     *     }
+     * }
+     * }
+ *

+ * Response Body Schema + *

+ *
{@code
+     * {
+     *     id: String (Required)
+     *     status: String (Required)
+     *     error (Optional): {
+     *         code: String (Required)
+     *         message: String (Required)
+     *         target: String (Optional)
+     *         details (Optional): [
+     *             (recursive schema, see above)
+     *         ]
+     *     }
+     * }
+     * }
+ * + * @param patientTimelineData The body of the Patient Timeline request. + * @param requestOptions The options to configure the HTTP request before HTTP client sends it. + * @throws HttpResponseException thrown if the request is rejected by server. + * @throws ClientAuthenticationException thrown if the request is rejected by server on status code 401. + * @throws ResourceNotFoundException thrown if the request is rejected by server on status code 404. + * @throws ResourceModifiedException thrown if the request is rejected by server on status code 409. + * @return status details for long running operations along with {@link Response}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + private Response inferPatientTimelineWithResponse(BinaryData patientTimelineData, + RequestOptions requestOptions) { + final String accept = "application/json"; + RequestOptions requestOptionsLocal = requestOptions == null ? new RequestOptions() : requestOptions; + String repeatabilityRequestId = UUID.randomUUID().toString(); + String repeatabilityFirstSent = DateTimeRfc1123.toRfc1123String(OffsetDateTime.now()); + requestOptionsLocal.addRequestCallback(requestLocal -> { + if (requestLocal.getHeaders().get(HttpHeaderName.fromString("repeatability-request-id")) == null) { + requestLocal.getHeaders().set(HttpHeaderName.fromString("repeatability-request-id"), + repeatabilityRequestId); + } + }); + requestOptionsLocal.addRequestCallback(requestLocal -> { + if (requestLocal.getHeaders().get(HttpHeaderName.fromString("repeatability-first-sent")) == null) { + requestLocal.getHeaders().set(HttpHeaderName.fromString("repeatability-first-sent"), + repeatabilityFirstSent); + } + }); + return service.inferPatientTimelineSync(this.getEndpoint(), this.getServiceVersion().getVersion(), accept, + patientTimelineData, requestOptionsLocal, Context.NONE); + } + + /** + * Create Patient Timeline job + * + * Creates a Patient Timeline job with the given request body. + *

+ * Header Parameters + *

+ * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + *
Header Parameters
NameTypeRequiredDescription
repeatability-request-idStringNoRepeatability request ID header
repeatability-first-sentStringNoRepeatability first sent header as HTTP-date
+ * You can add these to a request with {@link RequestOptions#addHeader} + *

+ * Request Body Schema + *

+ *
{@code
+     * {
+     *     patients (Required): [
+     *          (Required){
+     *             id: String (Required)
+     *             info (Optional): {
+     *                 sex: String(female/male/unspecified) (Optional)
+     *                 birthDate: LocalDate (Optional)
+     *                 clinicalInfo (Optional): [
+     *                      (Optional){
+     *                         resourceType: String (Required)
+     *                         id: String (Optional)
+     *                         meta (Optional): {
+     *                             versionId: String (Optional)
+     *                             lastUpdated: String (Optional)
+     *                             source: String (Optional)
+     *                             profile (Optional): [
+     *                                 String (Optional)
+     *                             ]
+     *                             security (Optional): [
+     *                                  (Optional){
+     *                                     id: String (Optional)
+     *                                     extension (Optional): [
+     *                                          (Optional){
+     *                                             id: String (Optional)
+     *                                             extension (Optional): [
+     *                                                 (recursive schema, see above)
+     *                                             ]
+     *                                             url: String (Required)
+     *                                             valueQuantity (Optional): {
+     *                                                 id: String (Optional)
+     *                                                 extension (Optional): [
+     *                                                     (recursive schema, see above)
+     *                                                 ]
+     *                                                 value: BigDecimal (Optional)
+     *                                                 comparator: String (Optional)
+     *                                                 unit: String (Optional)
+     *                                                 system: String (Optional)
+     *                                                 code: String (Optional)
+     *                                             }
+     *                                             valueCodeableConcept (Optional): {
+     *                                                 id: String (Optional)
+     *                                                 extension (Optional): [
+     *                                                     (recursive schema, see above)
+     *                                                 ]
+     *                                                 coding (Optional): [
+     *                                                     (recursive schema, see above)
+     *                                                 ]
+     *                                                 text: String (Optional)
+     *                                             }
+     *                                             valueString: String (Optional)
+     *                                             valueBoolean: Boolean (Optional)
+     *                                             valueInteger: Integer (Optional)
+     *                                             valueRange (Optional): {
+     *                                                 id: String (Optional)
+     *                                                 extension (Optional): [
+     *                                                     (recursive schema, see above)
+     *                                                 ]
+     *                                                 low (Optional): (recursive schema, see low above)
+     *                                                 high (Optional): (recursive schema, see high above)
+     *                                             }
+     *                                             valueRatio (Optional): {
+     *                                                 id: String (Optional)
+     *                                                 extension (Optional): [
+     *                                                     (recursive schema, see above)
+     *                                                 ]
+     *                                                 numerator (Optional): (recursive schema, see numerator above)
+     *                                                 denominator (Optional): (recursive schema, see denominator above)
+     *                                             }
+     *                                             valueSampledData (Optional): {
+     *                                                 id: String (Optional)
+     *                                                 extension (Optional): [
+     *                                                     (recursive schema, see above)
+     *                                                 ]
+     *                                                 origin (Required): (recursive schema, see origin above)
+     *                                                 period: BigDecimal (Required)
+     *                                                 factor: BigDecimal (Optional)
+     *                                                 lowerLimit: BigDecimal (Optional)
+     *                                                 upperLimit: BigDecimal (Optional)
+     *                                                 dimensions: int (Required)
+     *                                                 data: String (Optional)
+     *                                             }
+     *                                             valueTime: String (Optional)
+     *                                             valueDateTime: String (Optional)
+     *                                             valuePeriod (Optional): {
+     *                                                 id: String (Optional)
+     *                                                 extension (Optional): [
+     *                                                     (recursive schema, see above)
+     *                                                 ]
+     *                                                 start: String (Optional)
+     *                                                 end: String (Optional)
+     *                                             }
+     *                                             valueReference (Optional): {
+     *                                                 id: String (Optional)
+     *                                                 extension (Optional): [
+     *                                                     (recursive schema, see above)
+     *                                                 ]
+     *                                                 reference: String (Optional)
+     *                                                 type: String (Optional)
+     *                                                 identifier (Optional): {
+     *                                                     id: String (Optional)
+     *                                                     extension (Optional): [
+     *                                                         (recursive schema, see above)
+     *                                                     ]
+     *                                                     use: String (Optional)
+     *                                                     type (Optional): (recursive schema, see type above)
+     *                                                     system: String (Optional)
+     *                                                     value: String (Optional)
+     *                                                     period (Optional): (recursive schema, see period above)
+     *                                                     assigner (Optional): (recursive schema, see assigner above)
+     *                                                 }
+     *                                                 display: String (Optional)
+     *                                             }
+     *                                         }
+     *                                     ]
+     *                                     system: String (Optional)
+     *                                     version: String (Optional)
+     *                                     code: String (Optional)
+     *                                     display: String (Optional)
+     *                                 }
+     *                             ]
+     *                             tag (Optional): [
+     *                                 (recursive schema, see above)
+     *                             ]
+     *                         }
+     *                         implicitRules: String (Optional)
+     *                         language: String (Optional)
+     *                          (Optional): {
+     *                             String: Object (Required)
+     *                         }
+     *                     }
+     *                 ]
+     *             }
+     *             encounters (Optional): [
+     *                  (Optional){
+     *                     id: String (Required)
+     *                     period (Optional): {
+     *                         start: OffsetDateTime (Optional)
+     *                         end: OffsetDateTime (Optional)
+     *                     }
+     *                     class: String(inpatient/ambulatory/observation/emergency/virtual/healthHome) (Optional)
+     *                 }
+     *             ]
+     *             patientDocuments (Optional): [
+     *                  (Optional){
+     *                     type: String(note/fhirBundle/dicom/genomicSequencing) (Required)
+     *                     clinicalType: String(consultation/dischargeSummary/historyAndPhysical/radiologyReport/procedure/progress/laboratory/pathologyReport) (Optional)
+     *                     id: String (Required)
+     *                     language: String (Optional)
+     *                     createdDateTime: OffsetDateTime (Optional)
+     *                     authors (Optional): [
+     *                          (Optional){
+     *                             id: String (Optional)
+     *                             fullName: String (Optional)
+     *                         }
+     *                     ]
+     *                     specialtyType: String(pathology/radiology) (Optional)
+     *                     administrativeMetadata (Optional): {
+     *                         orderedProcedures (Optional): [
+     *                              (Optional){
+     *                                 extension (Optional): [
+     *                                     (recursive schema, see above)
+     *                                 ]
+     *                                 code (Optional): (recursive schema, see code above)
+     *                                 description: String (Optional)
+     *                             }
+     *                         ]
+     *                         encounterId: String (Optional)
+     *                     }
+     *                     content (Required): {
+     *                         sourceType: String(inline/reference) (Required)
+     *                         value: String (Required)
+     *                     }
+     *                 }
+     *             ]
+     *         }
+     *     ]
+     *     configuration (Optional): {
+     *         verbose: Boolean (Optional)
+     *         includeEvidence: Boolean (Optional)
+     *     }
+     * }
+     * }
+ *

+ * Response Body Schema + *

+ *
{@code
+     * {
+     *     id: String (Required)
+     *     status: String (Required)
+     *     error (Optional): {
+     *         code: String (Required)
+     *         message: String (Required)
+     *         target: String (Optional)
+     *         details (Optional): [
+     *             (recursive schema, see above)
+     *         ]
+     *     }
+     * }
+     * }
+ * + * @param patientTimelineData The body of the Patient Timeline request. + * @param requestOptions The options to configure the HTTP request before HTTP client sends it. + * @throws HttpResponseException thrown if the request is rejected by server. + * @throws ClientAuthenticationException thrown if the request is rejected by server on status code 401. + * @throws ResourceNotFoundException thrown if the request is rejected by server on status code 404. + * @throws ResourceModifiedException thrown if the request is rejected by server on status code 409. + * @return the {@link PollerFlux} for polling of status details for long running operations. + */ + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) + public PollerFlux beginInferPatientTimelineAsync(BinaryData patientTimelineData, + RequestOptions requestOptions) { + return PollerFlux.create(Duration.ofSeconds(1), + () -> this.inferPatientTimelineWithResponseAsync(patientTimelineData, requestOptions), + new com.azure.core.experimental.util.polling.OperationLocationPollingStrategy<>( + new PollingStrategyOptions(this.getHttpPipeline()) + .setEndpoint("{endpoint}/health-insights".replace("{endpoint}", this.getEndpoint())) + .setContext(requestOptions != null && requestOptions.getContext() != null + ? requestOptions.getContext() : Context.NONE) + .setServiceVersion(this.getServiceVersion().getVersion())), + TypeReference.createInstance(BinaryData.class), TypeReference.createInstance(BinaryData.class)); + } + + /** + * Create Patient Timeline job + * + * Creates a Patient Timeline job with the given request body. + *

+ * Header Parameters + *

+ * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + *
Header Parameters
NameTypeRequiredDescription
repeatability-request-idStringNoRepeatability request ID header
repeatability-first-sentStringNoRepeatability first sent header as HTTP-date
+ * You can add these to a request with {@link RequestOptions#addHeader} + *

+ * Request Body Schema + *

+ *
{@code
+     * {
+     *     patients (Required): [
+     *          (Required){
+     *             id: String (Required)
+     *             info (Optional): {
+     *                 sex: String(female/male/unspecified) (Optional)
+     *                 birthDate: LocalDate (Optional)
+     *                 clinicalInfo (Optional): [
+     *                      (Optional){
+     *                         resourceType: String (Required)
+     *                         id: String (Optional)
+     *                         meta (Optional): {
+     *                             versionId: String (Optional)
+     *                             lastUpdated: String (Optional)
+     *                             source: String (Optional)
+     *                             profile (Optional): [
+     *                                 String (Optional)
+     *                             ]
+     *                             security (Optional): [
+     *                                  (Optional){
+     *                                     id: String (Optional)
+     *                                     extension (Optional): [
+     *                                          (Optional){
+     *                                             id: String (Optional)
+     *                                             extension (Optional): [
+     *                                                 (recursive schema, see above)
+     *                                             ]
+     *                                             url: String (Required)
+     *                                             valueQuantity (Optional): {
+     *                                                 id: String (Optional)
+     *                                                 extension (Optional): [
+     *                                                     (recursive schema, see above)
+     *                                                 ]
+     *                                                 value: BigDecimal (Optional)
+     *                                                 comparator: String (Optional)
+     *                                                 unit: String (Optional)
+     *                                                 system: String (Optional)
+     *                                                 code: String (Optional)
+     *                                             }
+     *                                             valueCodeableConcept (Optional): {
+     *                                                 id: String (Optional)
+     *                                                 extension (Optional): [
+     *                                                     (recursive schema, see above)
+     *                                                 ]
+     *                                                 coding (Optional): [
+     *                                                     (recursive schema, see above)
+     *                                                 ]
+     *                                                 text: String (Optional)
+     *                                             }
+     *                                             valueString: String (Optional)
+     *                                             valueBoolean: Boolean (Optional)
+     *                                             valueInteger: Integer (Optional)
+     *                                             valueRange (Optional): {
+     *                                                 id: String (Optional)
+     *                                                 extension (Optional): [
+     *                                                     (recursive schema, see above)
+     *                                                 ]
+     *                                                 low (Optional): (recursive schema, see low above)
+     *                                                 high (Optional): (recursive schema, see high above)
+     *                                             }
+     *                                             valueRatio (Optional): {
+     *                                                 id: String (Optional)
+     *                                                 extension (Optional): [
+     *                                                     (recursive schema, see above)
+     *                                                 ]
+     *                                                 numerator (Optional): (recursive schema, see numerator above)
+     *                                                 denominator (Optional): (recursive schema, see denominator above)
+     *                                             }
+     *                                             valueSampledData (Optional): {
+     *                                                 id: String (Optional)
+     *                                                 extension (Optional): [
+     *                                                     (recursive schema, see above)
+     *                                                 ]
+     *                                                 origin (Required): (recursive schema, see origin above)
+     *                                                 period: BigDecimal (Required)
+     *                                                 factor: BigDecimal (Optional)
+     *                                                 lowerLimit: BigDecimal (Optional)
+     *                                                 upperLimit: BigDecimal (Optional)
+     *                                                 dimensions: int (Required)
+     *                                                 data: String (Optional)
+     *                                             }
+     *                                             valueTime: String (Optional)
+     *                                             valueDateTime: String (Optional)
+     *                                             valuePeriod (Optional): {
+     *                                                 id: String (Optional)
+     *                                                 extension (Optional): [
+     *                                                     (recursive schema, see above)
+     *                                                 ]
+     *                                                 start: String (Optional)
+     *                                                 end: String (Optional)
+     *                                             }
+     *                                             valueReference (Optional): {
+     *                                                 id: String (Optional)
+     *                                                 extension (Optional): [
+     *                                                     (recursive schema, see above)
+     *                                                 ]
+     *                                                 reference: String (Optional)
+     *                                                 type: String (Optional)
+     *                                                 identifier (Optional): {
+     *                                                     id: String (Optional)
+     *                                                     extension (Optional): [
+     *                                                         (recursive schema, see above)
+     *                                                     ]
+     *                                                     use: String (Optional)
+     *                                                     type (Optional): (recursive schema, see type above)
+     *                                                     system: String (Optional)
+     *                                                     value: String (Optional)
+     *                                                     period (Optional): (recursive schema, see period above)
+     *                                                     assigner (Optional): (recursive schema, see assigner above)
+     *                                                 }
+     *                                                 display: String (Optional)
+     *                                             }
+     *                                         }
+     *                                     ]
+     *                                     system: String (Optional)
+     *                                     version: String (Optional)
+     *                                     code: String (Optional)
+     *                                     display: String (Optional)
+     *                                 }
+     *                             ]
+     *                             tag (Optional): [
+     *                                 (recursive schema, see above)
+     *                             ]
+     *                         }
+     *                         implicitRules: String (Optional)
+     *                         language: String (Optional)
+     *                          (Optional): {
+     *                             String: Object (Required)
+     *                         }
+     *                     }
+     *                 ]
+     *             }
+     *             encounters (Optional): [
+     *                  (Optional){
+     *                     id: String (Required)
+     *                     period (Optional): {
+     *                         start: OffsetDateTime (Optional)
+     *                         end: OffsetDateTime (Optional)
+     *                     }
+     *                     class: String(inpatient/ambulatory/observation/emergency/virtual/healthHome) (Optional)
+     *                 }
+     *             ]
+     *             patientDocuments (Optional): [
+     *                  (Optional){
+     *                     type: String(note/fhirBundle/dicom/genomicSequencing) (Required)
+     *                     clinicalType: String(consultation/dischargeSummary/historyAndPhysical/radiologyReport/procedure/progress/laboratory/pathologyReport) (Optional)
+     *                     id: String (Required)
+     *                     language: String (Optional)
+     *                     createdDateTime: OffsetDateTime (Optional)
+     *                     authors (Optional): [
+     *                          (Optional){
+     *                             id: String (Optional)
+     *                             fullName: String (Optional)
+     *                         }
+     *                     ]
+     *                     specialtyType: String(pathology/radiology) (Optional)
+     *                     administrativeMetadata (Optional): {
+     *                         orderedProcedures (Optional): [
+     *                              (Optional){
+     *                                 extension (Optional): [
+     *                                     (recursive schema, see above)
+     *                                 ]
+     *                                 code (Optional): (recursive schema, see code above)
+     *                                 description: String (Optional)
+     *                             }
+     *                         ]
+     *                         encounterId: String (Optional)
+     *                     }
+     *                     content (Required): {
+     *                         sourceType: String(inline/reference) (Required)
+     *                         value: String (Required)
+     *                     }
+     *                 }
+     *             ]
+     *         }
+     *     ]
+     *     configuration (Optional): {
+     *         verbose: Boolean (Optional)
+     *         includeEvidence: Boolean (Optional)
+     *     }
+     * }
+     * }
+ *

+ * Response Body Schema + *

+ *
{@code
+     * {
+     *     id: String (Required)
+     *     status: String (Required)
+     *     error (Optional): {
+     *         code: String (Required)
+     *         message: String (Required)
+     *         target: String (Optional)
+     *         details (Optional): [
+     *             (recursive schema, see above)
+     *         ]
+     *     }
+     * }
+     * }
+ * + * @param patientTimelineData The body of the Patient Timeline request. + * @param requestOptions The options to configure the HTTP request before HTTP client sends it. + * @throws HttpResponseException thrown if the request is rejected by server. + * @throws ClientAuthenticationException thrown if the request is rejected by server on status code 401. + * @throws ResourceNotFoundException thrown if the request is rejected by server on status code 404. + * @throws ResourceModifiedException thrown if the request is rejected by server on status code 409. + * @return the {@link SyncPoller} for polling of status details for long running operations. + */ + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) + public SyncPoller beginInferPatientTimeline(BinaryData patientTimelineData, + RequestOptions requestOptions) { + return SyncPoller.createPoller(Duration.ofSeconds(1), + () -> this.inferPatientTimelineWithResponse(patientTimelineData, requestOptions), + new com.azure.core.experimental.util.polling.SyncOperationLocationPollingStrategy<>( + new PollingStrategyOptions(this.getHttpPipeline()) + .setEndpoint("{endpoint}/health-insights".replace("{endpoint}", this.getEndpoint())) + .setContext(requestOptions != null && requestOptions.getContext() != null + ? requestOptions.getContext() : Context.NONE) + .setServiceVersion(this.getServiceVersion().getVersion())), + TypeReference.createInstance(BinaryData.class), TypeReference.createInstance(BinaryData.class)); + } + + /** + * Create Patient Timeline job + * + * Creates a Patient Timeline job with the given request body. + *

+ * Header Parameters + *

+ * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + *
Header Parameters
NameTypeRequiredDescription
repeatability-request-idStringNoRepeatability request ID header
repeatability-first-sentStringNoRepeatability first sent header as HTTP-date
+ * You can add these to a request with {@link RequestOptions#addHeader} + *

+ * Request Body Schema + *

+ *
{@code
+     * {
+     *     patients (Required): [
+     *          (Required){
+     *             id: String (Required)
+     *             info (Optional): {
+     *                 sex: String(female/male/unspecified) (Optional)
+     *                 birthDate: LocalDate (Optional)
+     *                 clinicalInfo (Optional): [
+     *                      (Optional){
+     *                         resourceType: String (Required)
+     *                         id: String (Optional)
+     *                         meta (Optional): {
+     *                             versionId: String (Optional)
+     *                             lastUpdated: String (Optional)
+     *                             source: String (Optional)
+     *                             profile (Optional): [
+     *                                 String (Optional)
+     *                             ]
+     *                             security (Optional): [
+     *                                  (Optional){
+     *                                     id: String (Optional)
+     *                                     extension (Optional): [
+     *                                          (Optional){
+     *                                             id: String (Optional)
+     *                                             extension (Optional): [
+     *                                                 (recursive schema, see above)
+     *                                             ]
+     *                                             url: String (Required)
+     *                                             valueQuantity (Optional): {
+     *                                                 id: String (Optional)
+     *                                                 extension (Optional): [
+     *                                                     (recursive schema, see above)
+     *                                                 ]
+     *                                                 value: BigDecimal (Optional)
+     *                                                 comparator: String (Optional)
+     *                                                 unit: String (Optional)
+     *                                                 system: String (Optional)
+     *                                                 code: String (Optional)
+     *                                             }
+     *                                             valueCodeableConcept (Optional): {
+     *                                                 id: String (Optional)
+     *                                                 extension (Optional): [
+     *                                                     (recursive schema, see above)
+     *                                                 ]
+     *                                                 coding (Optional): [
+     *                                                     (recursive schema, see above)
+     *                                                 ]
+     *                                                 text: String (Optional)
+     *                                             }
+     *                                             valueString: String (Optional)
+     *                                             valueBoolean: Boolean (Optional)
+     *                                             valueInteger: Integer (Optional)
+     *                                             valueRange (Optional): {
+     *                                                 id: String (Optional)
+     *                                                 extension (Optional): [
+     *                                                     (recursive schema, see above)
+     *                                                 ]
+     *                                                 low (Optional): (recursive schema, see low above)
+     *                                                 high (Optional): (recursive schema, see high above)
+     *                                             }
+     *                                             valueRatio (Optional): {
+     *                                                 id: String (Optional)
+     *                                                 extension (Optional): [
+     *                                                     (recursive schema, see above)
+     *                                                 ]
+     *                                                 numerator (Optional): (recursive schema, see numerator above)
+     *                                                 denominator (Optional): (recursive schema, see denominator above)
+     *                                             }
+     *                                             valueSampledData (Optional): {
+     *                                                 id: String (Optional)
+     *                                                 extension (Optional): [
+     *                                                     (recursive schema, see above)
+     *                                                 ]
+     *                                                 origin (Required): (recursive schema, see origin above)
+     *                                                 period: BigDecimal (Required)
+     *                                                 factor: BigDecimal (Optional)
+     *                                                 lowerLimit: BigDecimal (Optional)
+     *                                                 upperLimit: BigDecimal (Optional)
+     *                                                 dimensions: int (Required)
+     *                                                 data: String (Optional)
+     *                                             }
+     *                                             valueTime: String (Optional)
+     *                                             valueDateTime: String (Optional)
+     *                                             valuePeriod (Optional): {
+     *                                                 id: String (Optional)
+     *                                                 extension (Optional): [
+     *                                                     (recursive schema, see above)
+     *                                                 ]
+     *                                                 start: String (Optional)
+     *                                                 end: String (Optional)
+     *                                             }
+     *                                             valueReference (Optional): {
+     *                                                 id: String (Optional)
+     *                                                 extension (Optional): [
+     *                                                     (recursive schema, see above)
+     *                                                 ]
+     *                                                 reference: String (Optional)
+     *                                                 type: String (Optional)
+     *                                                 identifier (Optional): {
+     *                                                     id: String (Optional)
+     *                                                     extension (Optional): [
+     *                                                         (recursive schema, see above)
+     *                                                     ]
+     *                                                     use: String (Optional)
+     *                                                     type (Optional): (recursive schema, see type above)
+     *                                                     system: String (Optional)
+     *                                                     value: String (Optional)
+     *                                                     period (Optional): (recursive schema, see period above)
+     *                                                     assigner (Optional): (recursive schema, see assigner above)
+     *                                                 }
+     *                                                 display: String (Optional)
+     *                                             }
+     *                                         }
+     *                                     ]
+     *                                     system: String (Optional)
+     *                                     version: String (Optional)
+     *                                     code: String (Optional)
+     *                                     display: String (Optional)
+     *                                 }
+     *                             ]
+     *                             tag (Optional): [
+     *                                 (recursive schema, see above)
+     *                             ]
+     *                         }
+     *                         implicitRules: String (Optional)
+     *                         language: String (Optional)
+     *                          (Optional): {
+     *                             String: Object (Required)
+     *                         }
+     *                     }
+     *                 ]
+     *             }
+     *             encounters (Optional): [
+     *                  (Optional){
+     *                     id: String (Required)
+     *                     period (Optional): {
+     *                         start: OffsetDateTime (Optional)
+     *                         end: OffsetDateTime (Optional)
+     *                     }
+     *                     class: String(inpatient/ambulatory/observation/emergency/virtual/healthHome) (Optional)
+     *                 }
+     *             ]
+     *             patientDocuments (Optional): [
+     *                  (Optional){
+     *                     type: String(note/fhirBundle/dicom/genomicSequencing) (Required)
+     *                     clinicalType: String(consultation/dischargeSummary/historyAndPhysical/radiologyReport/procedure/progress/laboratory/pathologyReport) (Optional)
+     *                     id: String (Required)
+     *                     language: String (Optional)
+     *                     createdDateTime: OffsetDateTime (Optional)
+     *                     authors (Optional): [
+     *                          (Optional){
+     *                             id: String (Optional)
+     *                             fullName: String (Optional)
+     *                         }
+     *                     ]
+     *                     specialtyType: String(pathology/radiology) (Optional)
+     *                     administrativeMetadata (Optional): {
+     *                         orderedProcedures (Optional): [
+     *                              (Optional){
+     *                                 extension (Optional): [
+     *                                     (recursive schema, see above)
+     *                                 ]
+     *                                 code (Optional): (recursive schema, see code above)
+     *                                 description: String (Optional)
+     *                             }
+     *                         ]
+     *                         encounterId: String (Optional)
+     *                     }
+     *                     content (Required): {
+     *                         sourceType: String(inline/reference) (Required)
+     *                         value: String (Required)
+     *                     }
+     *                 }
+     *             ]
+     *         }
+     *     ]
+     *     configuration (Optional): {
+     *         verbose: Boolean (Optional)
+     *         includeEvidence: Boolean (Optional)
+     *     }
+     * }
+     * }
+ *

+ * Response Body Schema + *

+ *
{@code
+     * {
+     *     id: String (Required)
+     *     status: String (Required)
+     *     error (Optional): {
+     *         code: String (Required)
+     *         message: String (Required)
+     *         target: String (Optional)
+     *         details (Optional): [
+     *             (recursive schema, see above)
+     *         ]
+     *     }
+     * }
+     * }
+ * + * @param patientTimelineData The body of the Patient Timeline request. + * @param requestOptions The options to configure the HTTP request before HTTP client sends it. + * @throws HttpResponseException thrown if the request is rejected by server. + * @throws ClientAuthenticationException thrown if the request is rejected by server on status code 401. + * @throws ResourceNotFoundException thrown if the request is rejected by server on status code 404. + * @throws ResourceModifiedException thrown if the request is rejected by server on status code 409. + * @return the {@link PollerFlux} for polling of status details for long running operations. + */ + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) + public PollerFlux + beginInferPatientTimelineWithModelAsync(BinaryData patientTimelineData, RequestOptions requestOptions) { + return PollerFlux.create(Duration.ofSeconds(1), + () -> this.inferPatientTimelineWithResponseAsync(patientTimelineData, requestOptions), + new com.azure.core.experimental.util.polling.OperationLocationPollingStrategy<>( + new PollingStrategyOptions(this.getHttpPipeline()) + .setEndpoint("{endpoint}/health-insights".replace("{endpoint}", this.getEndpoint())) + .setContext(requestOptions != null && requestOptions.getContext() != null + ? requestOptions.getContext() : Context.NONE) + .setServiceVersion(this.getServiceVersion().getVersion())), + TypeReference.createInstance(PollOperationDetails.class), + TypeReference.createInstance(PatientTimelineInferenceResult.class)); + } + + /** + * Create Patient Timeline job + * + * Creates a Patient Timeline job with the given request body. + *

+ * Header Parameters + *

+ * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + *
Header Parameters
NameTypeRequiredDescription
repeatability-request-idStringNoRepeatability request ID header
repeatability-first-sentStringNoRepeatability first sent header as HTTP-date
+ * You can add these to a request with {@link RequestOptions#addHeader} + *

+ * Request Body Schema + *

+ *
{@code
+     * {
+     *     patients (Required): [
+     *          (Required){
+     *             id: String (Required)
+     *             info (Optional): {
+     *                 sex: String(female/male/unspecified) (Optional)
+     *                 birthDate: LocalDate (Optional)
+     *                 clinicalInfo (Optional): [
+     *                      (Optional){
+     *                         resourceType: String (Required)
+     *                         id: String (Optional)
+     *                         meta (Optional): {
+     *                             versionId: String (Optional)
+     *                             lastUpdated: String (Optional)
+     *                             source: String (Optional)
+     *                             profile (Optional): [
+     *                                 String (Optional)
+     *                             ]
+     *                             security (Optional): [
+     *                                  (Optional){
+     *                                     id: String (Optional)
+     *                                     extension (Optional): [
+     *                                          (Optional){
+     *                                             id: String (Optional)
+     *                                             extension (Optional): [
+     *                                                 (recursive schema, see above)
+     *                                             ]
+     *                                             url: String (Required)
+     *                                             valueQuantity (Optional): {
+     *                                                 id: String (Optional)
+     *                                                 extension (Optional): [
+     *                                                     (recursive schema, see above)
+     *                                                 ]
+     *                                                 value: BigDecimal (Optional)
+     *                                                 comparator: String (Optional)
+     *                                                 unit: String (Optional)
+     *                                                 system: String (Optional)
+     *                                                 code: String (Optional)
+     *                                             }
+     *                                             valueCodeableConcept (Optional): {
+     *                                                 id: String (Optional)
+     *                                                 extension (Optional): [
+     *                                                     (recursive schema, see above)
+     *                                                 ]
+     *                                                 coding (Optional): [
+     *                                                     (recursive schema, see above)
+     *                                                 ]
+     *                                                 text: String (Optional)
+     *                                             }
+     *                                             valueString: String (Optional)
+     *                                             valueBoolean: Boolean (Optional)
+     *                                             valueInteger: Integer (Optional)
+     *                                             valueRange (Optional): {
+     *                                                 id: String (Optional)
+     *                                                 extension (Optional): [
+     *                                                     (recursive schema, see above)
+     *                                                 ]
+     *                                                 low (Optional): (recursive schema, see low above)
+     *                                                 high (Optional): (recursive schema, see high above)
+     *                                             }
+     *                                             valueRatio (Optional): {
+     *                                                 id: String (Optional)
+     *                                                 extension (Optional): [
+     *                                                     (recursive schema, see above)
+     *                                                 ]
+     *                                                 numerator (Optional): (recursive schema, see numerator above)
+     *                                                 denominator (Optional): (recursive schema, see denominator above)
+     *                                             }
+     *                                             valueSampledData (Optional): {
+     *                                                 id: String (Optional)
+     *                                                 extension (Optional): [
+     *                                                     (recursive schema, see above)
+     *                                                 ]
+     *                                                 origin (Required): (recursive schema, see origin above)
+     *                                                 period: BigDecimal (Required)
+     *                                                 factor: BigDecimal (Optional)
+     *                                                 lowerLimit: BigDecimal (Optional)
+     *                                                 upperLimit: BigDecimal (Optional)
+     *                                                 dimensions: int (Required)
+     *                                                 data: String (Optional)
+     *                                             }
+     *                                             valueTime: String (Optional)
+     *                                             valueDateTime: String (Optional)
+     *                                             valuePeriod (Optional): {
+     *                                                 id: String (Optional)
+     *                                                 extension (Optional): [
+     *                                                     (recursive schema, see above)
+     *                                                 ]
+     *                                                 start: String (Optional)
+     *                                                 end: String (Optional)
+     *                                             }
+     *                                             valueReference (Optional): {
+     *                                                 id: String (Optional)
+     *                                                 extension (Optional): [
+     *                                                     (recursive schema, see above)
+     *                                                 ]
+     *                                                 reference: String (Optional)
+     *                                                 type: String (Optional)
+     *                                                 identifier (Optional): {
+     *                                                     id: String (Optional)
+     *                                                     extension (Optional): [
+     *                                                         (recursive schema, see above)
+     *                                                     ]
+     *                                                     use: String (Optional)
+     *                                                     type (Optional): (recursive schema, see type above)
+     *                                                     system: String (Optional)
+     *                                                     value: String (Optional)
+     *                                                     period (Optional): (recursive schema, see period above)
+     *                                                     assigner (Optional): (recursive schema, see assigner above)
+     *                                                 }
+     *                                                 display: String (Optional)
+     *                                             }
+     *                                         }
+     *                                     ]
+     *                                     system: String (Optional)
+     *                                     version: String (Optional)
+     *                                     code: String (Optional)
+     *                                     display: String (Optional)
+     *                                 }
+     *                             ]
+     *                             tag (Optional): [
+     *                                 (recursive schema, see above)
+     *                             ]
+     *                         }
+     *                         implicitRules: String (Optional)
+     *                         language: String (Optional)
+     *                          (Optional): {
+     *                             String: Object (Required)
+     *                         }
+     *                     }
+     *                 ]
+     *             }
+     *             encounters (Optional): [
+     *                  (Optional){
+     *                     id: String (Required)
+     *                     period (Optional): {
+     *                         start: OffsetDateTime (Optional)
+     *                         end: OffsetDateTime (Optional)
+     *                     }
+     *                     class: String(inpatient/ambulatory/observation/emergency/virtual/healthHome) (Optional)
+     *                 }
+     *             ]
+     *             patientDocuments (Optional): [
+     *                  (Optional){
+     *                     type: String(note/fhirBundle/dicom/genomicSequencing) (Required)
+     *                     clinicalType: String(consultation/dischargeSummary/historyAndPhysical/radiologyReport/procedure/progress/laboratory/pathologyReport) (Optional)
+     *                     id: String (Required)
+     *                     language: String (Optional)
+     *                     createdDateTime: OffsetDateTime (Optional)
+     *                     authors (Optional): [
+     *                          (Optional){
+     *                             id: String (Optional)
+     *                             fullName: String (Optional)
+     *                         }
+     *                     ]
+     *                     specialtyType: String(pathology/radiology) (Optional)
+     *                     administrativeMetadata (Optional): {
+     *                         orderedProcedures (Optional): [
+     *                              (Optional){
+     *                                 extension (Optional): [
+     *                                     (recursive schema, see above)
+     *                                 ]
+     *                                 code (Optional): (recursive schema, see code above)
+     *                                 description: String (Optional)
+     *                             }
+     *                         ]
+     *                         encounterId: String (Optional)
+     *                     }
+     *                     content (Required): {
+     *                         sourceType: String(inline/reference) (Required)
+     *                         value: String (Required)
+     *                     }
+     *                 }
+     *             ]
+     *         }
+     *     ]
+     *     configuration (Optional): {
+     *         verbose: Boolean (Optional)
+     *         includeEvidence: Boolean (Optional)
+     *     }
+     * }
+     * }
+ *

+ * Response Body Schema + *

+ *
{@code
+     * {
+     *     id: String (Required)
+     *     status: String (Required)
+     *     error (Optional): {
+     *         code: String (Required)
+     *         message: String (Required)
+     *         target: String (Optional)
+     *         details (Optional): [
+     *             (recursive schema, see above)
+     *         ]
+     *     }
+     * }
+     * }
+ * + * @param patientTimelineData The body of the Patient Timeline request. + * @param requestOptions The options to configure the HTTP request before HTTP client sends it. + * @throws HttpResponseException thrown if the request is rejected by server. + * @throws ClientAuthenticationException thrown if the request is rejected by server on status code 401. + * @throws ResourceNotFoundException thrown if the request is rejected by server on status code 404. + * @throws ResourceModifiedException thrown if the request is rejected by server on status code 409. + * @return the {@link SyncPoller} for polling of status details for long running operations. + */ + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) + public SyncPoller + beginInferPatientTimelineWithModel(BinaryData patientTimelineData, RequestOptions requestOptions) { + return SyncPoller.createPoller(Duration.ofSeconds(1), + () -> this.inferPatientTimelineWithResponse(patientTimelineData, requestOptions), + new com.azure.core.experimental.util.polling.SyncOperationLocationPollingStrategy<>( + new PollingStrategyOptions(this.getHttpPipeline()) + .setEndpoint("{endpoint}/health-insights".replace("{endpoint}", this.getEndpoint())) + .setContext(requestOptions != null && requestOptions.getContext() != null + ? requestOptions.getContext() : Context.NONE) + .setServiceVersion(this.getServiceVersion().getVersion())), + TypeReference.createInstance(PollOperationDetails.class), + TypeReference.createInstance(PatientTimelineInferenceResult.class)); + } +} diff --git a/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/implementation/package-info.java b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/implementation/package-info.java new file mode 100644 index 0000000000000..e17285c067cea --- /dev/null +++ b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/implementation/package-info.java @@ -0,0 +1,12 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) TypeSpec Code Generator. + +/** + * + * Package containing the implementations for AzureHealthInsights. + * Azure AI Health Insights provides an API that serves insight models, specific for Health & Life Sciences, that + * perform analysis and provide inferences to be used by a human. + * + */ +package com.azure.health.insights.patienttimeline.implementation; diff --git a/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/Annotation.java b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/Annotation.java new file mode 100644 index 0000000000000..6ffc815bd0da7 --- /dev/null +++ b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/Annotation.java @@ -0,0 +1,124 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) TypeSpec Code Generator. + +package com.azure.health.insights.patienttimeline.models; + +import com.azure.core.annotation.Fluent; +import com.azure.core.annotation.Generated; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.util.List; + +/** + * A text note which also contains information about who made the statement and when + * Based on [FHIR Annotation](https://www.hl7.org/fhir/R4/datatypes.html#Annotation). + */ +@Fluent +public final class Annotation extends Element { + /* + * Individual responsible for the annotation + */ + @Generated + @JsonProperty(value = "authorString") + private String authorString; + + /* + * When the annotation was made + */ + @Generated + @JsonProperty(value = "time") + private String time; + + /* + * The annotation - text content (as markdown) + */ + @Generated + @JsonProperty(value = "text") + private String text; + + /** + * Creates an instance of Annotation class. + * + * @param text the text value to set. + */ + @Generated + @JsonCreator + public Annotation(@JsonProperty(value = "text") String text) { + this.text = text; + } + + /** + * Get the authorString property: Individual responsible for the annotation. + * + * @return the authorString value. + */ + @Generated + public String getAuthorString() { + return this.authorString; + } + + /** + * Set the authorString property: Individual responsible for the annotation. + * + * @param authorString the authorString value to set. + * @return the Annotation object itself. + */ + @Generated + public Annotation setAuthorString(String authorString) { + this.authorString = authorString; + return this; + } + + /** + * Get the time property: When the annotation was made. + * + * @return the time value. + */ + @Generated + public String getTime() { + return this.time; + } + + /** + * Set the time property: When the annotation was made. + * + * @param time the time value to set. + * @return the Annotation object itself. + */ + @Generated + public Annotation setTime(String time) { + this.time = time; + return this; + } + + /** + * Get the text property: The annotation - text content (as markdown). + * + * @return the text value. + */ + @Generated + public String getText() { + return this.text; + } + + /** + * {@inheritDoc} + */ + @Generated + @Override + public Annotation setId(String id) { + super.setId(id); + return this; + } + + /** + * {@inheritDoc} + */ + @Generated + @Override + public Annotation setExtension(List extension) { + super.setExtension(extension); + return this; + } +} diff --git a/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/ClinicalDocumentType.java b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/ClinicalDocumentType.java new file mode 100644 index 0000000000000..972994c089158 --- /dev/null +++ b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/ClinicalDocumentType.java @@ -0,0 +1,95 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) TypeSpec Code Generator. + +package com.azure.health.insights.patienttimeline.models; + +import com.azure.core.annotation.Generated; +import com.azure.core.util.ExpandableStringEnum; +import com.fasterxml.jackson.annotation.JsonCreator; +import java.util.Collection; + +/** + * The type of the clinical document. + */ +public final class ClinicalDocumentType extends ExpandableStringEnum { + /** + * Static value consultation for ClinicalDocumentType. + */ + @Generated + public static final ClinicalDocumentType CONSULTATION = fromString("consultation"); + + /** + * Static value dischargeSummary for ClinicalDocumentType. + */ + @Generated + public static final ClinicalDocumentType DISCHARGE_SUMMARY = fromString("dischargeSummary"); + + /** + * Static value historyAndPhysical for ClinicalDocumentType. + */ + @Generated + public static final ClinicalDocumentType HISTORY_AND_PHYSICAL = fromString("historyAndPhysical"); + + /** + * Static value radiologyReport for ClinicalDocumentType. + */ + @Generated + public static final ClinicalDocumentType RADIOLOGY_REPORT = fromString("radiologyReport"); + + /** + * Static value procedure for ClinicalDocumentType. + */ + @Generated + public static final ClinicalDocumentType PROCEDURE = fromString("procedure"); + + /** + * Static value progress for ClinicalDocumentType. + */ + @Generated + public static final ClinicalDocumentType PROGRESS = fromString("progress"); + + /** + * Static value laboratory for ClinicalDocumentType. + */ + @Generated + public static final ClinicalDocumentType LABORATORY = fromString("laboratory"); + + /** + * Static value pathologyReport for ClinicalDocumentType. + */ + @Generated + public static final ClinicalDocumentType PATHOLOGY_REPORT = fromString("pathologyReport"); + + /** + * Creates a new instance of ClinicalDocumentType value. + * + * @deprecated Use the {@link #fromString(String)} factory method. + */ + @Generated + @Deprecated + public ClinicalDocumentType() { + } + + /** + * Creates or finds a ClinicalDocumentType from its string representation. + * + * @param name a name to look for. + * @return the corresponding ClinicalDocumentType. + */ + @Generated + @JsonCreator + public static ClinicalDocumentType fromString(String name) { + return fromString(name, ClinicalDocumentType.class); + } + + /** + * Gets known ClinicalDocumentType values. + * + * @return known ClinicalDocumentType values. + */ + @Generated + public static Collection values() { + return values(ClinicalDocumentType.class); + } +} diff --git a/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/CodeableConcept.java b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/CodeableConcept.java new file mode 100644 index 0000000000000..ac7d0c0ee6f1e --- /dev/null +++ b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/CodeableConcept.java @@ -0,0 +1,102 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) TypeSpec Code Generator. + +package com.azure.health.insights.patienttimeline.models; + +import com.azure.core.annotation.Fluent; +import com.azure.core.annotation.Generated; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.util.List; + +/** + * Concept - reference to a terminology or just text + * Based on [FHIR CodeableConcept](https://www.hl7.org/fhir/R4/datatypes.html#CodeableConcept). + */ +@Fluent +public final class CodeableConcept extends Element { + /* + * Code defined by a terminology system + */ + @Generated + @JsonProperty(value = "coding") + private List coding; + + /* + * Plain text representation of the concept + */ + @Generated + @JsonProperty(value = "text") + private String text; + + /** + * Creates an instance of CodeableConcept class. + */ + @Generated + public CodeableConcept() { + } + + /** + * Get the coding property: Code defined by a terminology system. + * + * @return the coding value. + */ + @Generated + public List getCoding() { + return this.coding; + } + + /** + * Set the coding property: Code defined by a terminology system. + * + * @param coding the coding value to set. + * @return the CodeableConcept object itself. + */ + @Generated + public CodeableConcept setCoding(List coding) { + this.coding = coding; + return this; + } + + /** + * Get the text property: Plain text representation of the concept. + * + * @return the text value. + */ + @Generated + public String getText() { + return this.text; + } + + /** + * Set the text property: Plain text representation of the concept. + * + * @param text the text value to set. + * @return the CodeableConcept object itself. + */ + @Generated + public CodeableConcept setText(String text) { + this.text = text; + return this; + } + + /** + * {@inheritDoc} + */ + @Generated + @Override + public CodeableConcept setId(String id) { + super.setId(id); + return this; + } + + /** + * {@inheritDoc} + */ + @Generated + @Override + public CodeableConcept setExtension(List extension) { + super.setExtension(extension); + return this; + } +} diff --git a/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/Coding.java b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/Coding.java new file mode 100644 index 0000000000000..8bf6d7e1efd3f --- /dev/null +++ b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/Coding.java @@ -0,0 +1,160 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) TypeSpec Code Generator. + +package com.azure.health.insights.patienttimeline.models; + +import com.azure.core.annotation.Fluent; +import com.azure.core.annotation.Generated; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.util.List; + +/** + * A Coding is a representation of a defined concept using a symbol from a defined "code system". + * Based on [FHIR Coding](https://www.hl7.org/fhir/R4/datatypes.html#Coding). + */ +@Fluent +public final class Coding extends Element { + /* + * Identity of the terminology system + */ + @Generated + @JsonProperty(value = "system") + private String system; + + /* + * Version of the system - if relevant + */ + @Generated + @JsonProperty(value = "version") + private String version; + + /* + * Symbol in syntax defined by the system + */ + @Generated + @JsonProperty(value = "code") + private String code; + + /* + * Representation defined by the system + */ + @Generated + @JsonProperty(value = "display") + private String display; + + /** + * Creates an instance of Coding class. + */ + @Generated + public Coding() { + } + + /** + * Get the system property: Identity of the terminology system. + * + * @return the system value. + */ + @Generated + public String getSystem() { + return this.system; + } + + /** + * Set the system property: Identity of the terminology system. + * + * @param system the system value to set. + * @return the Coding object itself. + */ + @Generated + public Coding setSystem(String system) { + this.system = system; + return this; + } + + /** + * Get the version property: Version of the system - if relevant. + * + * @return the version value. + */ + @Generated + public String getVersion() { + return this.version; + } + + /** + * Set the version property: Version of the system - if relevant. + * + * @param version the version value to set. + * @return the Coding object itself. + */ + @Generated + public Coding setVersion(String version) { + this.version = version; + return this; + } + + /** + * Get the code property: Symbol in syntax defined by the system. + * + * @return the code value. + */ + @Generated + public String getCode() { + return this.code; + } + + /** + * Set the code property: Symbol in syntax defined by the system. + * + * @param code the code value to set. + * @return the Coding object itself. + */ + @Generated + public Coding setCode(String code) { + this.code = code; + return this; + } + + /** + * Get the display property: Representation defined by the system. + * + * @return the display value. + */ + @Generated + public String getDisplay() { + return this.display; + } + + /** + * Set the display property: Representation defined by the system. + * + * @param display the display value to set. + * @return the Coding object itself. + */ + @Generated + public Coding setDisplay(String display) { + this.display = display; + return this; + } + + /** + * {@inheritDoc} + */ + @Generated + @Override + public Coding setId(String id) { + super.setId(id); + return this; + } + + /** + * {@inheritDoc} + */ + @Generated + @Override + public Coding setExtension(List extension) { + super.setExtension(extension); + return this; + } +} diff --git a/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/Condition.java b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/Condition.java new file mode 100644 index 0000000000000..52464fed8545c --- /dev/null +++ b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/Condition.java @@ -0,0 +1,680 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) TypeSpec Code Generator. + +package com.azure.health.insights.patienttimeline.models; + +import com.azure.core.annotation.Fluent; +import com.azure.core.annotation.Generated; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonTypeInfo; +import com.fasterxml.jackson.annotation.JsonTypeName; +import java.util.List; +import java.util.Map; + +/** + * Detailed information about conditions, problems or diagnoses + * Based on [FHIR Condition](https://www.hl7.org/fhir/R4/condition.html). + */ +@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "resourceType") +@JsonTypeName("Condition") +@Fluent +public final class Condition extends DomainResource { + /* + * External Ids for this condition + */ + @Generated + @JsonProperty(value = "identifier") + private List identifier; + + /* + * active | recurrence | relapse | inactive | remission | resolved + */ + @Generated + @JsonProperty(value = "clinicalStatus") + private CodeableConcept clinicalStatus; + + /* + * unconfirmed | provisional | differential | confirmed | refuted | entered-in-error + */ + @Generated + @JsonProperty(value = "verificationStatus") + private CodeableConcept verificationStatus; + + /* + * problem-list-item | encounter-diagnosis + */ + @Generated + @JsonProperty(value = "category") + private List category; + + /* + * Subjective severity of condition + */ + @Generated + @JsonProperty(value = "severity") + private CodeableConcept severity; + + /* + * Identification of the condition, problem or diagnosis + */ + @Generated + @JsonProperty(value = "code") + private CodeableConcept code; + + /* + * Anatomical location, if relevant + */ + @Generated + @JsonProperty(value = "bodySite") + private List bodySite; + + /* + * Encounter created as part of + */ + @Generated + @JsonProperty(value = "encounter") + private Reference encounter; + + /* + * Estimated or actual date, date-time, or age + */ + @Generated + @JsonProperty(value = "onsetDateTime") + private String onsetDateTime; + + /* + * Estimated or actual date, date-time, or age + */ + @Generated + @JsonProperty(value = "onsetAge") + private Quantity onsetAge; + + /* + * Estimated or actual date, date-time, or age + */ + @Generated + @JsonProperty(value = "onsetPeriod") + private PeriodModel onsetPeriod; + + /* + * Estimated or actual date, date-time, or age + */ + @Generated + @JsonProperty(value = "onsetRange") + private Range onsetRange; + + /* + * Estimated or actual date, date-time, or age + */ + @Generated + @JsonProperty(value = "onsetString") + private String onsetString; + + /* + * When in resolution/remission + */ + @Generated + @JsonProperty(value = "abatementDateTime") + private String abatementDateTime; + + /* + * When in resolution/remission + */ + @Generated + @JsonProperty(value = "abatementAge") + private Quantity abatementAge; + + /* + * When in resolution/remission + */ + @Generated + @JsonProperty(value = "abatementPeriod") + private PeriodModel abatementPeriod; + + /* + * When in resolution/remission + */ + @Generated + @JsonProperty(value = "abatementRange") + private Range abatementRange; + + /* + * When in resolution/remission + */ + @Generated + @JsonProperty(value = "abatementString") + private String abatementString; + + /* + * Date record was first recorded + */ + @Generated + @JsonProperty(value = "recordedDate") + private String recordedDate; + + /* + * stge/grade, usually assessed formally + */ + @Generated + @JsonProperty(value = "stage") + private List stage; + + /* + * Additional information about the Condition + */ + @Generated + @JsonProperty(value = "note") + private List note; + + /** + * Creates an instance of Condition class. + */ + @Generated + public Condition() { + } + + /** + * Get the identifier property: External Ids for this condition. + * + * @return the identifier value. + */ + @Generated + public List getIdentifier() { + return this.identifier; + } + + /** + * Set the identifier property: External Ids for this condition. + * + * @param identifier the identifier value to set. + * @return the Condition object itself. + */ + @Generated + public Condition setIdentifier(List identifier) { + this.identifier = identifier; + return this; + } + + /** + * Get the clinicalStatus property: active | recurrence | relapse | inactive | remission | resolved. + * + * @return the clinicalStatus value. + */ + @Generated + public CodeableConcept getClinicalStatus() { + return this.clinicalStatus; + } + + /** + * Set the clinicalStatus property: active | recurrence | relapse | inactive | remission | resolved. + * + * @param clinicalStatus the clinicalStatus value to set. + * @return the Condition object itself. + */ + @Generated + public Condition setClinicalStatus(CodeableConcept clinicalStatus) { + this.clinicalStatus = clinicalStatus; + return this; + } + + /** + * Get the verificationStatus property: unconfirmed | provisional | differential | confirmed | refuted | + * entered-in-error. + * + * @return the verificationStatus value. + */ + @Generated + public CodeableConcept getVerificationStatus() { + return this.verificationStatus; + } + + /** + * Set the verificationStatus property: unconfirmed | provisional | differential | confirmed | refuted | + * entered-in-error. + * + * @param verificationStatus the verificationStatus value to set. + * @return the Condition object itself. + */ + @Generated + public Condition setVerificationStatus(CodeableConcept verificationStatus) { + this.verificationStatus = verificationStatus; + return this; + } + + /** + * Get the category property: problem-list-item | encounter-diagnosis. + * + * @return the category value. + */ + @Generated + public List getCategory() { + return this.category; + } + + /** + * Set the category property: problem-list-item | encounter-diagnosis. + * + * @param category the category value to set. + * @return the Condition object itself. + */ + @Generated + public Condition setCategory(List category) { + this.category = category; + return this; + } + + /** + * Get the severity property: Subjective severity of condition. + * + * @return the severity value. + */ + @Generated + public CodeableConcept getSeverity() { + return this.severity; + } + + /** + * Set the severity property: Subjective severity of condition. + * + * @param severity the severity value to set. + * @return the Condition object itself. + */ + @Generated + public Condition setSeverity(CodeableConcept severity) { + this.severity = severity; + return this; + } + + /** + * Get the code property: Identification of the condition, problem or diagnosis. + * + * @return the code value. + */ + @Generated + public CodeableConcept getCode() { + return this.code; + } + + /** + * Set the code property: Identification of the condition, problem or diagnosis. + * + * @param code the code value to set. + * @return the Condition object itself. + */ + @Generated + public Condition setCode(CodeableConcept code) { + this.code = code; + return this; + } + + /** + * Get the bodySite property: Anatomical location, if relevant. + * + * @return the bodySite value. + */ + @Generated + public List getBodySite() { + return this.bodySite; + } + + /** + * Set the bodySite property: Anatomical location, if relevant. + * + * @param bodySite the bodySite value to set. + * @return the Condition object itself. + */ + @Generated + public Condition setBodySite(List bodySite) { + this.bodySite = bodySite; + return this; + } + + /** + * Get the encounter property: Encounter created as part of. + * + * @return the encounter value. + */ + @Generated + public Reference getEncounter() { + return this.encounter; + } + + /** + * Set the encounter property: Encounter created as part of. + * + * @param encounter the encounter value to set. + * @return the Condition object itself. + */ + @Generated + public Condition setEncounter(Reference encounter) { + this.encounter = encounter; + return this; + } + + /** + * Get the onsetDateTime property: Estimated or actual date, date-time, or age. + * + * @return the onsetDateTime value. + */ + @Generated + public String getOnsetDateTime() { + return this.onsetDateTime; + } + + /** + * Set the onsetDateTime property: Estimated or actual date, date-time, or age. + * + * @param onsetDateTime the onsetDateTime value to set. + * @return the Condition object itself. + */ + @Generated + public Condition setOnsetDateTime(String onsetDateTime) { + this.onsetDateTime = onsetDateTime; + return this; + } + + /** + * Get the onsetAge property: Estimated or actual date, date-time, or age. + * + * @return the onsetAge value. + */ + @Generated + public Quantity getOnsetAge() { + return this.onsetAge; + } + + /** + * Set the onsetAge property: Estimated or actual date, date-time, or age. + * + * @param onsetAge the onsetAge value to set. + * @return the Condition object itself. + */ + @Generated + public Condition setOnsetAge(Quantity onsetAge) { + this.onsetAge = onsetAge; + return this; + } + + /** + * Get the onsetPeriod property: Estimated or actual date, date-time, or age. + * + * @return the onsetPeriod value. + */ + @Generated + public PeriodModel getOnsetPeriod() { + return this.onsetPeriod; + } + + /** + * Set the onsetPeriod property: Estimated or actual date, date-time, or age. + * + * @param onsetPeriod the onsetPeriod value to set. + * @return the Condition object itself. + */ + @Generated + public Condition setOnsetPeriod(PeriodModel onsetPeriod) { + this.onsetPeriod = onsetPeriod; + return this; + } + + /** + * Get the onsetRange property: Estimated or actual date, date-time, or age. + * + * @return the onsetRange value. + */ + @Generated + public Range getOnsetRange() { + return this.onsetRange; + } + + /** + * Set the onsetRange property: Estimated or actual date, date-time, or age. + * + * @param onsetRange the onsetRange value to set. + * @return the Condition object itself. + */ + @Generated + public Condition setOnsetRange(Range onsetRange) { + this.onsetRange = onsetRange; + return this; + } + + /** + * Get the onsetString property: Estimated or actual date, date-time, or age. + * + * @return the onsetString value. + */ + @Generated + public String getOnsetString() { + return this.onsetString; + } + + /** + * Set the onsetString property: Estimated or actual date, date-time, or age. + * + * @param onsetString the onsetString value to set. + * @return the Condition object itself. + */ + @Generated + public Condition setOnsetString(String onsetString) { + this.onsetString = onsetString; + return this; + } + + /** + * Get the abatementDateTime property: When in resolution/remission. + * + * @return the abatementDateTime value. + */ + @Generated + public String getAbatementDateTime() { + return this.abatementDateTime; + } + + /** + * Set the abatementDateTime property: When in resolution/remission. + * + * @param abatementDateTime the abatementDateTime value to set. + * @return the Condition object itself. + */ + @Generated + public Condition setAbatementDateTime(String abatementDateTime) { + this.abatementDateTime = abatementDateTime; + return this; + } + + /** + * Get the abatementAge property: When in resolution/remission. + * + * @return the abatementAge value. + */ + @Generated + public Quantity getAbatementAge() { + return this.abatementAge; + } + + /** + * Set the abatementAge property: When in resolution/remission. + * + * @param abatementAge the abatementAge value to set. + * @return the Condition object itself. + */ + @Generated + public Condition setAbatementAge(Quantity abatementAge) { + this.abatementAge = abatementAge; + return this; + } + + /** + * Get the abatementPeriod property: When in resolution/remission. + * + * @return the abatementPeriod value. + */ + @Generated + public PeriodModel getAbatementPeriod() { + return this.abatementPeriod; + } + + /** + * Set the abatementPeriod property: When in resolution/remission. + * + * @param abatementPeriod the abatementPeriod value to set. + * @return the Condition object itself. + */ + @Generated + public Condition setAbatementPeriod(PeriodModel abatementPeriod) { + this.abatementPeriod = abatementPeriod; + return this; + } + + /** + * Get the abatementRange property: When in resolution/remission. + * + * @return the abatementRange value. + */ + @Generated + public Range getAbatementRange() { + return this.abatementRange; + } + + /** + * Set the abatementRange property: When in resolution/remission. + * + * @param abatementRange the abatementRange value to set. + * @return the Condition object itself. + */ + @Generated + public Condition setAbatementRange(Range abatementRange) { + this.abatementRange = abatementRange; + return this; + } + + /** + * Get the abatementString property: When in resolution/remission. + * + * @return the abatementString value. + */ + @Generated + public String getAbatementString() { + return this.abatementString; + } + + /** + * Set the abatementString property: When in resolution/remission. + * + * @param abatementString the abatementString value to set. + * @return the Condition object itself. + */ + @Generated + public Condition setAbatementString(String abatementString) { + this.abatementString = abatementString; + return this; + } + + /** + * Get the recordedDate property: Date record was first recorded. + * + * @return the recordedDate value. + */ + @Generated + public String getRecordedDate() { + return this.recordedDate; + } + + /** + * Set the recordedDate property: Date record was first recorded. + * + * @param recordedDate the recordedDate value to set. + * @return the Condition object itself. + */ + @Generated + public Condition setRecordedDate(String recordedDate) { + this.recordedDate = recordedDate; + return this; + } + + /** + * Get the stage property: stge/grade, usually assessed formally. + * + * @return the stage value. + */ + @Generated + public List getStage() { + return this.stage; + } + + /** + * Set the stage property: stge/grade, usually assessed formally. + * + * @param stage the stage value to set. + * @return the Condition object itself. + */ + @Generated + public Condition setStage(List stage) { + this.stage = stage; + return this; + } + + /** + * Get the note property: Additional information about the Condition. + * + * @return the note value. + */ + @Generated + public List getNote() { + return this.note; + } + + /** + * Set the note property: Additional information about the Condition. + * + * @param note the note value to set. + * @return the Condition object itself. + */ + @Generated + public Condition setNote(List note) { + this.note = note; + return this; + } + + /** + * {@inheritDoc} + */ + @Generated + @Override + public Condition setText(Narrative text) { + super.setText(text); + return this; + } + + /** + * {@inheritDoc} + */ + @Generated + @Override + public Condition setContained(List> contained) { + super.setContained(contained); + return this; + } + + /** + * {@inheritDoc} + */ + @Generated + @Override + public Condition setExtension(List extension) { + super.setExtension(extension); + return this; + } + + /** + * {@inheritDoc} + */ + @Generated + @Override + public Condition setModifierExtension(List modifierExtension) { + super.setModifierExtension(modifierExtension); + return this; + } +} diff --git a/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/ConditionStage.java b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/ConditionStage.java new file mode 100644 index 0000000000000..8e2dae03ae4b9 --- /dev/null +++ b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/ConditionStage.java @@ -0,0 +1,81 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) TypeSpec Code Generator. + +package com.azure.health.insights.patienttimeline.models; + +import com.azure.core.annotation.Fluent; +import com.azure.core.annotation.Generated; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * Stage/grade, usually assessed formally + * Based on [FHIR Condition.Stage](https://www.hl7.org/fhir/R4/condition.html). + */ +@Fluent +public final class ConditionStage { + /* + * Simple summary (disease specific) + */ + @Generated + @JsonProperty(value = "summary") + private CodeableConcept summary; + + /* + * Kind of staging + */ + @Generated + @JsonProperty(value = "type") + private CodeableConcept type; + + /** + * Creates an instance of ConditionStage class. + */ + @Generated + public ConditionStage() { + } + + /** + * Get the summary property: Simple summary (disease specific). + * + * @return the summary value. + */ + @Generated + public CodeableConcept getSummary() { + return this.summary; + } + + /** + * Set the summary property: Simple summary (disease specific). + * + * @param summary the summary value to set. + * @return the ConditionStage object itself. + */ + @Generated + public ConditionStage setSummary(CodeableConcept summary) { + this.summary = summary; + return this; + } + + /** + * Get the type property: Kind of staging. + * + * @return the type value. + */ + @Generated + public CodeableConcept getType() { + return this.type; + } + + /** + * Set the type property: Kind of staging. + * + * @param type the type value to set. + * @return the ConditionStage object itself. + */ + @Generated + public ConditionStage setType(CodeableConcept type) { + this.type = type; + return this; + } +} diff --git a/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/ContactDetail.java b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/ContactDetail.java new file mode 100644 index 0000000000000..f9d43fa49abe5 --- /dev/null +++ b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/ContactDetail.java @@ -0,0 +1,101 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) TypeSpec Code Generator. + +package com.azure.health.insights.patienttimeline.models; + +import com.azure.core.annotation.Fluent; +import com.azure.core.annotation.Generated; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.util.List; + +/** + * Contact details (See: https://www.hl7.org/fhir/R4/metadatatypes.html#ContactDetail). + */ +@Fluent +public final class ContactDetail extends Element { + /* + * Name of an individual to contact + */ + @Generated + @JsonProperty(value = "name") + private String name; + + /* + * Contact details for individual or organization + */ + @Generated + @JsonProperty(value = "telecom") + private List telecom; + + /** + * Creates an instance of ContactDetail class. + */ + @Generated + public ContactDetail() { + } + + /** + * Get the name property: Name of an individual to contact. + * + * @return the name value. + */ + @Generated + public String getName() { + return this.name; + } + + /** + * Set the name property: Name of an individual to contact. + * + * @param name the name value to set. + * @return the ContactDetail object itself. + */ + @Generated + public ContactDetail setName(String name) { + this.name = name; + return this; + } + + /** + * Get the telecom property: Contact details for individual or organization. + * + * @return the telecom value. + */ + @Generated + public List getTelecom() { + return this.telecom; + } + + /** + * Set the telecom property: Contact details for individual or organization. + * + * @param telecom the telecom value to set. + * @return the ContactDetail object itself. + */ + @Generated + public ContactDetail setTelecom(List telecom) { + this.telecom = telecom; + return this; + } + + /** + * {@inheritDoc} + */ + @Generated + @Override + public ContactDetail setId(String id) { + super.setId(id); + return this; + } + + /** + * {@inheritDoc} + */ + @Generated + @Override + public ContactDetail setExtension(List extension) { + super.setExtension(extension); + return this; + } +} diff --git a/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/ContactPoint.java b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/ContactPoint.java new file mode 100644 index 0000000000000..1a0acbc37a2d5 --- /dev/null +++ b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/ContactPoint.java @@ -0,0 +1,169 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) TypeSpec Code Generator. + +package com.azure.health.insights.patienttimeline.models; + +import com.azure.core.annotation.Fluent; +import com.azure.core.annotation.Generated; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * Details for all kinds of technology mediated contact points for a person or organization, including telephone, + * email, etc. + * See https://www.hl7.org/fhir/R4/datatypes.html#ContactPoint. + */ +@Fluent +public final class ContactPoint { + /* + * phone | fax | email | pager | url | sms | other + */ + @Generated + @JsonProperty(value = "system") + private ContactPointSystem system; + + /* + * The actual contact point details + */ + @Generated + @JsonProperty(value = "value") + private String value; + + /* + * home | work | temp | old | mobile - purpose of this contact point + */ + @Generated + @JsonProperty(value = "use") + private ContactPointUse use; + + /* + * Specify preferred order of use (1 = highest) + */ + @Generated + @JsonProperty(value = "rank") + private Integer rank; + + /* + * Time period when the contact point was/is in use + */ + @Generated + @JsonProperty(value = "period") + private PeriodModel period; + + /** + * Creates an instance of ContactPoint class. + */ + @Generated + public ContactPoint() { + } + + /** + * Get the system property: phone | fax | email | pager | url | sms | other. + * + * @return the system value. + */ + @Generated + public ContactPointSystem getSystem() { + return this.system; + } + + /** + * Set the system property: phone | fax | email | pager | url | sms | other. + * + * @param system the system value to set. + * @return the ContactPoint object itself. + */ + @Generated + public ContactPoint setSystem(ContactPointSystem system) { + this.system = system; + return this; + } + + /** + * Get the value property: The actual contact point details. + * + * @return the value value. + */ + @Generated + public String getValue() { + return this.value; + } + + /** + * Set the value property: The actual contact point details. + * + * @param value the value value to set. + * @return the ContactPoint object itself. + */ + @Generated + public ContactPoint setValue(String value) { + this.value = value; + return this; + } + + /** + * Get the use property: home | work | temp | old | mobile - purpose of this contact point. + * + * @return the use value. + */ + @Generated + public ContactPointUse getUse() { + return this.use; + } + + /** + * Set the use property: home | work | temp | old | mobile - purpose of this contact point. + * + * @param use the use value to set. + * @return the ContactPoint object itself. + */ + @Generated + public ContactPoint setUse(ContactPointUse use) { + this.use = use; + return this; + } + + /** + * Get the rank property: Specify preferred order of use (1 = highest). + * + * @return the rank value. + */ + @Generated + public Integer getRank() { + return this.rank; + } + + /** + * Set the rank property: Specify preferred order of use (1 = highest). + * + * @param rank the rank value to set. + * @return the ContactPoint object itself. + */ + @Generated + public ContactPoint setRank(Integer rank) { + this.rank = rank; + return this; + } + + /** + * Get the period property: Time period when the contact point was/is in use. + * + * @return the period value. + */ + @Generated + public PeriodModel getPeriod() { + return this.period; + } + + /** + * Set the period property: Time period when the contact point was/is in use. + * + * @param period the period value to set. + * @return the ContactPoint object itself. + */ + @Generated + public ContactPoint setPeriod(PeriodModel period) { + this.period = period; + return this; + } +} diff --git a/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/ContactPointSystem.java b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/ContactPointSystem.java new file mode 100644 index 0000000000000..d3a1a8710bc38 --- /dev/null +++ b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/ContactPointSystem.java @@ -0,0 +1,90 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) TypeSpec Code Generator. + +package com.azure.health.insights.patienttimeline.models; + +import com.azure.core.annotation.Generated; +import com.azure.core.util.ExpandableStringEnum; +import com.fasterxml.jackson.annotation.JsonCreator; +import java.util.Collection; + +/** + * Contact Point System + * see https://www.hl7.org/fhir/R4/valueset-contact-point-system.html. + */ +public final class ContactPointSystem extends ExpandableStringEnum { + /** + * Phone. + */ + @Generated + public static final ContactPointSystem PHONE = fromString("phone"); + + /** + * Fax. + */ + @Generated + public static final ContactPointSystem FAX = fromString("fax"); + + /** + * Email. + */ + @Generated + public static final ContactPointSystem EMAIL = fromString("email"); + + /** + * Pager. + */ + @Generated + public static final ContactPointSystem PAGER = fromString("pager"); + + /** + * Url. + */ + @Generated + public static final ContactPointSystem URL = fromString("url"); + + /** + * Sms. + */ + @Generated + public static final ContactPointSystem SMS = fromString("sms"); + + /** + * Other. + */ + @Generated + public static final ContactPointSystem OTHER = fromString("other"); + + /** + * Creates a new instance of ContactPointSystem value. + * + * @deprecated Use the {@link #fromString(String)} factory method. + */ + @Generated + @Deprecated + public ContactPointSystem() { + } + + /** + * Creates or finds a ContactPointSystem from its string representation. + * + * @param name a name to look for. + * @return the corresponding ContactPointSystem. + */ + @Generated + @JsonCreator + public static ContactPointSystem fromString(String name) { + return fromString(name, ContactPointSystem.class); + } + + /** + * Gets known ContactPointSystem values. + * + * @return known ContactPointSystem values. + */ + @Generated + public static Collection values() { + return values(ContactPointSystem.class); + } +} diff --git a/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/ContactPointUse.java b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/ContactPointUse.java new file mode 100644 index 0000000000000..7efbf5026c74f --- /dev/null +++ b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/ContactPointUse.java @@ -0,0 +1,78 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) TypeSpec Code Generator. + +package com.azure.health.insights.patienttimeline.models; + +import com.azure.core.annotation.Generated; +import com.azure.core.util.ExpandableStringEnum; +import com.fasterxml.jackson.annotation.JsonCreator; +import java.util.Collection; + +/** + * Contact Point Use + * See: http://hl7.org/fhir/ValueSet/contact-point-use. + */ +public final class ContactPointUse extends ExpandableStringEnum { + /** + * Home. + */ + @Generated + public static final ContactPointUse HOME = fromString("home"); + + /** + * Work. + */ + @Generated + public static final ContactPointUse WORK = fromString("work"); + + /** + * Temp. + */ + @Generated + public static final ContactPointUse TEMP = fromString("temp"); + + /** + * Old. + */ + @Generated + public static final ContactPointUse OLD = fromString("old"); + + /** + * Mobile. + */ + @Generated + public static final ContactPointUse MOBILE = fromString("mobile"); + + /** + * Creates a new instance of ContactPointUse value. + * + * @deprecated Use the {@link #fromString(String)} factory method. + */ + @Generated + @Deprecated + public ContactPointUse() { + } + + /** + * Creates or finds a ContactPointUse from its string representation. + * + * @param name a name to look for. + * @return the corresponding ContactPointUse. + */ + @Generated + @JsonCreator + public static ContactPointUse fromString(String name) { + return fromString(name, ContactPointUse.class); + } + + /** + * Gets known ContactPointUse values. + * + * @return known ContactPointUse values. + */ + @Generated + public static Collection values() { + return values(ContactPointUse.class); + } +} diff --git a/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/DocumentAdministrativeMetadata.java b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/DocumentAdministrativeMetadata.java new file mode 100644 index 0000000000000..4f6aeafe317de --- /dev/null +++ b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/DocumentAdministrativeMetadata.java @@ -0,0 +1,81 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) TypeSpec Code Generator. + +package com.azure.health.insights.patienttimeline.models; + +import com.azure.core.annotation.Fluent; +import com.azure.core.annotation.Generated; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.util.List; + +/** + * Document administrative metadata. + */ +@Fluent +public final class DocumentAdministrativeMetadata { + /* + * List of procedure information associated with the document. + */ + @Generated + @JsonProperty(value = "orderedProcedures") + private List orderedProcedures; + + /* + * Reference to the encounter associated with the document. + */ + @Generated + @JsonProperty(value = "encounterId") + private String encounterId; + + /** + * Creates an instance of DocumentAdministrativeMetadata class. + */ + @Generated + public DocumentAdministrativeMetadata() { + } + + /** + * Get the orderedProcedures property: List of procedure information associated with the document. + * + * @return the orderedProcedures value. + */ + @Generated + public List getOrderedProcedures() { + return this.orderedProcedures; + } + + /** + * Set the orderedProcedures property: List of procedure information associated with the document. + * + * @param orderedProcedures the orderedProcedures value to set. + * @return the DocumentAdministrativeMetadata object itself. + */ + @Generated + public DocumentAdministrativeMetadata setOrderedProcedures(List orderedProcedures) { + this.orderedProcedures = orderedProcedures; + return this; + } + + /** + * Get the encounterId property: Reference to the encounter associated with the document. + * + * @return the encounterId value. + */ + @Generated + public String getEncounterId() { + return this.encounterId; + } + + /** + * Set the encounterId property: Reference to the encounter associated with the document. + * + * @param encounterId the encounterId value to set. + * @return the DocumentAdministrativeMetadata object itself. + */ + @Generated + public DocumentAdministrativeMetadata setEncounterId(String encounterId) { + this.encounterId = encounterId; + return this; + } +} diff --git a/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/DocumentAuthor.java b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/DocumentAuthor.java new file mode 100644 index 0000000000000..a11bb77229a7c --- /dev/null +++ b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/DocumentAuthor.java @@ -0,0 +1,80 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) TypeSpec Code Generator. + +package com.azure.health.insights.patienttimeline.models; + +import com.azure.core.annotation.Fluent; +import com.azure.core.annotation.Generated; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * Document author. + */ +@Fluent +public final class DocumentAuthor { + /* + * author id + */ + @Generated + @JsonProperty(value = "id") + private String id; + + /* + * Text representation of the full name + */ + @Generated + @JsonProperty(value = "fullName") + private String fullName; + + /** + * Creates an instance of DocumentAuthor class. + */ + @Generated + public DocumentAuthor() { + } + + /** + * Get the id property: author id. + * + * @return the id value. + */ + @Generated + public String getId() { + return this.id; + } + + /** + * Set the id property: author id. + * + * @param id the id value to set. + * @return the DocumentAuthor object itself. + */ + @Generated + public DocumentAuthor setId(String id) { + this.id = id; + return this; + } + + /** + * Get the fullName property: Text representation of the full name. + * + * @return the fullName value. + */ + @Generated + public String getFullName() { + return this.fullName; + } + + /** + * Set the fullName property: Text representation of the full name. + * + * @param fullName the fullName value to set. + * @return the DocumentAuthor object itself. + */ + @Generated + public DocumentAuthor setFullName(String fullName) { + this.fullName = fullName; + return this; + } +} diff --git a/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/DocumentContent.java b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/DocumentContent.java new file mode 100644 index 0000000000000..31d422a3b8e0b --- /dev/null +++ b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/DocumentContent.java @@ -0,0 +1,68 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) TypeSpec Code Generator. + +package com.azure.health.insights.patienttimeline.models; + +import com.azure.core.annotation.Generated; +import com.azure.core.annotation.Immutable; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The content of the patient document. + */ +@Immutable +public final class DocumentContent { + /* + * The type of the content's source. + * In case the source type is 'inline', the content is given as a string (for instance, text). + * In case the source type is 'reference', the content is given as a URI. + */ + @Generated + @JsonProperty(value = "sourceType") + private DocumentContentSourceType sourceType; + + /* + * The content of the document, given either inline (as a string) or as a reference (URI). + */ + @Generated + @JsonProperty(value = "value") + private String value; + + /** + * Creates an instance of DocumentContent class. + * + * @param sourceType the sourceType value to set. + * @param value the value value to set. + */ + @Generated + @JsonCreator + public DocumentContent(@JsonProperty(value = "sourceType") DocumentContentSourceType sourceType, + @JsonProperty(value = "value") String value) { + this.sourceType = sourceType; + this.value = value; + } + + /** + * Get the sourceType property: The type of the content's source. + * In case the source type is 'inline', the content is given as a string (for instance, text). + * In case the source type is 'reference', the content is given as a URI. + * + * @return the sourceType value. + */ + @Generated + public DocumentContentSourceType getSourceType() { + return this.sourceType; + } + + /** + * Get the value property: The content of the document, given either inline (as a string) or as a reference (URI). + * + * @return the value value. + */ + @Generated + public String getValue() { + return this.value; + } +} diff --git a/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/DocumentContentSourceType.java b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/DocumentContentSourceType.java new file mode 100644 index 0000000000000..483817b1f195a --- /dev/null +++ b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/DocumentContentSourceType.java @@ -0,0 +1,61 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) TypeSpec Code Generator. + +package com.azure.health.insights.patienttimeline.models; + +import com.azure.core.annotation.Generated; +import com.azure.core.util.ExpandableStringEnum; +import com.fasterxml.jackson.annotation.JsonCreator; +import java.util.Collection; + +/** + * The type of the content's source. + * In case the source type is 'inline', the content is given as a string (for instance, text). + * In case the source type is 'reference', the content is given as a URI. + */ +public final class DocumentContentSourceType extends ExpandableStringEnum { + /** + * The content is given as a string (for instance, text). + */ + @Generated + public static final DocumentContentSourceType INLINE = fromString("inline"); + + /** + * The content is given as a URI. + */ + @Generated + public static final DocumentContentSourceType REFERENCE = fromString("reference"); + + /** + * Creates a new instance of DocumentContentSourceType value. + * + * @deprecated Use the {@link #fromString(String)} factory method. + */ + @Generated + @Deprecated + public DocumentContentSourceType() { + } + + /** + * Creates or finds a DocumentContentSourceType from its string representation. + * + * @param name a name to look for. + * @return the corresponding DocumentContentSourceType. + */ + @Generated + @JsonCreator + public static DocumentContentSourceType fromString(String name) { + return fromString(name, DocumentContentSourceType.class); + } + + /** + * Gets known DocumentContentSourceType values. + * + * @return known DocumentContentSourceType values. + */ + @Generated + public static Collection values() { + return values(DocumentContentSourceType.class); + } +} diff --git a/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/DocumentType.java b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/DocumentType.java new file mode 100644 index 0000000000000..ef1b28564d7b5 --- /dev/null +++ b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/DocumentType.java @@ -0,0 +1,71 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) TypeSpec Code Generator. + +package com.azure.health.insights.patienttimeline.models; + +import com.azure.core.annotation.Generated; +import com.azure.core.util.ExpandableStringEnum; +import com.fasterxml.jackson.annotation.JsonCreator; +import java.util.Collection; + +/** + * The type of the patient document, such as 'note' (text document) or 'fhirBundle' (FHIR JSON document). + */ +public final class DocumentType extends ExpandableStringEnum { + /** + * Static value note for DocumentType. + */ + @Generated + public static final DocumentType NOTE = fromString("note"); + + /** + * Static value fhirBundle for DocumentType. + */ + @Generated + public static final DocumentType FHIR_BUNDLE = fromString("fhirBundle"); + + /** + * Static value dicom for DocumentType. + */ + @Generated + public static final DocumentType DICOM = fromString("dicom"); + + /** + * Static value genomicSequencing for DocumentType. + */ + @Generated + public static final DocumentType GENOMIC_SEQUENCING = fromString("genomicSequencing"); + + /** + * Creates a new instance of DocumentType value. + * + * @deprecated Use the {@link #fromString(String)} factory method. + */ + @Generated + @Deprecated + public DocumentType() { + } + + /** + * Creates or finds a DocumentType from its string representation. + * + * @param name a name to look for. + * @return the corresponding DocumentType. + */ + @Generated + @JsonCreator + public static DocumentType fromString(String name) { + return fromString(name, DocumentType.class); + } + + /** + * Gets known DocumentType values. + * + * @return known DocumentType values. + */ + @Generated + public static Collection values() { + return values(DocumentType.class); + } +} diff --git a/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/DomainResource.java b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/DomainResource.java new file mode 100644 index 0000000000000..7e5d76c685eaf --- /dev/null +++ b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/DomainResource.java @@ -0,0 +1,203 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) TypeSpec Code Generator. + +package com.azure.health.insights.patienttimeline.models; + +import com.azure.core.annotation.Fluent; +import com.azure.core.annotation.Generated; +import com.fasterxml.jackson.annotation.JsonAnyGetter; +import com.fasterxml.jackson.annotation.JsonAnySetter; +import com.fasterxml.jackson.annotation.JsonIgnore; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonSubTypes; +import com.fasterxml.jackson.annotation.JsonTypeInfo; +import com.fasterxml.jackson.annotation.JsonTypeName; +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +/** + * A resource with narrative, extensions, and contained resources + * Based on [FHIR DomainResource](https://www.hl7.org/fhir/domainresource.html). + */ +@JsonTypeInfo( + use = JsonTypeInfo.Id.NAME, + include = JsonTypeInfo.As.PROPERTY, + property = "resourceType", + defaultImpl = DomainResource.class) +@JsonTypeName("DomainResource") +@JsonSubTypes({ + @JsonSubTypes.Type(name = "Condition", value = Condition.class), + @JsonSubTypes.Type(name = "Observation", value = Observation.class), + @JsonSubTypes.Type(name = "ResearchStudy", value = ResearchStudy.class) }) +@Fluent +public class DomainResource { + /* + * Text summary of the resource, for human interpretation + */ + @Generated + @JsonProperty(value = "text") + private Narrative text; + + /* + * Contained, inline Resources + */ + @Generated + @JsonProperty(value = "contained") + private List> contained; + + /* + * Additional Content defined by implementations + */ + @Generated + @JsonProperty(value = "extension") + private List extension; + + /* + * Extensions that cannot be ignored + */ + @Generated + @JsonProperty(value = "modifierExtension") + private List modifierExtension; + + /* + * Resource is the ancestor of DomainResource from which most resources are derived. Bundle, Parameters, and Binary + * extend Resource directly. + * Based on [FHIR Resource](https://www.hl7.org/fhir/r4/resource.html + */ + @Generated + @JsonIgnore + private Map additionalProperties; + + /** + * Creates an instance of DomainResource class. + */ + @Generated + public DomainResource() { + } + + /** + * Get the text property: Text summary of the resource, for human interpretation. + * + * @return the text value. + */ + @Generated + public Narrative getText() { + return this.text; + } + + /** + * Set the text property: Text summary of the resource, for human interpretation. + * + * @param text the text value to set. + * @return the DomainResource object itself. + */ + @Generated + public DomainResource setText(Narrative text) { + this.text = text; + return this; + } + + /** + * Get the contained property: Contained, inline Resources. + * + * @return the contained value. + */ + @Generated + public List> getContained() { + return this.contained; + } + + /** + * Set the contained property: Contained, inline Resources. + * + * @param contained the contained value to set. + * @return the DomainResource object itself. + */ + @Generated + public DomainResource setContained(List> contained) { + this.contained = contained; + return this; + } + + /** + * Get the extension property: Additional Content defined by implementations. + * + * @return the extension value. + */ + @Generated + public List getExtension() { + return this.extension; + } + + /** + * Set the extension property: Additional Content defined by implementations. + * + * @param extension the extension value to set. + * @return the DomainResource object itself. + */ + @Generated + public DomainResource setExtension(List extension) { + this.extension = extension; + return this; + } + + /** + * Get the modifierExtension property: Extensions that cannot be ignored. + * + * @return the modifierExtension value. + */ + @Generated + public List getModifierExtension() { + return this.modifierExtension; + } + + /** + * Set the modifierExtension property: Extensions that cannot be ignored. + * + * @param modifierExtension the modifierExtension value to set. + * @return the DomainResource object itself. + */ + @Generated + public DomainResource setModifierExtension(List modifierExtension) { + this.modifierExtension = modifierExtension; + return this; + } + + /** + * Get the additionalProperties property: Resource is the ancestor of DomainResource from which most resources are + * derived. Bundle, Parameters, and Binary extend Resource directly. + * Based on [FHIR Resource](https://www.hl7.org/fhir/r4/resource.html. + * + * @return the additionalProperties value. + */ + @Generated + @JsonAnyGetter + public Map getAdditionalProperties() { + return this.additionalProperties; + } + + /** + * Set the additionalProperties property: Resource is the ancestor of DomainResource from which most resources are + * derived. Bundle, Parameters, and Binary extend Resource directly. + * Based on [FHIR Resource](https://www.hl7.org/fhir/r4/resource.html. + * + * @param additionalProperties the additionalProperties value to set. + * @return the DomainResource object itself. + */ + @Generated + public DomainResource setAdditionalProperties(Map additionalProperties) { + this.additionalProperties = additionalProperties; + return this; + } + + @Generated + @JsonAnySetter + void setAdditionalProperties(String key, Object value) { + if (additionalProperties == null) { + additionalProperties = new HashMap<>(); + } + additionalProperties.put(key, value); + } +} diff --git a/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/Element.java b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/Element.java new file mode 100644 index 0000000000000..89c8101ce7d68 --- /dev/null +++ b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/Element.java @@ -0,0 +1,82 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) TypeSpec Code Generator. + +package com.azure.health.insights.patienttimeline.models; + +import com.azure.core.annotation.Fluent; +import com.azure.core.annotation.Generated; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.util.List; + +/** + * The base definition for all elements contained inside a resource. + * Based on [FHIR Element](https://www.hl7.org/fhir/R4/element.html). + */ +@Fluent +public class Element { + /* + * Unique id for inter-element referencing + */ + @Generated + @JsonProperty(value = "id") + private String id; + + /* + * Additional Content defined by implementations + */ + @Generated + @JsonProperty(value = "extension") + private List extension; + + /** + * Creates an instance of Element class. + */ + @Generated + public Element() { + } + + /** + * Get the id property: Unique id for inter-element referencing. + * + * @return the id value. + */ + @Generated + public String getId() { + return this.id; + } + + /** + * Set the id property: Unique id for inter-element referencing. + * + * @param id the id value to set. + * @return the Element object itself. + */ + @Generated + public Element setId(String id) { + this.id = id; + return this; + } + + /** + * Get the extension property: Additional Content defined by implementations. + * + * @return the extension value. + */ + @Generated + public List getExtension() { + return this.extension; + } + + /** + * Set the extension property: Additional Content defined by implementations. + * + * @param extension the extension value to set. + * @return the Element object itself. + */ + @Generated + public Element setExtension(List extension) { + this.extension = extension; + return this; + } +} diff --git a/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/Encounter.java b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/Encounter.java new file mode 100644 index 0000000000000..aba778f858594 --- /dev/null +++ b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/Encounter.java @@ -0,0 +1,108 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) TypeSpec Code Generator. + +package com.azure.health.insights.patienttimeline.models; + +import com.azure.core.annotation.Fluent; +import com.azure.core.annotation.Generated; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * visit/encounter information. + */ +@Fluent +public final class Encounter { + /* + * The id of the visit. + */ + @Generated + @JsonProperty(value = "id") + private String id; + + /* + * Time period of the visit. + * In case of admission, use timePeriod.start to indicate the admission time and timePeriod.end to indicate the + * discharge time. + */ + @Generated + @JsonProperty(value = "period") + private TimePeriod period; + + /* + * The class of the encounter. + */ + @Generated + @JsonProperty(value = "class") + private EncounterClass classProperty; + + /** + * Creates an instance of Encounter class. + * + * @param id the id value to set. + */ + @Generated + @JsonCreator + public Encounter(@JsonProperty(value = "id") String id) { + this.id = id; + } + + /** + * Get the id property: The id of the visit. + * + * @return the id value. + */ + @Generated + public String getId() { + return this.id; + } + + /** + * Get the period property: Time period of the visit. + * In case of admission, use timePeriod.start to indicate the admission time and timePeriod.end to indicate the + * discharge time. + * + * @return the period value. + */ + @Generated + public TimePeriod getPeriod() { + return this.period; + } + + /** + * Set the period property: Time period of the visit. + * In case of admission, use timePeriod.start to indicate the admission time and timePeriod.end to indicate the + * discharge time. + * + * @param period the period value to set. + * @return the Encounter object itself. + */ + @Generated + public Encounter setPeriod(TimePeriod period) { + this.period = period; + return this; + } + + /** + * Get the classProperty property: The class of the encounter. + * + * @return the classProperty value. + */ + @Generated + public EncounterClass getClassProperty() { + return this.classProperty; + } + + /** + * Set the classProperty property: The class of the encounter. + * + * @param classProperty the classProperty value to set. + * @return the Encounter object itself. + */ + @Generated + public Encounter setClassProperty(EncounterClass classProperty) { + this.classProperty = classProperty; + return this; + } +} diff --git a/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/EncounterClass.java b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/EncounterClass.java new file mode 100644 index 0000000000000..78f8e085f6b7e --- /dev/null +++ b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/EncounterClass.java @@ -0,0 +1,91 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) TypeSpec Code Generator. + +package com.azure.health.insights.patienttimeline.models; + +import com.azure.core.annotation.Generated; +import com.azure.core.util.ExpandableStringEnum; +import com.fasterxml.jackson.annotation.JsonCreator; +import java.util.Collection; + +/** + * Known values codes that can be used to indicate the class of encounter (TODO://Based on FHIR value set--http://....). + */ +public final class EncounterClass extends ExpandableStringEnum { + /** + * A patient encounter where a patient is admitted by a hospital or equivalent facility, assigned to a location + * where patients generally stay at least overnight and provided with room, board, and continuous nursing service. + */ + @Generated + public static final EncounterClass IN_PATIENT = fromString("inpatient"); + + /** + * The term ambulatory usually implies that the patient has come to the location and is not assigned to a bed. + * Sometimes referred to as an outpatient encounter. + */ + @Generated + public static final EncounterClass AMBULATORY = fromString("ambulatory"); + + /** + * An encounter where the patient usually will start in different encounter, such as one in the emergency department + * but then transition to this type of encounter because they require a significant period of treatment and + * monitoring to determine whether or not their condition warrants an inpatient admission or discharge. + */ + @Generated + public static final EncounterClass OBSERVATION = fromString("observation"); + + /** + * A patient encounter that takes place at a dedicated healthcare service delivery location where the patient + * receives immediate evaluation and treatment, provided until the patient can be discharged or responsibility for + * the patient's care is transferred elsewhere (for example, the patient could be admitted as an inpatient or + * transferred to another facility. + */ + @Generated + public static final EncounterClass EMERGENCY = fromString("emergency"); + + /** + * A patient encounter where the patient is not physically present for the encounter, such as in a telehealth + * encounter, phone call, or electronic communication. + */ + @Generated + public static final EncounterClass VIRTUAL = fromString("virtual"); + + /** + * Healthcare encounter that takes place in the residence of the patient or a designee. + */ + @Generated + public static final EncounterClass HEALTH_HOME = fromString("healthHome"); + + /** + * Creates a new instance of EncounterClass value. + * + * @deprecated Use the {@link #fromString(String)} factory method. + */ + @Generated + @Deprecated + public EncounterClass() { + } + + /** + * Creates or finds a EncounterClass from its string representation. + * + * @param name a name to look for. + * @return the corresponding EncounterClass. + */ + @Generated + @JsonCreator + public static EncounterClass fromString(String name) { + return fromString(name, EncounterClass.class); + } + + /** + * Gets known EncounterClass values. + * + * @return known EncounterClass values. + */ + @Generated + public static Collection values() { + return values(EncounterClass.class); + } +} diff --git a/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/Extendible.java b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/Extendible.java new file mode 100644 index 0000000000000..913290a64b04a --- /dev/null +++ b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/Extendible.java @@ -0,0 +1,52 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) TypeSpec Code Generator. + +package com.azure.health.insights.patienttimeline.models; + +import com.azure.core.annotation.Fluent; +import com.azure.core.annotation.Generated; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.util.List; + +/** + * FHIR extendible element. + */ +@Fluent +public class Extendible { + /* + * Additional Content defined by implementations + */ + @Generated + @JsonProperty(value = "extension") + private List extension; + + /** + * Creates an instance of Extendible class. + */ + @Generated + public Extendible() { + } + + /** + * Get the extension property: Additional Content defined by implementations. + * + * @return the extension value. + */ + @Generated + public List getExtension() { + return this.extension; + } + + /** + * Set the extension property: Additional Content defined by implementations. + * + * @param extension the extension value to set. + * @return the Extendible object itself. + */ + @Generated + public Extendible setExtension(List extension) { + this.extension = extension; + return this; + } +} diff --git a/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/Extension.java b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/Extension.java new file mode 100644 index 0000000000000..076fbaa5a818d --- /dev/null +++ b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/Extension.java @@ -0,0 +1,414 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) TypeSpec Code Generator. + +package com.azure.health.insights.patienttimeline.models; + +import com.azure.core.annotation.Fluent; +import com.azure.core.annotation.Generated; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.util.List; + +/** + * Base for all elements + * Based on [FHIR Element](https://www.hl7.org/fhir/datatypes.html#Element). + */ +@Fluent +public final class Extension extends Element { + /* + * Source of the definition for the extension code - a logical name or a URL. + */ + @Generated + @JsonProperty(value = "url") + private String url; + + /* + * Value as Quantity + */ + @Generated + @JsonProperty(value = "valueQuantity") + private Quantity valueQuantity; + + /* + * Value as CodeableConcept + */ + @Generated + @JsonProperty(value = "valueCodeableConcept") + private CodeableConcept valueCodeableConcept; + + /* + * Value as string + */ + @Generated + @JsonProperty(value = "valueString") + private String valueString; + + /* + * Value as boolean + */ + @Generated + @JsonProperty(value = "valueBoolean") + private Boolean valueBoolean; + + /* + * Value as integer + */ + @Generated + @JsonProperty(value = "valueInteger") + private Integer valueInteger; + + /* + * Value as Range. + */ + @Generated + @JsonProperty(value = "valueRange") + private Range valueRange; + + /* + * Value as Ratio. + */ + @Generated + @JsonProperty(value = "valueRatio") + private Ratio valueRatio; + + /* + * Value as SampledData. + */ + @Generated + @JsonProperty(value = "valueSampledData") + private SampledData valueSampledData; + + /* + * Value as time (hh:mm:ss) + */ + @Generated + @JsonProperty(value = "valueTime") + private String valueTime; + + /* + * Value as dateTime. + */ + @Generated + @JsonProperty(value = "valueDateTime") + private String valueDateTime; + + /* + * Value as Period. + */ + @Generated + @JsonProperty(value = "valuePeriod") + private PeriodModel valuePeriod; + + /* + * Value as reference. + */ + @Generated + @JsonProperty(value = "valueReference") + private Reference valueReference; + + /** + * Creates an instance of Extension class. + * + * @param url the url value to set. + */ + @Generated + @JsonCreator + public Extension(@JsonProperty(value = "url") String url) { + this.url = url; + } + + /** + * Get the url property: Source of the definition for the extension code - a logical name or a URL. + * + * @return the url value. + */ + @Generated + public String getUrl() { + return this.url; + } + + /** + * Get the valueQuantity property: Value as Quantity. + * + * @return the valueQuantity value. + */ + @Generated + public Quantity getValueQuantity() { + return this.valueQuantity; + } + + /** + * Set the valueQuantity property: Value as Quantity. + * + * @param valueQuantity the valueQuantity value to set. + * @return the Extension object itself. + */ + @Generated + public Extension setValueQuantity(Quantity valueQuantity) { + this.valueQuantity = valueQuantity; + return this; + } + + /** + * Get the valueCodeableConcept property: Value as CodeableConcept. + * + * @return the valueCodeableConcept value. + */ + @Generated + public CodeableConcept getValueCodeableConcept() { + return this.valueCodeableConcept; + } + + /** + * Set the valueCodeableConcept property: Value as CodeableConcept. + * + * @param valueCodeableConcept the valueCodeableConcept value to set. + * @return the Extension object itself. + */ + @Generated + public Extension setValueCodeableConcept(CodeableConcept valueCodeableConcept) { + this.valueCodeableConcept = valueCodeableConcept; + return this; + } + + /** + * Get the valueString property: Value as string. + * + * @return the valueString value. + */ + @Generated + public String getValueString() { + return this.valueString; + } + + /** + * Set the valueString property: Value as string. + * + * @param valueString the valueString value to set. + * @return the Extension object itself. + */ + @Generated + public Extension setValueString(String valueString) { + this.valueString = valueString; + return this; + } + + /** + * Get the valueBoolean property: Value as boolean. + * + * @return the valueBoolean value. + */ + @Generated + public Boolean isValueBoolean() { + return this.valueBoolean; + } + + /** + * Set the valueBoolean property: Value as boolean. + * + * @param valueBoolean the valueBoolean value to set. + * @return the Extension object itself. + */ + @Generated + public Extension setValueBoolean(Boolean valueBoolean) { + this.valueBoolean = valueBoolean; + return this; + } + + /** + * Get the valueInteger property: Value as integer. + * + * @return the valueInteger value. + */ + @Generated + public Integer getValueInteger() { + return this.valueInteger; + } + + /** + * Set the valueInteger property: Value as integer. + * + * @param valueInteger the valueInteger value to set. + * @return the Extension object itself. + */ + @Generated + public Extension setValueInteger(Integer valueInteger) { + this.valueInteger = valueInteger; + return this; + } + + /** + * Get the valueRange property: Value as Range. + * + * @return the valueRange value. + */ + @Generated + public Range getValueRange() { + return this.valueRange; + } + + /** + * Set the valueRange property: Value as Range. + * + * @param valueRange the valueRange value to set. + * @return the Extension object itself. + */ + @Generated + public Extension setValueRange(Range valueRange) { + this.valueRange = valueRange; + return this; + } + + /** + * Get the valueRatio property: Value as Ratio. + * + * @return the valueRatio value. + */ + @Generated + public Ratio getValueRatio() { + return this.valueRatio; + } + + /** + * Set the valueRatio property: Value as Ratio. + * + * @param valueRatio the valueRatio value to set. + * @return the Extension object itself. + */ + @Generated + public Extension setValueRatio(Ratio valueRatio) { + this.valueRatio = valueRatio; + return this; + } + + /** + * Get the valueSampledData property: Value as SampledData. + * + * @return the valueSampledData value. + */ + @Generated + public SampledData getValueSampledData() { + return this.valueSampledData; + } + + /** + * Set the valueSampledData property: Value as SampledData. + * + * @param valueSampledData the valueSampledData value to set. + * @return the Extension object itself. + */ + @Generated + public Extension setValueSampledData(SampledData valueSampledData) { + this.valueSampledData = valueSampledData; + return this; + } + + /** + * Get the valueTime property: Value as time (hh:mm:ss). + * + * @return the valueTime value. + */ + @Generated + public String getValueTime() { + return this.valueTime; + } + + /** + * Set the valueTime property: Value as time (hh:mm:ss). + * + * @param valueTime the valueTime value to set. + * @return the Extension object itself. + */ + @Generated + public Extension setValueTime(String valueTime) { + this.valueTime = valueTime; + return this; + } + + /** + * Get the valueDateTime property: Value as dateTime. + * + * @return the valueDateTime value. + */ + @Generated + public String getValueDateTime() { + return this.valueDateTime; + } + + /** + * Set the valueDateTime property: Value as dateTime. + * + * @param valueDateTime the valueDateTime value to set. + * @return the Extension object itself. + */ + @Generated + public Extension setValueDateTime(String valueDateTime) { + this.valueDateTime = valueDateTime; + return this; + } + + /** + * Get the valuePeriod property: Value as Period. + * + * @return the valuePeriod value. + */ + @Generated + public PeriodModel getValuePeriod() { + return this.valuePeriod; + } + + /** + * Set the valuePeriod property: Value as Period. + * + * @param valuePeriod the valuePeriod value to set. + * @return the Extension object itself. + */ + @Generated + public Extension setValuePeriod(PeriodModel valuePeriod) { + this.valuePeriod = valuePeriod; + return this; + } + + /** + * Get the valueReference property: Value as reference. + * + * @return the valueReference value. + */ + @Generated + public Reference getValueReference() { + return this.valueReference; + } + + /** + * Set the valueReference property: Value as reference. + * + * @param valueReference the valueReference value to set. + * @return the Extension object itself. + */ + @Generated + public Extension setValueReference(Reference valueReference) { + this.valueReference = valueReference; + return this; + } + + /** + * {@inheritDoc} + */ + @Generated + @Override + public Extension setId(String id) { + super.setId(id); + return this; + } + + /** + * {@inheritDoc} + */ + @Generated + @Override + public Extension setExtension(List extension) { + super.setExtension(extension); + return this; + } +} diff --git a/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/Identifier.java b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/Identifier.java new file mode 100644 index 0000000000000..9a8fb75e2de1f --- /dev/null +++ b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/Identifier.java @@ -0,0 +1,218 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) TypeSpec Code Generator. + +package com.azure.health.insights.patienttimeline.models; + +import com.azure.core.annotation.Fluent; +import com.azure.core.annotation.Generated; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.util.List; + +/** + * An identifier intended for computation + * Based on [FHIR Identifier](https://www.hl7.org/fhir/R4/identifier.html). + */ +@Fluent +public final class Identifier extends Element { + /* + * usual | official | temp | secondary | old (If known) + */ + @Generated + @JsonProperty(value = "use") + private String use; + + /* + * Description of identifier + */ + @Generated + @JsonProperty(value = "type") + private CodeableConcept type; + + /* + * The namespace for the identifier value + */ + @Generated + @JsonProperty(value = "system") + private String system; + + /* + * The value that is unique + */ + @Generated + @JsonProperty(value = "value") + private String value; + + /* + * Time period when id is/was valid for use + */ + @Generated + @JsonProperty(value = "period") + private PeriodModel period; + + /* + * Organization that issued id (may be just text) + */ + @Generated + @JsonProperty(value = "assigner") + private Reference assigner; + + /** + * Creates an instance of Identifier class. + */ + @Generated + public Identifier() { + } + + /** + * Get the use property: usual | official | temp | secondary | old (If known). + * + * @return the use value. + */ + @Generated + public String getUse() { + return this.use; + } + + /** + * Set the use property: usual | official | temp | secondary | old (If known). + * + * @param use the use value to set. + * @return the Identifier object itself. + */ + @Generated + public Identifier setUse(String use) { + this.use = use; + return this; + } + + /** + * Get the type property: Description of identifier. + * + * @return the type value. + */ + @Generated + public CodeableConcept getType() { + return this.type; + } + + /** + * Set the type property: Description of identifier. + * + * @param type the type value to set. + * @return the Identifier object itself. + */ + @Generated + public Identifier setType(CodeableConcept type) { + this.type = type; + return this; + } + + /** + * Get the system property: The namespace for the identifier value. + * + * @return the system value. + */ + @Generated + public String getSystem() { + return this.system; + } + + /** + * Set the system property: The namespace for the identifier value. + * + * @param system the system value to set. + * @return the Identifier object itself. + */ + @Generated + public Identifier setSystem(String system) { + this.system = system; + return this; + } + + /** + * Get the value property: The value that is unique. + * + * @return the value value. + */ + @Generated + public String getValue() { + return this.value; + } + + /** + * Set the value property: The value that is unique. + * + * @param value the value value to set. + * @return the Identifier object itself. + */ + @Generated + public Identifier setValue(String value) { + this.value = value; + return this; + } + + /** + * Get the period property: Time period when id is/was valid for use. + * + * @return the period value. + */ + @Generated + public PeriodModel getPeriod() { + return this.period; + } + + /** + * Set the period property: Time period when id is/was valid for use. + * + * @param period the period value to set. + * @return the Identifier object itself. + */ + @Generated + public Identifier setPeriod(PeriodModel period) { + this.period = period; + return this; + } + + /** + * Get the assigner property: Organization that issued id (may be just text). + * + * @return the assigner value. + */ + @Generated + public Reference getAssigner() { + return this.assigner; + } + + /** + * Set the assigner property: Organization that issued id (may be just text). + * + * @param assigner the assigner value to set. + * @return the Identifier object itself. + */ + @Generated + public Identifier setAssigner(Reference assigner) { + this.assigner = assigner; + return this; + } + + /** + * {@inheritDoc} + */ + @Generated + @Override + public Identifier setId(String id) { + super.setId(id); + return this; + } + + /** + * {@inheritDoc} + */ + @Generated + @Override + public Identifier setExtension(List extension) { + super.setExtension(extension); + return this; + } +} diff --git a/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/Meta.java b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/Meta.java new file mode 100644 index 0000000000000..2b93db0bca6b9 --- /dev/null +++ b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/Meta.java @@ -0,0 +1,223 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) TypeSpec Code Generator. + +package com.azure.health.insights.patienttimeline.models; + +import com.azure.core.annotation.Fluent; +import com.azure.core.annotation.Generated; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.util.List; + +/** + * Metadata about a resource + * Based on [FHIR Meta](https://www.hl7.org/fhir/R4/resource.html#Meta). + */ +@Fluent +public final class Meta { + /* + * The version specific identifier, as it appears in the version portion of the URL. This value changes when the + * resource is created, updated, or deleted. + */ + @Generated + @JsonProperty(value = "versionId") + private String versionId; + + /* + * When the resource last changed - e.g. when the version changed. + */ + @Generated + @JsonProperty(value = "lastUpdated") + private String lastUpdated; + + /* + * A uri that identifies the source system of the resource. This provides a minimal amount of Provenance + * information that can be used to track or differentiate the source of information in the resource. The source may + * identify another FHIR server, document, message, database, etc. + */ + @Generated + @JsonProperty(value = "source") + private String source; + + /* + * A list of profiles (references to [StructureDefinition](https://www.hl7.org/fhir/structuredefinition.html) + * resources) that this resource claims to conform to. The URL is a reference to + * [StructureDefinition.url](https://www.hl7.org/fhir/structuredefinition-definitions.html#StructureDefinition.url). + */ + @Generated + @JsonProperty(value = "profile") + private List profile; + + /* + * Security labels applied to this resource. These tags connect specific resources to the overall security policy + * and infrastructure. + */ + @Generated + @JsonProperty(value = "security") + private List security; + + /* + * Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and + * workflow, and applications are not required to consider the tags when interpreting the meaning of a resource. + */ + @Generated + @JsonProperty(value = "tag") + private List tag; + + /** + * Creates an instance of Meta class. + */ + @Generated + public Meta() { + } + + /** + * Get the versionId property: The version specific identifier, as it appears in the version portion of the URL. + * This value changes when the resource is created, updated, or deleted. + * + * @return the versionId value. + */ + @Generated + public String getVersionId() { + return this.versionId; + } + + /** + * Set the versionId property: The version specific identifier, as it appears in the version portion of the URL. + * This value changes when the resource is created, updated, or deleted. + * + * @param versionId the versionId value to set. + * @return the Meta object itself. + */ + @Generated + public Meta setVersionId(String versionId) { + this.versionId = versionId; + return this; + } + + /** + * Get the lastUpdated property: When the resource last changed - e.g. when the version changed. + * + * @return the lastUpdated value. + */ + @Generated + public String getLastUpdated() { + return this.lastUpdated; + } + + /** + * Set the lastUpdated property: When the resource last changed - e.g. when the version changed. + * + * @param lastUpdated the lastUpdated value to set. + * @return the Meta object itself. + */ + @Generated + public Meta setLastUpdated(String lastUpdated) { + this.lastUpdated = lastUpdated; + return this; + } + + /** + * Get the source property: A uri that identifies the source system of the resource. This provides a minimal amount + * of Provenance information that can be used to track or differentiate the source of information in the resource. + * The source may identify another FHIR server, document, message, database, etc. + * + * @return the source value. + */ + @Generated + public String getSource() { + return this.source; + } + + /** + * Set the source property: A uri that identifies the source system of the resource. This provides a minimal amount + * of Provenance information that can be used to track or differentiate the source of information in the resource. + * The source may identify another FHIR server, document, message, database, etc. + * + * @param source the source value to set. + * @return the Meta object itself. + */ + @Generated + public Meta setSource(String source) { + this.source = source; + return this; + } + + /** + * Get the profile property: A list of profiles (references to + * [StructureDefinition](https://www.hl7.org/fhir/structuredefinition.html) resources) that this resource claims to + * conform to. The URL is a reference to + * [StructureDefinition.url](https://www.hl7.org/fhir/structuredefinition-definitions.html#StructureDefinition.url). + * + * @return the profile value. + */ + @Generated + public List getProfile() { + return this.profile; + } + + /** + * Set the profile property: A list of profiles (references to + * [StructureDefinition](https://www.hl7.org/fhir/structuredefinition.html) resources) that this resource claims to + * conform to. The URL is a reference to + * [StructureDefinition.url](https://www.hl7.org/fhir/structuredefinition-definitions.html#StructureDefinition.url). + * + * @param profile the profile value to set. + * @return the Meta object itself. + */ + @Generated + public Meta setProfile(List profile) { + this.profile = profile; + return this; + } + + /** + * Get the security property: Security labels applied to this resource. These tags connect specific resources to + * the overall security policy and infrastructure. + * + * @return the security value. + */ + @Generated + public List getSecurity() { + return this.security; + } + + /** + * Set the security property: Security labels applied to this resource. These tags connect specific resources to + * the overall security policy and infrastructure. + * + * @param security the security value to set. + * @return the Meta object itself. + */ + @Generated + public Meta setSecurity(List security) { + this.security = security; + return this; + } + + /** + * Get the tag property: Tags applied to this resource. Tags are intended to be used to identify and relate + * resources to process and workflow, and applications are not required to consider the tags when interpreting the + * meaning of a resource. + * + * @return the tag value. + */ + @Generated + public List getTag() { + return this.tag; + } + + /** + * Set the tag property: Tags applied to this resource. Tags are intended to be used to identify and relate + * resources to process and workflow, and applications are not required to consider the tags when interpreting the + * meaning of a resource. + * + * @param tag the tag value to set. + * @return the Meta object itself. + */ + @Generated + public Meta setTag(List tag) { + this.tag = tag; + return this; + } +} diff --git a/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/Narrative.java b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/Narrative.java new file mode 100644 index 0000000000000..924aa5401acc1 --- /dev/null +++ b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/Narrative.java @@ -0,0 +1,87 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) TypeSpec Code Generator. + +package com.azure.health.insights.patienttimeline.models; + +import com.azure.core.annotation.Fluent; +import com.azure.core.annotation.Generated; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.util.List; + +/** + * Any resource that is a [DomainResource](https://www.hl7.org/fhir/domainresource.html) may include a human-readable + * narrative that contains a summary of the resource and may be used to represent the content of the resource to a + * human. + * Based on [FHIR Narrative](https://www.hl7.org/fhir/R4/narrative.html#Narrative). + */ +@Fluent +public final class Narrative extends Element { + /* + * generated, extensions, additional, empty + */ + @Generated + @JsonProperty(value = "status") + private String status; + + /* + * xhtml + */ + @Generated + @JsonProperty(value = "div") + private String div; + + /** + * Creates an instance of Narrative class. + * + * @param status the status value to set. + * @param div the div value to set. + */ + @Generated + @JsonCreator + public Narrative(@JsonProperty(value = "status") String status, @JsonProperty(value = "div") String div) { + this.status = status; + this.div = div; + } + + /** + * Get the status property: generated, extensions, additional, empty. + * + * @return the status value. + */ + @Generated + public String getStatus() { + return this.status; + } + + /** + * Get the div property: xhtml. + * + * @return the div value. + */ + @Generated + public String getDiv() { + return this.div; + } + + /** + * {@inheritDoc} + */ + @Generated + @Override + public Narrative setId(String id) { + super.setId(id); + return this; + } + + /** + * {@inheritDoc} + */ + @Generated + @Override + public Narrative setExtension(List extension) { + super.setExtension(extension); + return this; + } +} diff --git a/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/Observation.java b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/Observation.java new file mode 100644 index 0000000000000..f3f5cab904f6f --- /dev/null +++ b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/Observation.java @@ -0,0 +1,923 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) TypeSpec Code Generator. + +package com.azure.health.insights.patienttimeline.models; + +import com.azure.core.annotation.Fluent; +import com.azure.core.annotation.Generated; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonTypeInfo; +import com.fasterxml.jackson.annotation.JsonTypeName; +import java.util.List; +import java.util.Map; + +/** + * Detailed information about observations + * Based on [FHIR Observation](https://www.hl7.org/fhir/R4/observation.html). + */ +@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "resourceType") +@JsonTypeName("Observation") +@Fluent +public final class Observation extends DomainResource { + /* + * Business Identifier for observation + */ + @Generated + @JsonProperty(value = "identifier") + private List identifier; + + /* + * registered | preliminary | final | amended + + */ + @Generated + @JsonProperty(value = "status") + private ObservationStatusCodeType status; + + /* + * Classification of type of observation + */ + @Generated + @JsonProperty(value = "category") + private List category; + + /* + * Type of observation (code / type) + */ + @Generated + @JsonProperty(value = "code") + private CodeableConcept code; + + /* + * Who and/or what the observation is about + */ + @Generated + @JsonProperty(value = "subject") + private Reference subject; + + /* + * Healthcare event during which this observation is made + */ + @Generated + @JsonProperty(value = "encounter") + private Reference encounter; + + /* + * Clinically relevant time/time-period for observation + */ + @Generated + @JsonProperty(value = "effectiveDateTime") + private String effectiveDateTime; + + /* + * Clinically relevant time/time-period for observation + */ + @Generated + @JsonProperty(value = "effectivePeriod") + private PeriodModel effectivePeriod; + + /* + * Clinically relevant time/time-period for observation + */ + @Generated + @JsonProperty(value = "effectiveInstant") + private String effectiveInstant; + + /* + * Date/Time this version was made available + */ + @Generated + @JsonProperty(value = "issued") + private String issued; + + /* + * Actual result + */ + @Generated + @JsonProperty(value = "valueQuantity") + private Quantity valueQuantity; + + /* + * Actual result + */ + @Generated + @JsonProperty(value = "valueCodeableConcept") + private CodeableConcept valueCodeableConcept; + + /* + * Actual result + */ + @Generated + @JsonProperty(value = "valueString") + private String valueString; + + /* + * Actual result + */ + @Generated + @JsonProperty(value = "valueBoolean") + private Boolean valueBoolean; + + /* + * Actual result + */ + @Generated + @JsonProperty(value = "valueInteger") + private Integer valueInteger; + + /* + * Actual result + */ + @Generated + @JsonProperty(value = "valueRange") + private Range valueRange; + + /* + * Actual result + */ + @Generated + @JsonProperty(value = "valueRatio") + private Ratio valueRatio; + + /* + * Actual result + */ + @Generated + @JsonProperty(value = "valueSampledData") + private SampledData valueSampledData; + + /* + * Actual result + */ + @Generated + @JsonProperty(value = "valueTime") + private String valueTime; + + /* + * Actual result + */ + @Generated + @JsonProperty(value = "valueDateTime") + private String valueDateTime; + + /* + * Actual result + */ + @Generated + @JsonProperty(value = "valuePeriod") + private PeriodModel valuePeriod; + + /* + * Why the result is missing + */ + @Generated + @JsonProperty(value = "dataAbsentReason") + private CodeableConcept dataAbsentReason; + + /* + * High, low, normal, etc. + */ + @Generated + @JsonProperty(value = "interpretation") + private List interpretation; + + /* + * Comments about the observation + */ + @Generated + @JsonProperty(value = "note") + private List note; + + /* + * Observed body part + */ + @Generated + @JsonProperty(value = "bodySite") + private CodeableConcept bodySite; + + /* + * How it was done + */ + @Generated + @JsonProperty(value = "method") + private CodeableConcept method; + + /* + * Provides guide for interpretation + */ + @Generated + @JsonProperty(value = "referenceRange") + private List referenceRange; + + /* + * Related resource that belongs to the Observation group + */ + @Generated + @JsonProperty(value = "hasMember") + private List hasMember; + + /* + * Related measurements the observation is made from + */ + @Generated + @JsonProperty(value = "derivedFrom") + private List derivedFrom; + + /* + * Component results + */ + @Generated + @JsonProperty(value = "component") + private List component; + + /** + * Creates an instance of Observation class. + * + * @param status the status value to set. + * @param code the code value to set. + */ + @Generated + @JsonCreator + public Observation(@JsonProperty(value = "status") ObservationStatusCodeType status, + @JsonProperty(value = "code") CodeableConcept code) { + this.status = status; + this.code = code; + } + + /** + * Get the identifier property: Business Identifier for observation. + * + * @return the identifier value. + */ + @Generated + public List getIdentifier() { + return this.identifier; + } + + /** + * Set the identifier property: Business Identifier for observation. + * + * @param identifier the identifier value to set. + * @return the Observation object itself. + */ + @Generated + public Observation setIdentifier(List identifier) { + this.identifier = identifier; + return this; + } + + /** + * Get the status property: registered | preliminary | final | amended +. + * + * @return the status value. + */ + @Generated + public ObservationStatusCodeType getStatus() { + return this.status; + } + + /** + * Get the category property: Classification of type of observation. + * + * @return the category value. + */ + @Generated + public List getCategory() { + return this.category; + } + + /** + * Set the category property: Classification of type of observation. + * + * @param category the category value to set. + * @return the Observation object itself. + */ + @Generated + public Observation setCategory(List category) { + this.category = category; + return this; + } + + /** + * Get the code property: Type of observation (code / type). + * + * @return the code value. + */ + @Generated + public CodeableConcept getCode() { + return this.code; + } + + /** + * Get the subject property: Who and/or what the observation is about. + * + * @return the subject value. + */ + @Generated + public Reference getSubject() { + return this.subject; + } + + /** + * Set the subject property: Who and/or what the observation is about. + * + * @param subject the subject value to set. + * @return the Observation object itself. + */ + @Generated + public Observation setSubject(Reference subject) { + this.subject = subject; + return this; + } + + /** + * Get the encounter property: Healthcare event during which this observation is made. + * + * @return the encounter value. + */ + @Generated + public Reference getEncounter() { + return this.encounter; + } + + /** + * Set the encounter property: Healthcare event during which this observation is made. + * + * @param encounter the encounter value to set. + * @return the Observation object itself. + */ + @Generated + public Observation setEncounter(Reference encounter) { + this.encounter = encounter; + return this; + } + + /** + * Get the effectiveDateTime property: Clinically relevant time/time-period for observation. + * + * @return the effectiveDateTime value. + */ + @Generated + public String getEffectiveDateTime() { + return this.effectiveDateTime; + } + + /** + * Set the effectiveDateTime property: Clinically relevant time/time-period for observation. + * + * @param effectiveDateTime the effectiveDateTime value to set. + * @return the Observation object itself. + */ + @Generated + public Observation setEffectiveDateTime(String effectiveDateTime) { + this.effectiveDateTime = effectiveDateTime; + return this; + } + + /** + * Get the effectivePeriod property: Clinically relevant time/time-period for observation. + * + * @return the effectivePeriod value. + */ + @Generated + public PeriodModel getEffectivePeriod() { + return this.effectivePeriod; + } + + /** + * Set the effectivePeriod property: Clinically relevant time/time-period for observation. + * + * @param effectivePeriod the effectivePeriod value to set. + * @return the Observation object itself. + */ + @Generated + public Observation setEffectivePeriod(PeriodModel effectivePeriod) { + this.effectivePeriod = effectivePeriod; + return this; + } + + /** + * Get the effectiveInstant property: Clinically relevant time/time-period for observation. + * + * @return the effectiveInstant value. + */ + @Generated + public String getEffectiveInstant() { + return this.effectiveInstant; + } + + /** + * Set the effectiveInstant property: Clinically relevant time/time-period for observation. + * + * @param effectiveInstant the effectiveInstant value to set. + * @return the Observation object itself. + */ + @Generated + public Observation setEffectiveInstant(String effectiveInstant) { + this.effectiveInstant = effectiveInstant; + return this; + } + + /** + * Get the issued property: Date/Time this version was made available. + * + * @return the issued value. + */ + @Generated + public String getIssued() { + return this.issued; + } + + /** + * Set the issued property: Date/Time this version was made available. + * + * @param issued the issued value to set. + * @return the Observation object itself. + */ + @Generated + public Observation setIssued(String issued) { + this.issued = issued; + return this; + } + + /** + * Get the valueQuantity property: Actual result. + * + * @return the valueQuantity value. + */ + @Generated + public Quantity getValueQuantity() { + return this.valueQuantity; + } + + /** + * Set the valueQuantity property: Actual result. + * + * @param valueQuantity the valueQuantity value to set. + * @return the Observation object itself. + */ + @Generated + public Observation setValueQuantity(Quantity valueQuantity) { + this.valueQuantity = valueQuantity; + return this; + } + + /** + * Get the valueCodeableConcept property: Actual result. + * + * @return the valueCodeableConcept value. + */ + @Generated + public CodeableConcept getValueCodeableConcept() { + return this.valueCodeableConcept; + } + + /** + * Set the valueCodeableConcept property: Actual result. + * + * @param valueCodeableConcept the valueCodeableConcept value to set. + * @return the Observation object itself. + */ + @Generated + public Observation setValueCodeableConcept(CodeableConcept valueCodeableConcept) { + this.valueCodeableConcept = valueCodeableConcept; + return this; + } + + /** + * Get the valueString property: Actual result. + * + * @return the valueString value. + */ + @Generated + public String getValueString() { + return this.valueString; + } + + /** + * Set the valueString property: Actual result. + * + * @param valueString the valueString value to set. + * @return the Observation object itself. + */ + @Generated + public Observation setValueString(String valueString) { + this.valueString = valueString; + return this; + } + + /** + * Get the valueBoolean property: Actual result. + * + * @return the valueBoolean value. + */ + @Generated + public Boolean isValueBoolean() { + return this.valueBoolean; + } + + /** + * Set the valueBoolean property: Actual result. + * + * @param valueBoolean the valueBoolean value to set. + * @return the Observation object itself. + */ + @Generated + public Observation setValueBoolean(Boolean valueBoolean) { + this.valueBoolean = valueBoolean; + return this; + } + + /** + * Get the valueInteger property: Actual result. + * + * @return the valueInteger value. + */ + @Generated + public Integer getValueInteger() { + return this.valueInteger; + } + + /** + * Set the valueInteger property: Actual result. + * + * @param valueInteger the valueInteger value to set. + * @return the Observation object itself. + */ + @Generated + public Observation setValueInteger(Integer valueInteger) { + this.valueInteger = valueInteger; + return this; + } + + /** + * Get the valueRange property: Actual result. + * + * @return the valueRange value. + */ + @Generated + public Range getValueRange() { + return this.valueRange; + } + + /** + * Set the valueRange property: Actual result. + * + * @param valueRange the valueRange value to set. + * @return the Observation object itself. + */ + @Generated + public Observation setValueRange(Range valueRange) { + this.valueRange = valueRange; + return this; + } + + /** + * Get the valueRatio property: Actual result. + * + * @return the valueRatio value. + */ + @Generated + public Ratio getValueRatio() { + return this.valueRatio; + } + + /** + * Set the valueRatio property: Actual result. + * + * @param valueRatio the valueRatio value to set. + * @return the Observation object itself. + */ + @Generated + public Observation setValueRatio(Ratio valueRatio) { + this.valueRatio = valueRatio; + return this; + } + + /** + * Get the valueSampledData property: Actual result. + * + * @return the valueSampledData value. + */ + @Generated + public SampledData getValueSampledData() { + return this.valueSampledData; + } + + /** + * Set the valueSampledData property: Actual result. + * + * @param valueSampledData the valueSampledData value to set. + * @return the Observation object itself. + */ + @Generated + public Observation setValueSampledData(SampledData valueSampledData) { + this.valueSampledData = valueSampledData; + return this; + } + + /** + * Get the valueTime property: Actual result. + * + * @return the valueTime value. + */ + @Generated + public String getValueTime() { + return this.valueTime; + } + + /** + * Set the valueTime property: Actual result. + * + * @param valueTime the valueTime value to set. + * @return the Observation object itself. + */ + @Generated + public Observation setValueTime(String valueTime) { + this.valueTime = valueTime; + return this; + } + + /** + * Get the valueDateTime property: Actual result. + * + * @return the valueDateTime value. + */ + @Generated + public String getValueDateTime() { + return this.valueDateTime; + } + + /** + * Set the valueDateTime property: Actual result. + * + * @param valueDateTime the valueDateTime value to set. + * @return the Observation object itself. + */ + @Generated + public Observation setValueDateTime(String valueDateTime) { + this.valueDateTime = valueDateTime; + return this; + } + + /** + * Get the valuePeriod property: Actual result. + * + * @return the valuePeriod value. + */ + @Generated + public PeriodModel getValuePeriod() { + return this.valuePeriod; + } + + /** + * Set the valuePeriod property: Actual result. + * + * @param valuePeriod the valuePeriod value to set. + * @return the Observation object itself. + */ + @Generated + public Observation setValuePeriod(PeriodModel valuePeriod) { + this.valuePeriod = valuePeriod; + return this; + } + + /** + * Get the dataAbsentReason property: Why the result is missing. + * + * @return the dataAbsentReason value. + */ + @Generated + public CodeableConcept getDataAbsentReason() { + return this.dataAbsentReason; + } + + /** + * Set the dataAbsentReason property: Why the result is missing. + * + * @param dataAbsentReason the dataAbsentReason value to set. + * @return the Observation object itself. + */ + @Generated + public Observation setDataAbsentReason(CodeableConcept dataAbsentReason) { + this.dataAbsentReason = dataAbsentReason; + return this; + } + + /** + * Get the interpretation property: High, low, normal, etc. + * + * @return the interpretation value. + */ + @Generated + public List getInterpretation() { + return this.interpretation; + } + + /** + * Set the interpretation property: High, low, normal, etc. + * + * @param interpretation the interpretation value to set. + * @return the Observation object itself. + */ + @Generated + public Observation setInterpretation(List interpretation) { + this.interpretation = interpretation; + return this; + } + + /** + * Get the note property: Comments about the observation. + * + * @return the note value. + */ + @Generated + public List getNote() { + return this.note; + } + + /** + * Set the note property: Comments about the observation. + * + * @param note the note value to set. + * @return the Observation object itself. + */ + @Generated + public Observation setNote(List note) { + this.note = note; + return this; + } + + /** + * Get the bodySite property: Observed body part. + * + * @return the bodySite value. + */ + @Generated + public CodeableConcept getBodySite() { + return this.bodySite; + } + + /** + * Set the bodySite property: Observed body part. + * + * @param bodySite the bodySite value to set. + * @return the Observation object itself. + */ + @Generated + public Observation setBodySite(CodeableConcept bodySite) { + this.bodySite = bodySite; + return this; + } + + /** + * Get the method property: How it was done. + * + * @return the method value. + */ + @Generated + public CodeableConcept getMethod() { + return this.method; + } + + /** + * Set the method property: How it was done. + * + * @param method the method value to set. + * @return the Observation object itself. + */ + @Generated + public Observation setMethod(CodeableConcept method) { + this.method = method; + return this; + } + + /** + * Get the referenceRange property: Provides guide for interpretation. + * + * @return the referenceRange value. + */ + @Generated + public List getReferenceRange() { + return this.referenceRange; + } + + /** + * Set the referenceRange property: Provides guide for interpretation. + * + * @param referenceRange the referenceRange value to set. + * @return the Observation object itself. + */ + @Generated + public Observation setReferenceRange(List referenceRange) { + this.referenceRange = referenceRange; + return this; + } + + /** + * Get the hasMember property: Related resource that belongs to the Observation group. + * + * @return the hasMember value. + */ + @Generated + public List getHasMember() { + return this.hasMember; + } + + /** + * Set the hasMember property: Related resource that belongs to the Observation group. + * + * @param hasMember the hasMember value to set. + * @return the Observation object itself. + */ + @Generated + public Observation setHasMember(List hasMember) { + this.hasMember = hasMember; + return this; + } + + /** + * Get the derivedFrom property: Related measurements the observation is made from. + * + * @return the derivedFrom value. + */ + @Generated + public List getDerivedFrom() { + return this.derivedFrom; + } + + /** + * Set the derivedFrom property: Related measurements the observation is made from. + * + * @param derivedFrom the derivedFrom value to set. + * @return the Observation object itself. + */ + @Generated + public Observation setDerivedFrom(List derivedFrom) { + this.derivedFrom = derivedFrom; + return this; + } + + /** + * Get the component property: Component results. + * + * @return the component value. + */ + @Generated + public List getComponent() { + return this.component; + } + + /** + * Set the component property: Component results. + * + * @param component the component value to set. + * @return the Observation object itself. + */ + @Generated + public Observation setComponent(List component) { + this.component = component; + return this; + } + + /** + * {@inheritDoc} + */ + @Generated + @Override + public Observation setText(Narrative text) { + super.setText(text); + return this; + } + + /** + * {@inheritDoc} + */ + @Generated + @Override + public Observation setContained(List> contained) { + super.setContained(contained); + return this; + } + + /** + * {@inheritDoc} + */ + @Generated + @Override + public Observation setExtension(List extension) { + super.setExtension(extension); + return this; + } + + /** + * {@inheritDoc} + */ + @Generated + @Override + public Observation setModifierExtension(List modifierExtension) { + super.setModifierExtension(modifierExtension); + return this; + } +} diff --git a/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/ObservationComponent.java b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/ObservationComponent.java new file mode 100644 index 0000000000000..c677d1270adf6 --- /dev/null +++ b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/ObservationComponent.java @@ -0,0 +1,501 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) TypeSpec Code Generator. + +package com.azure.health.insights.patienttimeline.models; + +import com.azure.core.annotation.Fluent; +import com.azure.core.annotation.Generated; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.util.List; + +/** + * Component results + * Based on [FHIR Observation.component](https://www.hl7.org/fhir/R4/observation.html). + */ +@Fluent +public final class ObservationComponent extends Element { + /* + * Type of component observation (code / type) + */ + @Generated + @JsonProperty(value = "code") + private CodeableConcept code; + + /* + * Value as Quantity + */ + @Generated + @JsonProperty(value = "valueQuantity") + private Quantity valueQuantity; + + /* + * Value as CodeableConcept + */ + @Generated + @JsonProperty(value = "valueCodeableConcept") + private CodeableConcept valueCodeableConcept; + + /* + * Value as string + */ + @Generated + @JsonProperty(value = "valueString") + private String valueString; + + /* + * Value as boolean + */ + @Generated + @JsonProperty(value = "valueBoolean") + private Boolean valueBoolean; + + /* + * Value as integer + */ + @Generated + @JsonProperty(value = "valueInteger") + private Integer valueInteger; + + /* + * Value as Range. + */ + @Generated + @JsonProperty(value = "valueRange") + private Range valueRange; + + /* + * Value as Ratio. + */ + @Generated + @JsonProperty(value = "valueRatio") + private Ratio valueRatio; + + /* + * Value as SampledData. + */ + @Generated + @JsonProperty(value = "valueSampledData") + private SampledData valueSampledData; + + /* + * Value as time (hh:mm:ss) + */ + @Generated + @JsonProperty(value = "valueTime") + private String valueTime; + + /* + * Value as dateTime. + */ + @Generated + @JsonProperty(value = "valueDateTime") + private String valueDateTime; + + /* + * Value as Period. + */ + @Generated + @JsonProperty(value = "valuePeriod") + private PeriodModel valuePeriod; + + /* + * Value as reference. + */ + @Generated + @JsonProperty(value = "valueReference") + private Reference valueReference; + + /* + * Why the component result is missing + */ + @Generated + @JsonProperty(value = "dataAbsentReason") + private CodeableConcept dataAbsentReason; + + /* + * High, low, normal, etc. + */ + @Generated + @JsonProperty(value = "interpretation") + private List interpretation; + + /* + * Provides guide for interpretation of component result + */ + @Generated + @JsonProperty(value = "referenceRange") + private List referenceRange; + + /** + * Creates an instance of ObservationComponent class. + * + * @param code the code value to set. + */ + @Generated + @JsonCreator + public ObservationComponent(@JsonProperty(value = "code") CodeableConcept code) { + this.code = code; + } + + /** + * Get the code property: Type of component observation (code / type). + * + * @return the code value. + */ + @Generated + public CodeableConcept getCode() { + return this.code; + } + + /** + * Get the valueQuantity property: Value as Quantity. + * + * @return the valueQuantity value. + */ + @Generated + public Quantity getValueQuantity() { + return this.valueQuantity; + } + + /** + * Set the valueQuantity property: Value as Quantity. + * + * @param valueQuantity the valueQuantity value to set. + * @return the ObservationComponent object itself. + */ + @Generated + public ObservationComponent setValueQuantity(Quantity valueQuantity) { + this.valueQuantity = valueQuantity; + return this; + } + + /** + * Get the valueCodeableConcept property: Value as CodeableConcept. + * + * @return the valueCodeableConcept value. + */ + @Generated + public CodeableConcept getValueCodeableConcept() { + return this.valueCodeableConcept; + } + + /** + * Set the valueCodeableConcept property: Value as CodeableConcept. + * + * @param valueCodeableConcept the valueCodeableConcept value to set. + * @return the ObservationComponent object itself. + */ + @Generated + public ObservationComponent setValueCodeableConcept(CodeableConcept valueCodeableConcept) { + this.valueCodeableConcept = valueCodeableConcept; + return this; + } + + /** + * Get the valueString property: Value as string. + * + * @return the valueString value. + */ + @Generated + public String getValueString() { + return this.valueString; + } + + /** + * Set the valueString property: Value as string. + * + * @param valueString the valueString value to set. + * @return the ObservationComponent object itself. + */ + @Generated + public ObservationComponent setValueString(String valueString) { + this.valueString = valueString; + return this; + } + + /** + * Get the valueBoolean property: Value as boolean. + * + * @return the valueBoolean value. + */ + @Generated + public Boolean isValueBoolean() { + return this.valueBoolean; + } + + /** + * Set the valueBoolean property: Value as boolean. + * + * @param valueBoolean the valueBoolean value to set. + * @return the ObservationComponent object itself. + */ + @Generated + public ObservationComponent setValueBoolean(Boolean valueBoolean) { + this.valueBoolean = valueBoolean; + return this; + } + + /** + * Get the valueInteger property: Value as integer. + * + * @return the valueInteger value. + */ + @Generated + public Integer getValueInteger() { + return this.valueInteger; + } + + /** + * Set the valueInteger property: Value as integer. + * + * @param valueInteger the valueInteger value to set. + * @return the ObservationComponent object itself. + */ + @Generated + public ObservationComponent setValueInteger(Integer valueInteger) { + this.valueInteger = valueInteger; + return this; + } + + /** + * Get the valueRange property: Value as Range. + * + * @return the valueRange value. + */ + @Generated + public Range getValueRange() { + return this.valueRange; + } + + /** + * Set the valueRange property: Value as Range. + * + * @param valueRange the valueRange value to set. + * @return the ObservationComponent object itself. + */ + @Generated + public ObservationComponent setValueRange(Range valueRange) { + this.valueRange = valueRange; + return this; + } + + /** + * Get the valueRatio property: Value as Ratio. + * + * @return the valueRatio value. + */ + @Generated + public Ratio getValueRatio() { + return this.valueRatio; + } + + /** + * Set the valueRatio property: Value as Ratio. + * + * @param valueRatio the valueRatio value to set. + * @return the ObservationComponent object itself. + */ + @Generated + public ObservationComponent setValueRatio(Ratio valueRatio) { + this.valueRatio = valueRatio; + return this; + } + + /** + * Get the valueSampledData property: Value as SampledData. + * + * @return the valueSampledData value. + */ + @Generated + public SampledData getValueSampledData() { + return this.valueSampledData; + } + + /** + * Set the valueSampledData property: Value as SampledData. + * + * @param valueSampledData the valueSampledData value to set. + * @return the ObservationComponent object itself. + */ + @Generated + public ObservationComponent setValueSampledData(SampledData valueSampledData) { + this.valueSampledData = valueSampledData; + return this; + } + + /** + * Get the valueTime property: Value as time (hh:mm:ss). + * + * @return the valueTime value. + */ + @Generated + public String getValueTime() { + return this.valueTime; + } + + /** + * Set the valueTime property: Value as time (hh:mm:ss). + * + * @param valueTime the valueTime value to set. + * @return the ObservationComponent object itself. + */ + @Generated + public ObservationComponent setValueTime(String valueTime) { + this.valueTime = valueTime; + return this; + } + + /** + * Get the valueDateTime property: Value as dateTime. + * + * @return the valueDateTime value. + */ + @Generated + public String getValueDateTime() { + return this.valueDateTime; + } + + /** + * Set the valueDateTime property: Value as dateTime. + * + * @param valueDateTime the valueDateTime value to set. + * @return the ObservationComponent object itself. + */ + @Generated + public ObservationComponent setValueDateTime(String valueDateTime) { + this.valueDateTime = valueDateTime; + return this; + } + + /** + * Get the valuePeriod property: Value as Period. + * + * @return the valuePeriod value. + */ + @Generated + public PeriodModel getValuePeriod() { + return this.valuePeriod; + } + + /** + * Set the valuePeriod property: Value as Period. + * + * @param valuePeriod the valuePeriod value to set. + * @return the ObservationComponent object itself. + */ + @Generated + public ObservationComponent setValuePeriod(PeriodModel valuePeriod) { + this.valuePeriod = valuePeriod; + return this; + } + + /** + * Get the valueReference property: Value as reference. + * + * @return the valueReference value. + */ + @Generated + public Reference getValueReference() { + return this.valueReference; + } + + /** + * Set the valueReference property: Value as reference. + * + * @param valueReference the valueReference value to set. + * @return the ObservationComponent object itself. + */ + @Generated + public ObservationComponent setValueReference(Reference valueReference) { + this.valueReference = valueReference; + return this; + } + + /** + * Get the dataAbsentReason property: Why the component result is missing. + * + * @return the dataAbsentReason value. + */ + @Generated + public CodeableConcept getDataAbsentReason() { + return this.dataAbsentReason; + } + + /** + * Set the dataAbsentReason property: Why the component result is missing. + * + * @param dataAbsentReason the dataAbsentReason value to set. + * @return the ObservationComponent object itself. + */ + @Generated + public ObservationComponent setDataAbsentReason(CodeableConcept dataAbsentReason) { + this.dataAbsentReason = dataAbsentReason; + return this; + } + + /** + * Get the interpretation property: High, low, normal, etc. + * + * @return the interpretation value. + */ + @Generated + public List getInterpretation() { + return this.interpretation; + } + + /** + * Set the interpretation property: High, low, normal, etc. + * + * @param interpretation the interpretation value to set. + * @return the ObservationComponent object itself. + */ + @Generated + public ObservationComponent setInterpretation(List interpretation) { + this.interpretation = interpretation; + return this; + } + + /** + * Get the referenceRange property: Provides guide for interpretation of component result. + * + * @return the referenceRange value. + */ + @Generated + public List getReferenceRange() { + return this.referenceRange; + } + + /** + * Set the referenceRange property: Provides guide for interpretation of component result. + * + * @param referenceRange the referenceRange value to set. + * @return the ObservationComponent object itself. + */ + @Generated + public ObservationComponent setReferenceRange(List referenceRange) { + this.referenceRange = referenceRange; + return this; + } + + /** + * {@inheritDoc} + */ + @Generated + @Override + public ObservationComponent setId(String id) { + super.setId(id); + return this; + } + + /** + * {@inheritDoc} + */ + @Generated + @Override + public ObservationComponent setExtension(List extension) { + super.setExtension(extension); + return this; + } +} diff --git a/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/ObservationReferenceRange.java b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/ObservationReferenceRange.java new file mode 100644 index 0000000000000..3363a023190f4 --- /dev/null +++ b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/ObservationReferenceRange.java @@ -0,0 +1,198 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) TypeSpec Code Generator. + +package com.azure.health.insights.patienttimeline.models; + +import com.azure.core.annotation.Fluent; +import com.azure.core.annotation.Generated; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.util.List; + +/** + * Provides guide for interpretation of component result + * Based on [FHIR Observation.referenceRange](https://www.hl7.org/fhir/R4/observation.html). + */ +@Fluent +public final class ObservationReferenceRange { + /* + * Low Range, if relevant + */ + @Generated + @JsonProperty(value = "low") + private Quantity low; + + /* + * High Range, if relevant + */ + @Generated + @JsonProperty(value = "high") + private Quantity high; + + /* + * Reference range qualifier + */ + @Generated + @JsonProperty(value = "type") + private CodeableConcept type; + + /* + * Reference range population + */ + @Generated + @JsonProperty(value = "appliesTo") + private List appliesTo; + + /* + * Applicable age range, if relevant + */ + @Generated + @JsonProperty(value = "age") + private Range age; + + /* + * Text based reference range in an observation + */ + @Generated + @JsonProperty(value = "text") + private String text; + + /** + * Creates an instance of ObservationReferenceRange class. + */ + @Generated + public ObservationReferenceRange() { + } + + /** + * Get the low property: Low Range, if relevant. + * + * @return the low value. + */ + @Generated + public Quantity getLow() { + return this.low; + } + + /** + * Set the low property: Low Range, if relevant. + * + * @param low the low value to set. + * @return the ObservationReferenceRange object itself. + */ + @Generated + public ObservationReferenceRange setLow(Quantity low) { + this.low = low; + return this; + } + + /** + * Get the high property: High Range, if relevant. + * + * @return the high value. + */ + @Generated + public Quantity getHigh() { + return this.high; + } + + /** + * Set the high property: High Range, if relevant. + * + * @param high the high value to set. + * @return the ObservationReferenceRange object itself. + */ + @Generated + public ObservationReferenceRange setHigh(Quantity high) { + this.high = high; + return this; + } + + /** + * Get the type property: Reference range qualifier. + * + * @return the type value. + */ + @Generated + public CodeableConcept getType() { + return this.type; + } + + /** + * Set the type property: Reference range qualifier. + * + * @param type the type value to set. + * @return the ObservationReferenceRange object itself. + */ + @Generated + public ObservationReferenceRange setType(CodeableConcept type) { + this.type = type; + return this; + } + + /** + * Get the appliesTo property: Reference range population. + * + * @return the appliesTo value. + */ + @Generated + public List getAppliesTo() { + return this.appliesTo; + } + + /** + * Set the appliesTo property: Reference range population. + * + * @param appliesTo the appliesTo value to set. + * @return the ObservationReferenceRange object itself. + */ + @Generated + public ObservationReferenceRange setAppliesTo(List appliesTo) { + this.appliesTo = appliesTo; + return this; + } + + /** + * Get the age property: Applicable age range, if relevant. + * + * @return the age value. + */ + @Generated + public Range getAge() { + return this.age; + } + + /** + * Set the age property: Applicable age range, if relevant. + * + * @param age the age value to set. + * @return the ObservationReferenceRange object itself. + */ + @Generated + public ObservationReferenceRange setAge(Range age) { + this.age = age; + return this; + } + + /** + * Get the text property: Text based reference range in an observation. + * + * @return the text value. + */ + @Generated + public String getText() { + return this.text; + } + + /** + * Set the text property: Text based reference range in an observation. + * + * @param text the text value to set. + * @return the ObservationReferenceRange object itself. + */ + @Generated + public ObservationReferenceRange setText(String text) { + this.text = text; + return this; + } +} diff --git a/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/ObservationStatusCodeType.java b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/ObservationStatusCodeType.java new file mode 100644 index 0000000000000..9fbc6288002b5 --- /dev/null +++ b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/ObservationStatusCodeType.java @@ -0,0 +1,99 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) TypeSpec Code Generator. + +package com.azure.health.insights.patienttimeline.models; + +import com.azure.core.annotation.Generated; +import com.azure.core.util.ExpandableStringEnum; +import com.fasterxml.jackson.annotation.JsonCreator; +import java.util.Collection; + +/** + * Observation Status + * Based on [FHIR ObservationStatus](https://www.hl7.org/fhir/R4/valueset-observation-status.html). + */ +public final class ObservationStatusCodeType extends ExpandableStringEnum { + /** + * The existence of the observation is registered, but there is no result yet available. + */ + @Generated + public static final ObservationStatusCodeType REGISTERED = fromString("registered"); + + /** + * This is an initial or interim observation: data may be incomplete or unverified. + */ + @Generated + public static final ObservationStatusCodeType PRELIMINARY = fromString("preliminary"); + + /** + * The observation is complete and verified by an authorized person. + */ + @Generated + public static final ObservationStatusCodeType FINAL = fromString("final"); + + /** + * Subsequent to being Final, the observation has been modified subsequent. This includes updates/new information + * and corrections. + */ + @Generated + public static final ObservationStatusCodeType AMENDED = fromString("amended"); + + /** + * Subsequent to being Final, the observation has been modified to correct an error in the test result. + */ + @Generated + public static final ObservationStatusCodeType CORRECTED = fromString("corrected"); + + /** + * The observation is unavailable because the measurement was not started or not completed (also sometimes called + * "aborted"). + */ + @Generated + public static final ObservationStatusCodeType CANCELLED = fromString("cancelled"); + + /** + * The observation has been withdrawn following previous final release. + */ + @Generated + public static final ObservationStatusCodeType ENTERED_IN_ERROR = fromString("entered-in-error"); + + /** + * The observation status is unknown. Note that "unknown" is a value of last resort and every attempt should be made + * to provide a meaningful value other than "unknown". + */ + @Generated + public static final ObservationStatusCodeType UNKNOWN = fromString("unknown"); + + /** + * Creates a new instance of ObservationStatusCodeType value. + * + * @deprecated Use the {@link #fromString(String)} factory method. + */ + @Generated + @Deprecated + public ObservationStatusCodeType() { + } + + /** + * Creates or finds a ObservationStatusCodeType from its string representation. + * + * @param name a name to look for. + * @return the corresponding ObservationStatusCodeType. + */ + @Generated + @JsonCreator + public static ObservationStatusCodeType fromString(String name) { + return fromString(name, ObservationStatusCodeType.class); + } + + /** + * Gets known ObservationStatusCodeType values. + * + * @return known ObservationStatusCodeType values. + */ + @Generated + public static Collection values() { + return values(ObservationStatusCodeType.class); + } +} diff --git a/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/OrderedProcedure.java b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/OrderedProcedure.java new file mode 100644 index 0000000000000..ca71a87644cb2 --- /dev/null +++ b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/OrderedProcedure.java @@ -0,0 +1,91 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) TypeSpec Code Generator. + +package com.azure.health.insights.patienttimeline.models; + +import com.azure.core.annotation.Fluent; +import com.azure.core.annotation.Generated; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.util.List; + +/** + * Procedure information. + */ +@Fluent +public final class OrderedProcedure extends Extendible { + /* + * Procedure code + */ + @Generated + @JsonProperty(value = "code") + private CodeableConcept code; + + /* + * Procedure description + */ + @Generated + @JsonProperty(value = "description") + private String description; + + /** + * Creates an instance of OrderedProcedure class. + */ + @Generated + public OrderedProcedure() { + } + + /** + * Get the code property: Procedure code. + * + * @return the code value. + */ + @Generated + public CodeableConcept getCode() { + return this.code; + } + + /** + * Set the code property: Procedure code. + * + * @param code the code value to set. + * @return the OrderedProcedure object itself. + */ + @Generated + public OrderedProcedure setCode(CodeableConcept code) { + this.code = code; + return this; + } + + /** + * Get the description property: Procedure description. + * + * @return the description value. + */ + @Generated + public String getDescription() { + return this.description; + } + + /** + * Set the description property: Procedure description. + * + * @param description the description value to set. + * @return the OrderedProcedure object itself. + */ + @Generated + public OrderedProcedure setDescription(String description) { + this.description = description; + return this; + } + + /** + * {@inheritDoc} + */ + @Generated + @Override + public OrderedProcedure setExtension(List extension) { + super.setExtension(extension); + return this; + } +} diff --git a/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/PatientDocument.java b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/PatientDocument.java new file mode 100644 index 0000000000000..d67d157257d9c --- /dev/null +++ b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/PatientDocument.java @@ -0,0 +1,261 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) TypeSpec Code Generator. + +package com.azure.health.insights.patienttimeline.models; + +import com.azure.core.annotation.Fluent; +import com.azure.core.annotation.Generated; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.time.OffsetDateTime; +import java.util.List; + +/** + * A clinical document related to a patient. Document here is in the wide sense - not just a text document (note). + */ +@Fluent +public final class PatientDocument { + /* + * The type of the patient document, such as 'note' (text document) or 'fhirBundle' (FHIR JSON document). + */ + @Generated + @JsonProperty(value = "type") + private DocumentType type; + + /* + * The type of the clinical document. + */ + @Generated + @JsonProperty(value = "clinicalType") + private ClinicalDocumentType clinicalType; + + /* + * A given identifier for the document. Has to be unique across all documents for a single patient. + */ + @Generated + @JsonProperty(value = "id") + private String id; + + /* + * A 2 letter ISO 639-1 representation of the language of the document. + */ + @Generated + @JsonProperty(value = "language") + private String language; + + /* + * The date and time when the document was created. + */ + @Generated + @JsonProperty(value = "createdDateTime") + private OffsetDateTime createdDateTime; + + /* + * Document author(s) + */ + @Generated + @JsonProperty(value = "authors") + private List authors; + + /* + * specialty type the document + */ + @Generated + @JsonProperty(value = "specialtyType") + private SpecialtyType specialtyType; + + /* + * Administrative metadata for the document. + */ + @Generated + @JsonProperty(value = "administrativeMetadata") + private DocumentAdministrativeMetadata administrativeMetadata; + + /* + * The content of the patient document. + */ + @Generated + @JsonProperty(value = "content") + private DocumentContent content; + + /** + * Creates an instance of PatientDocument class. + * + * @param type the type value to set. + * @param id the id value to set. + * @param content the content value to set. + */ + @Generated + @JsonCreator + public PatientDocument(@JsonProperty(value = "type") DocumentType type, @JsonProperty(value = "id") String id, + @JsonProperty(value = "content") DocumentContent content) { + this.type = type; + this.id = id; + this.content = content; + } + + /** + * Get the type property: The type of the patient document, such as 'note' (text document) or 'fhirBundle' (FHIR + * JSON document). + * + * @return the type value. + */ + @Generated + public DocumentType getType() { + return this.type; + } + + /** + * Get the clinicalType property: The type of the clinical document. + * + * @return the clinicalType value. + */ + @Generated + public ClinicalDocumentType getClinicalType() { + return this.clinicalType; + } + + /** + * Set the clinicalType property: The type of the clinical document. + * + * @param clinicalType the clinicalType value to set. + * @return the PatientDocument object itself. + */ + @Generated + public PatientDocument setClinicalType(ClinicalDocumentType clinicalType) { + this.clinicalType = clinicalType; + return this; + } + + /** + * Get the id property: A given identifier for the document. Has to be unique across all documents for a single + * patient. + * + * @return the id value. + */ + @Generated + public String getId() { + return this.id; + } + + /** + * Get the language property: A 2 letter ISO 639-1 representation of the language of the document. + * + * @return the language value. + */ + @Generated + public String getLanguage() { + return this.language; + } + + /** + * Set the language property: A 2 letter ISO 639-1 representation of the language of the document. + * + * @param language the language value to set. + * @return the PatientDocument object itself. + */ + @Generated + public PatientDocument setLanguage(String language) { + this.language = language; + return this; + } + + /** + * Get the createdDateTime property: The date and time when the document was created. + * + * @return the createdDateTime value. + */ + @Generated + public OffsetDateTime getCreatedDateTime() { + return this.createdDateTime; + } + + /** + * Set the createdDateTime property: The date and time when the document was created. + * + * @param createdDateTime the createdDateTime value to set. + * @return the PatientDocument object itself. + */ + @Generated + public PatientDocument setCreatedDateTime(OffsetDateTime createdDateTime) { + this.createdDateTime = createdDateTime; + return this; + } + + /** + * Get the authors property: Document author(s). + * + * @return the authors value. + */ + @Generated + public List getAuthors() { + return this.authors; + } + + /** + * Set the authors property: Document author(s). + * + * @param authors the authors value to set. + * @return the PatientDocument object itself. + */ + @Generated + public PatientDocument setAuthors(List authors) { + this.authors = authors; + return this; + } + + /** + * Get the specialtyType property: specialty type the document. + * + * @return the specialtyType value. + */ + @Generated + public SpecialtyType getSpecialtyType() { + return this.specialtyType; + } + + /** + * Set the specialtyType property: specialty type the document. + * + * @param specialtyType the specialtyType value to set. + * @return the PatientDocument object itself. + */ + @Generated + public PatientDocument setSpecialtyType(SpecialtyType specialtyType) { + this.specialtyType = specialtyType; + return this; + } + + /** + * Get the administrativeMetadata property: Administrative metadata for the document. + * + * @return the administrativeMetadata value. + */ + @Generated + public DocumentAdministrativeMetadata getAdministrativeMetadata() { + return this.administrativeMetadata; + } + + /** + * Set the administrativeMetadata property: Administrative metadata for the document. + * + * @param administrativeMetadata the administrativeMetadata value to set. + * @return the PatientDocument object itself. + */ + @Generated + public PatientDocument setAdministrativeMetadata(DocumentAdministrativeMetadata administrativeMetadata) { + this.administrativeMetadata = administrativeMetadata; + return this; + } + + /** + * Get the content property: The content of the patient document. + * + * @return the content value. + */ + @Generated + public DocumentContent getContent() { + return this.content; + } +} diff --git a/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/PatientInfo.java b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/PatientInfo.java new file mode 100644 index 0000000000000..39252c0134305 --- /dev/null +++ b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/PatientInfo.java @@ -0,0 +1,111 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) TypeSpec Code Generator. + +package com.azure.health.insights.patienttimeline.models; + +import com.azure.core.annotation.Fluent; +import com.azure.core.annotation.Generated; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.time.LocalDate; +import java.util.List; + +/** + * Patient structured information, including demographics and known structured clinical information. + */ +@Fluent +public final class PatientInfo { + /* + * The patient's sex. + */ + @Generated + @JsonProperty(value = "sex") + private PatientInfoSex sex; + + /* + * The patient's date of birth. + */ + @Generated + @JsonProperty(value = "birthDate") + private LocalDate birthDate; + + /* + * Known clinical information for the patient, structured. + */ + @Generated + @JsonProperty(value = "clinicalInfo") + private List clinicalInfo; + + /** + * Creates an instance of PatientInfo class. + */ + @Generated + public PatientInfo() { + } + + /** + * Get the sex property: The patient's sex. + * + * @return the sex value. + */ + @Generated + public PatientInfoSex getSex() { + return this.sex; + } + + /** + * Set the sex property: The patient's sex. + * + * @param sex the sex value to set. + * @return the PatientInfo object itself. + */ + @Generated + public PatientInfo setSex(PatientInfoSex sex) { + this.sex = sex; + return this; + } + + /** + * Get the birthDate property: The patient's date of birth. + * + * @return the birthDate value. + */ + @Generated + public LocalDate getBirthDate() { + return this.birthDate; + } + + /** + * Set the birthDate property: The patient's date of birth. + * + * @param birthDate the birthDate value to set. + * @return the PatientInfo object itself. + */ + @Generated + public PatientInfo setBirthDate(LocalDate birthDate) { + this.birthDate = birthDate; + return this; + } + + /** + * Get the clinicalInfo property: Known clinical information for the patient, structured. + * + * @return the clinicalInfo value. + */ + @Generated + public List getClinicalInfo() { + return this.clinicalInfo; + } + + /** + * Set the clinicalInfo property: Known clinical information for the patient, structured. + * + * @param clinicalInfo the clinicalInfo value to set. + * @return the PatientInfo object itself. + */ + @Generated + public PatientInfo setClinicalInfo(List clinicalInfo) { + this.clinicalInfo = clinicalInfo; + return this; + } +} diff --git a/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/PatientInfoSex.java b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/PatientInfoSex.java new file mode 100644 index 0000000000000..44414a15b66db --- /dev/null +++ b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/PatientInfoSex.java @@ -0,0 +1,65 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) TypeSpec Code Generator. + +package com.azure.health.insights.patienttimeline.models; + +import com.azure.core.annotation.Generated; +import com.azure.core.util.ExpandableStringEnum; +import com.fasterxml.jackson.annotation.JsonCreator; +import java.util.Collection; + +/** + * The patient's sex. + */ +public final class PatientInfoSex extends ExpandableStringEnum { + /** + * Static value female for PatientInfoSex. + */ + @Generated + public static final PatientInfoSex FEMALE = fromString("female"); + + /** + * Static value male for PatientInfoSex. + */ + @Generated + public static final PatientInfoSex MALE = fromString("male"); + + /** + * Static value unspecified for PatientInfoSex. + */ + @Generated + public static final PatientInfoSex UNSPECIFIED = fromString("unspecified"); + + /** + * Creates a new instance of PatientInfoSex value. + * + * @deprecated Use the {@link #fromString(String)} factory method. + */ + @Generated + @Deprecated + public PatientInfoSex() { + } + + /** + * Creates or finds a PatientInfoSex from its string representation. + * + * @param name a name to look for. + * @return the corresponding PatientInfoSex. + */ + @Generated + @JsonCreator + public static PatientInfoSex fromString(String name) { + return fromString(name, PatientInfoSex.class); + } + + /** + * Gets known PatientInfoSex values. + * + * @return known PatientInfoSex values. + */ + @Generated + public static Collection values() { + return values(PatientInfoSex.class); + } +} diff --git a/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/PatientRecord.java b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/PatientRecord.java new file mode 100644 index 0000000000000..a3dc1077b35a0 --- /dev/null +++ b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/PatientRecord.java @@ -0,0 +1,135 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) TypeSpec Code Generator. + +package com.azure.health.insights.patienttimeline.models; + +import com.azure.core.annotation.Fluent; +import com.azure.core.annotation.Generated; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.util.List; + +/** + * A patient record, including their clinical information and data. + */ +@Fluent +public final class PatientRecord { + /* + * A given identifier for the patient. Has to be unique across all patients in a single request. + */ + @Generated + @JsonProperty(value = "id") + private String id; + + /* + * Patient structured information, including demographics and known structured clinical information. + */ + @Generated + @JsonProperty(value = "info") + private PatientInfo info; + + /* + * Patient encounters/visits. + */ + @Generated + @JsonProperty(value = "encounters") + private List encounters; + + /* + * Patient unstructured clinical data, given as documents. + */ + @Generated + @JsonProperty(value = "patientDocuments") + private List patientDocuments; + + /** + * Creates an instance of PatientRecord class. + * + * @param id the id value to set. + */ + @Generated + @JsonCreator + public PatientRecord(@JsonProperty(value = "id") String id) { + this.id = id; + } + + /** + * Get the id property: A given identifier for the patient. Has to be unique across all patients in a single + * request. + * + * @return the id value. + */ + @Generated + public String getId() { + return this.id; + } + + /** + * Get the info property: Patient structured information, including demographics and known structured clinical + * information. + * + * @return the info value. + */ + @Generated + public PatientInfo getInfo() { + return this.info; + } + + /** + * Set the info property: Patient structured information, including demographics and known structured clinical + * information. + * + * @param info the info value to set. + * @return the PatientRecord object itself. + */ + @Generated + public PatientRecord setInfo(PatientInfo info) { + this.info = info; + return this; + } + + /** + * Get the encounters property: Patient encounters/visits. + * + * @return the encounters value. + */ + @Generated + public List getEncounters() { + return this.encounters; + } + + /** + * Set the encounters property: Patient encounters/visits. + * + * @param encounters the encounters value to set. + * @return the PatientRecord object itself. + */ + @Generated + public PatientRecord setEncounters(List encounters) { + this.encounters = encounters; + return this; + } + + /** + * Get the patientDocuments property: Patient unstructured clinical data, given as documents. + * + * @return the patientDocuments value. + */ + @Generated + public List getPatientDocuments() { + return this.patientDocuments; + } + + /** + * Set the patientDocuments property: Patient unstructured clinical data, given as documents. + * + * @param patientDocuments the patientDocuments value to set. + * @return the PatientRecord object itself. + */ + @Generated + public PatientRecord setPatientDocuments(List patientDocuments) { + this.patientDocuments = patientDocuments; + return this; + } +} diff --git a/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/PatientTimelineData.java b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/PatientTimelineData.java new file mode 100644 index 0000000000000..a4eb9046414a4 --- /dev/null +++ b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/PatientTimelineData.java @@ -0,0 +1,74 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) TypeSpec Code Generator. + +package com.azure.health.insights.patienttimeline.models; + +import com.azure.core.annotation.Fluent; +import com.azure.core.annotation.Generated; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.util.List; + +/** + * The body of the Patient Timeline request. + */ +@Fluent +public final class PatientTimelineData { + /* + * The list of patients, including their clinical information and data. + */ + @Generated + @JsonProperty(value = "patients") + private List patients; + + /* + * Configuration affecting the Patient Timeline model's inference. + */ + @Generated + @JsonProperty(value = "configuration") + private PatientTimelineModelConfiguration configuration; + + /** + * Creates an instance of PatientTimelineData class. + * + * @param patients the patients value to set. + */ + @Generated + @JsonCreator + public PatientTimelineData(@JsonProperty(value = "patients") List patients) { + this.patients = patients; + } + + /** + * Get the patients property: The list of patients, including their clinical information and data. + * + * @return the patients value. + */ + @Generated + public List getPatients() { + return this.patients; + } + + /** + * Get the configuration property: Configuration affecting the Patient Timeline model's inference. + * + * @return the configuration value. + */ + @Generated + public PatientTimelineModelConfiguration getConfiguration() { + return this.configuration; + } + + /** + * Set the configuration property: Configuration affecting the Patient Timeline model's inference. + * + * @param configuration the configuration value to set. + * @return the PatientTimelineData object itself. + */ + @Generated + public PatientTimelineData setConfiguration(PatientTimelineModelConfiguration configuration) { + this.configuration = configuration; + return this; + } +} diff --git a/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/PatientTimelineInference.java b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/PatientTimelineInference.java new file mode 100644 index 0000000000000..7d2ff7381103c --- /dev/null +++ b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/PatientTimelineInference.java @@ -0,0 +1,119 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) TypeSpec Code Generator. + +package com.azure.health.insights.patienttimeline.models; + +import com.azure.core.annotation.Fluent; +import com.azure.core.annotation.Generated; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.util.List; + +/** + * An inference made by the Patient Timeline model regarding a patient. + */ +@Fluent +public final class PatientTimelineInference extends Extendible { + /* + * The type of the Patient Timeline inference. + */ + @Generated + @JsonProperty(value = "type") + private PatientTimelineInferenceType type; + + /* + * FHIR 4.0 representation of the piece of clinical info. + * additional dependent resources maybe contained (e.g. MedicationStatement may contain Medication) + * -- In the SDK we will have custom mapping to map this type to JsonObject + */ + @Generated + @JsonProperty(value = "resource") + private DomainResource resource; + + /* + * Time range relevant to this Timeline inference. + */ + @Generated + @JsonProperty(value = "period") + private TimePeriod period; + + /** + * Creates an instance of PatientTimelineInference class. + * + * @param type the type value to set. + */ + @Generated + @JsonCreator + public PatientTimelineInference(@JsonProperty(value = "type") PatientTimelineInferenceType type) { + this.type = type; + } + + /** + * Get the type property: The type of the Patient Timeline inference. + * + * @return the type value. + */ + @Generated + public PatientTimelineInferenceType getType() { + return this.type; + } + + /** + * Get the resource property: FHIR 4.0 representation of the piece of clinical info. + * additional dependent resources maybe contained (e.g. MedicationStatement may contain Medication) + * -- In the SDK we will have custom mapping to map this type to JsonObject. + * + * @return the resource value. + */ + @Generated + public DomainResource getResource() { + return this.resource; + } + + /** + * Set the resource property: FHIR 4.0 representation of the piece of clinical info. + * additional dependent resources maybe contained (e.g. MedicationStatement may contain Medication) + * -- In the SDK we will have custom mapping to map this type to JsonObject. + * + * @param resource the resource value to set. + * @return the PatientTimelineInference object itself. + */ + @Generated + public PatientTimelineInference setResource(DomainResource resource) { + this.resource = resource; + return this; + } + + /** + * Get the period property: Time range relevant to this Timeline inference. + * + * @return the period value. + */ + @Generated + public TimePeriod getPeriod() { + return this.period; + } + + /** + * Set the period property: Time range relevant to this Timeline inference. + * + * @param period the period value to set. + * @return the PatientTimelineInference object itself. + */ + @Generated + public PatientTimelineInference setPeriod(TimePeriod period) { + this.period = period; + return this; + } + + /** + * {@inheritDoc} + */ + @Generated + @Override + public PatientTimelineInference setExtension(List extension) { + super.setExtension(extension); + return this; + } +} diff --git a/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/PatientTimelineInferenceResult.java b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/PatientTimelineInferenceResult.java new file mode 100644 index 0000000000000..2f136ee07d91c --- /dev/null +++ b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/PatientTimelineInferenceResult.java @@ -0,0 +1,66 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) TypeSpec Code Generator. + +package com.azure.health.insights.patienttimeline.models; + +import com.azure.core.annotation.Generated; +import com.azure.core.annotation.Immutable; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.util.List; + +/** + * The inference results for the Patient Timeline request. + */ +@Immutable +public final class PatientTimelineInferenceResult { + /* + * Results for the patients given in the request. + */ + @Generated + @JsonProperty(value = "patientResults") + private List patientResults; + + /* + * The version of the model used for inference, expressed as the model date. + */ + @Generated + @JsonProperty(value = "modelVersion") + private String modelVersion; + + /** + * Creates an instance of PatientTimelineInferenceResult class. + * + * @param patientResults the patientResults value to set. + * @param modelVersion the modelVersion value to set. + */ + @Generated + @JsonCreator + private PatientTimelineInferenceResult( + @JsonProperty(value = "patientResults") List patientResults, + @JsonProperty(value = "modelVersion") String modelVersion) { + this.patientResults = patientResults; + this.modelVersion = modelVersion; + } + + /** + * Get the patientResults property: Results for the patients given in the request. + * + * @return the patientResults value. + */ + @Generated + public List getPatientResults() { + return this.patientResults; + } + + /** + * Get the modelVersion property: The version of the model used for inference, expressed as the model date. + * + * @return the modelVersion value. + */ + @Generated + public String getModelVersion() { + return this.modelVersion; + } +} diff --git a/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/PatientTimelineInferenceType.java b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/PatientTimelineInferenceType.java new file mode 100644 index 0000000000000..f0adfe94753ec --- /dev/null +++ b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/PatientTimelineInferenceType.java @@ -0,0 +1,59 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) TypeSpec Code Generator. + +package com.azure.health.insights.patienttimeline.models; + +import com.azure.core.annotation.Generated; +import com.azure.core.util.ExpandableStringEnum; +import com.fasterxml.jackson.annotation.JsonCreator; +import java.util.Collection; + +/** + * The type of the Patient Timeline inference. + */ +public final class PatientTimelineInferenceType extends ExpandableStringEnum { + /** + * The inference is a timeline event. + */ + @Generated + public static final PatientTimelineInferenceType TIMELINE_EVENT = fromString("timelineEvent"); + + /** + * The inference is a summary item. + */ + @Generated + public static final PatientTimelineInferenceType SUMMARY_ITEM = fromString("summaryItem"); + + /** + * Creates a new instance of PatientTimelineInferenceType value. + * + * @deprecated Use the {@link #fromString(String)} factory method. + */ + @Generated + @Deprecated + public PatientTimelineInferenceType() { + } + + /** + * Creates or finds a PatientTimelineInferenceType from its string representation. + * + * @param name a name to look for. + * @return the corresponding PatientTimelineInferenceType. + */ + @Generated + @JsonCreator + public static PatientTimelineInferenceType fromString(String name) { + return fromString(name, PatientTimelineInferenceType.class); + } + + /** + * Gets known PatientTimelineInferenceType values. + * + * @return known PatientTimelineInferenceType values. + */ + @Generated + public static Collection values() { + return values(PatientTimelineInferenceType.class); + } +} diff --git a/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/PatientTimelineModelConfiguration.java b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/PatientTimelineModelConfiguration.java new file mode 100644 index 0000000000000..9ce20582da125 --- /dev/null +++ b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/PatientTimelineModelConfiguration.java @@ -0,0 +1,82 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) TypeSpec Code Generator. + +package com.azure.health.insights.patienttimeline.models; + +import com.azure.core.annotation.Fluent; +import com.azure.core.annotation.Generated; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * Configuration affecting the Patient Timeline model's inference. + */ +@Fluent +public final class PatientTimelineModelConfiguration { + /* + * An indication whether the model should produce verbose output. + */ + @Generated + @JsonProperty(value = "verbose") + private Boolean verbose; + + /* + * An indication whether the model's output should include evidence for the inferences. + */ + @Generated + @JsonProperty(value = "includeEvidence") + private Boolean includeEvidence; + + /** + * Creates an instance of PatientTimelineModelConfiguration class. + */ + @Generated + public PatientTimelineModelConfiguration() { + } + + /** + * Get the verbose property: An indication whether the model should produce verbose output. + * + * @return the verbose value. + */ + @Generated + public Boolean isVerbose() { + return this.verbose; + } + + /** + * Set the verbose property: An indication whether the model should produce verbose output. + * + * @param verbose the verbose value to set. + * @return the PatientTimelineModelConfiguration object itself. + */ + @Generated + public PatientTimelineModelConfiguration setVerbose(Boolean verbose) { + this.verbose = verbose; + return this; + } + + /** + * Get the includeEvidence property: An indication whether the model's output should include evidence for the + * inferences. + * + * @return the includeEvidence value. + */ + @Generated + public Boolean isIncludeEvidence() { + return this.includeEvidence; + } + + /** + * Set the includeEvidence property: An indication whether the model's output should include evidence for the + * inferences. + * + * @param includeEvidence the includeEvidence value to set. + * @return the PatientTimelineModelConfiguration object itself. + */ + @Generated + public PatientTimelineModelConfiguration setIncludeEvidence(Boolean includeEvidence) { + this.includeEvidence = includeEvidence; + return this; + } +} diff --git a/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/PatientTimelinePatientResult.java b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/PatientTimelinePatientResult.java new file mode 100644 index 0000000000000..4a3a3c31e17db --- /dev/null +++ b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/PatientTimelinePatientResult.java @@ -0,0 +1,65 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) TypeSpec Code Generator. + +package com.azure.health.insights.patienttimeline.models; + +import com.azure.core.annotation.Generated; +import com.azure.core.annotation.Immutable; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.util.List; + +/** + * The results of the model's work for a single patient. + */ +@Immutable +public final class PatientTimelinePatientResult { + /* + * The identifier given for the patient in the request. + */ + @Generated + @JsonProperty(value = "patientId") + private String patientId; + + /* + * The model's inferences for the given patient. + */ + @Generated + @JsonProperty(value = "inferences") + private List inferences; + + /** + * Creates an instance of PatientTimelinePatientResult class. + * + * @param patientId the patientId value to set. + * @param inferences the inferences value to set. + */ + @Generated + @JsonCreator + private PatientTimelinePatientResult(@JsonProperty(value = "patientId") String patientId, + @JsonProperty(value = "inferences") List inferences) { + this.patientId = patientId; + this.inferences = inferences; + } + + /** + * Get the patientId property: The identifier given for the patient in the request. + * + * @return the patientId value. + */ + @Generated + public String getPatientId() { + return this.patientId; + } + + /** + * Get the inferences property: The model's inferences for the given patient. + * + * @return the inferences value. + */ + @Generated + public List getInferences() { + return this.inferences; + } +} diff --git a/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/PeriodModel.java b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/PeriodModel.java new file mode 100644 index 0000000000000..70e6adca0dfb0 --- /dev/null +++ b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/PeriodModel.java @@ -0,0 +1,102 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) TypeSpec Code Generator. + +package com.azure.health.insights.patienttimeline.models; + +import com.azure.core.annotation.Fluent; +import com.azure.core.annotation.Generated; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.util.List; + +/** + * A time period defined by a start and end date and optionally time + * Based on [FHIR Period](https://www.hl7.org/fhir/R4/datatypes.html#Period). + */ +@Fluent +public final class PeriodModel extends Element { + /* + * Starting time with inclusive boundary + */ + @Generated + @JsonProperty(value = "start") + private String start; + + /* + * End time with inclusive boundary, if not ongoing + */ + @Generated + @JsonProperty(value = "end") + private String end; + + /** + * Creates an instance of PeriodModel class. + */ + @Generated + public PeriodModel() { + } + + /** + * Get the start property: Starting time with inclusive boundary. + * + * @return the start value. + */ + @Generated + public String getStart() { + return this.start; + } + + /** + * Set the start property: Starting time with inclusive boundary. + * + * @param start the start value to set. + * @return the PeriodModel object itself. + */ + @Generated + public PeriodModel setStart(String start) { + this.start = start; + return this; + } + + /** + * Get the end property: End time with inclusive boundary, if not ongoing. + * + * @return the end value. + */ + @Generated + public String getEnd() { + return this.end; + } + + /** + * Set the end property: End time with inclusive boundary, if not ongoing. + * + * @param end the end value to set. + * @return the PeriodModel object itself. + */ + @Generated + public PeriodModel setEnd(String end) { + this.end = end; + return this; + } + + /** + * {@inheritDoc} + */ + @Generated + @Override + public PeriodModel setId(String id) { + super.setId(id); + return this; + } + + /** + * {@inheritDoc} + */ + @Generated + @Override + public PeriodModel setExtension(List extension) { + super.setExtension(extension); + return this; + } +} diff --git a/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/Quantity.java b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/Quantity.java new file mode 100644 index 0000000000000..219a8a2ad5d29 --- /dev/null +++ b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/Quantity.java @@ -0,0 +1,190 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) TypeSpec Code Generator. + +package com.azure.health.insights.patienttimeline.models; + +import com.azure.core.annotation.Fluent; +import com.azure.core.annotation.Generated; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.math.BigDecimal; +import java.util.List; + +/** + * A measured or measurable amount + * Based on [FHIR Quantity](https://www.hl7.org/fhir/R4/datatypes.html#Quantity). + */ +@Fluent +public final class Quantity extends Element { + /* + * Numerical value (with implicit precision) + */ + @Generated + @JsonProperty(value = "value") + private BigDecimal value; + + /* + * < | <= | >= | > - how to understand the value + */ + @Generated + @JsonProperty(value = "comparator") + private String comparator; + + /* + * Unit representation + */ + @Generated + @JsonProperty(value = "unit") + private String unit; + + /* + * System that defines coded unit form + */ + @Generated + @JsonProperty(value = "system") + private String system; + + /* + * Coded form of the unit + */ + @Generated + @JsonProperty(value = "code") + private String code; + + /** + * Creates an instance of Quantity class. + */ + @Generated + public Quantity() { + } + + /** + * Get the value property: Numerical value (with implicit precision). + * + * @return the value value. + */ + @Generated + public BigDecimal getValue() { + return this.value; + } + + /** + * Set the value property: Numerical value (with implicit precision). + * + * @param value the value value to set. + * @return the Quantity object itself. + */ + @Generated + public Quantity setValue(BigDecimal value) { + this.value = value; + return this; + } + + /** + * Get the comparator property: < | <= | >= | > - how to understand the value. + * + * @return the comparator value. + */ + @Generated + public String getComparator() { + return this.comparator; + } + + /** + * Set the comparator property: < | <= | >= | > - how to understand the value. + * + * @param comparator the comparator value to set. + * @return the Quantity object itself. + */ + @Generated + public Quantity setComparator(String comparator) { + this.comparator = comparator; + return this; + } + + /** + * Get the unit property: Unit representation. + * + * @return the unit value. + */ + @Generated + public String getUnit() { + return this.unit; + } + + /** + * Set the unit property: Unit representation. + * + * @param unit the unit value to set. + * @return the Quantity object itself. + */ + @Generated + public Quantity setUnit(String unit) { + this.unit = unit; + return this; + } + + /** + * Get the system property: System that defines coded unit form. + * + * @return the system value. + */ + @Generated + public String getSystem() { + return this.system; + } + + /** + * Set the system property: System that defines coded unit form. + * + * @param system the system value to set. + * @return the Quantity object itself. + */ + @Generated + public Quantity setSystem(String system) { + this.system = system; + return this; + } + + /** + * Get the code property: Coded form of the unit. + * + * @return the code value. + */ + @Generated + public String getCode() { + return this.code; + } + + /** + * Set the code property: Coded form of the unit. + * + * @param code the code value to set. + * @return the Quantity object itself. + */ + @Generated + public Quantity setCode(String code) { + this.code = code; + return this; + } + + /** + * {@inheritDoc} + */ + @Generated + @Override + public Quantity setId(String id) { + super.setId(id); + return this; + } + + /** + * {@inheritDoc} + */ + @Generated + @Override + public Quantity setExtension(List extension) { + super.setExtension(extension); + return this; + } +} diff --git a/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/Range.java b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/Range.java new file mode 100644 index 0000000000000..968820f11b7d4 --- /dev/null +++ b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/Range.java @@ -0,0 +1,102 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) TypeSpec Code Generator. + +package com.azure.health.insights.patienttimeline.models; + +import com.azure.core.annotation.Fluent; +import com.azure.core.annotation.Generated; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.util.List; + +/** + * A set of ordered Quantities defined by a low and high limit + * Based on [FHIR Range](https://www.hl7.org/fhir/R4/datatypes.html#Range). + */ +@Fluent +public final class Range extends Element { + /* + * Low limit + */ + @Generated + @JsonProperty(value = "low") + private Quantity low; + + /* + * High limit + */ + @Generated + @JsonProperty(value = "high") + private Quantity high; + + /** + * Creates an instance of Range class. + */ + @Generated + public Range() { + } + + /** + * Get the low property: Low limit. + * + * @return the low value. + */ + @Generated + public Quantity getLow() { + return this.low; + } + + /** + * Set the low property: Low limit. + * + * @param low the low value to set. + * @return the Range object itself. + */ + @Generated + public Range setLow(Quantity low) { + this.low = low; + return this; + } + + /** + * Get the high property: High limit. + * + * @return the high value. + */ + @Generated + public Quantity getHigh() { + return this.high; + } + + /** + * Set the high property: High limit. + * + * @param high the high value to set. + * @return the Range object itself. + */ + @Generated + public Range setHigh(Quantity high) { + this.high = high; + return this; + } + + /** + * {@inheritDoc} + */ + @Generated + @Override + public Range setId(String id) { + super.setId(id); + return this; + } + + /** + * {@inheritDoc} + */ + @Generated + @Override + public Range setExtension(List extension) { + super.setExtension(extension); + return this; + } +} diff --git a/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/Ratio.java b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/Ratio.java new file mode 100644 index 0000000000000..9228b9e385b09 --- /dev/null +++ b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/Ratio.java @@ -0,0 +1,102 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) TypeSpec Code Generator. + +package com.azure.health.insights.patienttimeline.models; + +import com.azure.core.annotation.Fluent; +import com.azure.core.annotation.Generated; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.util.List; + +/** + * A ratio of two Quantity values - a numerator and a denominator + * Based on [FHIR Ratio](https://www.hl7.org/fhir/R4/datatypes.html#Ratio). + */ +@Fluent +public final class Ratio extends Element { + /* + * Numerator value + */ + @Generated + @JsonProperty(value = "numerator") + private Quantity numerator; + + /* + * Denominator value + */ + @Generated + @JsonProperty(value = "denominator") + private Quantity denominator; + + /** + * Creates an instance of Ratio class. + */ + @Generated + public Ratio() { + } + + /** + * Get the numerator property: Numerator value. + * + * @return the numerator value. + */ + @Generated + public Quantity getNumerator() { + return this.numerator; + } + + /** + * Set the numerator property: Numerator value. + * + * @param numerator the numerator value to set. + * @return the Ratio object itself. + */ + @Generated + public Ratio setNumerator(Quantity numerator) { + this.numerator = numerator; + return this; + } + + /** + * Get the denominator property: Denominator value. + * + * @return the denominator value. + */ + @Generated + public Quantity getDenominator() { + return this.denominator; + } + + /** + * Set the denominator property: Denominator value. + * + * @param denominator the denominator value to set. + * @return the Ratio object itself. + */ + @Generated + public Ratio setDenominator(Quantity denominator) { + this.denominator = denominator; + return this; + } + + /** + * {@inheritDoc} + */ + @Generated + @Override + public Ratio setId(String id) { + super.setId(id); + return this; + } + + /** + * {@inheritDoc} + */ + @Generated + @Override + public Ratio setExtension(List extension) { + super.setExtension(extension); + return this; + } +} diff --git a/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/Reference.java b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/Reference.java new file mode 100644 index 0000000000000..d6622d109b542 --- /dev/null +++ b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/Reference.java @@ -0,0 +1,160 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) TypeSpec Code Generator. + +package com.azure.health.insights.patienttimeline.models; + +import com.azure.core.annotation.Fluent; +import com.azure.core.annotation.Generated; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.util.List; + +/** + * A reference from one resource to another + * Based on [FHIR Reference](https://www.hl7.org/fhir/R4/references.html). + */ +@Fluent +public final class Reference extends Element { + /* + * Literal reference, Relative, internal or absolute URL + */ + @Generated + @JsonProperty(value = "reference") + private String reference; + + /* + * Type the reference refers to (e.g. "Patient") + */ + @Generated + @JsonProperty(value = "type") + private String type; + + /* + * Logical reference, when literal reference is not known + */ + @Generated + @JsonProperty(value = "identifier") + private Identifier identifier; + + /* + * Text alternative for the resource + */ + @Generated + @JsonProperty(value = "display") + private String display; + + /** + * Creates an instance of Reference class. + */ + @Generated + public Reference() { + } + + /** + * Get the reference property: Literal reference, Relative, internal or absolute URL. + * + * @return the reference value. + */ + @Generated + public String getReference() { + return this.reference; + } + + /** + * Set the reference property: Literal reference, Relative, internal or absolute URL. + * + * @param reference the reference value to set. + * @return the Reference object itself. + */ + @Generated + public Reference setReference(String reference) { + this.reference = reference; + return this; + } + + /** + * Get the type property: Type the reference refers to (e.g. "Patient"). + * + * @return the type value. + */ + @Generated + public String getType() { + return this.type; + } + + /** + * Set the type property: Type the reference refers to (e.g. "Patient"). + * + * @param type the type value to set. + * @return the Reference object itself. + */ + @Generated + public Reference setType(String type) { + this.type = type; + return this; + } + + /** + * Get the identifier property: Logical reference, when literal reference is not known. + * + * @return the identifier value. + */ + @Generated + public Identifier getIdentifier() { + return this.identifier; + } + + /** + * Set the identifier property: Logical reference, when literal reference is not known. + * + * @param identifier the identifier value to set. + * @return the Reference object itself. + */ + @Generated + public Reference setIdentifier(Identifier identifier) { + this.identifier = identifier; + return this; + } + + /** + * Get the display property: Text alternative for the resource. + * + * @return the display value. + */ + @Generated + public String getDisplay() { + return this.display; + } + + /** + * Set the display property: Text alternative for the resource. + * + * @param display the display value to set. + * @return the Reference object itself. + */ + @Generated + public Reference setDisplay(String display) { + this.display = display; + return this; + } + + /** + * {@inheritDoc} + */ + @Generated + @Override + public Reference setId(String id) { + super.setId(id); + return this; + } + + /** + * {@inheritDoc} + */ + @Generated + @Override + public Reference setExtension(List extension) { + super.setExtension(extension); + return this; + } +} diff --git a/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/ResearchStudy.java b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/ResearchStudy.java new file mode 100644 index 0000000000000..1389920ec8f81 --- /dev/null +++ b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/ResearchStudy.java @@ -0,0 +1,741 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) TypeSpec Code Generator. + +package com.azure.health.insights.patienttimeline.models; + +import com.azure.core.annotation.Fluent; +import com.azure.core.annotation.Generated; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonTypeInfo; +import com.fasterxml.jackson.annotation.JsonTypeName; +import java.util.List; +import java.util.Map; + +/** + * Detailed information about Research Study + * Based on [FHIR ResearchStudy](https://www.hl7.org/fhir/R4/researchstudy.html). + */ +@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "resourceType") +@JsonTypeName("ResearchStudy") +@Fluent +public final class ResearchStudy extends DomainResource { + /* + * Business Identifier for study + */ + @Generated + @JsonProperty(value = "identifier") + private List identifier; + + /* + * Name for this study + */ + @Generated + @JsonProperty(value = "title") + private String title; + + /* + * Steps followed in executing study + */ + @Generated + @JsonProperty(value = "protocol") + private List protocol; + + /* + * Part of larger study + */ + @Generated + @JsonProperty(value = "partOf") + private List partOf; + + /* + * active | administratively-completed | approved | closed-to-accrual | closed-to-accrual-and-intervention | + * completed | disapproved | in-review | temporarily-closed-to-accrual | + * temporarily-closed-to-accrual-and-intervention | withdrawn + */ + @Generated + @JsonProperty(value = "status") + private ResearchStudyStatusCodeType status; + + /* + * treatment | prevention | diagnostic | supportive-care | screening | health-services-research | basic-science | + * device-feasibility + */ + @Generated + @JsonProperty(value = "primaryPurposeType") + private CodeableConcept primaryPurposeType; + + /* + * n-a | early-phase-1 | phase-1 | phase-1-phase-2 | phase-2 | phase-2-phase-3 | phase-3 | phase-4 + */ + @Generated + @JsonProperty(value = "phase") + private CodeableConcept phase; + + /* + * Classifications for the study + */ + @Generated + @JsonProperty(value = "category") + private List category; + + /* + * Drugs, devices, etc. under study + */ + @Generated + @JsonProperty(value = "focus") + private List focus; + + /* + * Condition being studied + */ + @Generated + @JsonProperty(value = "condition") + private List condition; + + /* + * Contact details for the study + */ + @Generated + @JsonProperty(value = "contact") + private List contact; + + /* + * Used to search for the study + */ + @Generated + @JsonProperty(value = "keyword") + private List keyword; + + /* + * Geographic region(s) for study + */ + @Generated + @JsonProperty(value = "location") + private List location; + + /* + * What this is study doing + */ + @Generated + @JsonProperty(value = "description") + private String description; + + /* + * Inclusion & exclusion criteria + */ + @Generated + @JsonProperty(value = "enrollment") + private List enrollment; + + /* + * When the study began and ended + */ + @Generated + @JsonProperty(value = "period") + private PeriodModel period; + + /* + * Organization that initiates and is legally responsible for the study + */ + @Generated + @JsonProperty(value = "sponsor") + private Reference sponsor; + + /* + * Researcher who oversees multiple aspects of the study + */ + @Generated + @JsonProperty(value = "principalInvestigator") + private Reference principalInvestigator; + + /* + * Facility where study activities are conducted + */ + @Generated + @JsonProperty(value = "site") + private List site; + + /* + * accrual-goal-met | closed-due-to-toxicity | closed-due-to-lack-of-study-progress | + * temporarily-closed-per-study-design + */ + @Generated + @JsonProperty(value = "reasonStopped") + private CodeableConcept reasonStopped; + + /* + * Comments made about the study + */ + @Generated + @JsonProperty(value = "note") + private List note; + + /* + * Defined path through the study for a subject + */ + @Generated + @JsonProperty(value = "arm") + private List arm; + + /* + * A goal for the study + */ + @Generated + @JsonProperty(value = "objective") + private List objective; + + /** + * Creates an instance of ResearchStudy class. + * + * @param status the status value to set. + */ + @Generated + @JsonCreator + public ResearchStudy(@JsonProperty(value = "status") ResearchStudyStatusCodeType status) { + this.status = status; + } + + /** + * Get the identifier property: Business Identifier for study. + * + * @return the identifier value. + */ + @Generated + public List getIdentifier() { + return this.identifier; + } + + /** + * Set the identifier property: Business Identifier for study. + * + * @param identifier the identifier value to set. + * @return the ResearchStudy object itself. + */ + @Generated + public ResearchStudy setIdentifier(List identifier) { + this.identifier = identifier; + return this; + } + + /** + * Get the title property: Name for this study. + * + * @return the title value. + */ + @Generated + public String getTitle() { + return this.title; + } + + /** + * Set the title property: Name for this study. + * + * @param title the title value to set. + * @return the ResearchStudy object itself. + */ + @Generated + public ResearchStudy setTitle(String title) { + this.title = title; + return this; + } + + /** + * Get the protocol property: Steps followed in executing study. + * + * @return the protocol value. + */ + @Generated + public List getProtocol() { + return this.protocol; + } + + /** + * Set the protocol property: Steps followed in executing study. + * + * @param protocol the protocol value to set. + * @return the ResearchStudy object itself. + */ + @Generated + public ResearchStudy setProtocol(List protocol) { + this.protocol = protocol; + return this; + } + + /** + * Get the partOf property: Part of larger study. + * + * @return the partOf value. + */ + @Generated + public List getPartOf() { + return this.partOf; + } + + /** + * Set the partOf property: Part of larger study. + * + * @param partOf the partOf value to set. + * @return the ResearchStudy object itself. + */ + @Generated + public ResearchStudy setPartOf(List partOf) { + this.partOf = partOf; + return this; + } + + /** + * Get the status property: active | administratively-completed | approved | closed-to-accrual | + * closed-to-accrual-and-intervention | completed | disapproved | in-review | temporarily-closed-to-accrual | + * temporarily-closed-to-accrual-and-intervention | withdrawn. + * + * @return the status value. + */ + @Generated + public ResearchStudyStatusCodeType getStatus() { + return this.status; + } + + /** + * Get the primaryPurposeType property: treatment | prevention | diagnostic | supportive-care | screening | + * health-services-research | basic-science | device-feasibility. + * + * @return the primaryPurposeType value. + */ + @Generated + public CodeableConcept getPrimaryPurposeType() { + return this.primaryPurposeType; + } + + /** + * Set the primaryPurposeType property: treatment | prevention | diagnostic | supportive-care | screening | + * health-services-research | basic-science | device-feasibility. + * + * @param primaryPurposeType the primaryPurposeType value to set. + * @return the ResearchStudy object itself. + */ + @Generated + public ResearchStudy setPrimaryPurposeType(CodeableConcept primaryPurposeType) { + this.primaryPurposeType = primaryPurposeType; + return this; + } + + /** + * Get the phase property: n-a | early-phase-1 | phase-1 | phase-1-phase-2 | phase-2 | phase-2-phase-3 | phase-3 | + * phase-4. + * + * @return the phase value. + */ + @Generated + public CodeableConcept getPhase() { + return this.phase; + } + + /** + * Set the phase property: n-a | early-phase-1 | phase-1 | phase-1-phase-2 | phase-2 | phase-2-phase-3 | phase-3 | + * phase-4. + * + * @param phase the phase value to set. + * @return the ResearchStudy object itself. + */ + @Generated + public ResearchStudy setPhase(CodeableConcept phase) { + this.phase = phase; + return this; + } + + /** + * Get the category property: Classifications for the study. + * + * @return the category value. + */ + @Generated + public List getCategory() { + return this.category; + } + + /** + * Set the category property: Classifications for the study. + * + * @param category the category value to set. + * @return the ResearchStudy object itself. + */ + @Generated + public ResearchStudy setCategory(List category) { + this.category = category; + return this; + } + + /** + * Get the focus property: Drugs, devices, etc. under study. + * + * @return the focus value. + */ + @Generated + public List getFocus() { + return this.focus; + } + + /** + * Set the focus property: Drugs, devices, etc. under study. + * + * @param focus the focus value to set. + * @return the ResearchStudy object itself. + */ + @Generated + public ResearchStudy setFocus(List focus) { + this.focus = focus; + return this; + } + + /** + * Get the condition property: Condition being studied. + * + * @return the condition value. + */ + @Generated + public List getCondition() { + return this.condition; + } + + /** + * Set the condition property: Condition being studied. + * + * @param condition the condition value to set. + * @return the ResearchStudy object itself. + */ + @Generated + public ResearchStudy setCondition(List condition) { + this.condition = condition; + return this; + } + + /** + * Get the contact property: Contact details for the study. + * + * @return the contact value. + */ + @Generated + public List getContact() { + return this.contact; + } + + /** + * Set the contact property: Contact details for the study. + * + * @param contact the contact value to set. + * @return the ResearchStudy object itself. + */ + @Generated + public ResearchStudy setContact(List contact) { + this.contact = contact; + return this; + } + + /** + * Get the keyword property: Used to search for the study. + * + * @return the keyword value. + */ + @Generated + public List getKeyword() { + return this.keyword; + } + + /** + * Set the keyword property: Used to search for the study. + * + * @param keyword the keyword value to set. + * @return the ResearchStudy object itself. + */ + @Generated + public ResearchStudy setKeyword(List keyword) { + this.keyword = keyword; + return this; + } + + /** + * Get the location property: Geographic region(s) for study. + * + * @return the location value. + */ + @Generated + public List getLocation() { + return this.location; + } + + /** + * Set the location property: Geographic region(s) for study. + * + * @param location the location value to set. + * @return the ResearchStudy object itself. + */ + @Generated + public ResearchStudy setLocation(List location) { + this.location = location; + return this; + } + + /** + * Get the description property: What this is study doing. + * + * @return the description value. + */ + @Generated + public String getDescription() { + return this.description; + } + + /** + * Set the description property: What this is study doing. + * + * @param description the description value to set. + * @return the ResearchStudy object itself. + */ + @Generated + public ResearchStudy setDescription(String description) { + this.description = description; + return this; + } + + /** + * Get the enrollment property: Inclusion & exclusion criteria. + * + * @return the enrollment value. + */ + @Generated + public List getEnrollment() { + return this.enrollment; + } + + /** + * Set the enrollment property: Inclusion & exclusion criteria. + * + * @param enrollment the enrollment value to set. + * @return the ResearchStudy object itself. + */ + @Generated + public ResearchStudy setEnrollment(List enrollment) { + this.enrollment = enrollment; + return this; + } + + /** + * Get the period property: When the study began and ended. + * + * @return the period value. + */ + @Generated + public PeriodModel getPeriod() { + return this.period; + } + + /** + * Set the period property: When the study began and ended. + * + * @param period the period value to set. + * @return the ResearchStudy object itself. + */ + @Generated + public ResearchStudy setPeriod(PeriodModel period) { + this.period = period; + return this; + } + + /** + * Get the sponsor property: Organization that initiates and is legally responsible for the study. + * + * @return the sponsor value. + */ + @Generated + public Reference getSponsor() { + return this.sponsor; + } + + /** + * Set the sponsor property: Organization that initiates and is legally responsible for the study. + * + * @param sponsor the sponsor value to set. + * @return the ResearchStudy object itself. + */ + @Generated + public ResearchStudy setSponsor(Reference sponsor) { + this.sponsor = sponsor; + return this; + } + + /** + * Get the principalInvestigator property: Researcher who oversees multiple aspects of the study. + * + * @return the principalInvestigator value. + */ + @Generated + public Reference getPrincipalInvestigator() { + return this.principalInvestigator; + } + + /** + * Set the principalInvestigator property: Researcher who oversees multiple aspects of the study. + * + * @param principalInvestigator the principalInvestigator value to set. + * @return the ResearchStudy object itself. + */ + @Generated + public ResearchStudy setPrincipalInvestigator(Reference principalInvestigator) { + this.principalInvestigator = principalInvestigator; + return this; + } + + /** + * Get the site property: Facility where study activities are conducted. + * + * @return the site value. + */ + @Generated + public List getSite() { + return this.site; + } + + /** + * Set the site property: Facility where study activities are conducted. + * + * @param site the site value to set. + * @return the ResearchStudy object itself. + */ + @Generated + public ResearchStudy setSite(List site) { + this.site = site; + return this; + } + + /** + * Get the reasonStopped property: accrual-goal-met | closed-due-to-toxicity | closed-due-to-lack-of-study-progress + * | temporarily-closed-per-study-design. + * + * @return the reasonStopped value. + */ + @Generated + public CodeableConcept getReasonStopped() { + return this.reasonStopped; + } + + /** + * Set the reasonStopped property: accrual-goal-met | closed-due-to-toxicity | closed-due-to-lack-of-study-progress + * | temporarily-closed-per-study-design. + * + * @param reasonStopped the reasonStopped value to set. + * @return the ResearchStudy object itself. + */ + @Generated + public ResearchStudy setReasonStopped(CodeableConcept reasonStopped) { + this.reasonStopped = reasonStopped; + return this; + } + + /** + * Get the note property: Comments made about the study. + * + * @return the note value. + */ + @Generated + public List getNote() { + return this.note; + } + + /** + * Set the note property: Comments made about the study. + * + * @param note the note value to set. + * @return the ResearchStudy object itself. + */ + @Generated + public ResearchStudy setNote(List note) { + this.note = note; + return this; + } + + /** + * Get the arm property: Defined path through the study for a subject. + * + * @return the arm value. + */ + @Generated + public List getArm() { + return this.arm; + } + + /** + * Set the arm property: Defined path through the study for a subject. + * + * @param arm the arm value to set. + * @return the ResearchStudy object itself. + */ + @Generated + public ResearchStudy setArm(List arm) { + this.arm = arm; + return this; + } + + /** + * Get the objective property: A goal for the study. + * + * @return the objective value. + */ + @Generated + public List getObjective() { + return this.objective; + } + + /** + * Set the objective property: A goal for the study. + * + * @param objective the objective value to set. + * @return the ResearchStudy object itself. + */ + @Generated + public ResearchStudy setObjective(List objective) { + this.objective = objective; + return this; + } + + /** + * {@inheritDoc} + */ + @Generated + @Override + public ResearchStudy setText(Narrative text) { + super.setText(text); + return this; + } + + /** + * {@inheritDoc} + */ + @Generated + @Override + public ResearchStudy setContained(List> contained) { + super.setContained(contained); + return this; + } + + /** + * {@inheritDoc} + */ + @Generated + @Override + public ResearchStudy setExtension(List extension) { + super.setExtension(extension); + return this; + } + + /** + * {@inheritDoc} + */ + @Generated + @Override + public ResearchStudy setModifierExtension(List modifierExtension) { + super.setModifierExtension(modifierExtension); + return this; + } +} diff --git a/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/ResearchStudyArm.java b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/ResearchStudyArm.java new file mode 100644 index 0000000000000..d6c7702f3a4d0 --- /dev/null +++ b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/ResearchStudyArm.java @@ -0,0 +1,102 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) TypeSpec Code Generator. + +package com.azure.health.insights.patienttimeline.models; + +import com.azure.core.annotation.Fluent; +import com.azure.core.annotation.Generated; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The ResearchStudyArm model. + */ +@Fluent +public final class ResearchStudyArm { + /* + * Label for study arm + */ + @Generated + @JsonProperty(value = "name") + private String name; + + /* + * Categorization of study arm + */ + @Generated + @JsonProperty(value = "type") + private CodeableConcept type; + + /* + * Short explanation of study path + */ + @Generated + @JsonProperty(value = "description") + private String description; + + /** + * Creates an instance of ResearchStudyArm class. + * + * @param name the name value to set. + */ + @Generated + @JsonCreator + public ResearchStudyArm(@JsonProperty(value = "name") String name) { + this.name = name; + } + + /** + * Get the name property: Label for study arm. + * + * @return the name value. + */ + @Generated + public String getName() { + return this.name; + } + + /** + * Get the type property: Categorization of study arm. + * + * @return the type value. + */ + @Generated + public CodeableConcept getType() { + return this.type; + } + + /** + * Set the type property: Categorization of study arm. + * + * @param type the type value to set. + * @return the ResearchStudyArm object itself. + */ + @Generated + public ResearchStudyArm setType(CodeableConcept type) { + this.type = type; + return this; + } + + /** + * Get the description property: Short explanation of study path. + * + * @return the description value. + */ + @Generated + public String getDescription() { + return this.description; + } + + /** + * Set the description property: Short explanation of study path. + * + * @param description the description value to set. + * @return the ResearchStudyArm object itself. + */ + @Generated + public ResearchStudyArm setDescription(String description) { + this.description = description; + return this; + } +} diff --git a/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/ResearchStudyObjective.java b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/ResearchStudyObjective.java new file mode 100644 index 0000000000000..9b7733f9287a2 --- /dev/null +++ b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/ResearchStudyObjective.java @@ -0,0 +1,73 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) TypeSpec Code Generator. + +package com.azure.health.insights.patienttimeline.models; + +import com.azure.core.annotation.Fluent; +import com.azure.core.annotation.Generated; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The ResearchStudyObjective model. + */ +@Fluent +public final class ResearchStudyObjective { + /* + * Label for the objective + */ + @Generated + @JsonProperty(value = "name") + private String name; + + /* + * primary | secondary | exploratory + */ + @Generated + @JsonProperty(value = "type") + private CodeableConcept type; + + /** + * Creates an instance of ResearchStudyObjective class. + * + * @param name the name value to set. + */ + @Generated + @JsonCreator + public ResearchStudyObjective(@JsonProperty(value = "name") String name) { + this.name = name; + } + + /** + * Get the name property: Label for the objective. + * + * @return the name value. + */ + @Generated + public String getName() { + return this.name; + } + + /** + * Get the type property: primary | secondary | exploratory. + * + * @return the type value. + */ + @Generated + public CodeableConcept getType() { + return this.type; + } + + /** + * Set the type property: primary | secondary | exploratory. + * + * @param type the type value to set. + * @return the ResearchStudyObjective object itself. + */ + @Generated + public ResearchStudyObjective setType(CodeableConcept type) { + this.type = type; + return this; + } +} diff --git a/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/ResearchStudyStatusCodeType.java b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/ResearchStudyStatusCodeType.java new file mode 100644 index 0000000000000..e3b396031e2f9 --- /dev/null +++ b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/ResearchStudyStatusCodeType.java @@ -0,0 +1,120 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) TypeSpec Code Generator. + +package com.azure.health.insights.patienttimeline.models; + +import com.azure.core.annotation.Generated; +import com.azure.core.util.ExpandableStringEnum; +import com.fasterxml.jackson.annotation.JsonCreator; +import java.util.Collection; + +/** + * https://www.hl7.org/fhir/R4/codesystem-research-study-status.html. + */ +public final class ResearchStudyStatusCodeType extends ExpandableStringEnum { + /** + * The study is open for accrual. + */ + @Generated + public static final ResearchStudyStatusCodeType ACTIVE = fromString("active"); + + /** + * Study is completed prematurely and will not resume; patients are no longer examined nor treated. + */ + @Generated + public static final ResearchStudyStatusCodeType ADMINISTRATIVELY_COMPLETED + = fromString("administratively-completed"); + + /** + * Protocol is approved by the review board. + */ + @Generated + public static final ResearchStudyStatusCodeType APPROVED = fromString("approved"); + + /** + * Study is closed for accrual; patients can be examined and treated. + */ + @Generated + public static final ResearchStudyStatusCodeType CLOSED_TO_ACCRUAL = fromString("closed-to-accrual"); + + /** + * The study is closed to accrual and intervention, i.e. the study is closed to enrollment, all study subjects have + * completed treatment or intervention but are still being followed according to the primary objective of the study. + */ + @Generated + public static final ResearchStudyStatusCodeType CLOSED_TO_ACCRUAL_AND_INTERVENTION + = fromString("closed-to-accrual-and-intervention"); + + /** + * Study is closed to accrual and intervention, i.e. the study is closed to enrollment, all study subjects have + * completed treatment or intervention but are still being followed according to the primary objective of the study. + */ + @Generated + public static final ResearchStudyStatusCodeType COMPLETED = fromString("completed"); + + /** + * Protocol was disapproved by the review board. + */ + @Generated + public static final ResearchStudyStatusCodeType DISAPPROVED = fromString("disapproved"); + + /** + * Protocol is submitted to the review board for approval. + */ + @Generated + public static final ResearchStudyStatusCodeType IN_REVIEW = fromString("in-review"); + + /** + * The study is temporarily closed to accrual; a pause in accrual while study is reviewed, but is expected to + * resume. + */ + @Generated + public static final ResearchStudyStatusCodeType TEMPORARILY_CLOSED_TO_ACCRUAL + = fromString("temporarily-closed-to-accrual"); + + /** + * Study is temporarily closed for accrual; can be potentially resumed in the future. + */ + @Generated + public static final ResearchStudyStatusCodeType TEMPORARILY_CLOSED_TO_ACCRUAL_AND_INTERVENTION + = fromString("temporarily-closed-to-accrual-and-intervention"); + + /** + * Protocol was withdrawn by the lead organization. + */ + @Generated + public static final ResearchStudyStatusCodeType WITHDRAWN = fromString("withdrawn"); + + /** + * Creates a new instance of ResearchStudyStatusCodeType value. + * + * @deprecated Use the {@link #fromString(String)} factory method. + */ + @Generated + @Deprecated + public ResearchStudyStatusCodeType() { + } + + /** + * Creates or finds a ResearchStudyStatusCodeType from its string representation. + * + * @param name a name to look for. + * @return the corresponding ResearchStudyStatusCodeType. + */ + @Generated + @JsonCreator + public static ResearchStudyStatusCodeType fromString(String name) { + return fromString(name, ResearchStudyStatusCodeType.class); + } + + /** + * Gets known ResearchStudyStatusCodeType values. + * + * @return known ResearchStudyStatusCodeType values. + */ + @Generated + public static Collection values() { + return values(ResearchStudyStatusCodeType.class); + } +} diff --git a/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/Resource.java b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/Resource.java new file mode 100644 index 0000000000000..e09310a6d93b3 --- /dev/null +++ b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/Resource.java @@ -0,0 +1,212 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) TypeSpec Code Generator. + +package com.azure.health.insights.patienttimeline.models; + +import com.azure.core.annotation.Fluent; +import com.azure.core.annotation.Generated; +import com.fasterxml.jackson.annotation.JsonAnyGetter; +import com.fasterxml.jackson.annotation.JsonAnySetter; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.fasterxml.jackson.annotation.JsonIgnore; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.util.HashMap; +import java.util.Map; + +/** + * Resource is the ancestor of DomainResource from which most resources are derived. Bundle, Parameters, and Binary + * extend Resource directly. + * Based on [FHIR Resource](https://www.hl7.org/fhir/r4/resource.html. + */ +@Fluent +public final class Resource { + /* + * The type of resource + */ + @Generated + @JsonProperty(value = "resourceType") + private String resourceType; + + /* + * Resource Id + */ + @Generated + @JsonProperty(value = "id") + private String id; + + /* + * Metadata about the resource + */ + @Generated + @JsonProperty(value = "meta") + private Meta meta; + + /* + * A set of rules under which this content was created + */ + @Generated + @JsonProperty(value = "implicitRules") + private String implicitRules; + + /* + * Language of the resource content + */ + @Generated + @JsonProperty(value = "language") + private String language; + + /* + * Resource is the ancestor of DomainResource from which most resources are derived. Bundle, Parameters, and Binary + * extend Resource directly. + * Based on [FHIR Resource](https://www.hl7.org/fhir/r4/resource.html + */ + @Generated + @JsonIgnore + private Map additionalProperties; + + /** + * Creates an instance of Resource class. + * + * @param resourceType the resourceType value to set. + */ + @Generated + @JsonCreator + public Resource(@JsonProperty(value = "resourceType") String resourceType) { + this.resourceType = resourceType; + } + + /** + * Get the resourceType property: The type of resource. + * + * @return the resourceType value. + */ + @Generated + public String getResourceType() { + return this.resourceType; + } + + /** + * Get the id property: Resource Id. + * + * @return the id value. + */ + @Generated + public String getId() { + return this.id; + } + + /** + * Set the id property: Resource Id. + * + * @param id the id value to set. + * @return the Resource object itself. + */ + @Generated + public Resource setId(String id) { + this.id = id; + return this; + } + + /** + * Get the meta property: Metadata about the resource. + * + * @return the meta value. + */ + @Generated + public Meta getMeta() { + return this.meta; + } + + /** + * Set the meta property: Metadata about the resource. + * + * @param meta the meta value to set. + * @return the Resource object itself. + */ + @Generated + public Resource setMeta(Meta meta) { + this.meta = meta; + return this; + } + + /** + * Get the implicitRules property: A set of rules under which this content was created. + * + * @return the implicitRules value. + */ + @Generated + public String getImplicitRules() { + return this.implicitRules; + } + + /** + * Set the implicitRules property: A set of rules under which this content was created. + * + * @param implicitRules the implicitRules value to set. + * @return the Resource object itself. + */ + @Generated + public Resource setImplicitRules(String implicitRules) { + this.implicitRules = implicitRules; + return this; + } + + /** + * Get the language property: Language of the resource content. + * + * @return the language value. + */ + @Generated + public String getLanguage() { + return this.language; + } + + /** + * Set the language property: Language of the resource content. + * + * @param language the language value to set. + * @return the Resource object itself. + */ + @Generated + public Resource setLanguage(String language) { + this.language = language; + return this; + } + + /** + * Get the additionalProperties property: Resource is the ancestor of DomainResource from which most resources are + * derived. Bundle, Parameters, and Binary extend Resource directly. + * Based on [FHIR Resource](https://www.hl7.org/fhir/r4/resource.html. + * + * @return the additionalProperties value. + */ + @Generated + @JsonAnyGetter + public Map getAdditionalProperties() { + return this.additionalProperties; + } + + /** + * Set the additionalProperties property: Resource is the ancestor of DomainResource from which most resources are + * derived. Bundle, Parameters, and Binary extend Resource directly. + * Based on [FHIR Resource](https://www.hl7.org/fhir/r4/resource.html. + * + * @param additionalProperties the additionalProperties value to set. + * @return the Resource object itself. + */ + @Generated + public Resource setAdditionalProperties(Map additionalProperties) { + this.additionalProperties = additionalProperties; + return this; + } + + @Generated + @JsonAnySetter + void setAdditionalProperties(String key, Object value) { + if (additionalProperties == null) { + additionalProperties = new HashMap<>(); + } + additionalProperties.put(key, value); + } +} diff --git a/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/SampledData.java b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/SampledData.java new file mode 100644 index 0000000000000..6de6eb8fd75db --- /dev/null +++ b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/SampledData.java @@ -0,0 +1,222 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) TypeSpec Code Generator. + +package com.azure.health.insights.patienttimeline.models; + +import com.azure.core.annotation.Fluent; +import com.azure.core.annotation.Generated; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.math.BigDecimal; +import java.util.List; + +/** + * A series of measurements taken by a device + * Based on [FHIR SampledData](https://www.hl7.org/fhir/R4/datatypes.html#SampledData). + */ +@Fluent +public final class SampledData extends Element { + /* + * Zero value and units + */ + @Generated + @JsonProperty(value = "origin") + private Quantity origin; + + /* + * Number of milliseconds between samples + */ + @Generated + @JsonProperty(value = "period") + private BigDecimal period; + + /* + * Multiply data by this before adding to origin + */ + @Generated + @JsonProperty(value = "factor") + private BigDecimal factor; + + /* + * Lower limit of detection + */ + @Generated + @JsonProperty(value = "lowerLimit") + private BigDecimal lowerLimit; + + /* + * Upper limit of detection + */ + @Generated + @JsonProperty(value = "upperLimit") + private BigDecimal upperLimit; + + /* + * Number of sample points at each time point + */ + @Generated + @JsonProperty(value = "dimensions") + private int dimensions; + + /* + * Decimal values with spaces, or "E" | "U" | "L" + */ + @Generated + @JsonProperty(value = "data") + private String data; + + /** + * Creates an instance of SampledData class. + * + * @param origin the origin value to set. + * @param period the period value to set. + * @param dimensions the dimensions value to set. + */ + @Generated + @JsonCreator + public SampledData(@JsonProperty(value = "origin") Quantity origin, + @JsonProperty(value = "period") BigDecimal period, @JsonProperty(value = "dimensions") int dimensions) { + this.origin = origin; + this.period = period; + this.dimensions = dimensions; + } + + /** + * Get the origin property: Zero value and units. + * + * @return the origin value. + */ + @Generated + public Quantity getOrigin() { + return this.origin; + } + + /** + * Get the period property: Number of milliseconds between samples. + * + * @return the period value. + */ + @Generated + public BigDecimal getPeriod() { + return this.period; + } + + /** + * Get the factor property: Multiply data by this before adding to origin. + * + * @return the factor value. + */ + @Generated + public BigDecimal getFactor() { + return this.factor; + } + + /** + * Set the factor property: Multiply data by this before adding to origin. + * + * @param factor the factor value to set. + * @return the SampledData object itself. + */ + @Generated + public SampledData setFactor(BigDecimal factor) { + this.factor = factor; + return this; + } + + /** + * Get the lowerLimit property: Lower limit of detection. + * + * @return the lowerLimit value. + */ + @Generated + public BigDecimal getLowerLimit() { + return this.lowerLimit; + } + + /** + * Set the lowerLimit property: Lower limit of detection. + * + * @param lowerLimit the lowerLimit value to set. + * @return the SampledData object itself. + */ + @Generated + public SampledData setLowerLimit(BigDecimal lowerLimit) { + this.lowerLimit = lowerLimit; + return this; + } + + /** + * Get the upperLimit property: Upper limit of detection. + * + * @return the upperLimit value. + */ + @Generated + public BigDecimal getUpperLimit() { + return this.upperLimit; + } + + /** + * Set the upperLimit property: Upper limit of detection. + * + * @param upperLimit the upperLimit value to set. + * @return the SampledData object itself. + */ + @Generated + public SampledData setUpperLimit(BigDecimal upperLimit) { + this.upperLimit = upperLimit; + return this; + } + + /** + * Get the dimensions property: Number of sample points at each time point. + * + * @return the dimensions value. + */ + @Generated + public int getDimensions() { + return this.dimensions; + } + + /** + * Get the data property: Decimal values with spaces, or "E" | "U" | "L". + * + * @return the data value. + */ + @Generated + public String getData() { + return this.data; + } + + /** + * Set the data property: Decimal values with spaces, or "E" | "U" | "L". + * + * @param data the data value to set. + * @return the SampledData object itself. + */ + @Generated + public SampledData setData(String data) { + this.data = data; + return this; + } + + /** + * {@inheritDoc} + */ + @Generated + @Override + public SampledData setId(String id) { + super.setId(id); + return this; + } + + /** + * {@inheritDoc} + */ + @Generated + @Override + public SampledData setExtension(List extension) { + super.setExtension(extension); + return this; + } +} diff --git a/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/SpecialtyType.java b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/SpecialtyType.java new file mode 100644 index 0000000000000..0acf42346a91f --- /dev/null +++ b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/SpecialtyType.java @@ -0,0 +1,59 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) TypeSpec Code Generator. + +package com.azure.health.insights.patienttimeline.models; + +import com.azure.core.annotation.Generated; +import com.azure.core.util.ExpandableStringEnum; +import com.fasterxml.jackson.annotation.JsonCreator; +import java.util.Collection; + +/** + * Known values codes that can be used to indicate the type of the Specialty. + */ +public final class SpecialtyType extends ExpandableStringEnum { + /** + * pathology. + */ + @Generated + public static final SpecialtyType PATHOLOGY = fromString("pathology"); + + /** + * radiology. + */ + @Generated + public static final SpecialtyType RADIOLOGY = fromString("radiology"); + + /** + * Creates a new instance of SpecialtyType value. + * + * @deprecated Use the {@link #fromString(String)} factory method. + */ + @Generated + @Deprecated + public SpecialtyType() { + } + + /** + * Creates or finds a SpecialtyType from its string representation. + * + * @param name a name to look for. + * @return the corresponding SpecialtyType. + */ + @Generated + @JsonCreator + public static SpecialtyType fromString(String name) { + return fromString(name, SpecialtyType.class); + } + + /** + * Gets known SpecialtyType values. + * + * @return known SpecialtyType values. + */ + @Generated + public static Collection values() { + return values(SpecialtyType.class); + } +} diff --git a/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/TimePeriod.java b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/TimePeriod.java new file mode 100644 index 0000000000000..a3c79c6601dbd --- /dev/null +++ b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/TimePeriod.java @@ -0,0 +1,81 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) TypeSpec Code Generator. + +package com.azure.health.insights.patienttimeline.models; + +import com.azure.core.annotation.Fluent; +import com.azure.core.annotation.Generated; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.time.OffsetDateTime; + +/** + * A duration of time during which an event is happening. + */ +@Fluent +public final class TimePeriod { + /* + * Starting time with inclusive boundary + */ + @Generated + @JsonProperty(value = "start") + private OffsetDateTime start; + + /* + * End time with inclusive boundary, if not ongoing + */ + @Generated + @JsonProperty(value = "end") + private OffsetDateTime end; + + /** + * Creates an instance of TimePeriod class. + */ + @Generated + public TimePeriod() { + } + + /** + * Get the start property: Starting time with inclusive boundary. + * + * @return the start value. + */ + @Generated + public OffsetDateTime getStart() { + return this.start; + } + + /** + * Set the start property: Starting time with inclusive boundary. + * + * @param start the start value to set. + * @return the TimePeriod object itself. + */ + @Generated + public TimePeriod setStart(OffsetDateTime start) { + this.start = start; + return this; + } + + /** + * Get the end property: End time with inclusive boundary, if not ongoing. + * + * @return the end value. + */ + @Generated + public OffsetDateTime getEnd() { + return this.end; + } + + /** + * Set the end property: End time with inclusive boundary, if not ongoing. + * + * @param end the end value to set. + * @return the TimePeriod object itself. + */ + @Generated + public TimePeriod setEnd(OffsetDateTime end) { + this.end = end; + return this; + } +} diff --git a/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/package-info.java b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/package-info.java new file mode 100644 index 0000000000000..2696d04a34575 --- /dev/null +++ b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/models/package-info.java @@ -0,0 +1,12 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) TypeSpec Code Generator. + +/** + * + * Package containing the data models for AzureHealthInsights. + * Azure AI Health Insights provides an API that serves insight models, specific for Health & Life Sciences, that + * perform analysis and provide inferences to be used by a human. + * + */ +package com.azure.health.insights.patienttimeline.models; diff --git a/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/package-info.java b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/package-info.java new file mode 100644 index 0000000000000..870748da3b510 --- /dev/null +++ b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/com/azure/health/insights/patienttimeline/package-info.java @@ -0,0 +1,12 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) TypeSpec Code Generator. + +/** + * + * Package containing the classes for AzureHealthInsights. + * Azure AI Health Insights provides an API that serves insight models, specific for Health & Life Sciences, that + * perform analysis and provide inferences to be used by a human. + * + */ +package com.azure.health.insights.patienttimeline; diff --git a/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/module-info.java b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/module-info.java new file mode 100644 index 0000000000000..297246b4a4129 --- /dev/null +++ b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/java/module-info.java @@ -0,0 +1,13 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) TypeSpec Code Generator. + +module com.azure.health.insights.patienttimeline { + requires transitive com.azure.core; + requires transitive com.azure.core.experimental; + + exports com.azure.health.insights.patienttimeline; + exports com.azure.health.insights.patienttimeline.models; + + opens com.azure.health.insights.patienttimeline.models to com.azure.core, com.fasterxml.jackson.databind; +} diff --git a/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/resources/azure-health-insights-patienttimeline.properties b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/resources/azure-health-insights-patienttimeline.properties new file mode 100644 index 0000000000000..ca812989b4f27 --- /dev/null +++ b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/main/resources/azure-health-insights-patienttimeline.properties @@ -0,0 +1,2 @@ +name=${project.artifactId} +version=${project.version} diff --git a/sdk/healthinsights/azure-healthinsights-patienttimeline/src/samples/java/com/azure/health/insights/patienttimeline/ReadmeSamples.java b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/samples/java/com/azure/health/insights/patienttimeline/ReadmeSamples.java new file mode 100644 index 0000000000000..f779b5619181b --- /dev/null +++ b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/samples/java/com/azure/health/insights/patienttimeline/ReadmeSamples.java @@ -0,0 +1,12 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) TypeSpec Code Generator. + +package com.azure.health.insights.patienttimeline; + +public final class ReadmeSamples { + public void readmeSamples() { + // BEGIN: com.azure.health.insights.patienttimeline.readme + // END: com.azure.health.insights.patienttimeline.readme + } +} diff --git a/sdk/healthinsights/azure-healthinsights-patienttimeline/src/test/java/com/azure/health/insights/patienttimeline/generated/PatientTimelineClientTestBase.java b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/test/java/com/azure/health/insights/patienttimeline/generated/PatientTimelineClientTestBase.java new file mode 100644 index 0000000000000..e2204ea291dfd --- /dev/null +++ b/sdk/healthinsights/azure-healthinsights-patienttimeline/src/test/java/com/azure/health/insights/patienttimeline/generated/PatientTimelineClientTestBase.java @@ -0,0 +1,37 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) TypeSpec Code Generator. + +package com.azure.health.insights.patienttimeline.generated; + +// The Java test files under 'generated' package are generated for your reference. +// If you wish to modify these files, please copy them out of the 'generated' package, and modify there. +// See https://aka.ms/azsdk/dpg/java/tests for guide on adding a test. + +import com.azure.core.http.HttpClient; +import com.azure.core.http.policy.HttpLogDetailLevel; +import com.azure.core.http.policy.HttpLogOptions; +import com.azure.core.test.TestMode; +import com.azure.core.test.TestProxyTestBase; +import com.azure.core.util.Configuration; +import com.azure.health.insights.patienttimeline.PatientTimelineClient; +import com.azure.health.insights.patienttimeline.PatientTimelineClientBuilder; + +class PatientTimelineClientTestBase extends TestProxyTestBase { + protected PatientTimelineClient patientTimelineClient; + + @Override + protected void beforeTest() { + PatientTimelineClientBuilder patientTimelineClientbuilder = new PatientTimelineClientBuilder() + .endpoint(Configuration.getGlobalConfiguration().get("ENDPOINT", "endpoint")) + .httpClient(HttpClient.createDefault()) + .httpLogOptions(new HttpLogOptions().setLogLevel(HttpLogDetailLevel.BASIC)); + if (getTestMode() == TestMode.PLAYBACK) { + patientTimelineClientbuilder.httpClient(interceptorManager.getPlaybackClient()); + } else if (getTestMode() == TestMode.RECORD) { + patientTimelineClientbuilder.addPolicy(interceptorManager.getRecordPolicy()); + } + patientTimelineClient = patientTimelineClientbuilder.buildClient(); + + } +} diff --git a/sdk/healthinsights/azure-healthinsights-patienttimeline/tsp-location.yaml b/sdk/healthinsights/azure-healthinsights-patienttimeline/tsp-location.yaml new file mode 100644 index 0000000000000..27365c6100ec6 --- /dev/null +++ b/sdk/healthinsights/azure-healthinsights-patienttimeline/tsp-location.yaml @@ -0,0 +1,7 @@ +commit: 97b69b1a57b1799145be508d0e2938ceddfb6746 +directory: specification/ai/HealthInsights/HealthInsights.PatientTimeline +repo: Azure/azure-rest-api-specs +additionalDirectories: +- specification/ai/HealthInsights/HealthInsights.Common/ +- specification/ai/HealthInsights/HealthInsights.OpenAPI/ + diff --git a/sdk/healthinsights/ci.yml b/sdk/healthinsights/ci.yml index 960570420b498..6e0806aa37efe 100644 --- a/sdk/healthinsights/ci.yml +++ b/sdk/healthinsights/ci.yml @@ -1,4 +1,5 @@ # NOTE: Please refer to https://aka.ms/azsdk/engsys/ci-yaml before editing this file. + trigger: branches: include: @@ -13,7 +14,6 @@ trigger: - sdk/healthinsights/azure-health-insights-cancerprofiling/pom.xml - sdk/healthinsights/azure-health-insights-clinicalmatching/pom.xml - pr: branches: include: @@ -40,4 +40,6 @@ extends: - name: azure-health-insights-cancerprofiling groupId: com.azure safeName: azurehealthinsightscancerprofiling - + - name: azure-healthinsights-patienttimeline + groupId: com.azure + safeName: azurehealthinsightspatienttimeline diff --git a/sdk/healthinsights/pom.xml b/sdk/healthinsights/pom.xml index 1620d1255c4f1..e2b121060571d 100644 --- a/sdk/healthinsights/pom.xml +++ b/sdk/healthinsights/pom.xml @@ -8,7 +8,8 @@ pom 1.0.0 - azure-health-insights-cancerprofiling - azure-health-insights-clinicalmatching + azure-health-insights-cancerprofiling + azure-health-insights-clinicalmatching + azure-healthinsights-patienttimeline