diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/Azure.Analytics.Purview.DataMap.sln b/sdk/purview/Azure.Analytics.Purview.DataMap/Azure.Analytics.Purview.DataMap.sln new file mode 100644 index 0000000000000..0d89c175ed5e1 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/Azure.Analytics.Purview.DataMap.sln @@ -0,0 +1,56 @@ +Microsoft Visual Studio Solution File, Format Version 12.00 +# Visual Studio Version 16 +VisualStudioVersion = 16.0.29709.97 +MinimumVisualStudioVersion = 10.0.40219.1 +Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Azure.Core.TestFramework", "..\..\core\Azure.Core.TestFramework\src\Azure.Core.TestFramework.csproj", "{ECC730C1-4AEA-420C-916A-66B19B79E4DC}" +EndProject +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Azure.Analytics.Purview.DataMap", "src\Azure.Analytics.Purview.DataMap.csproj", "{28FF4005-4467-4E36-92E7-DEA27DEB1519}" +EndProject +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Azure.Analytics.Purview.DataMap.Tests", "tests\Azure.Analytics.Purview.DataMap.Tests.csproj", "{1F1CD1D4-9932-4B73-99D8-C252A67D4B46}" +EndProject +Global + GlobalSection(SolutionConfigurationPlatforms) = preSolution + Debug|Any CPU = Debug|Any CPU + Release|Any CPU = Release|Any CPU + EndGlobalSection + GlobalSection(ProjectConfigurationPlatforms) = postSolution + {B0C276D1-2930-4887-B29A-D1A33E7009A2}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {B0C276D1-2930-4887-B29A-D1A33E7009A2}.Debug|Any CPU.Build.0 = Debug|Any CPU + {B0C276D1-2930-4887-B29A-D1A33E7009A2}.Release|Any CPU.ActiveCfg = Release|Any CPU + {B0C276D1-2930-4887-B29A-D1A33E7009A2}.Release|Any CPU.Build.0 = Release|Any CPU + {8E9A77AC-792A-4432-8320-ACFD46730401}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {8E9A77AC-792A-4432-8320-ACFD46730401}.Debug|Any CPU.Build.0 = Debug|Any CPU + {8E9A77AC-792A-4432-8320-ACFD46730401}.Release|Any CPU.ActiveCfg = Release|Any CPU + {8E9A77AC-792A-4432-8320-ACFD46730401}.Release|Any CPU.Build.0 = Release|Any CPU + {ECC730C1-4AEA-420C-916A-66B19B79E4DC}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {ECC730C1-4AEA-420C-916A-66B19B79E4DC}.Debug|Any CPU.Build.0 = Debug|Any CPU + {ECC730C1-4AEA-420C-916A-66B19B79E4DC}.Release|Any CPU.ActiveCfg = Release|Any CPU + {ECC730C1-4AEA-420C-916A-66B19B79E4DC}.Release|Any CPU.Build.0 = Release|Any CPU + {A4241C1F-A53D-474C-9E4E-075054407E74}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {A4241C1F-A53D-474C-9E4E-075054407E74}.Debug|Any CPU.Build.0 = Debug|Any CPU + {A4241C1F-A53D-474C-9E4E-075054407E74}.Release|Any CPU.ActiveCfg = Release|Any CPU + {A4241C1F-A53D-474C-9E4E-075054407E74}.Release|Any CPU.Build.0 = Release|Any CPU + {FA8BD3F1-8616-47B6-974C-7576CDF4717E}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {FA8BD3F1-8616-47B6-974C-7576CDF4717E}.Debug|Any CPU.Build.0 = Debug|Any CPU + {FA8BD3F1-8616-47B6-974C-7576CDF4717E}.Release|Any CPU.ActiveCfg = Release|Any CPU + {FA8BD3F1-8616-47B6-974C-7576CDF4717E}.Release|Any CPU.Build.0 = Release|Any CPU + {85677AD3-C214-42FA-AE6E-49B956CAC8DC}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {85677AD3-C214-42FA-AE6E-49B956CAC8DC}.Debug|Any CPU.Build.0 = Debug|Any CPU + {85677AD3-C214-42FA-AE6E-49B956CAC8DC}.Release|Any CPU.ActiveCfg = Release|Any CPU + {85677AD3-C214-42FA-AE6E-49B956CAC8DC}.Release|Any CPU.Build.0 = Release|Any CPU + {28FF4005-4467-4E36-92E7-DEA27DEB1519}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {28FF4005-4467-4E36-92E7-DEA27DEB1519}.Debug|Any CPU.Build.0 = Debug|Any CPU + {28FF4005-4467-4E36-92E7-DEA27DEB1519}.Release|Any CPU.ActiveCfg = Release|Any CPU + {28FF4005-4467-4E36-92E7-DEA27DEB1519}.Release|Any CPU.Build.0 = Release|Any CPU + {1F1CD1D4-9932-4B73-99D8-C252A67D4B46}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {1F1CD1D4-9932-4B73-99D8-C252A67D4B46}.Debug|Any CPU.Build.0 = Debug|Any CPU + {1F1CD1D4-9932-4B73-99D8-C252A67D4B46}.Release|Any CPU.ActiveCfg = Release|Any CPU + {1F1CD1D4-9932-4B73-99D8-C252A67D4B46}.Release|Any CPU.Build.0 = Release|Any CPU + EndGlobalSection + GlobalSection(SolutionProperties) = preSolution + HideSolutionNode = FALSE + EndGlobalSection + GlobalSection(ExtensibilityGlobals) = postSolution + SolutionGuid = {A97F4B90-2591-4689-B1F8-5F21FE6D6CAE} + EndGlobalSection +EndGlobal diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/CHANGELOG.md b/sdk/purview/Azure.Analytics.Purview.DataMap/CHANGELOG.md new file mode 100644 index 0000000000000..13dd08af78abe --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/CHANGELOG.md @@ -0,0 +1,11 @@ +# Release History + +## 1.0.0-beta.1 (Unreleased) + +### Features Added + +### Breaking Changes + +### Bugs Fixed + +### Other Changes diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/Directory.Build.props b/sdk/purview/Azure.Analytics.Purview.DataMap/Directory.Build.props new file mode 100644 index 0000000000000..63bd836ad44b7 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/Directory.Build.props @@ -0,0 +1,6 @@ + + + + diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/README.md b/sdk/purview/Azure.Analytics.Purview.DataMap/README.md new file mode 100644 index 0000000000000..7444377620460 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/README.md @@ -0,0 +1,86 @@ +# Azure.Analytics.Purview.DataMap client library for .NET + +Azure.Analytics.Purview.DataMap is a managed service that helps developers get secret simply and securely. + +Use the client library for to: + +* [Get secret](https://docs.microsoft.com/azure) + +[Source code][source_root] | [Package (NuGet)][package] | [API reference documentation][reference_docs] | [Product documentation][azconfig_docs] | [Samples][source_samples] + + [Source code](https://github.com/Azure/azure-sdk-for-net/blob/main/sdk/purview/Azure.Analytics.Purview.DataMap/src) | [Package (NuGet)](https://www.nuget.org/packages) | [API reference documentation](https://azure.github.io/azure-sdk-for-net) | [Product documentation](https://docs.microsoft.com/azure) + +## Getting started + +This section should include everything a developer needs to do to install and create their first client connection *very quickly*. + +### Install the package + +First, provide instruction for obtaining and installing the package or library. This section might include only a single line of code, like `dotnet add package package-name`, but should enable a developer to successfully install the package from NuGet, npm, or even cloning a GitHub repository. + +Install the client library for .NET with [NuGet](https://www.nuget.org/ ): + +```dotnetcli +dotnet add package Azure.Analytics.Purview.DataMap --prerelease +``` + +### Prerequisites + +Include a section after the install command that details any requirements that must be satisfied before a developer can [authenticate](#authenticate-the-client) and test all of the snippets in the [Examples](#examples) section. For example, for Cosmos DB: + +> You must have an [Azure subscription](https://azure.microsoft.com/free/dotnet/) and [Cosmos DB account](https://docs.microsoft.com/azure/cosmos-db/account-overview) (SQL API). In order to take advantage of the C# 8.0 syntax, it is recommended that you compile using the [.NET Core SDK](https://dotnet.microsoft.com/download) 3.0 or higher with a [language version](https://docs.microsoft.com/dotnet/csharp/language-reference/configure-language-version#override-a-default) of `latest`. It is also possible to compile with the .NET Core SDK 2.1.x using a language version of `preview`. + +### Authenticate the client + +If your library requires authentication for use, such as for Azure services, include instructions and example code needed for initializing and authenticating. + +For example, include details on obtaining an account key and endpoint URI, setting environment variables for each, and initializing the client object. + +## Key concepts + +The *Key concepts* section should describe the functionality of the main classes. Point out the most important and useful classes in the package (with links to their reference pages) and explain how those classes work together. Feel free to use bulleted lists, tables, code blocks, or even diagrams for clarity. + +Include the *Thread safety* and *Additional concepts* sections below at the end of your *Key concepts* section. You may remove or add links depending on what your library makes use of: + +### Thread safety + +We guarantee that all client instance methods are thread-safe and independent of each other ([guideline](https://azure.github.io/azure-sdk/dotnet_introduction.html#dotnet-service-methods-thread-safety)). This ensures that the recommendation of reusing client instances is always safe, even across threads. + +### Additional concepts + +[Client options](https://github.com/Azure/azure-sdk-for-net/blob/main/sdk/core/Azure.Core/README.md#configuring-service-clients-using-clientoptions) | +[Accessing the response](https://github.com/Azure/azure-sdk-for-net/blob/main/sdk/core/Azure.Core/README.md#accessing-http-response-details-using-responset) | +[Long-running operations](https://github.com/Azure/azure-sdk-for-net/blob/main/sdk/core/Azure.Core/README.md#consuming-long-running-operations-using-operationt) | +[Handling failures](https://github.com/Azure/azure-sdk-for-net/blob/main/sdk/core/Azure.Core/README.md#reporting-errors-requestfailedexception) | +[Diagnostics](https://github.com/Azure/azure-sdk-for-net/blob/main/sdk/core/Azure.Core/samples/Diagnostics.md) | +[Mocking](https://github.com/Azure/azure-sdk-for-net/blob/main/sdk/core/Azure.Core/README.md#mocking) | +[Client lifetime](https://devblogs.microsoft.com/azure-sdk/lifetime-management-and-thread-safety-guarantees-of-azure-sdk-net-clients/) + + +## Examples + +You can familiarize yourself with different APIs using [Samples](https://github.com/Azure/azure-sdk-for-net/tree/main/sdk/purview/Azure.Analytics.Purview.DataMap/samples). + +## Troubleshooting + +Describe common errors and exceptions, how to "unpack" them if necessary, and include guidance for graceful handling and recovery. + +Provide information to help developers avoid throttling or other service-enforced errors they might encounter. For example, provide guidance and examples for using retry or connection policies in the API. + +If the package or a related package supports it, include tips for logging or enabling instrumentation to help them debug their code. + +## Next steps + +* Provide a link to additional code examples, ideally to those sitting alongside the README in the package's `/samples` directory. +* If appropriate, point users to other packages that might be useful. +* If you think there's a good chance that developers might stumble across your package in error (because they're searching for specific functionality and mistakenly think the package provides that functionality), point them to the packages they might be looking for. + +## Contributing + +This is a template, but your SDK readme should include details on how to contribute code to the repo/package. + + +[style-guide-msft]: https://docs.microsoft.com/style-guide/capitalization +[style-guide-cloud]: https://aka.ms/azsdk/cloud-style-guide + +![Impressions](https://azure-sdk-impressions.azurewebsites.net/api/impressions/azure-sdk-for-net/sdk/purview/Azure.Analytics.Purview.DataMap/README.png) diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Azure.Analytics.Purview.DataMap.csproj b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Azure.Analytics.Purview.DataMap.csproj new file mode 100644 index 0000000000000..77eb5a8b662a7 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Azure.Analytics.Purview.DataMap.csproj @@ -0,0 +1,20 @@ + + + This is the Azure.Analytics.Purview.DataMap client library for developing .NET applications with rich experience. + Azure SDK Code Generation Azure.Analytics.Purview.DataMap for Azure Data Plane + 1.0.0-beta.1 + Azure.Analytics.Purview.DataMap + $(RequiredTargetFrameworks) + true + + + + + + + + + + + + diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AnalyticsPurviewDataMapClientBuilderExtensions.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AnalyticsPurviewDataMapClientBuilderExtensions.cs new file mode 100644 index 0000000000000..2d6f5b66cd410 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AnalyticsPurviewDataMapClientBuilderExtensions.cs @@ -0,0 +1,35 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using Azure.Analytics.Purview.DataMap; +using Azure.Core.Extensions; + +namespace Microsoft.Extensions.Azure +{ + /// Extension methods to add to client builder. + public static partial class AnalyticsPurviewDataMapClientBuilderExtensions + { + /// Registers a instance. + /// The builder to register with. + /// The to use. + public static IAzureClientBuilder AddDataMapClient(this TBuilder builder, Uri endpoint) + where TBuilder : IAzureClientFactoryBuilderWithCredential + { + return builder.RegisterClientFactory((options, cred) => new DataMapClient(endpoint, cred, options)); + } + + /// Registers a instance. + /// The builder to register with. + /// The configuration values. + public static IAzureClientBuilder AddDataMapClient(this TBuilder builder, TConfiguration configuration) + where TBuilder : IAzureClientFactoryBuilderWithConfiguration + { + return builder.RegisterClientFactory(configuration); + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AnalyticsPurviewDataMapModelFactory.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AnalyticsPurviewDataMapModelFactory.cs new file mode 100644 index 0000000000000..4f46bb3ca3cf4 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AnalyticsPurviewDataMapModelFactory.cs @@ -0,0 +1,512 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Collections.Generic; +using System.Linq; + +namespace Azure.Analytics.Purview.DataMap +{ + /// Model factory for models. + public static partial class AnalyticsPurviewDataMapModelFactory + { + /// Initializes a new instance of . + /// The attributes of the struct. + /// The name of the type. + /// ETag for concurrency control. + /// Business attributes. + /// An array of classifications. + /// The created time of the record. + /// The user who created the record. + /// Custom Attribute. + /// The GUID of the entity. + /// The home ID of the entity. + /// The collection ID of the entity. + /// Whether it is a shell entity. + /// labels. + /// An array of term assignment headers indicating the meanings of the entity. + /// Used to record the provenance of an instance of an entity or relationship. + /// Determines if there's a proxy. + /// The attributes of relationship. + /// + /// Status of the entity - can be active or deleted. Deleted entities are not + /// removed. + /// + /// The update time of the record. + /// The user who updated the record. + /// The version of the entity. + /// The dictionary of contacts for entities. Key could be Expert or Owner. + /// A new instance for mocking. + public static AtlasEntity AtlasEntity(IDictionary attributes = null, string typeName = null, string lastModifiedTS = null, IDictionary businessAttributes = null, IEnumerable classifications = null, long? createTime = null, string createdBy = null, IDictionary customAttributes = null, string guid = null, string homeId = null, string collectionId = null, bool? isIncomplete = null, IEnumerable labels = null, IEnumerable meanings = null, int? provenanceType = null, bool? proxy = null, IDictionary relationshipAttributes = null, EntityStatus? status = null, long? updateTime = null, string updatedBy = null, long? version = null, IDictionary> contacts = null) + { + attributes ??= new Dictionary(); + businessAttributes ??= new Dictionary(); + classifications ??= new List(); + customAttributes ??= new Dictionary(); + labels ??= new List(); + meanings ??= new List(); + relationshipAttributes ??= new Dictionary(); + contacts ??= new Dictionary>(); + + return new AtlasEntity(attributes, typeName, lastModifiedTS, businessAttributes, classifications?.ToList(), createTime, createdBy, customAttributes, guid, homeId, collectionId, isIncomplete, labels?.ToList(), meanings?.ToList(), provenanceType, proxy, relationshipAttributes, status, updateTime, updatedBy, version, contacts); + } + + /// Initializes a new instance of . + /// A map of GUID assignments with entities. + /// The entity headers of mutated entities. + /// An array of entity headers that partially updated. + /// A new instance for mocking. + public static EntityMutationResult EntityMutationResult(IReadOnlyDictionary guidAssignments = null, IReadOnlyDictionary> mutatedEntities = null, IEnumerable partialUpdatedEntities = null) + { + guidAssignments ??= new Dictionary(); + mutatedEntities ??= new Dictionary>(); + partialUpdatedEntities ??= new List(); + + return new EntityMutationResult(guidAssignments, mutatedEntities, partialUpdatedEntities?.ToList()); + } + + /// Initializes a new instance of . + /// An array of objects. + /// The size of the page. + /// The sorted by field. + /// to specify whether the result should be sorted? If yes, whether asc or desc. + /// The start index of the page. + /// The total count of items. + /// A new instance for mocking. + public static AtlasClassifications AtlasClassifications(IEnumerable list = null, int? pageSize = null, string sortBy = null, SortType? sortType = null, int? startIndex = null, int? totalCount = null) + { + list ??= new List(); + + return new AtlasClassifications(list?.ToList(), pageSize, sortBy, sortType, startIndex, totalCount); + } + + /// Initializes a new instance of . + /// failed importInfoList. + /// successful importInfoList. + /// A new instance for mocking. + public static BulkImportResult BulkImportResult(IEnumerable failedImportInfoList = null, IEnumerable successImportInfoList = null) + { + failedImportInfoList ??= new List(); + successImportInfoList ??= new List(); + + return new BulkImportResult(failedImportInfoList?.ToList(), successImportInfoList?.ToList()); + } + + /// Initializes a new instance of . + /// childObjectName. + /// importStatus. + /// parentObjectName. + /// remarks. + /// A new instance for mocking. + public static ImportInfo ImportInfo(string childObjectName = null, ImportStatus? importStatus = null, string parentObjectName = null, string remarks = null) + { + return new ImportInfo(childObjectName, importStatus, parentObjectName, remarks); + } + + /// Initializes a new instance of . + /// The GUID of the object. + /// An array of classifications. + /// The long version description. + /// The name of the glossary object. + /// The qualified name of the glossary object. + /// The short version of description. + /// ETag for concurrency control. + /// The created time of the record. + /// The user who created the record. + /// The update time of the record. + /// The user who updated the record. + /// An array of categories. + /// The language of the glossary. + /// An array of related term headers. + /// The usage of the glossary. + /// The glossary category information. + /// The glossary term information. + /// A new instance for mocking. + public static AtlasGlossaryExtInfo AtlasGlossaryExtInfo(string guid = null, IEnumerable classifications = null, string longDescription = null, string name = null, string qualifiedName = null, string shortDescription = null, string lastModifiedTS = null, long? createTime = null, string createdBy = null, long? updateTime = null, string updatedBy = null, IEnumerable categories = null, string language = null, IEnumerable terms = null, string usage = null, IReadOnlyDictionary categoryInfo = null, IReadOnlyDictionary termInfo = null) + { + classifications ??= new List(); + categories ??= new List(); + terms ??= new List(); + categoryInfo ??= new Dictionary(); + termInfo ??= new Dictionary(); + + return new AtlasGlossaryExtInfo(guid, classifications?.ToList(), longDescription, name, qualifiedName, shortDescription, lastModifiedTS, createTime, createdBy, updateTime, updatedBy, categories?.ToList(), language, terms?.ToList(), usage, categoryInfo, termInfo); + } + + /// Initializes a new instance of . + /// + /// The total number of search results (not the number of documents in a single + /// page). + /// + /// 'True' if the '@search.count' is an approximate value and vise versa. + /// The token used to get next batch of data. Absent if there's no more data. + /// + /// A facet list that consists of index fields assetType ,classification, + /// contactId, and label. When the facet is specified in the request, the value of + /// the facet is returned as an element of @search.facets. + /// + /// Search result value. + /// A new instance for mocking. + public static SearchResult SearchResult(int? searchCount = null, bool? searchCountApproximate = null, string continuationToken = null, SearchFacetResultValue searchFacets = null, IEnumerable value = null) + { + value ??= new List(); + + return new SearchResult(searchCount, searchCountApproximate, continuationToken, searchFacets, value?.ToList()); + } + + /// Initializes a new instance of . + /// Entity type. + /// Asset type. + /// Classification. + /// Term. + /// Contact id. + /// Contact type. + /// Label. + /// Glossary type. + /// Term status. + /// Term template. + /// A new instance for mocking. + public static SearchFacetResultValue SearchFacetResultValue(IEnumerable entityType = null, IEnumerable assetType = null, IEnumerable classification = null, IEnumerable term = null, IEnumerable contactId = null, IEnumerable contactType = null, IEnumerable label = null, IEnumerable glossaryType = null, IEnumerable termStatus = null, IEnumerable termTemplate = null) + { + entityType ??= new List(); + assetType ??= new List(); + classification ??= new List(); + term ??= new List(); + contactId ??= new List(); + contactType ??= new List(); + label ??= new List(); + glossaryType ??= new List(); + termStatus ??= new List(); + termTemplate ??= new List(); + + return new SearchFacetResultValue(entityType?.ToList(), assetType?.ToList(), classification?.ToList(), term?.ToList(), contactId?.ToList(), contactType?.ToList(), label?.ToList(), glossaryType?.ToList(), termStatus?.ToList(), termTemplate?.ToList()); + } + + /// Initializes a new instance of . + /// The count of the facet item. + /// The name of the facet item. + /// A new instance for mocking. + public static SearchFacetItemValue SearchFacetItemValue(int? count = null, string value = null) + { + return new SearchFacetItemValue(count, value); + } + + /// Initializes a new instance of . + /// + /// The search score calculated by the search engine. The results are ordered by + /// search score by default. + /// + /// + /// A highlight list that consists of index fields id ,qualifiedName, name, + /// description, entityType. When the keyword appears in those fields, the value of + /// the field, attached with emphasis mark, is returned as an element of + /// @search.highlights. + /// + /// + /// The object type of the record. Object type is the top-level property to + /// distinguish whether a record is an asset or a term. + /// + /// The create time of the record. The Unix epoch format. + /// The last update time of the record. The Unix epoch format. + /// The GUID of the record. + /// The name of the record. + /// The qualified name of the record. + /// The type name of the asset. + /// The description of the asset. + /// The endorsement of the asset. + /// The owner of the record. + /// The classifications of the record. + /// The labels of the asset. + /// The terms assigned to the asset. + /// The contacts of the asset. + /// The asset types of the asset. + /// + /// The type name of the term. Could be AtlasGlossary, AtlasGlossaryTerm or + /// AtlasGlossaryCategory. + /// + /// The glossary name of the term. + /// The status of the term. + /// The term template names used by the term. + /// The definition of the term. + /// A new instance for mocking. + public static SearchResultValue SearchResultValue(float? searchScore = null, SearchHighlights searchHighlights = null, string objectType = null, long? createTime = null, long? updateTime = null, string id = null, string name = null, string qualifiedName = null, string entityType = null, string description = null, string endorsement = null, string owner = null, IEnumerable classification = null, IEnumerable label = null, IEnumerable term = null, IEnumerable contact = null, IEnumerable assetType = null, string glossaryType = null, string glossary = null, string termStatus = null, IEnumerable termTemplate = null, string longDescription = null) + { + classification ??= new List(); + label ??= new List(); + term ??= new List(); + contact ??= new List(); + assetType ??= new List(); + termTemplate ??= new List(); + + return new SearchResultValue(searchScore, searchHighlights, objectType, createTime, updateTime, id, name, qualifiedName, entityType, description, endorsement, owner, classification?.ToList(), label?.ToList(), term?.ToList(), contact?.ToList(), assetType?.ToList(), glossaryType, glossary, termStatus, termTemplate?.ToList(), longDescription); + } + + /// Initializes a new instance of . + /// Id. + /// Qualified name. + /// Name. + /// Description. + /// Entity type. + /// A new instance for mocking. + public static SearchHighlights SearchHighlights(IEnumerable id = null, IEnumerable qualifiedName = null, IEnumerable name = null, IEnumerable description = null, IEnumerable entityType = null) + { + id ??= new List(); + qualifiedName ??= new List(); + name ??= new List(); + description ??= new List(); + entityType ??= new List(); + + return new SearchHighlights(id?.ToList(), qualifiedName?.ToList(), name?.ToList(), description?.ToList(), entityType?.ToList()); + } + + /// Initializes a new instance of . + /// The name of the term. + /// The name of the glossary which contains the term. + /// The GUID of the term. + /// A new instance for mocking. + public static TermSearchResultValue TermSearchResultValue(string name = null, string glossaryName = null, string guid = null) + { + return new TermSearchResultValue(name, glossaryName, guid); + } + + /// Initializes a new instance of . + /// The GUID of the contact. + /// The description of the contact. + /// + /// The type of the contact. It can be Expert or Owner for an entity. It can be + /// Expert or Steward for a glossary term. + /// + /// A new instance for mocking. + public static ContactSearchResultValue ContactSearchResultValue(string id = null, string info = null, string contactType = null) + { + return new ContactSearchResultValue(id, info, contactType); + } + + /// Initializes a new instance of . + /// The result value. + /// A new instance for mocking. + public static SuggestResult SuggestResult(IEnumerable value = null) + { + value ??= new List(); + + return new SuggestResult(value?.ToList()); + } + + /// Initializes a new instance of . + /// + /// The search score calculated by the search engine. The results are ordered by + /// search score by default. + /// + /// + /// The target text that contains the keyword as prefix. The keyword is wrapped + /// with emphasis mark. + /// + /// + /// The object type of the record. Object type is the top-level property to + /// distinguish whether a record is an asset or a term. + /// + /// The create time of the record. The Unix epoch format. + /// The last update time of the record. The Unix epoch format. + /// The GUID of the record. + /// The name of the record. + /// The qualified name of the record. + /// The type name of the asset. + /// The description of the asset. + /// The endorsement of the asset. + /// The owner of the record. + /// The classifications of the record. + /// The labels of the asset. + /// The terms assigned to the asset. + /// The contacts of the asset. + /// The asset types of the asset. + /// + /// The type name of the term. Could be AtlasGlossary, AtlasGlossaryTerm or + /// AtlasGlossaryCategory. + /// + /// The glossary name of the term. + /// The status of the term. + /// The term template names used by the term. + /// The definition of the term. + /// A new instance for mocking. + public static SuggestResultValue SuggestResultValue(float? searchScore = null, string searchText = null, string objectType = null, long? createTime = null, long? updateTime = null, string id = null, string name = null, string qualifiedName = null, string entityType = null, string description = null, string endorsement = null, string owner = null, IEnumerable classification = null, IEnumerable label = null, IEnumerable term = null, IEnumerable contact = null, IEnumerable assetType = null, string glossaryType = null, string glossary = null, string termStatus = null, IEnumerable termTemplate = null, string longDescription = null) + { + classification ??= new List(); + label ??= new List(); + term ??= new List(); + contact ??= new List(); + assetType ??= new List(); + termTemplate ??= new List(); + + return new SuggestResultValue(searchScore, searchText, objectType, createTime, updateTime, id, name, qualifiedName, entityType, description, endorsement, owner, classification?.ToList(), label?.ToList(), term?.ToList(), contact?.ToList(), assetType?.ToList(), glossaryType, glossary, termStatus, termTemplate?.ToList(), longDescription); + } + + /// Initializes a new instance of . + /// The result value. + /// A new instance for mocking. + public static AutoCompleteResult AutoCompleteResult(IEnumerable value = null) + { + value ??= new List(); + + return new AutoCompleteResult(value?.ToList()); + } + + /// Initializes a new instance of . + /// The completed term or phrase. + /// The completed search query text. + /// A new instance for mocking. + public static AutoCompleteResultValue AutoCompleteResultValue(string text = null, string queryPlusText = null) + { + return new AutoCompleteResultValue(text, queryPlusText); + } + + /// Initializes a new instance of . + /// The GUID of the base entity. + /// The GUID entity map. + /// The entity count in specific direction. + /// The depth of lineage. + /// The width of lineage. + /// The number of children node. + /// The enum of lineage direction. + /// An array of parentRelations relations. + /// An array of lineage relations. + /// A new instance for mocking. + public static AtlasLineageInfo AtlasLineageInfo(string baseEntityGuid = null, IReadOnlyDictionary guidEntityMap = null, IReadOnlyDictionary> widthCounts = null, int? lineageDepth = null, int? lineageWidth = null, int? childrenCount = null, LineageDirection? lineageDirection = null, IEnumerable parentRelations = null, IEnumerable relations = null) + { + guidEntityMap ??= new Dictionary(); + widthCounts ??= new Dictionary>(); + parentRelations ??= new List(); + relations ??= new List(); + + return new AtlasLineageInfo(baseEntityGuid, guidEntityMap, widthCounts, lineageDepth, lineageWidth, childrenCount, lineageDirection, parentRelations?.ToList(), relations?.ToList()); + } + + /// Initializes a new instance of . + /// The GUID of child entity. + /// The GUID of relationship. + /// The GUID of parent entity. + /// A new instance for mocking. + public static ParentRelation ParentRelation(string childEntityId = null, string relationshipId = null, string parentEntityId = null) + { + return new ParentRelation(childEntityId, relationshipId, parentEntityId); + } + + /// Initializes a new instance of . + /// The GUID of from-entity. + /// The GUID of relationship. + /// The GUID of to-entity. + /// A new instance for mocking. + public static LineageRelation LineageRelation(string fromEntityId = null, string relationshipId = null, string toEntityId = null) + { + return new LineageRelation(fromEntityId, relationshipId, toEntityId); + } + + /// Initializes a new instance of . + /// The referred entity header. + /// Atlas relationship instance. + /// A new instance for mocking. + public static AtlasRelationshipWithExtInfo AtlasRelationshipWithExtInfo(IReadOnlyDictionary referredEntities = null, AtlasRelationship relationship = null) + { + referredEntities ??= new Dictionary(); + + return new AtlasRelationshipWithExtInfo(referredEntities, relationship); + } + + /// Initializes a new instance of . + /// The enum of type category. + /// The created time of the record. + /// The user who created the record. + /// The date format. + /// The description of the type definition. + /// The GUID of the type definition. + /// The name of the type definition. + /// The options for the type definition. + /// The service type. + /// The version of the type. + /// The update time of the record. + /// The user who updated the record. + /// The version of the record. + /// ETag for concurrency control. + /// + /// Specifying a list of entityType names in the classificationDef, ensures that + /// classifications can + /// only be applied to those entityTypes. + /// + /// Any subtypes of the entity types inherit the restriction. + /// + /// Any classificationDef subtypes inherit the parents entityTypes restrictions. + /// + /// Any classificationDef subtypes can further restrict the parents entityTypes + /// restrictions by specifying a subset of the entityTypes. + /// + /// An empty entityTypes list when there are no parent restrictions means there are no + /// restrictions. + /// + /// An empty entityTypes list when there are parent + /// restrictions means that the subtype picks up the parents + /// restrictions. + /// + /// If a list of entityTypes are supplied, where one inherits + /// from another, this will be rejected. This should encourage cleaner + /// classificationsDefs. + /// + /// + /// An array of sub types. + /// An array of super types. + /// An array of relationship attributes. + /// The default value. + /// An array of enum element definitions. + /// + /// The relationshipEndDef represents an end of the relationship. The end of the + /// relationship is defined by a type, an + /// attribute name, cardinality and whether + /// it is the container end of the relationship. + /// + /// + /// The relationshipEndDef represents an end of the relationship. The end of the + /// relationship is defined by a type, an + /// attribute name, cardinality and whether + /// it is the container end of the relationship. + /// + /// + /// The Relationship category determines the style of relationship around + /// containment and lifecycle. + /// UML terminology is used for the values. + /// + /// ASSOCIATION is a relationship with no containment. + /// COMPOSITION and AGGREGATION are containment relationships. + /// + /// The difference being in the lifecycles of the container and its children. + /// In the COMPOSITION case, the children cannot exist without the container. + /// For AGGREGATION, the life cycles of the container and children are totally independent. + /// + /// The label of the relationship. + /// An array of attribute definitions. + /// A new instance for mocking. + public static AtlasTypeDef AtlasTypeDef(TypeCategory? category = null, long? createTime = null, string createdBy = null, DateFormat dateFormatter = null, string description = null, string guid = null, string name = null, IReadOnlyDictionary options = null, string serviceType = null, string typeVersion = null, long? updateTime = null, string updatedBy = null, long? version = null, string lastModifiedTS = null, IEnumerable entityTypes = null, IEnumerable subTypes = null, IEnumerable superTypes = null, IEnumerable relationshipAttributeDefs = null, string defaultValue = null, IEnumerable elementDefs = null, AtlasRelationshipEndDef endDef1 = null, AtlasRelationshipEndDef endDef2 = null, RelationshipCategory? relationshipCategory = null, string relationshipLabel = null, IEnumerable attributeDefs = null) + { + options ??= new Dictionary(); + entityTypes ??= new List(); + subTypes ??= new List(); + superTypes ??= new List(); + relationshipAttributeDefs ??= new List(); + elementDefs ??= new List(); + attributeDefs ??= new List(); + + return new AtlasTypeDef(category, createTime, createdBy, dateFormatter, description, guid, name, options, serviceType, typeVersion, updateTime, updatedBy, version, lastModifiedTS, entityTypes?.ToList(), subTypes?.ToList(), superTypes?.ToList(), relationshipAttributeDefs?.ToList(), defaultValue, elementDefs?.ToList(), endDef1, endDef2, relationshipCategory, relationshipLabel, attributeDefs?.ToList()); + } + + /// Initializes a new instance of . + /// The enum of type category. + /// The GUID of the type definition. + /// The name of the type definition. + /// A new instance for mocking. + public static AtlasTypeDefHeader AtlasTypeDefHeader(TypeCategory? category = null, string guid = null, string name = null) + { + return new AtlasTypeDefHeader(category, guid, name); + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AndFilter.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AndFilter.Serialization.cs new file mode 100644 index 0000000000000..6d0250f487471 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AndFilter.Serialization.cs @@ -0,0 +1,38 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class AndFilter : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + writer.WritePropertyName("and"u8); + writer.WriteStartArray(); + foreach (var item in AndFilters) + { + writer.WriteObjectValue(item); + } + writer.WriteEndArray(); + writer.WritePropertyName("kind"u8); + writer.WriteStringValue(Kind); + writer.WriteEndObject(); + } + + /// Convert into a Utf8JsonRequestContent. + internal override RequestContent ToRequestContent() + { + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(this); + return content; + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AndFilter.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AndFilter.cs new file mode 100644 index 0000000000000..840f0f746427f --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AndFilter.cs @@ -0,0 +1,44 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Collections.Generic; +using System.Linq; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + /// And filter for search. + public partial class AndFilter : SearchFilter + { + /// Initializes a new instance of . + /// List of filters. + /// is null. + public AndFilter(IEnumerable andFilters) + { + Argument.AssertNotNull(andFilters, nameof(andFilters)); + + Kind = "AndFilter"; + AndFilters = andFilters.ToList(); + } + + /// Initializes a new instance of . + /// Discriminator. + /// List of filters. + internal AndFilter(string kind, IList andFilters) : base(kind) + { + AndFilters = andFilters; + } + + /// + /// List of filters + /// Please note is the base class. According to the scenario, a derived class of the base class might need to be assigned here, or this property needs to be casted to one of the possible derived classes. + /// The available derived classes include , , , , , , , , , , , , , , , , , , , , and . + /// + public IList AndFilters { get; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AssetTypeFilter.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AssetTypeFilter.Serialization.cs new file mode 100644 index 0000000000000..6d59f8f97b2b9 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AssetTypeFilter.Serialization.cs @@ -0,0 +1,33 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class AssetTypeFilter : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + writer.WritePropertyName("assetType"u8); + writer.WriteStringValue(AssetType); + writer.WritePropertyName("kind"u8); + writer.WriteStringValue(Kind); + writer.WriteEndObject(); + } + + /// Convert into a Utf8JsonRequestContent. + internal override RequestContent ToRequestContent() + { + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(this); + return content; + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AssetTypeFilter.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AssetTypeFilter.cs new file mode 100644 index 0000000000000..fa055ef62b7b9 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AssetTypeFilter.cs @@ -0,0 +1,38 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + /// Asset type filter for search. + public partial class AssetTypeFilter : SearchFilter + { + /// Initializes a new instance of . + /// Asset type name. + /// is null. + public AssetTypeFilter(string assetType) + { + Argument.AssertNotNull(assetType, nameof(assetType)); + + Kind = "AssetTypeFilter"; + AssetType = assetType; + } + + /// Initializes a new instance of . + /// Discriminator. + /// Asset type name. + internal AssetTypeFilter(string kind, string assetType) : base(kind) + { + AssetType = assetType; + } + + /// Asset type name. + public string AssetType { get; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasAttributeDef.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasAttributeDef.Serialization.cs new file mode 100644 index 0000000000000..5e9567608de77 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasAttributeDef.Serialization.cs @@ -0,0 +1,251 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using System.Text.Json; +using Azure; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class AtlasAttributeDef : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + if (Optional.IsDefined(Cardinality)) + { + writer.WritePropertyName("cardinality"u8); + writer.WriteStringValue(Cardinality.Value.ToString()); + } + if (Optional.IsCollectionDefined(Constraints)) + { + writer.WritePropertyName("constraints"u8); + writer.WriteStartArray(); + foreach (var item in Constraints) + { + writer.WriteObjectValue(item); + } + writer.WriteEndArray(); + } + if (Optional.IsDefined(DefaultValue)) + { + writer.WritePropertyName("defaultValue"u8); + writer.WriteStringValue(DefaultValue); + } + if (Optional.IsDefined(Description)) + { + writer.WritePropertyName("description"u8); + writer.WriteStringValue(Description); + } + if (Optional.IsDefined(IncludeInNotification)) + { + writer.WritePropertyName("includeInNotification"u8); + writer.WriteBooleanValue(IncludeInNotification.Value); + } + if (Optional.IsDefined(IsIndexable)) + { + writer.WritePropertyName("isIndexable"u8); + writer.WriteBooleanValue(IsIndexable.Value); + } + if (Optional.IsDefined(IsOptional)) + { + writer.WritePropertyName("isOptional"u8); + writer.WriteBooleanValue(IsOptional.Value); + } + if (Optional.IsDefined(IsUnique)) + { + writer.WritePropertyName("isUnique"u8); + writer.WriteBooleanValue(IsUnique.Value); + } + if (Optional.IsDefined(Name)) + { + writer.WritePropertyName("name"u8); + writer.WriteStringValue(Name); + } + if (Optional.IsCollectionDefined(Options)) + { + writer.WritePropertyName("options"u8); + writer.WriteStartObject(); + foreach (var item in Options) + { + writer.WritePropertyName(item.Key); + writer.WriteStringValue(item.Value); + } + writer.WriteEndObject(); + } + if (Optional.IsDefined(TypeName)) + { + writer.WritePropertyName("typeName"u8); + writer.WriteStringValue(TypeName); + } + if (Optional.IsDefined(ValuesMaxCount)) + { + writer.WritePropertyName("valuesMaxCount"u8); + writer.WriteNumberValue(ValuesMaxCount.Value); + } + if (Optional.IsDefined(ValuesMinCount)) + { + writer.WritePropertyName("valuesMinCount"u8); + writer.WriteNumberValue(ValuesMinCount.Value); + } + writer.WriteEndObject(); + } + + internal static AtlasAttributeDef DeserializeAtlasAttributeDef(JsonElement element) + { + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + Optional cardinality = default; + Optional> constraints = default; + Optional defaultValue = default; + Optional description = default; + Optional includeInNotification = default; + Optional isIndexable = default; + Optional isOptional = default; + Optional isUnique = default; + Optional name = default; + Optional> options = default; + Optional typeName = default; + Optional valuesMaxCount = default; + Optional valuesMinCount = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("cardinality"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + cardinality = new CardinalityValue(property.Value.GetString()); + continue; + } + if (property.NameEquals("constraints"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(AtlasConstraintDef.DeserializeAtlasConstraintDef(item)); + } + constraints = array; + continue; + } + if (property.NameEquals("defaultValue"u8)) + { + defaultValue = property.Value.GetString(); + continue; + } + if (property.NameEquals("description"u8)) + { + description = property.Value.GetString(); + continue; + } + if (property.NameEquals("includeInNotification"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + includeInNotification = property.Value.GetBoolean(); + continue; + } + if (property.NameEquals("isIndexable"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + isIndexable = property.Value.GetBoolean(); + continue; + } + if (property.NameEquals("isOptional"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + isOptional = property.Value.GetBoolean(); + continue; + } + if (property.NameEquals("isUnique"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + isUnique = property.Value.GetBoolean(); + continue; + } + if (property.NameEquals("name"u8)) + { + name = property.Value.GetString(); + continue; + } + if (property.NameEquals("options"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + Dictionary dictionary = new Dictionary(); + foreach (var property0 in property.Value.EnumerateObject()) + { + dictionary.Add(property0.Name, property0.Value.GetString()); + } + options = dictionary; + continue; + } + if (property.NameEquals("typeName"u8)) + { + typeName = property.Value.GetString(); + continue; + } + if (property.NameEquals("valuesMaxCount"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + valuesMaxCount = property.Value.GetInt32(); + continue; + } + if (property.NameEquals("valuesMinCount"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + valuesMinCount = property.Value.GetInt32(); + continue; + } + } + return new AtlasAttributeDef(Optional.ToNullable(cardinality), Optional.ToList(constraints), defaultValue.Value, description.Value, Optional.ToNullable(includeInNotification), Optional.ToNullable(isIndexable), Optional.ToNullable(isOptional), Optional.ToNullable(isUnique), name.Value, Optional.ToDictionary(options), typeName.Value, Optional.ToNullable(valuesMaxCount), Optional.ToNullable(valuesMinCount)); + } + + /// Deserializes the model from a raw response. + /// The response to deserialize the model from. + internal static AtlasAttributeDef FromResponse(Response response) + { + using var document = JsonDocument.Parse(response.Content); + return DeserializeAtlasAttributeDef(document.RootElement); + } + + /// Convert into a Utf8JsonRequestContent. + internal virtual RequestContent ToRequestContent() + { + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(this); + return content; + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasAttributeDef.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasAttributeDef.cs new file mode 100644 index 0000000000000..919695c4be025 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasAttributeDef.cs @@ -0,0 +1,81 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + /// class that captures details of a struct-attribute. + public partial class AtlasAttributeDef + { + /// Initializes a new instance of . + public AtlasAttributeDef() + { + Constraints = new ChangeTrackingList(); + Options = new ChangeTrackingDictionary(); + } + + /// Initializes a new instance of . + /// single-valued attribute or multi-valued attribute. + /// An array of constraints. + /// The default value of the attribute. + /// The description of the attribute. + /// Determines if it is included in notification. + /// Determines if it is indexable. + /// Determines if it is optional. + /// Determines if it unique. + /// The name of the attribute. + /// The options for the attribute. + /// The name of the type. + /// The maximum count of the values. + /// The minimum count of the values. + internal AtlasAttributeDef(CardinalityValue? cardinality, IList constraints, string defaultValue, string description, bool? includeInNotification, bool? isIndexable, bool? isOptional, bool? isUnique, string name, IDictionary options, string typeName, int? valuesMaxCount, int? valuesMinCount) + { + Cardinality = cardinality; + Constraints = constraints; + DefaultValue = defaultValue; + Description = description; + IncludeInNotification = includeInNotification; + IsIndexable = isIndexable; + IsOptional = isOptional; + IsUnique = isUnique; + Name = name; + Options = options; + TypeName = typeName; + ValuesMaxCount = valuesMaxCount; + ValuesMinCount = valuesMinCount; + } + + /// single-valued attribute or multi-valued attribute. + public CardinalityValue? Cardinality { get; set; } + /// An array of constraints. + public IList Constraints { get; } + /// The default value of the attribute. + public string DefaultValue { get; set; } + /// The description of the attribute. + public string Description { get; set; } + /// Determines if it is included in notification. + public bool? IncludeInNotification { get; set; } + /// Determines if it is indexable. + public bool? IsIndexable { get; set; } + /// Determines if it is optional. + public bool? IsOptional { get; set; } + /// Determines if it unique. + public bool? IsUnique { get; set; } + /// The name of the attribute. + public string Name { get; set; } + /// The options for the attribute. + public IDictionary Options { get; } + /// The name of the type. + public string TypeName { get; set; } + /// The maximum count of the values. + public int? ValuesMaxCount { get; set; } + /// The minimum count of the values. + public int? ValuesMinCount { get; set; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasBusinessMetadataDef.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasBusinessMetadataDef.Serialization.cs new file mode 100644 index 0000000000000..286d267531744 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasBusinessMetadataDef.Serialization.cs @@ -0,0 +1,265 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using System.Text.Json; +using Azure; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class AtlasBusinessMetadataDef : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + if (Optional.IsDefined(Category)) + { + writer.WritePropertyName("category"u8); + writer.WriteStringValue(Category.Value.ToString()); + } + if (Optional.IsDefined(CreateTime)) + { + writer.WritePropertyName("createTime"u8); + writer.WriteNumberValue(CreateTime.Value); + } + if (Optional.IsDefined(CreatedBy)) + { + writer.WritePropertyName("createdBy"u8); + writer.WriteStringValue(CreatedBy); + } + if (Optional.IsDefined(DateFormatter)) + { + writer.WritePropertyName("dateFormatter"u8); + writer.WriteObjectValue(DateFormatter); + } + if (Optional.IsDefined(Description)) + { + writer.WritePropertyName("description"u8); + writer.WriteStringValue(Description); + } + if (Optional.IsDefined(Guid)) + { + writer.WritePropertyName("guid"u8); + writer.WriteStringValue(Guid); + } + if (Optional.IsDefined(Name)) + { + writer.WritePropertyName("name"u8); + writer.WriteStringValue(Name); + } + if (Optional.IsCollectionDefined(Options)) + { + writer.WritePropertyName("options"u8); + writer.WriteStartObject(); + foreach (var item in Options) + { + writer.WritePropertyName(item.Key); + writer.WriteStringValue(item.Value); + } + writer.WriteEndObject(); + } + if (Optional.IsDefined(ServiceType)) + { + writer.WritePropertyName("serviceType"u8); + writer.WriteStringValue(ServiceType); + } + if (Optional.IsDefined(TypeVersion)) + { + writer.WritePropertyName("typeVersion"u8); + writer.WriteStringValue(TypeVersion); + } + if (Optional.IsDefined(UpdateTime)) + { + writer.WritePropertyName("updateTime"u8); + writer.WriteNumberValue(UpdateTime.Value); + } + if (Optional.IsDefined(UpdatedBy)) + { + writer.WritePropertyName("updatedBy"u8); + writer.WriteStringValue(UpdatedBy); + } + if (Optional.IsDefined(Version)) + { + writer.WritePropertyName("version"u8); + writer.WriteNumberValue(Version.Value); + } + if (Optional.IsDefined(LastModifiedTS)) + { + writer.WritePropertyName("lastModifiedTS"u8); + writer.WriteStringValue(LastModifiedTS); + } + if (Optional.IsCollectionDefined(AttributeDefs)) + { + writer.WritePropertyName("attributeDefs"u8); + writer.WriteStartArray(); + foreach (var item in AttributeDefs) + { + writer.WriteObjectValue(item); + } + writer.WriteEndArray(); + } + writer.WriteEndObject(); + } + + internal static AtlasBusinessMetadataDef DeserializeAtlasBusinessMetadataDef(JsonElement element) + { + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + Optional category = default; + Optional createTime = default; + Optional createdBy = default; + Optional dateFormatter = default; + Optional description = default; + Optional guid = default; + Optional name = default; + Optional> options = default; + Optional serviceType = default; + Optional typeVersion = default; + Optional updateTime = default; + Optional updatedBy = default; + Optional version = default; + Optional lastModifiedTS = default; + Optional> attributeDefs = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("category"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + category = new TypeCategory(property.Value.GetString()); + continue; + } + if (property.NameEquals("createTime"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + createTime = property.Value.GetInt64(); + continue; + } + if (property.NameEquals("createdBy"u8)) + { + createdBy = property.Value.GetString(); + continue; + } + if (property.NameEquals("dateFormatter"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + dateFormatter = DateFormat.DeserializeDateFormat(property.Value); + continue; + } + if (property.NameEquals("description"u8)) + { + description = property.Value.GetString(); + continue; + } + if (property.NameEquals("guid"u8)) + { + guid = property.Value.GetString(); + continue; + } + if (property.NameEquals("name"u8)) + { + name = property.Value.GetString(); + continue; + } + if (property.NameEquals("options"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + Dictionary dictionary = new Dictionary(); + foreach (var property0 in property.Value.EnumerateObject()) + { + dictionary.Add(property0.Name, property0.Value.GetString()); + } + options = dictionary; + continue; + } + if (property.NameEquals("serviceType"u8)) + { + serviceType = property.Value.GetString(); + continue; + } + if (property.NameEquals("typeVersion"u8)) + { + typeVersion = property.Value.GetString(); + continue; + } + if (property.NameEquals("updateTime"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + updateTime = property.Value.GetInt64(); + continue; + } + if (property.NameEquals("updatedBy"u8)) + { + updatedBy = property.Value.GetString(); + continue; + } + if (property.NameEquals("version"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + version = property.Value.GetInt64(); + continue; + } + if (property.NameEquals("lastModifiedTS"u8)) + { + lastModifiedTS = property.Value.GetString(); + continue; + } + if (property.NameEquals("attributeDefs"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(AtlasAttributeDef.DeserializeAtlasAttributeDef(item)); + } + attributeDefs = array; + continue; + } + } + return new AtlasBusinessMetadataDef(Optional.ToNullable(category), Optional.ToNullable(createTime), createdBy.Value, dateFormatter.Value, description.Value, guid.Value, name.Value, Optional.ToDictionary(options), serviceType.Value, typeVersion.Value, Optional.ToNullable(updateTime), updatedBy.Value, Optional.ToNullable(version), lastModifiedTS.Value, Optional.ToList(attributeDefs)); + } + + /// Deserializes the model from a raw response. + /// The response to deserialize the model from. + internal static AtlasBusinessMetadataDef FromResponse(Response response) + { + using var document = JsonDocument.Parse(response.Content); + return DeserializeAtlasBusinessMetadataDef(document.RootElement); + } + + /// Convert into a Utf8JsonRequestContent. + internal virtual RequestContent ToRequestContent() + { + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(this); + return content; + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasBusinessMetadataDef.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasBusinessMetadataDef.cs new file mode 100644 index 0000000000000..3eb61e443f148 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasBusinessMetadataDef.cs @@ -0,0 +1,89 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + /// class that captures details of a struct-type. + public partial class AtlasBusinessMetadataDef + { + /// Initializes a new instance of . + public AtlasBusinessMetadataDef() + { + Options = new ChangeTrackingDictionary(); + AttributeDefs = new ChangeTrackingList(); + } + + /// Initializes a new instance of . + /// The enum of type category. + /// The created time of the record. + /// The user who created the record. + /// The date format. + /// The description of the type definition. + /// The GUID of the type definition. + /// The name of the type definition. + /// The options for the type definition. + /// The service type. + /// The version of the type. + /// The update time of the record. + /// The user who updated the record. + /// The version of the record. + /// ETag for concurrency control. + /// An array of attribute definitions. + internal AtlasBusinessMetadataDef(TypeCategory? category, long? createTime, string createdBy, DateFormat dateFormatter, string description, string guid, string name, IDictionary options, string serviceType, string typeVersion, long? updateTime, string updatedBy, long? version, string lastModifiedTS, IList attributeDefs) + { + Category = category; + CreateTime = createTime; + CreatedBy = createdBy; + DateFormatter = dateFormatter; + Description = description; + Guid = guid; + Name = name; + Options = options; + ServiceType = serviceType; + TypeVersion = typeVersion; + UpdateTime = updateTime; + UpdatedBy = updatedBy; + Version = version; + LastModifiedTS = lastModifiedTS; + AttributeDefs = attributeDefs; + } + + /// The enum of type category. + public TypeCategory? Category { get; set; } + /// The created time of the record. + public long? CreateTime { get; set; } + /// The user who created the record. + public string CreatedBy { get; set; } + /// The date format. + public DateFormat DateFormatter { get; set; } + /// The description of the type definition. + public string Description { get; set; } + /// The GUID of the type definition. + public string Guid { get; set; } + /// The name of the type definition. + public string Name { get; set; } + /// The options for the type definition. + public IDictionary Options { get; } + /// The service type. + public string ServiceType { get; set; } + /// The version of the type. + public string TypeVersion { get; set; } + /// The update time of the record. + public long? UpdateTime { get; set; } + /// The user who updated the record. + public string UpdatedBy { get; set; } + /// The version of the record. + public long? Version { get; set; } + /// ETag for concurrency control. + public string LastModifiedTS { get; set; } + /// An array of attribute definitions. + public IList AttributeDefs { get; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasClassification.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasClassification.Serialization.cs new file mode 100644 index 0000000000000..7ec521d415604 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasClassification.Serialization.cs @@ -0,0 +1,185 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Collections.Generic; +using System.Text.Json; +using Azure; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class AtlasClassification : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + if (Optional.IsCollectionDefined(Attributes)) + { + writer.WritePropertyName("attributes"u8); + writer.WriteStartObject(); + foreach (var item in Attributes) + { + writer.WritePropertyName(item.Key); + if (item.Value == null) + { + writer.WriteNullValue(); + continue; + } +#if NET6_0_OR_GREATER + writer.WriteRawValue(item.Value); +#else + using (JsonDocument document = JsonDocument.Parse(item.Value)) + { + JsonSerializer.Serialize(writer, document.RootElement); + } +#endif + } + writer.WriteEndObject(); + } + if (Optional.IsDefined(TypeName)) + { + writer.WritePropertyName("typeName"u8); + writer.WriteStringValue(TypeName); + } + if (Optional.IsDefined(LastModifiedTS)) + { + writer.WritePropertyName("lastModifiedTS"u8); + writer.WriteStringValue(LastModifiedTS); + } + if (Optional.IsDefined(EntityGuid)) + { + writer.WritePropertyName("entityGuid"u8); + writer.WriteStringValue(EntityGuid); + } + if (Optional.IsDefined(EntityStatus)) + { + writer.WritePropertyName("entityStatus"u8); + writer.WriteStringValue(EntityStatus.Value.ToString()); + } + if (Optional.IsDefined(RemovePropagationsOnEntityDelete)) + { + writer.WritePropertyName("removePropagationsOnEntityDelete"u8); + writer.WriteBooleanValue(RemovePropagationsOnEntityDelete.Value); + } + if (Optional.IsCollectionDefined(ValidityPeriods)) + { + writer.WritePropertyName("validityPeriods"u8); + writer.WriteStartArray(); + foreach (var item in ValidityPeriods) + { + writer.WriteObjectValue(item); + } + writer.WriteEndArray(); + } + writer.WriteEndObject(); + } + + internal static AtlasClassification DeserializeAtlasClassification(JsonElement element) + { + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + Optional> attributes = default; + Optional typeName = default; + Optional lastModifiedTS = default; + Optional entityGuid = default; + Optional entityStatus = default; + Optional removePropagationsOnEntityDelete = default; + Optional> validityPeriods = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("attributes"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + Dictionary dictionary = new Dictionary(); + foreach (var property0 in property.Value.EnumerateObject()) + { + if (property0.Value.ValueKind == JsonValueKind.Null) + { + dictionary.Add(property0.Name, null); + } + else + { + dictionary.Add(property0.Name, BinaryData.FromString(property0.Value.GetRawText())); + } + } + attributes = dictionary; + continue; + } + if (property.NameEquals("typeName"u8)) + { + typeName = property.Value.GetString(); + continue; + } + if (property.NameEquals("lastModifiedTS"u8)) + { + lastModifiedTS = property.Value.GetString(); + continue; + } + if (property.NameEquals("entityGuid"u8)) + { + entityGuid = property.Value.GetString(); + continue; + } + if (property.NameEquals("entityStatus"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + entityStatus = new EntityStatus(property.Value.GetString()); + continue; + } + if (property.NameEquals("removePropagationsOnEntityDelete"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + removePropagationsOnEntityDelete = property.Value.GetBoolean(); + continue; + } + if (property.NameEquals("validityPeriods"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(TimeBoundary.DeserializeTimeBoundary(item)); + } + validityPeriods = array; + continue; + } + } + return new AtlasClassification(Optional.ToDictionary(attributes), typeName.Value, lastModifiedTS.Value, entityGuid.Value, Optional.ToNullable(entityStatus), Optional.ToNullable(removePropagationsOnEntityDelete), Optional.ToList(validityPeriods)); + } + + /// Deserializes the model from a raw response. + /// The response to deserialize the model from. + internal static AtlasClassification FromResponse(Response response) + { + using var document = JsonDocument.Parse(response.Content); + return DeserializeAtlasClassification(document.RootElement); + } + + /// Convert into a Utf8JsonRequestContent. + internal virtual RequestContent ToRequestContent() + { + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(this); + return content; + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasClassification.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasClassification.cs new file mode 100644 index 0000000000000..9e16531758040 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasClassification.cs @@ -0,0 +1,96 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Collections.Generic; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + /// + /// An instance of a classification; it doesn't have an identity, this object + /// exists only when associated with an entity. + /// + public partial class AtlasClassification + { + /// Initializes a new instance of . + public AtlasClassification() + { + Attributes = new ChangeTrackingDictionary(); + ValidityPeriods = new ChangeTrackingList(); + } + + /// Initializes a new instance of . + /// The attributes of the struct. + /// The name of the type. + /// ETag for concurrency control. + /// The GUID of the entity. + /// + /// Status of the entity - can be active or deleted. Deleted entities are not + /// removed. + /// + /// Determines if propagations will be removed on entity deletion. + /// An array of time boundaries indicating validity periods. + internal AtlasClassification(IDictionary attributes, string typeName, string lastModifiedTS, string entityGuid, EntityStatus? entityStatus, bool? removePropagationsOnEntityDelete, IList validityPeriods) + { + Attributes = attributes; + TypeName = typeName; + LastModifiedTS = lastModifiedTS; + EntityGuid = entityGuid; + EntityStatus = entityStatus; + RemovePropagationsOnEntityDelete = removePropagationsOnEntityDelete; + ValidityPeriods = validityPeriods; + } + + /// + /// The attributes of the struct. + /// + /// To assign an object to the value of this property use . + /// + /// + /// To assign an already formatted json string to this property use . + /// + /// + /// Examples: + /// + /// + /// BinaryData.FromObjectAsJson("foo") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromString("\"foo\"") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromObjectAsJson(new { key = "value" }) + /// Creates a payload of { "key": "value" }. + /// + /// + /// BinaryData.FromString("{\"key\": \"value\"}") + /// Creates a payload of { "key": "value" }. + /// + /// + /// + /// + public IDictionary Attributes { get; } + /// The name of the type. + public string TypeName { get; set; } + /// ETag for concurrency control. + public string LastModifiedTS { get; set; } + /// The GUID of the entity. + public string EntityGuid { get; set; } + /// + /// Status of the entity - can be active or deleted. Deleted entities are not + /// removed. + /// + public EntityStatus? EntityStatus { get; set; } + /// Determines if propagations will be removed on entity deletion. + public bool? RemovePropagationsOnEntityDelete { get; set; } + /// An array of time boundaries indicating validity periods. + public IList ValidityPeriods { get; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasClassificationDef.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasClassificationDef.Serialization.cs new file mode 100644 index 0000000000000..8802132173879 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasClassificationDef.Serialization.cs @@ -0,0 +1,340 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using System.Text.Json; +using Azure; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class AtlasClassificationDef : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + if (Optional.IsDefined(Category)) + { + writer.WritePropertyName("category"u8); + writer.WriteStringValue(Category.Value.ToString()); + } + if (Optional.IsDefined(CreateTime)) + { + writer.WritePropertyName("createTime"u8); + writer.WriteNumberValue(CreateTime.Value); + } + if (Optional.IsDefined(CreatedBy)) + { + writer.WritePropertyName("createdBy"u8); + writer.WriteStringValue(CreatedBy); + } + if (Optional.IsDefined(DateFormatter)) + { + writer.WritePropertyName("dateFormatter"u8); + writer.WriteObjectValue(DateFormatter); + } + if (Optional.IsDefined(Description)) + { + writer.WritePropertyName("description"u8); + writer.WriteStringValue(Description); + } + if (Optional.IsDefined(Guid)) + { + writer.WritePropertyName("guid"u8); + writer.WriteStringValue(Guid); + } + if (Optional.IsDefined(Name)) + { + writer.WritePropertyName("name"u8); + writer.WriteStringValue(Name); + } + if (Optional.IsCollectionDefined(Options)) + { + writer.WritePropertyName("options"u8); + writer.WriteStartObject(); + foreach (var item in Options) + { + writer.WritePropertyName(item.Key); + writer.WriteStringValue(item.Value); + } + writer.WriteEndObject(); + } + if (Optional.IsDefined(ServiceType)) + { + writer.WritePropertyName("serviceType"u8); + writer.WriteStringValue(ServiceType); + } + if (Optional.IsDefined(TypeVersion)) + { + writer.WritePropertyName("typeVersion"u8); + writer.WriteStringValue(TypeVersion); + } + if (Optional.IsDefined(UpdateTime)) + { + writer.WritePropertyName("updateTime"u8); + writer.WriteNumberValue(UpdateTime.Value); + } + if (Optional.IsDefined(UpdatedBy)) + { + writer.WritePropertyName("updatedBy"u8); + writer.WriteStringValue(UpdatedBy); + } + if (Optional.IsDefined(Version)) + { + writer.WritePropertyName("version"u8); + writer.WriteNumberValue(Version.Value); + } + if (Optional.IsDefined(LastModifiedTS)) + { + writer.WritePropertyName("lastModifiedTS"u8); + writer.WriteStringValue(LastModifiedTS); + } + if (Optional.IsCollectionDefined(AttributeDefs)) + { + writer.WritePropertyName("attributeDefs"u8); + writer.WriteStartArray(); + foreach (var item in AttributeDefs) + { + writer.WriteObjectValue(item); + } + writer.WriteEndArray(); + } + if (Optional.IsCollectionDefined(EntityTypes)) + { + writer.WritePropertyName("entityTypes"u8); + writer.WriteStartArray(); + foreach (var item in EntityTypes) + { + writer.WriteStringValue(item); + } + writer.WriteEndArray(); + } + if (Optional.IsCollectionDefined(SubTypes)) + { + writer.WritePropertyName("subTypes"u8); + writer.WriteStartArray(); + foreach (var item in SubTypes) + { + writer.WriteStringValue(item); + } + writer.WriteEndArray(); + } + if (Optional.IsCollectionDefined(SuperTypes)) + { + writer.WritePropertyName("superTypes"u8); + writer.WriteStartArray(); + foreach (var item in SuperTypes) + { + writer.WriteStringValue(item); + } + writer.WriteEndArray(); + } + writer.WriteEndObject(); + } + + internal static AtlasClassificationDef DeserializeAtlasClassificationDef(JsonElement element) + { + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + Optional category = default; + Optional createTime = default; + Optional createdBy = default; + Optional dateFormatter = default; + Optional description = default; + Optional guid = default; + Optional name = default; + Optional> options = default; + Optional serviceType = default; + Optional typeVersion = default; + Optional updateTime = default; + Optional updatedBy = default; + Optional version = default; + Optional lastModifiedTS = default; + Optional> attributeDefs = default; + Optional> entityTypes = default; + Optional> subTypes = default; + Optional> superTypes = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("category"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + category = new TypeCategory(property.Value.GetString()); + continue; + } + if (property.NameEquals("createTime"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + createTime = property.Value.GetInt64(); + continue; + } + if (property.NameEquals("createdBy"u8)) + { + createdBy = property.Value.GetString(); + continue; + } + if (property.NameEquals("dateFormatter"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + dateFormatter = DateFormat.DeserializeDateFormat(property.Value); + continue; + } + if (property.NameEquals("description"u8)) + { + description = property.Value.GetString(); + continue; + } + if (property.NameEquals("guid"u8)) + { + guid = property.Value.GetString(); + continue; + } + if (property.NameEquals("name"u8)) + { + name = property.Value.GetString(); + continue; + } + if (property.NameEquals("options"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + Dictionary dictionary = new Dictionary(); + foreach (var property0 in property.Value.EnumerateObject()) + { + dictionary.Add(property0.Name, property0.Value.GetString()); + } + options = dictionary; + continue; + } + if (property.NameEquals("serviceType"u8)) + { + serviceType = property.Value.GetString(); + continue; + } + if (property.NameEquals("typeVersion"u8)) + { + typeVersion = property.Value.GetString(); + continue; + } + if (property.NameEquals("updateTime"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + updateTime = property.Value.GetInt64(); + continue; + } + if (property.NameEquals("updatedBy"u8)) + { + updatedBy = property.Value.GetString(); + continue; + } + if (property.NameEquals("version"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + version = property.Value.GetInt64(); + continue; + } + if (property.NameEquals("lastModifiedTS"u8)) + { + lastModifiedTS = property.Value.GetString(); + continue; + } + if (property.NameEquals("attributeDefs"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(AtlasAttributeDef.DeserializeAtlasAttributeDef(item)); + } + attributeDefs = array; + continue; + } + if (property.NameEquals("entityTypes"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(item.GetString()); + } + entityTypes = array; + continue; + } + if (property.NameEquals("subTypes"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(item.GetString()); + } + subTypes = array; + continue; + } + if (property.NameEquals("superTypes"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(item.GetString()); + } + superTypes = array; + continue; + } + } + return new AtlasClassificationDef(Optional.ToNullable(category), Optional.ToNullable(createTime), createdBy.Value, dateFormatter.Value, description.Value, guid.Value, name.Value, Optional.ToDictionary(options), serviceType.Value, typeVersion.Value, Optional.ToNullable(updateTime), updatedBy.Value, Optional.ToNullable(version), lastModifiedTS.Value, Optional.ToList(attributeDefs), Optional.ToList(entityTypes), Optional.ToList(subTypes), Optional.ToList(superTypes)); + } + + /// Deserializes the model from a raw response. + /// The response to deserialize the model from. + internal static AtlasClassificationDef FromResponse(Response response) + { + using var document = JsonDocument.Parse(response.Content); + return DeserializeAtlasClassificationDef(document.RootElement); + } + + /// Convert into a Utf8JsonRequestContent. + internal virtual RequestContent ToRequestContent() + { + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(this); + return content; + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasClassificationDef.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasClassificationDef.cs new file mode 100644 index 0000000000000..1b9264180a6ec --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasClassificationDef.cs @@ -0,0 +1,150 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + /// class that captures details of a classification-type. + public partial class AtlasClassificationDef + { + /// Initializes a new instance of . + public AtlasClassificationDef() + { + Options = new ChangeTrackingDictionary(); + AttributeDefs = new ChangeTrackingList(); + EntityTypes = new ChangeTrackingList(); + SubTypes = new ChangeTrackingList(); + SuperTypes = new ChangeTrackingList(); + } + + /// Initializes a new instance of . + /// The enum of type category. + /// The created time of the record. + /// The user who created the record. + /// The date format. + /// The description of the type definition. + /// The GUID of the type definition. + /// The name of the type definition. + /// The options for the type definition. + /// The service type. + /// The version of the type. + /// The update time of the record. + /// The user who updated the record. + /// The version of the record. + /// ETag for concurrency control. + /// An array of attribute definitions. + /// + /// Specifying a list of entityType names in the classificationDef, ensures that + /// classifications can + /// only be applied to those entityTypes. + /// + /// Any subtypes of the entity types inherit the restriction. + /// + /// Any classificationDef subtypes inherit the parents entityTypes restrictions. + /// + /// Any classificationDef subtypes can further restrict the parents entityTypes + /// restrictions by specifying a subset of the entityTypes. + /// + /// An empty entityTypes list when there are no parent restrictions means there are no + /// restrictions. + /// + /// An empty entityTypes list when there are parent + /// restrictions means that the subtype picks up the parents + /// restrictions. + /// + /// If a list of entityTypes are supplied, where one inherits + /// from another, this will be rejected. This should encourage cleaner + /// classificationsDefs. + /// + /// + /// An array of sub types. + /// An array of super types. + internal AtlasClassificationDef(TypeCategory? category, long? createTime, string createdBy, DateFormat dateFormatter, string description, string guid, string name, IDictionary options, string serviceType, string typeVersion, long? updateTime, string updatedBy, long? version, string lastModifiedTS, IList attributeDefs, IList entityTypes, IList subTypes, IList superTypes) + { + Category = category; + CreateTime = createTime; + CreatedBy = createdBy; + DateFormatter = dateFormatter; + Description = description; + Guid = guid; + Name = name; + Options = options; + ServiceType = serviceType; + TypeVersion = typeVersion; + UpdateTime = updateTime; + UpdatedBy = updatedBy; + Version = version; + LastModifiedTS = lastModifiedTS; + AttributeDefs = attributeDefs; + EntityTypes = entityTypes; + SubTypes = subTypes; + SuperTypes = superTypes; + } + + /// The enum of type category. + public TypeCategory? Category { get; set; } + /// The created time of the record. + public long? CreateTime { get; set; } + /// The user who created the record. + public string CreatedBy { get; set; } + /// The date format. + public DateFormat DateFormatter { get; set; } + /// The description of the type definition. + public string Description { get; set; } + /// The GUID of the type definition. + public string Guid { get; set; } + /// The name of the type definition. + public string Name { get; set; } + /// The options for the type definition. + public IDictionary Options { get; } + /// The service type. + public string ServiceType { get; set; } + /// The version of the type. + public string TypeVersion { get; set; } + /// The update time of the record. + public long? UpdateTime { get; set; } + /// The user who updated the record. + public string UpdatedBy { get; set; } + /// The version of the record. + public long? Version { get; set; } + /// ETag for concurrency control. + public string LastModifiedTS { get; set; } + /// An array of attribute definitions. + public IList AttributeDefs { get; } + /// + /// Specifying a list of entityType names in the classificationDef, ensures that + /// classifications can + /// only be applied to those entityTypes. + /// + /// Any subtypes of the entity types inherit the restriction. + /// + /// Any classificationDef subtypes inherit the parents entityTypes restrictions. + /// + /// Any classificationDef subtypes can further restrict the parents entityTypes + /// restrictions by specifying a subset of the entityTypes. + /// + /// An empty entityTypes list when there are no parent restrictions means there are no + /// restrictions. + /// + /// An empty entityTypes list when there are parent + /// restrictions means that the subtype picks up the parents + /// restrictions. + /// + /// If a list of entityTypes are supplied, where one inherits + /// from another, this will be rejected. This should encourage cleaner + /// classificationsDefs. + /// + /// + public IList EntityTypes { get; } + /// An array of sub types. + public IList SubTypes { get; } + /// An array of super types. + public IList SuperTypes { get; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasClassifications.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasClassifications.Serialization.cs new file mode 100644 index 0000000000000..823759f38abc5 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasClassifications.Serialization.cs @@ -0,0 +1,106 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Collections.Generic; +using System.Text.Json; +using Azure; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class AtlasClassifications + { + internal static AtlasClassifications DeserializeAtlasClassifications(JsonElement element) + { + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + Optional> list = default; + Optional pageSize = default; + Optional sortBy = default; + Optional sortType = default; + Optional startIndex = default; + Optional totalCount = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("list"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + if (item.ValueKind == JsonValueKind.Null) + { + array.Add(null); + } + else + { + array.Add(BinaryData.FromString(item.GetRawText())); + } + } + list = array; + continue; + } + if (property.NameEquals("pageSize"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + pageSize = property.Value.GetInt32(); + continue; + } + if (property.NameEquals("sortBy"u8)) + { + sortBy = property.Value.GetString(); + continue; + } + if (property.NameEquals("sortType"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + sortType = new SortType(property.Value.GetString()); + continue; + } + if (property.NameEquals("startIndex"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + startIndex = property.Value.GetInt32(); + continue; + } + if (property.NameEquals("totalCount"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + totalCount = property.Value.GetInt32(); + continue; + } + } + return new AtlasClassifications(Optional.ToList(list), Optional.ToNullable(pageSize), sortBy.Value, Optional.ToNullable(sortType), Optional.ToNullable(startIndex), Optional.ToNullable(totalCount)); + } + + /// Deserializes the model from a raw response. + /// The response to deserialize the model from. + internal static AtlasClassifications FromResponse(Response response) + { + using var document = JsonDocument.Parse(response.Content); + return DeserializeAtlasClassifications(document.RootElement); + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasClassifications.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasClassifications.cs new file mode 100644 index 0000000000000..6c88d15f62669 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasClassifications.cs @@ -0,0 +1,82 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Collections.Generic; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + /// REST serialization friendly list. + public partial class AtlasClassifications + { + /// Initializes a new instance of . + internal AtlasClassifications() + { + List = new ChangeTrackingList(); + } + + /// Initializes a new instance of . + /// An array of objects. + /// The size of the page. + /// The sorted by field. + /// to specify whether the result should be sorted? If yes, whether asc or desc. + /// The start index of the page. + /// The total count of items. + internal AtlasClassifications(IReadOnlyList list, int? pageSize, string sortBy, SortType? sortType, int? startIndex, int? totalCount) + { + List = list; + PageSize = pageSize; + SortBy = sortBy; + SortType = sortType; + StartIndex = startIndex; + TotalCount = totalCount; + } + + /// + /// An array of objects. + /// + /// To assign an object to the element of this property use . + /// + /// + /// To assign an already formatted json string to this property use . + /// + /// + /// Examples: + /// + /// + /// BinaryData.FromObjectAsJson("foo") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromString("\"foo\"") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromObjectAsJson(new { key = "value" }) + /// Creates a payload of { "key": "value" }. + /// + /// + /// BinaryData.FromString("{\"key\": \"value\"}") + /// Creates a payload of { "key": "value" }. + /// + /// + /// + /// + public IReadOnlyList List { get; } + /// The size of the page. + public int? PageSize { get; } + /// The sorted by field. + public string SortBy { get; } + /// to specify whether the result should be sorted? If yes, whether asc or desc. + public SortType? SortType { get; } + /// The start index of the page. + public int? StartIndex { get; } + /// The total count of items. + public int? TotalCount { get; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasConstraintDef.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasConstraintDef.Serialization.cs new file mode 100644 index 0000000000000..852e295b3f7d5 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasConstraintDef.Serialization.cs @@ -0,0 +1,108 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Collections.Generic; +using System.Text.Json; +using Azure; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class AtlasConstraintDef : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + if (Optional.IsCollectionDefined(Params)) + { + writer.WritePropertyName("params"u8); + writer.WriteStartObject(); + foreach (var item in Params) + { + writer.WritePropertyName(item.Key); + if (item.Value == null) + { + writer.WriteNullValue(); + continue; + } +#if NET6_0_OR_GREATER + writer.WriteRawValue(item.Value); +#else + using (JsonDocument document = JsonDocument.Parse(item.Value)) + { + JsonSerializer.Serialize(writer, document.RootElement); + } +#endif + } + writer.WriteEndObject(); + } + if (Optional.IsDefined(Type)) + { + writer.WritePropertyName("type"u8); + writer.WriteStringValue(Type); + } + writer.WriteEndObject(); + } + + internal static AtlasConstraintDef DeserializeAtlasConstraintDef(JsonElement element) + { + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + Optional> @params = default; + Optional type = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("params"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + Dictionary dictionary = new Dictionary(); + foreach (var property0 in property.Value.EnumerateObject()) + { + if (property0.Value.ValueKind == JsonValueKind.Null) + { + dictionary.Add(property0.Name, null); + } + else + { + dictionary.Add(property0.Name, BinaryData.FromString(property0.Value.GetRawText())); + } + } + @params = dictionary; + continue; + } + if (property.NameEquals("type"u8)) + { + type = property.Value.GetString(); + continue; + } + } + return new AtlasConstraintDef(Optional.ToDictionary(@params), type.Value); + } + + /// Deserializes the model from a raw response. + /// The response to deserialize the model from. + internal static AtlasConstraintDef FromResponse(Response response) + { + using var document = JsonDocument.Parse(response.Content); + return DeserializeAtlasConstraintDef(document.RootElement); + } + + /// Convert into a Utf8JsonRequestContent. + internal virtual RequestContent ToRequestContent() + { + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(this); + return content; + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasConstraintDef.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasConstraintDef.cs new file mode 100644 index 0000000000000..5c7509e584dcb --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasConstraintDef.cs @@ -0,0 +1,66 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Collections.Generic; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + /// class that captures details of a constraint. + public partial class AtlasConstraintDef + { + /// Initializes a new instance of . + public AtlasConstraintDef() + { + Params = new ChangeTrackingDictionary(); + } + + /// Initializes a new instance of . + /// The parameters of the constraint definition. + /// The type of the constraint. + internal AtlasConstraintDef(IDictionary @params, string type) + { + Params = @params; + Type = type; + } + + /// + /// The parameters of the constraint definition. + /// + /// To assign an object to the value of this property use . + /// + /// + /// To assign an already formatted json string to this property use . + /// + /// + /// Examples: + /// + /// + /// BinaryData.FromObjectAsJson("foo") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromString("\"foo\"") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromObjectAsJson(new { key = "value" }) + /// Creates a payload of { "key": "value" }. + /// + /// + /// BinaryData.FromString("{\"key\": \"value\"}") + /// Creates a payload of { "key": "value" }. + /// + /// + /// + /// + public IDictionary Params { get; } + /// The type of the constraint. + public string Type { get; set; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasEntitiesWithExtInfo.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasEntitiesWithExtInfo.Serialization.cs new file mode 100644 index 0000000000000..43513897c4568 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasEntitiesWithExtInfo.Serialization.cs @@ -0,0 +1,102 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using System.Text.Json; +using Azure; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class AtlasEntitiesWithExtInfo : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + if (Optional.IsCollectionDefined(ReferredEntities)) + { + writer.WritePropertyName("referredEntities"u8); + writer.WriteStartObject(); + foreach (var item in ReferredEntities) + { + writer.WritePropertyName(item.Key); + writer.WriteObjectValue(item.Value); + } + writer.WriteEndObject(); + } + if (Optional.IsCollectionDefined(Entities)) + { + writer.WritePropertyName("entities"u8); + writer.WriteStartArray(); + foreach (var item in Entities) + { + writer.WriteObjectValue(item); + } + writer.WriteEndArray(); + } + writer.WriteEndObject(); + } + + internal static AtlasEntitiesWithExtInfo DeserializeAtlasEntitiesWithExtInfo(JsonElement element) + { + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + Optional> referredEntities = default; + Optional> entities = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("referredEntities"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + Dictionary dictionary = new Dictionary(); + foreach (var property0 in property.Value.EnumerateObject()) + { + dictionary.Add(property0.Name, AtlasEntity.DeserializeAtlasEntity(property0.Value)); + } + referredEntities = dictionary; + continue; + } + if (property.NameEquals("entities"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(AtlasEntity.DeserializeAtlasEntity(item)); + } + entities = array; + continue; + } + } + return new AtlasEntitiesWithExtInfo(Optional.ToDictionary(referredEntities), Optional.ToList(entities)); + } + + /// Deserializes the model from a raw response. + /// The response to deserialize the model from. + internal static AtlasEntitiesWithExtInfo FromResponse(Response response) + { + using var document = JsonDocument.Parse(response.Content); + return DeserializeAtlasEntitiesWithExtInfo(document.RootElement); + } + + /// Convert into a Utf8JsonRequestContent. + internal virtual RequestContent ToRequestContent() + { + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(this); + return content; + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasEntitiesWithExtInfo.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasEntitiesWithExtInfo.cs new file mode 100644 index 0000000000000..7683070bc0e5a --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasEntitiesWithExtInfo.cs @@ -0,0 +1,40 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + /// + /// An instance of an entity along with extended info - like hive_table, + /// hive_database. + /// + public partial class AtlasEntitiesWithExtInfo + { + /// Initializes a new instance of . + public AtlasEntitiesWithExtInfo() + { + ReferredEntities = new ChangeTrackingDictionary(); + Entities = new ChangeTrackingList(); + } + + /// Initializes a new instance of . + /// The referred entities. + /// An array of entities. + internal AtlasEntitiesWithExtInfo(IDictionary referredEntities, IList entities) + { + ReferredEntities = referredEntities; + Entities = entities; + } + + /// The referred entities. + public IDictionary ReferredEntities { get; } + /// An array of entities. + public IList Entities { get; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasEntity.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasEntity.Serialization.cs new file mode 100644 index 0000000000000..bd1f863757d0e --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasEntity.Serialization.cs @@ -0,0 +1,513 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Collections.Generic; +using System.Text.Json; +using Azure; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class AtlasEntity : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + if (Optional.IsCollectionDefined(Attributes)) + { + writer.WritePropertyName("attributes"u8); + writer.WriteStartObject(); + foreach (var item in Attributes) + { + writer.WritePropertyName(item.Key); + if (item.Value == null) + { + writer.WriteNullValue(); + continue; + } +#if NET6_0_OR_GREATER + writer.WriteRawValue(item.Value); +#else + using (JsonDocument document = JsonDocument.Parse(item.Value)) + { + JsonSerializer.Serialize(writer, document.RootElement); + } +#endif + } + writer.WriteEndObject(); + } + if (Optional.IsDefined(TypeName)) + { + writer.WritePropertyName("typeName"u8); + writer.WriteStringValue(TypeName); + } + if (Optional.IsDefined(LastModifiedTS)) + { + writer.WritePropertyName("lastModifiedTS"u8); + writer.WriteStringValue(LastModifiedTS); + } + if (Optional.IsCollectionDefined(BusinessAttributes)) + { + writer.WritePropertyName("businessAttributes"u8); + writer.WriteStartObject(); + foreach (var item in BusinessAttributes) + { + writer.WritePropertyName(item.Key); + if (item.Value == null) + { + writer.WriteNullValue(); + continue; + } +#if NET6_0_OR_GREATER + writer.WriteRawValue(item.Value); +#else + using (JsonDocument document = JsonDocument.Parse(item.Value)) + { + JsonSerializer.Serialize(writer, document.RootElement); + } +#endif + } + writer.WriteEndObject(); + } + if (Optional.IsCollectionDefined(Classifications)) + { + writer.WritePropertyName("classifications"u8); + writer.WriteStartArray(); + foreach (var item in Classifications) + { + writer.WriteObjectValue(item); + } + writer.WriteEndArray(); + } + if (Optional.IsDefined(CreateTime)) + { + writer.WritePropertyName("createTime"u8); + writer.WriteNumberValue(CreateTime.Value); + } + if (Optional.IsDefined(CreatedBy)) + { + writer.WritePropertyName("createdBy"u8); + writer.WriteStringValue(CreatedBy); + } + if (Optional.IsCollectionDefined(CustomAttributes)) + { + writer.WritePropertyName("customAttributes"u8); + writer.WriteStartObject(); + foreach (var item in CustomAttributes) + { + writer.WritePropertyName(item.Key); + writer.WriteStringValue(item.Value); + } + writer.WriteEndObject(); + } + if (Optional.IsDefined(Guid)) + { + writer.WritePropertyName("guid"u8); + writer.WriteStringValue(Guid); + } + if (Optional.IsDefined(HomeId)) + { + writer.WritePropertyName("homeId"u8); + writer.WriteStringValue(HomeId); + } + if (Optional.IsDefined(IsIncomplete)) + { + writer.WritePropertyName("isIncomplete"u8); + writer.WriteBooleanValue(IsIncomplete.Value); + } + if (Optional.IsCollectionDefined(Labels)) + { + writer.WritePropertyName("labels"u8); + writer.WriteStartArray(); + foreach (var item in Labels) + { + writer.WriteStringValue(item); + } + writer.WriteEndArray(); + } + if (Optional.IsCollectionDefined(Meanings)) + { + writer.WritePropertyName("meanings"u8); + writer.WriteStartArray(); + foreach (var item in Meanings) + { + writer.WriteObjectValue(item); + } + writer.WriteEndArray(); + } + if (Optional.IsDefined(ProvenanceType)) + { + writer.WritePropertyName("provenanceType"u8); + writer.WriteNumberValue(ProvenanceType.Value); + } + if (Optional.IsDefined(Proxy)) + { + writer.WritePropertyName("proxy"u8); + writer.WriteBooleanValue(Proxy.Value); + } + if (Optional.IsCollectionDefined(RelationshipAttributes)) + { + writer.WritePropertyName("relationshipAttributes"u8); + writer.WriteStartObject(); + foreach (var item in RelationshipAttributes) + { + writer.WritePropertyName(item.Key); + if (item.Value == null) + { + writer.WriteNullValue(); + continue; + } +#if NET6_0_OR_GREATER + writer.WriteRawValue(item.Value); +#else + using (JsonDocument document = JsonDocument.Parse(item.Value)) + { + JsonSerializer.Serialize(writer, document.RootElement); + } +#endif + } + writer.WriteEndObject(); + } + if (Optional.IsDefined(Status)) + { + writer.WritePropertyName("status"u8); + writer.WriteStringValue(Status.Value.ToString()); + } + if (Optional.IsDefined(UpdateTime)) + { + writer.WritePropertyName("updateTime"u8); + writer.WriteNumberValue(UpdateTime.Value); + } + if (Optional.IsDefined(UpdatedBy)) + { + writer.WritePropertyName("updatedBy"u8); + writer.WriteStringValue(UpdatedBy); + } + if (Optional.IsDefined(Version)) + { + writer.WritePropertyName("version"u8); + writer.WriteNumberValue(Version.Value); + } + if (Optional.IsCollectionDefined(Contacts)) + { + writer.WritePropertyName("contacts"u8); + writer.WriteStartObject(); + foreach (var item in Contacts) + { + writer.WritePropertyName(item.Key); + if (item.Value == null) + { + writer.WriteNullValue(); + continue; + } + writer.WriteStartArray(); + foreach (var item0 in item.Value) + { + writer.WriteObjectValue(item0); + } + writer.WriteEndArray(); + } + writer.WriteEndObject(); + } + writer.WriteEndObject(); + } + + internal static AtlasEntity DeserializeAtlasEntity(JsonElement element) + { + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + Optional> attributes = default; + Optional typeName = default; + Optional lastModifiedTS = default; + Optional> businessAttributes = default; + Optional> classifications = default; + Optional createTime = default; + Optional createdBy = default; + Optional> customAttributes = default; + Optional guid = default; + Optional homeId = default; + Optional collectionId = default; + Optional isIncomplete = default; + Optional> labels = default; + Optional> meanings = default; + Optional provenanceType = default; + Optional proxy = default; + Optional> relationshipAttributes = default; + Optional status = default; + Optional updateTime = default; + Optional updatedBy = default; + Optional version = default; + Optional>> contacts = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("attributes"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + Dictionary dictionary = new Dictionary(); + foreach (var property0 in property.Value.EnumerateObject()) + { + if (property0.Value.ValueKind == JsonValueKind.Null) + { + dictionary.Add(property0.Name, null); + } + else + { + dictionary.Add(property0.Name, BinaryData.FromString(property0.Value.GetRawText())); + } + } + attributes = dictionary; + continue; + } + if (property.NameEquals("typeName"u8)) + { + typeName = property.Value.GetString(); + continue; + } + if (property.NameEquals("lastModifiedTS"u8)) + { + lastModifiedTS = property.Value.GetString(); + continue; + } + if (property.NameEquals("businessAttributes"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + Dictionary dictionary = new Dictionary(); + foreach (var property0 in property.Value.EnumerateObject()) + { + if (property0.Value.ValueKind == JsonValueKind.Null) + { + dictionary.Add(property0.Name, null); + } + else + { + dictionary.Add(property0.Name, BinaryData.FromString(property0.Value.GetRawText())); + } + } + businessAttributes = dictionary; + continue; + } + if (property.NameEquals("classifications"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(AtlasClassification.DeserializeAtlasClassification(item)); + } + classifications = array; + continue; + } + if (property.NameEquals("createTime"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + createTime = property.Value.GetInt64(); + continue; + } + if (property.NameEquals("createdBy"u8)) + { + createdBy = property.Value.GetString(); + continue; + } + if (property.NameEquals("customAttributes"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + Dictionary dictionary = new Dictionary(); + foreach (var property0 in property.Value.EnumerateObject()) + { + dictionary.Add(property0.Name, property0.Value.GetString()); + } + customAttributes = dictionary; + continue; + } + if (property.NameEquals("guid"u8)) + { + guid = property.Value.GetString(); + continue; + } + if (property.NameEquals("homeId"u8)) + { + homeId = property.Value.GetString(); + continue; + } + if (property.NameEquals("collectionId"u8)) + { + collectionId = property.Value.GetString(); + continue; + } + if (property.NameEquals("isIncomplete"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + isIncomplete = property.Value.GetBoolean(); + continue; + } + if (property.NameEquals("labels"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(item.GetString()); + } + labels = array; + continue; + } + if (property.NameEquals("meanings"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(AtlasTermAssignmentHeader.DeserializeAtlasTermAssignmentHeader(item)); + } + meanings = array; + continue; + } + if (property.NameEquals("provenanceType"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + provenanceType = property.Value.GetInt32(); + continue; + } + if (property.NameEquals("proxy"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + proxy = property.Value.GetBoolean(); + continue; + } + if (property.NameEquals("relationshipAttributes"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + Dictionary dictionary = new Dictionary(); + foreach (var property0 in property.Value.EnumerateObject()) + { + if (property0.Value.ValueKind == JsonValueKind.Null) + { + dictionary.Add(property0.Name, null); + } + else + { + dictionary.Add(property0.Name, BinaryData.FromString(property0.Value.GetRawText())); + } + } + relationshipAttributes = dictionary; + continue; + } + if (property.NameEquals("status"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + status = new EntityStatus(property.Value.GetString()); + continue; + } + if (property.NameEquals("updateTime"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + updateTime = property.Value.GetInt64(); + continue; + } + if (property.NameEquals("updatedBy"u8)) + { + updatedBy = property.Value.GetString(); + continue; + } + if (property.NameEquals("version"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + version = property.Value.GetInt64(); + continue; + } + if (property.NameEquals("contacts"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + Dictionary> dictionary = new Dictionary>(); + foreach (var property0 in property.Value.EnumerateObject()) + { + if (property0.Value.ValueKind == JsonValueKind.Null) + { + dictionary.Add(property0.Name, null); + } + else + { + List array = new List(); + foreach (var item in property0.Value.EnumerateArray()) + { + array.Add(ContactInfo.DeserializeContactInfo(item)); + } + dictionary.Add(property0.Name, array); + } + } + contacts = dictionary; + continue; + } + } + return new AtlasEntity(Optional.ToDictionary(attributes), typeName.Value, lastModifiedTS.Value, Optional.ToDictionary(businessAttributes), Optional.ToList(classifications), Optional.ToNullable(createTime), createdBy.Value, Optional.ToDictionary(customAttributes), guid.Value, homeId.Value, collectionId.Value, Optional.ToNullable(isIncomplete), Optional.ToList(labels), Optional.ToList(meanings), Optional.ToNullable(provenanceType), Optional.ToNullable(proxy), Optional.ToDictionary(relationshipAttributes), Optional.ToNullable(status), Optional.ToNullable(updateTime), updatedBy.Value, Optional.ToNullable(version), Optional.ToDictionary(contacts)); + } + + /// Deserializes the model from a raw response. + /// The response to deserialize the model from. + internal static AtlasEntity FromResponse(Response response) + { + using var document = JsonDocument.Parse(response.Content); + return DeserializeAtlasEntity(document.RootElement); + } + + /// Convert into a Utf8JsonRequestContent. + internal virtual RequestContent ToRequestContent() + { + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(this); + return content; + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasEntity.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasEntity.cs new file mode 100644 index 0000000000000..bed0be20ef83d --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasEntity.cs @@ -0,0 +1,217 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Collections.Generic; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + /// An instance of an entity - like hive_table, hive_database. + public partial class AtlasEntity + { + /// Initializes a new instance of . + public AtlasEntity() + { + Attributes = new ChangeTrackingDictionary(); + BusinessAttributes = new ChangeTrackingDictionary(); + Classifications = new ChangeTrackingList(); + CustomAttributes = new ChangeTrackingDictionary(); + Labels = new ChangeTrackingList(); + Meanings = new ChangeTrackingList(); + RelationshipAttributes = new ChangeTrackingDictionary(); + Contacts = new ChangeTrackingDictionary>(); + } + + /// Initializes a new instance of . + /// The attributes of the struct. + /// The name of the type. + /// ETag for concurrency control. + /// Business attributes. + /// An array of classifications. + /// The created time of the record. + /// The user who created the record. + /// Custom Attribute. + /// The GUID of the entity. + /// The home ID of the entity. + /// The collection ID of the entity. + /// Whether it is a shell entity. + /// labels. + /// An array of term assignment headers indicating the meanings of the entity. + /// Used to record the provenance of an instance of an entity or relationship. + /// Determines if there's a proxy. + /// The attributes of relationship. + /// + /// Status of the entity - can be active or deleted. Deleted entities are not + /// removed. + /// + /// The update time of the record. + /// The user who updated the record. + /// The version of the entity. + /// The dictionary of contacts for entities. Key could be Expert or Owner. + internal AtlasEntity(IDictionary attributes, string typeName, string lastModifiedTS, IDictionary businessAttributes, IList classifications, long? createTime, string createdBy, IDictionary customAttributes, string guid, string homeId, string collectionId, bool? isIncomplete, IList labels, IList meanings, int? provenanceType, bool? proxy, IDictionary relationshipAttributes, EntityStatus? status, long? updateTime, string updatedBy, long? version, IDictionary> contacts) + { + Attributes = attributes; + TypeName = typeName; + LastModifiedTS = lastModifiedTS; + BusinessAttributes = businessAttributes; + Classifications = classifications; + CreateTime = createTime; + CreatedBy = createdBy; + CustomAttributes = customAttributes; + Guid = guid; + HomeId = homeId; + CollectionId = collectionId; + IsIncomplete = isIncomplete; + Labels = labels; + Meanings = meanings; + ProvenanceType = provenanceType; + Proxy = proxy; + RelationshipAttributes = relationshipAttributes; + Status = status; + UpdateTime = updateTime; + UpdatedBy = updatedBy; + Version = version; + Contacts = contacts; + } + + /// + /// The attributes of the struct. + /// + /// To assign an object to the value of this property use . + /// + /// + /// To assign an already formatted json string to this property use . + /// + /// + /// Examples: + /// + /// + /// BinaryData.FromObjectAsJson("foo") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromString("\"foo\"") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromObjectAsJson(new { key = "value" }) + /// Creates a payload of { "key": "value" }. + /// + /// + /// BinaryData.FromString("{\"key\": \"value\"}") + /// Creates a payload of { "key": "value" }. + /// + /// + /// + /// + public IDictionary Attributes { get; } + /// The name of the type. + public string TypeName { get; set; } + /// ETag for concurrency control. + public string LastModifiedTS { get; set; } + /// + /// Business attributes + /// + /// To assign an object to the value of this property use . + /// + /// + /// To assign an already formatted json string to this property use . + /// + /// + /// Examples: + /// + /// + /// BinaryData.FromObjectAsJson("foo") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromString("\"foo\"") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromObjectAsJson(new { key = "value" }) + /// Creates a payload of { "key": "value" }. + /// + /// + /// BinaryData.FromString("{\"key\": \"value\"}") + /// Creates a payload of { "key": "value" }. + /// + /// + /// + /// + public IDictionary BusinessAttributes { get; } + /// An array of classifications. + public IList Classifications { get; } + /// The created time of the record. + public long? CreateTime { get; set; } + /// The user who created the record. + public string CreatedBy { get; set; } + /// Custom Attribute. + public IDictionary CustomAttributes { get; } + /// The GUID of the entity. + public string Guid { get; set; } + /// The home ID of the entity. + public string HomeId { get; set; } + /// The collection ID of the entity. + public string CollectionId { get; } + /// Whether it is a shell entity. + public bool? IsIncomplete { get; set; } + /// labels. + public IList Labels { get; } + /// An array of term assignment headers indicating the meanings of the entity. + public IList Meanings { get; } + /// Used to record the provenance of an instance of an entity or relationship. + public int? ProvenanceType { get; set; } + /// Determines if there's a proxy. + public bool? Proxy { get; set; } + /// + /// The attributes of relationship. + /// + /// To assign an object to the value of this property use . + /// + /// + /// To assign an already formatted json string to this property use . + /// + /// + /// Examples: + /// + /// + /// BinaryData.FromObjectAsJson("foo") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromString("\"foo\"") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromObjectAsJson(new { key = "value" }) + /// Creates a payload of { "key": "value" }. + /// + /// + /// BinaryData.FromString("{\"key\": \"value\"}") + /// Creates a payload of { "key": "value" }. + /// + /// + /// + /// + public IDictionary RelationshipAttributes { get; } + /// + /// Status of the entity - can be active or deleted. Deleted entities are not + /// removed. + /// + public EntityStatus? Status { get; set; } + /// The update time of the record. + public long? UpdateTime { get; set; } + /// The user who updated the record. + public string UpdatedBy { get; set; } + /// The version of the entity. + public long? Version { get; set; } + /// The dictionary of contacts for entities. Key could be Expert or Owner. + public IDictionary> Contacts { get; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasEntityDef.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasEntityDef.Serialization.cs new file mode 100644 index 0000000000000..f61dc29885b15 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasEntityDef.Serialization.cs @@ -0,0 +1,340 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using System.Text.Json; +using Azure; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class AtlasEntityDef : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + if (Optional.IsDefined(Category)) + { + writer.WritePropertyName("category"u8); + writer.WriteStringValue(Category.Value.ToString()); + } + if (Optional.IsDefined(CreateTime)) + { + writer.WritePropertyName("createTime"u8); + writer.WriteNumberValue(CreateTime.Value); + } + if (Optional.IsDefined(CreatedBy)) + { + writer.WritePropertyName("createdBy"u8); + writer.WriteStringValue(CreatedBy); + } + if (Optional.IsDefined(DateFormatter)) + { + writer.WritePropertyName("dateFormatter"u8); + writer.WriteObjectValue(DateFormatter); + } + if (Optional.IsDefined(Description)) + { + writer.WritePropertyName("description"u8); + writer.WriteStringValue(Description); + } + if (Optional.IsDefined(Guid)) + { + writer.WritePropertyName("guid"u8); + writer.WriteStringValue(Guid); + } + if (Optional.IsDefined(Name)) + { + writer.WritePropertyName("name"u8); + writer.WriteStringValue(Name); + } + if (Optional.IsCollectionDefined(Options)) + { + writer.WritePropertyName("options"u8); + writer.WriteStartObject(); + foreach (var item in Options) + { + writer.WritePropertyName(item.Key); + writer.WriteStringValue(item.Value); + } + writer.WriteEndObject(); + } + if (Optional.IsDefined(ServiceType)) + { + writer.WritePropertyName("serviceType"u8); + writer.WriteStringValue(ServiceType); + } + if (Optional.IsDefined(TypeVersion)) + { + writer.WritePropertyName("typeVersion"u8); + writer.WriteStringValue(TypeVersion); + } + if (Optional.IsDefined(UpdateTime)) + { + writer.WritePropertyName("updateTime"u8); + writer.WriteNumberValue(UpdateTime.Value); + } + if (Optional.IsDefined(UpdatedBy)) + { + writer.WritePropertyName("updatedBy"u8); + writer.WriteStringValue(UpdatedBy); + } + if (Optional.IsDefined(Version)) + { + writer.WritePropertyName("version"u8); + writer.WriteNumberValue(Version.Value); + } + if (Optional.IsDefined(LastModifiedTS)) + { + writer.WritePropertyName("lastModifiedTS"u8); + writer.WriteStringValue(LastModifiedTS); + } + if (Optional.IsCollectionDefined(AttributeDefs)) + { + writer.WritePropertyName("attributeDefs"u8); + writer.WriteStartArray(); + foreach (var item in AttributeDefs) + { + writer.WriteObjectValue(item); + } + writer.WriteEndArray(); + } + if (Optional.IsCollectionDefined(SubTypes)) + { + writer.WritePropertyName("subTypes"u8); + writer.WriteStartArray(); + foreach (var item in SubTypes) + { + writer.WriteStringValue(item); + } + writer.WriteEndArray(); + } + if (Optional.IsCollectionDefined(SuperTypes)) + { + writer.WritePropertyName("superTypes"u8); + writer.WriteStartArray(); + foreach (var item in SuperTypes) + { + writer.WriteStringValue(item); + } + writer.WriteEndArray(); + } + if (Optional.IsCollectionDefined(RelationshipAttributeDefs)) + { + writer.WritePropertyName("relationshipAttributeDefs"u8); + writer.WriteStartArray(); + foreach (var item in RelationshipAttributeDefs) + { + writer.WriteObjectValue(item); + } + writer.WriteEndArray(); + } + writer.WriteEndObject(); + } + + internal static AtlasEntityDef DeserializeAtlasEntityDef(JsonElement element) + { + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + Optional category = default; + Optional createTime = default; + Optional createdBy = default; + Optional dateFormatter = default; + Optional description = default; + Optional guid = default; + Optional name = default; + Optional> options = default; + Optional serviceType = default; + Optional typeVersion = default; + Optional updateTime = default; + Optional updatedBy = default; + Optional version = default; + Optional lastModifiedTS = default; + Optional> attributeDefs = default; + Optional> subTypes = default; + Optional> superTypes = default; + Optional> relationshipAttributeDefs = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("category"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + category = new TypeCategory(property.Value.GetString()); + continue; + } + if (property.NameEquals("createTime"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + createTime = property.Value.GetInt64(); + continue; + } + if (property.NameEquals("createdBy"u8)) + { + createdBy = property.Value.GetString(); + continue; + } + if (property.NameEquals("dateFormatter"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + dateFormatter = DateFormat.DeserializeDateFormat(property.Value); + continue; + } + if (property.NameEquals("description"u8)) + { + description = property.Value.GetString(); + continue; + } + if (property.NameEquals("guid"u8)) + { + guid = property.Value.GetString(); + continue; + } + if (property.NameEquals("name"u8)) + { + name = property.Value.GetString(); + continue; + } + if (property.NameEquals("options"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + Dictionary dictionary = new Dictionary(); + foreach (var property0 in property.Value.EnumerateObject()) + { + dictionary.Add(property0.Name, property0.Value.GetString()); + } + options = dictionary; + continue; + } + if (property.NameEquals("serviceType"u8)) + { + serviceType = property.Value.GetString(); + continue; + } + if (property.NameEquals("typeVersion"u8)) + { + typeVersion = property.Value.GetString(); + continue; + } + if (property.NameEquals("updateTime"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + updateTime = property.Value.GetInt64(); + continue; + } + if (property.NameEquals("updatedBy"u8)) + { + updatedBy = property.Value.GetString(); + continue; + } + if (property.NameEquals("version"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + version = property.Value.GetInt64(); + continue; + } + if (property.NameEquals("lastModifiedTS"u8)) + { + lastModifiedTS = property.Value.GetString(); + continue; + } + if (property.NameEquals("attributeDefs"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(AtlasAttributeDef.DeserializeAtlasAttributeDef(item)); + } + attributeDefs = array; + continue; + } + if (property.NameEquals("subTypes"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(item.GetString()); + } + subTypes = array; + continue; + } + if (property.NameEquals("superTypes"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(item.GetString()); + } + superTypes = array; + continue; + } + if (property.NameEquals("relationshipAttributeDefs"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(AtlasRelationshipAttributeDef.DeserializeAtlasRelationshipAttributeDef(item)); + } + relationshipAttributeDefs = array; + continue; + } + } + return new AtlasEntityDef(Optional.ToNullable(category), Optional.ToNullable(createTime), createdBy.Value, dateFormatter.Value, description.Value, guid.Value, name.Value, Optional.ToDictionary(options), serviceType.Value, typeVersion.Value, Optional.ToNullable(updateTime), updatedBy.Value, Optional.ToNullable(version), lastModifiedTS.Value, Optional.ToList(attributeDefs), Optional.ToList(subTypes), Optional.ToList(superTypes), Optional.ToList(relationshipAttributeDefs)); + } + + /// Deserializes the model from a raw response. + /// The response to deserialize the model from. + internal static AtlasEntityDef FromResponse(Response response) + { + using var document = JsonDocument.Parse(response.Content); + return DeserializeAtlasEntityDef(document.RootElement); + } + + /// Convert into a Utf8JsonRequestContent. + internal virtual RequestContent ToRequestContent() + { + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(this); + return content; + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasEntityDef.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasEntityDef.cs new file mode 100644 index 0000000000000..03b16824199d3 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasEntityDef.cs @@ -0,0 +1,104 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + /// class that captures details of a entity-type. + public partial class AtlasEntityDef + { + /// Initializes a new instance of . + public AtlasEntityDef() + { + Options = new ChangeTrackingDictionary(); + AttributeDefs = new ChangeTrackingList(); + SubTypes = new ChangeTrackingList(); + SuperTypes = new ChangeTrackingList(); + RelationshipAttributeDefs = new ChangeTrackingList(); + } + + /// Initializes a new instance of . + /// The enum of type category. + /// The created time of the record. + /// The user who created the record. + /// The date format. + /// The description of the type definition. + /// The GUID of the type definition. + /// The name of the type definition. + /// The options for the type definition. + /// The service type. + /// The version of the type. + /// The update time of the record. + /// The user who updated the record. + /// The version of the record. + /// ETag for concurrency control. + /// An array of attribute definitions. + /// An array of sub types. + /// An array of super types. + /// An array of relationship attributes. + internal AtlasEntityDef(TypeCategory? category, long? createTime, string createdBy, DateFormat dateFormatter, string description, string guid, string name, IDictionary options, string serviceType, string typeVersion, long? updateTime, string updatedBy, long? version, string lastModifiedTS, IList attributeDefs, IList subTypes, IList superTypes, IList relationshipAttributeDefs) + { + Category = category; + CreateTime = createTime; + CreatedBy = createdBy; + DateFormatter = dateFormatter; + Description = description; + Guid = guid; + Name = name; + Options = options; + ServiceType = serviceType; + TypeVersion = typeVersion; + UpdateTime = updateTime; + UpdatedBy = updatedBy; + Version = version; + LastModifiedTS = lastModifiedTS; + AttributeDefs = attributeDefs; + SubTypes = subTypes; + SuperTypes = superTypes; + RelationshipAttributeDefs = relationshipAttributeDefs; + } + + /// The enum of type category. + public TypeCategory? Category { get; set; } + /// The created time of the record. + public long? CreateTime { get; set; } + /// The user who created the record. + public string CreatedBy { get; set; } + /// The date format. + public DateFormat DateFormatter { get; set; } + /// The description of the type definition. + public string Description { get; set; } + /// The GUID of the type definition. + public string Guid { get; set; } + /// The name of the type definition. + public string Name { get; set; } + /// The options for the type definition. + public IDictionary Options { get; } + /// The service type. + public string ServiceType { get; set; } + /// The version of the type. + public string TypeVersion { get; set; } + /// The update time of the record. + public long? UpdateTime { get; set; } + /// The user who updated the record. + public string UpdatedBy { get; set; } + /// The version of the record. + public long? Version { get; set; } + /// ETag for concurrency control. + public string LastModifiedTS { get; set; } + /// An array of attribute definitions. + public IList AttributeDefs { get; } + /// An array of sub types. + public IList SubTypes { get; } + /// An array of super types. + public IList SuperTypes { get; } + /// An array of relationship attributes. + public IList RelationshipAttributeDefs { get; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasEntityHeader.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasEntityHeader.Serialization.cs new file mode 100644 index 0000000000000..eddddf80f836d --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasEntityHeader.Serialization.cs @@ -0,0 +1,296 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Collections.Generic; +using System.Text.Json; +using Azure; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class AtlasEntityHeader : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + if (Optional.IsCollectionDefined(Attributes)) + { + writer.WritePropertyName("attributes"u8); + writer.WriteStartObject(); + foreach (var item in Attributes) + { + writer.WritePropertyName(item.Key); + if (item.Value == null) + { + writer.WriteNullValue(); + continue; + } +#if NET6_0_OR_GREATER + writer.WriteRawValue(item.Value); +#else + using (JsonDocument document = JsonDocument.Parse(item.Value)) + { + JsonSerializer.Serialize(writer, document.RootElement); + } +#endif + } + writer.WriteEndObject(); + } + if (Optional.IsDefined(TypeName)) + { + writer.WritePropertyName("typeName"u8); + writer.WriteStringValue(TypeName); + } + if (Optional.IsDefined(LastModifiedTS)) + { + writer.WritePropertyName("lastModifiedTS"u8); + writer.WriteStringValue(LastModifiedTS); + } + if (Optional.IsCollectionDefined(ClassificationNames)) + { + writer.WritePropertyName("classificationNames"u8); + writer.WriteStartArray(); + foreach (var item in ClassificationNames) + { + writer.WriteStringValue(item); + } + writer.WriteEndArray(); + } + if (Optional.IsCollectionDefined(Classifications)) + { + writer.WritePropertyName("classifications"u8); + writer.WriteStartArray(); + foreach (var item in Classifications) + { + writer.WriteObjectValue(item); + } + writer.WriteEndArray(); + } + if (Optional.IsDefined(DisplayText)) + { + writer.WritePropertyName("displayText"u8); + writer.WriteStringValue(DisplayText); + } + if (Optional.IsDefined(Guid)) + { + writer.WritePropertyName("guid"u8); + writer.WriteStringValue(Guid); + } + if (Optional.IsDefined(IsIncomplete)) + { + writer.WritePropertyName("isIncomplete"u8); + writer.WriteBooleanValue(IsIncomplete.Value); + } + if (Optional.IsCollectionDefined(Labels)) + { + writer.WritePropertyName("labels"u8); + writer.WriteStartArray(); + foreach (var item in Labels) + { + writer.WriteStringValue(item); + } + writer.WriteEndArray(); + } + if (Optional.IsCollectionDefined(MeaningNames)) + { + writer.WritePropertyName("meaningNames"u8); + writer.WriteStartArray(); + foreach (var item in MeaningNames) + { + writer.WriteStringValue(item); + } + writer.WriteEndArray(); + } + if (Optional.IsCollectionDefined(Meanings)) + { + writer.WritePropertyName("meanings"u8); + writer.WriteStartArray(); + foreach (var item in Meanings) + { + writer.WriteObjectValue(item); + } + writer.WriteEndArray(); + } + if (Optional.IsDefined(Status)) + { + writer.WritePropertyName("status"u8); + writer.WriteStringValue(Status.Value.ToString()); + } + writer.WriteEndObject(); + } + + internal static AtlasEntityHeader DeserializeAtlasEntityHeader(JsonElement element) + { + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + Optional> attributes = default; + Optional typeName = default; + Optional lastModifiedTS = default; + Optional> classificationNames = default; + Optional> classifications = default; + Optional displayText = default; + Optional guid = default; + Optional isIncomplete = default; + Optional> labels = default; + Optional> meaningNames = default; + Optional> meanings = default; + Optional status = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("attributes"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + Dictionary dictionary = new Dictionary(); + foreach (var property0 in property.Value.EnumerateObject()) + { + if (property0.Value.ValueKind == JsonValueKind.Null) + { + dictionary.Add(property0.Name, null); + } + else + { + dictionary.Add(property0.Name, BinaryData.FromString(property0.Value.GetRawText())); + } + } + attributes = dictionary; + continue; + } + if (property.NameEquals("typeName"u8)) + { + typeName = property.Value.GetString(); + continue; + } + if (property.NameEquals("lastModifiedTS"u8)) + { + lastModifiedTS = property.Value.GetString(); + continue; + } + if (property.NameEquals("classificationNames"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(item.GetString()); + } + classificationNames = array; + continue; + } + if (property.NameEquals("classifications"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(AtlasClassification.DeserializeAtlasClassification(item)); + } + classifications = array; + continue; + } + if (property.NameEquals("displayText"u8)) + { + displayText = property.Value.GetString(); + continue; + } + if (property.NameEquals("guid"u8)) + { + guid = property.Value.GetString(); + continue; + } + if (property.NameEquals("isIncomplete"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + isIncomplete = property.Value.GetBoolean(); + continue; + } + if (property.NameEquals("labels"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(item.GetString()); + } + labels = array; + continue; + } + if (property.NameEquals("meaningNames"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(item.GetString()); + } + meaningNames = array; + continue; + } + if (property.NameEquals("meanings"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(AtlasTermAssignmentHeader.DeserializeAtlasTermAssignmentHeader(item)); + } + meanings = array; + continue; + } + if (property.NameEquals("status"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + status = new EntityStatus(property.Value.GetString()); + continue; + } + } + return new AtlasEntityHeader(Optional.ToDictionary(attributes), typeName.Value, lastModifiedTS.Value, Optional.ToList(classificationNames), Optional.ToList(classifications), displayText.Value, guid.Value, Optional.ToNullable(isIncomplete), Optional.ToList(labels), Optional.ToList(meaningNames), Optional.ToList(meanings), Optional.ToNullable(status)); + } + + /// Deserializes the model from a raw response. + /// The response to deserialize the model from. + internal static AtlasEntityHeader FromResponse(Response response) + { + using var document = JsonDocument.Parse(response.Content); + return DeserializeAtlasEntityHeader(document.RootElement); + } + + /// Convert into a Utf8JsonRequestContent. + internal virtual RequestContent ToRequestContent() + { + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(this); + return content; + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasEntityHeader.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasEntityHeader.cs new file mode 100644 index 0000000000000..9836ff132ac00 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasEntityHeader.cs @@ -0,0 +1,117 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Collections.Generic; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + /// An instance of an entity - like hive_table, hive_database. + public partial class AtlasEntityHeader + { + /// Initializes a new instance of . + public AtlasEntityHeader() + { + Attributes = new ChangeTrackingDictionary(); + ClassificationNames = new ChangeTrackingList(); + Classifications = new ChangeTrackingList(); + Labels = new ChangeTrackingList(); + MeaningNames = new ChangeTrackingList(); + Meanings = new ChangeTrackingList(); + } + + /// Initializes a new instance of . + /// The attributes of the struct. + /// The name of the type. + /// ETag for concurrency control. + /// An array of classification names. + /// An array of classifications. + /// The display text. + /// The GUID of the record. + /// Whether it is a shell entity. + /// labels. + /// An array of meanings. + /// An array of term assignment headers. + /// + /// Status of the entity - can be active or deleted. Deleted entities are not + /// removed. + /// + internal AtlasEntityHeader(IDictionary attributes, string typeName, string lastModifiedTS, IList classificationNames, IList classifications, string displayText, string guid, bool? isIncomplete, IList labels, IList meaningNames, IList meanings, EntityStatus? status) + { + Attributes = attributes; + TypeName = typeName; + LastModifiedTS = lastModifiedTS; + ClassificationNames = classificationNames; + Classifications = classifications; + DisplayText = displayText; + Guid = guid; + IsIncomplete = isIncomplete; + Labels = labels; + MeaningNames = meaningNames; + Meanings = meanings; + Status = status; + } + + /// + /// The attributes of the struct. + /// + /// To assign an object to the value of this property use . + /// + /// + /// To assign an already formatted json string to this property use . + /// + /// + /// Examples: + /// + /// + /// BinaryData.FromObjectAsJson("foo") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromString("\"foo\"") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromObjectAsJson(new { key = "value" }) + /// Creates a payload of { "key": "value" }. + /// + /// + /// BinaryData.FromString("{\"key\": \"value\"}") + /// Creates a payload of { "key": "value" }. + /// + /// + /// + /// + public IDictionary Attributes { get; } + /// The name of the type. + public string TypeName { get; set; } + /// ETag for concurrency control. + public string LastModifiedTS { get; set; } + /// An array of classification names. + public IList ClassificationNames { get; } + /// An array of classifications. + public IList Classifications { get; } + /// The display text. + public string DisplayText { get; set; } + /// The GUID of the record. + public string Guid { get; set; } + /// Whether it is a shell entity. + public bool? IsIncomplete { get; set; } + /// labels. + public IList Labels { get; } + /// An array of meanings. + public IList MeaningNames { get; } + /// An array of term assignment headers. + public IList Meanings { get; } + /// + /// Status of the entity - can be active or deleted. Deleted entities are not + /// removed. + /// + public EntityStatus? Status { get; set; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasEntityHeaders.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasEntityHeaders.Serialization.cs new file mode 100644 index 0000000000000..a8e48e53fbd65 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasEntityHeaders.Serialization.cs @@ -0,0 +1,40 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class AtlasEntityHeaders : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + if (Optional.IsCollectionDefined(GuidHeaderMap)) + { + writer.WritePropertyName("guidHeaderMap"u8); + writer.WriteStartObject(); + foreach (var item in GuidHeaderMap) + { + writer.WritePropertyName(item.Key); + writer.WriteObjectValue(item.Value); + } + writer.WriteEndObject(); + } + writer.WriteEndObject(); + } + + /// Convert into a Utf8JsonRequestContent. + internal virtual RequestContent ToRequestContent() + { + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(this); + return content; + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasEntityHeaders.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasEntityHeaders.cs new file mode 100644 index 0000000000000..3a6533b025418 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasEntityHeaders.cs @@ -0,0 +1,32 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + /// An instance of an entity header map. + public partial class AtlasEntityHeaders + { + /// Initializes a new instance of . + public AtlasEntityHeaders() + { + GuidHeaderMap = new ChangeTrackingDictionary(); + } + + /// Initializes a new instance of . + /// The description of the guid header map,. + internal AtlasEntityHeaders(IDictionary guidHeaderMap) + { + GuidHeaderMap = guidHeaderMap; + } + + /// The description of the guid header map,. + public IDictionary GuidHeaderMap { get; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasEntityWithExtInfo.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasEntityWithExtInfo.Serialization.cs new file mode 100644 index 0000000000000..0cd266001986c --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasEntityWithExtInfo.Serialization.cs @@ -0,0 +1,92 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using System.Text.Json; +using Azure; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class AtlasEntityWithExtInfo : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + if (Optional.IsCollectionDefined(ReferredEntities)) + { + writer.WritePropertyName("referredEntities"u8); + writer.WriteStartObject(); + foreach (var item in ReferredEntities) + { + writer.WritePropertyName(item.Key); + writer.WriteObjectValue(item.Value); + } + writer.WriteEndObject(); + } + if (Optional.IsDefined(Entity)) + { + writer.WritePropertyName("entity"u8); + writer.WriteObjectValue(Entity); + } + writer.WriteEndObject(); + } + + internal static AtlasEntityWithExtInfo DeserializeAtlasEntityWithExtInfo(JsonElement element) + { + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + Optional> referredEntities = default; + Optional entity = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("referredEntities"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + Dictionary dictionary = new Dictionary(); + foreach (var property0 in property.Value.EnumerateObject()) + { + dictionary.Add(property0.Name, AtlasEntity.DeserializeAtlasEntity(property0.Value)); + } + referredEntities = dictionary; + continue; + } + if (property.NameEquals("entity"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + entity = AtlasEntity.DeserializeAtlasEntity(property.Value); + continue; + } + } + return new AtlasEntityWithExtInfo(Optional.ToDictionary(referredEntities), entity.Value); + } + + /// Deserializes the model from a raw response. + /// The response to deserialize the model from. + internal static AtlasEntityWithExtInfo FromResponse(Response response) + { + using var document = JsonDocument.Parse(response.Content); + return DeserializeAtlasEntityWithExtInfo(document.RootElement); + } + + /// Convert into a Utf8JsonRequestContent. + internal virtual RequestContent ToRequestContent() + { + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(this); + return content; + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasEntityWithExtInfo.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasEntityWithExtInfo.cs new file mode 100644 index 0000000000000..74ce52b433c70 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasEntityWithExtInfo.cs @@ -0,0 +1,39 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + /// + /// An instance of an entity along with extended info - like hive_table, + /// hive_database. + /// + public partial class AtlasEntityWithExtInfo + { + /// Initializes a new instance of . + public AtlasEntityWithExtInfo() + { + ReferredEntities = new ChangeTrackingDictionary(); + } + + /// Initializes a new instance of . + /// The referred entities. + /// An instance of an entity - like hive_table, hive_database. + internal AtlasEntityWithExtInfo(IDictionary referredEntities, AtlasEntity entity) + { + ReferredEntities = referredEntities; + Entity = entity; + } + + /// The referred entities. + public IDictionary ReferredEntities { get; } + /// An instance of an entity - like hive_table, hive_database. + public AtlasEntity Entity { get; set; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasEnumDef.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasEnumDef.Serialization.cs new file mode 100644 index 0000000000000..992ba8eb22342 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasEnumDef.Serialization.cs @@ -0,0 +1,276 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using System.Text.Json; +using Azure; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class AtlasEnumDef : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + if (Optional.IsDefined(Category)) + { + writer.WritePropertyName("category"u8); + writer.WriteStringValue(Category.Value.ToString()); + } + if (Optional.IsDefined(CreateTime)) + { + writer.WritePropertyName("createTime"u8); + writer.WriteNumberValue(CreateTime.Value); + } + if (Optional.IsDefined(CreatedBy)) + { + writer.WritePropertyName("createdBy"u8); + writer.WriteStringValue(CreatedBy); + } + if (Optional.IsDefined(DateFormatter)) + { + writer.WritePropertyName("dateFormatter"u8); + writer.WriteObjectValue(DateFormatter); + } + if (Optional.IsDefined(Description)) + { + writer.WritePropertyName("description"u8); + writer.WriteStringValue(Description); + } + if (Optional.IsDefined(Guid)) + { + writer.WritePropertyName("guid"u8); + writer.WriteStringValue(Guid); + } + if (Optional.IsDefined(Name)) + { + writer.WritePropertyName("name"u8); + writer.WriteStringValue(Name); + } + if (Optional.IsCollectionDefined(Options)) + { + writer.WritePropertyName("options"u8); + writer.WriteStartObject(); + foreach (var item in Options) + { + writer.WritePropertyName(item.Key); + writer.WriteStringValue(item.Value); + } + writer.WriteEndObject(); + } + if (Optional.IsDefined(ServiceType)) + { + writer.WritePropertyName("serviceType"u8); + writer.WriteStringValue(ServiceType); + } + if (Optional.IsDefined(TypeVersion)) + { + writer.WritePropertyName("typeVersion"u8); + writer.WriteStringValue(TypeVersion); + } + if (Optional.IsDefined(UpdateTime)) + { + writer.WritePropertyName("updateTime"u8); + writer.WriteNumberValue(UpdateTime.Value); + } + if (Optional.IsDefined(UpdatedBy)) + { + writer.WritePropertyName("updatedBy"u8); + writer.WriteStringValue(UpdatedBy); + } + if (Optional.IsDefined(Version)) + { + writer.WritePropertyName("version"u8); + writer.WriteNumberValue(Version.Value); + } + if (Optional.IsDefined(LastModifiedTS)) + { + writer.WritePropertyName("lastModifiedTS"u8); + writer.WriteStringValue(LastModifiedTS); + } + if (Optional.IsDefined(DefaultValue)) + { + writer.WritePropertyName("defaultValue"u8); + writer.WriteStringValue(DefaultValue); + } + if (Optional.IsCollectionDefined(ElementDefs)) + { + writer.WritePropertyName("elementDefs"u8); + writer.WriteStartArray(); + foreach (var item in ElementDefs) + { + writer.WriteObjectValue(item); + } + writer.WriteEndArray(); + } + writer.WriteEndObject(); + } + + internal static AtlasEnumDef DeserializeAtlasEnumDef(JsonElement element) + { + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + Optional category = default; + Optional createTime = default; + Optional createdBy = default; + Optional dateFormatter = default; + Optional description = default; + Optional guid = default; + Optional name = default; + Optional> options = default; + Optional serviceType = default; + Optional typeVersion = default; + Optional updateTime = default; + Optional updatedBy = default; + Optional version = default; + Optional lastModifiedTS = default; + Optional defaultValue = default; + Optional> elementDefs = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("category"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + category = new TypeCategory(property.Value.GetString()); + continue; + } + if (property.NameEquals("createTime"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + createTime = property.Value.GetInt64(); + continue; + } + if (property.NameEquals("createdBy"u8)) + { + createdBy = property.Value.GetString(); + continue; + } + if (property.NameEquals("dateFormatter"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + dateFormatter = DateFormat.DeserializeDateFormat(property.Value); + continue; + } + if (property.NameEquals("description"u8)) + { + description = property.Value.GetString(); + continue; + } + if (property.NameEquals("guid"u8)) + { + guid = property.Value.GetString(); + continue; + } + if (property.NameEquals("name"u8)) + { + name = property.Value.GetString(); + continue; + } + if (property.NameEquals("options"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + Dictionary dictionary = new Dictionary(); + foreach (var property0 in property.Value.EnumerateObject()) + { + dictionary.Add(property0.Name, property0.Value.GetString()); + } + options = dictionary; + continue; + } + if (property.NameEquals("serviceType"u8)) + { + serviceType = property.Value.GetString(); + continue; + } + if (property.NameEquals("typeVersion"u8)) + { + typeVersion = property.Value.GetString(); + continue; + } + if (property.NameEquals("updateTime"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + updateTime = property.Value.GetInt64(); + continue; + } + if (property.NameEquals("updatedBy"u8)) + { + updatedBy = property.Value.GetString(); + continue; + } + if (property.NameEquals("version"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + version = property.Value.GetInt64(); + continue; + } + if (property.NameEquals("lastModifiedTS"u8)) + { + lastModifiedTS = property.Value.GetString(); + continue; + } + if (property.NameEquals("defaultValue"u8)) + { + defaultValue = property.Value.GetString(); + continue; + } + if (property.NameEquals("elementDefs"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(AtlasEnumElementDef.DeserializeAtlasEnumElementDef(item)); + } + elementDefs = array; + continue; + } + } + return new AtlasEnumDef(Optional.ToNullable(category), Optional.ToNullable(createTime), createdBy.Value, dateFormatter.Value, description.Value, guid.Value, name.Value, Optional.ToDictionary(options), serviceType.Value, typeVersion.Value, Optional.ToNullable(updateTime), updatedBy.Value, Optional.ToNullable(version), lastModifiedTS.Value, defaultValue.Value, Optional.ToList(elementDefs)); + } + + /// Deserializes the model from a raw response. + /// The response to deserialize the model from. + internal static AtlasEnumDef FromResponse(Response response) + { + using var document = JsonDocument.Parse(response.Content); + return DeserializeAtlasEnumDef(document.RootElement); + } + + /// Convert into a Utf8JsonRequestContent. + internal virtual RequestContent ToRequestContent() + { + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(this); + return content; + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasEnumDef.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasEnumDef.cs new file mode 100644 index 0000000000000..0ca4b33dc1910 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasEnumDef.cs @@ -0,0 +1,93 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + /// class that captures details of an enum-type. + public partial class AtlasEnumDef + { + /// Initializes a new instance of . + public AtlasEnumDef() + { + Options = new ChangeTrackingDictionary(); + ElementDefs = new ChangeTrackingList(); + } + + /// Initializes a new instance of . + /// The enum of type category. + /// The created time of the record. + /// The user who created the record. + /// The date format. + /// The description of the type definition. + /// The GUID of the type definition. + /// The name of the type definition. + /// The options for the type definition. + /// The service type. + /// The version of the type. + /// The update time of the record. + /// The user who updated the record. + /// The version of the record. + /// ETag for concurrency control. + /// The default value. + /// An array of enum element definitions. + internal AtlasEnumDef(TypeCategory? category, long? createTime, string createdBy, DateFormat dateFormatter, string description, string guid, string name, IDictionary options, string serviceType, string typeVersion, long? updateTime, string updatedBy, long? version, string lastModifiedTS, string defaultValue, IList elementDefs) + { + Category = category; + CreateTime = createTime; + CreatedBy = createdBy; + DateFormatter = dateFormatter; + Description = description; + Guid = guid; + Name = name; + Options = options; + ServiceType = serviceType; + TypeVersion = typeVersion; + UpdateTime = updateTime; + UpdatedBy = updatedBy; + Version = version; + LastModifiedTS = lastModifiedTS; + DefaultValue = defaultValue; + ElementDefs = elementDefs; + } + + /// The enum of type category. + public TypeCategory? Category { get; set; } + /// The created time of the record. + public long? CreateTime { get; set; } + /// The user who created the record. + public string CreatedBy { get; set; } + /// The date format. + public DateFormat DateFormatter { get; set; } + /// The description of the type definition. + public string Description { get; set; } + /// The GUID of the type definition. + public string Guid { get; set; } + /// The name of the type definition. + public string Name { get; set; } + /// The options for the type definition. + public IDictionary Options { get; } + /// The service type. + public string ServiceType { get; set; } + /// The version of the type. + public string TypeVersion { get; set; } + /// The update time of the record. + public long? UpdateTime { get; set; } + /// The user who updated the record. + public string UpdatedBy { get; set; } + /// The version of the record. + public long? Version { get; set; } + /// ETag for concurrency control. + public string LastModifiedTS { get; set; } + /// The default value. + public string DefaultValue { get; set; } + /// An array of enum element definitions. + public IList ElementDefs { get; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasEnumElementDef.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasEnumElementDef.Serialization.cs new file mode 100644 index 0000000000000..922ffaa77ff74 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasEnumElementDef.Serialization.cs @@ -0,0 +1,87 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class AtlasEnumElementDef : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + if (Optional.IsDefined(Description)) + { + writer.WritePropertyName("description"u8); + writer.WriteStringValue(Description); + } + if (Optional.IsDefined(Ordinal)) + { + writer.WritePropertyName("ordinal"u8); + writer.WriteNumberValue(Ordinal.Value); + } + if (Optional.IsDefined(Value)) + { + writer.WritePropertyName("value"u8); + writer.WriteStringValue(Value); + } + writer.WriteEndObject(); + } + + internal static AtlasEnumElementDef DeserializeAtlasEnumElementDef(JsonElement element) + { + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + Optional description = default; + Optional ordinal = default; + Optional value = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("description"u8)) + { + description = property.Value.GetString(); + continue; + } + if (property.NameEquals("ordinal"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + ordinal = property.Value.GetInt32(); + continue; + } + if (property.NameEquals("value"u8)) + { + value = property.Value.GetString(); + continue; + } + } + return new AtlasEnumElementDef(description.Value, Optional.ToNullable(ordinal), value.Value); + } + + /// Deserializes the model from a raw response. + /// The response to deserialize the model from. + internal static AtlasEnumElementDef FromResponse(Response response) + { + using var document = JsonDocument.Parse(response.Content); + return DeserializeAtlasEnumElementDef(document.RootElement); + } + + /// Convert into a Utf8JsonRequestContent. + internal virtual RequestContent ToRequestContent() + { + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(this); + return content; + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasEnumElementDef.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasEnumElementDef.cs new file mode 100644 index 0000000000000..8dc119f6537c9 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasEnumElementDef.cs @@ -0,0 +1,36 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +namespace Azure.Analytics.Purview.DataMap +{ + /// class that captures details of an enum-element. + public partial class AtlasEnumElementDef + { + /// Initializes a new instance of . + public AtlasEnumElementDef() + { + } + + /// Initializes a new instance of . + /// The description of the enum element definition. + /// The ordinal of the enum element definition. + /// The value of the enum element definition. + internal AtlasEnumElementDef(string description, int? ordinal, string value) + { + Description = description; + Ordinal = ordinal; + Value = value; + } + + /// The description of the enum element definition. + public string Description { get; set; } + /// The ordinal of the enum element definition. + public int? Ordinal { get; set; } + /// The value of the enum element definition. + public string Value { get; set; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasGlossary.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasGlossary.Serialization.cs new file mode 100644 index 0000000000000..a9cbd6ef5949c --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasGlossary.Serialization.cs @@ -0,0 +1,266 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using System.Text.Json; +using Azure; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class AtlasGlossary : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + if (Optional.IsDefined(Guid)) + { + writer.WritePropertyName("guid"u8); + writer.WriteStringValue(Guid); + } + if (Optional.IsCollectionDefined(Classifications)) + { + writer.WritePropertyName("classifications"u8); + writer.WriteStartArray(); + foreach (var item in Classifications) + { + writer.WriteObjectValue(item); + } + writer.WriteEndArray(); + } + if (Optional.IsDefined(LongDescription)) + { + writer.WritePropertyName("longDescription"u8); + writer.WriteStringValue(LongDescription); + } + if (Optional.IsDefined(Name)) + { + writer.WritePropertyName("name"u8); + writer.WriteStringValue(Name); + } + if (Optional.IsDefined(QualifiedName)) + { + writer.WritePropertyName("qualifiedName"u8); + writer.WriteStringValue(QualifiedName); + } + if (Optional.IsDefined(ShortDescription)) + { + writer.WritePropertyName("shortDescription"u8); + writer.WriteStringValue(ShortDescription); + } + if (Optional.IsDefined(LastModifiedTS)) + { + writer.WritePropertyName("lastModifiedTS"u8); + writer.WriteStringValue(LastModifiedTS); + } + if (Optional.IsDefined(CreateTime)) + { + writer.WritePropertyName("createTime"u8); + writer.WriteNumberValue(CreateTime.Value); + } + if (Optional.IsDefined(CreatedBy)) + { + writer.WritePropertyName("createdBy"u8); + writer.WriteStringValue(CreatedBy); + } + if (Optional.IsDefined(UpdateTime)) + { + writer.WritePropertyName("updateTime"u8); + writer.WriteNumberValue(UpdateTime.Value); + } + if (Optional.IsDefined(UpdatedBy)) + { + writer.WritePropertyName("updatedBy"u8); + writer.WriteStringValue(UpdatedBy); + } + if (Optional.IsCollectionDefined(Categories)) + { + writer.WritePropertyName("categories"u8); + writer.WriteStartArray(); + foreach (var item in Categories) + { + writer.WriteObjectValue(item); + } + writer.WriteEndArray(); + } + if (Optional.IsDefined(Language)) + { + writer.WritePropertyName("language"u8); + writer.WriteStringValue(Language); + } + if (Optional.IsCollectionDefined(Terms)) + { + writer.WritePropertyName("terms"u8); + writer.WriteStartArray(); + foreach (var item in Terms) + { + writer.WriteObjectValue(item); + } + writer.WriteEndArray(); + } + if (Optional.IsDefined(Usage)) + { + writer.WritePropertyName("usage"u8); + writer.WriteStringValue(Usage); + } + writer.WriteEndObject(); + } + + internal static AtlasGlossary DeserializeAtlasGlossary(JsonElement element) + { + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + Optional guid = default; + Optional> classifications = default; + Optional longDescription = default; + Optional name = default; + Optional qualifiedName = default; + Optional shortDescription = default; + Optional lastModifiedTS = default; + Optional createTime = default; + Optional createdBy = default; + Optional updateTime = default; + Optional updatedBy = default; + Optional> categories = default; + Optional language = default; + Optional> terms = default; + Optional usage = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("guid"u8)) + { + guid = property.Value.GetString(); + continue; + } + if (property.NameEquals("classifications"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(AtlasClassification.DeserializeAtlasClassification(item)); + } + classifications = array; + continue; + } + if (property.NameEquals("longDescription"u8)) + { + longDescription = property.Value.GetString(); + continue; + } + if (property.NameEquals("name"u8)) + { + name = property.Value.GetString(); + continue; + } + if (property.NameEquals("qualifiedName"u8)) + { + qualifiedName = property.Value.GetString(); + continue; + } + if (property.NameEquals("shortDescription"u8)) + { + shortDescription = property.Value.GetString(); + continue; + } + if (property.NameEquals("lastModifiedTS"u8)) + { + lastModifiedTS = property.Value.GetString(); + continue; + } + if (property.NameEquals("createTime"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + createTime = property.Value.GetInt64(); + continue; + } + if (property.NameEquals("createdBy"u8)) + { + createdBy = property.Value.GetString(); + continue; + } + if (property.NameEquals("updateTime"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + updateTime = property.Value.GetInt64(); + continue; + } + if (property.NameEquals("updatedBy"u8)) + { + updatedBy = property.Value.GetString(); + continue; + } + if (property.NameEquals("categories"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(AtlasRelatedCategoryHeader.DeserializeAtlasRelatedCategoryHeader(item)); + } + categories = array; + continue; + } + if (property.NameEquals("language"u8)) + { + language = property.Value.GetString(); + continue; + } + if (property.NameEquals("terms"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(AtlasRelatedTermHeader.DeserializeAtlasRelatedTermHeader(item)); + } + terms = array; + continue; + } + if (property.NameEquals("usage"u8)) + { + usage = property.Value.GetString(); + continue; + } + } + return new AtlasGlossary(guid.Value, Optional.ToList(classifications), longDescription.Value, name.Value, qualifiedName.Value, shortDescription.Value, lastModifiedTS.Value, Optional.ToNullable(createTime), createdBy.Value, Optional.ToNullable(updateTime), updatedBy.Value, Optional.ToList(categories), language.Value, Optional.ToList(terms), usage.Value); + } + + /// Deserializes the model from a raw response. + /// The response to deserialize the model from. + internal static AtlasGlossary FromResponse(Response response) + { + using var document = JsonDocument.Parse(response.Content); + return DeserializeAtlasGlossary(document.RootElement); + } + + /// Convert into a Utf8JsonRequestContent. + internal virtual RequestContent ToRequestContent() + { + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(this); + return content; + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasGlossary.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasGlossary.cs new file mode 100644 index 0000000000000..7ab12333607ba --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasGlossary.cs @@ -0,0 +1,90 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + /// The glossary object. + public partial class AtlasGlossary + { + /// Initializes a new instance of . + public AtlasGlossary() + { + Classifications = new ChangeTrackingList(); + Categories = new ChangeTrackingList(); + Terms = new ChangeTrackingList(); + } + + /// Initializes a new instance of . + /// The GUID of the object. + /// An array of classifications. + /// The long version description. + /// The name of the glossary object. + /// The qualified name of the glossary object. + /// The short version of description. + /// ETag for concurrency control. + /// The created time of the record. + /// The user who created the record. + /// The update time of the record. + /// The user who updated the record. + /// An array of categories. + /// The language of the glossary. + /// An array of related term headers. + /// The usage of the glossary. + internal AtlasGlossary(string guid, IList classifications, string longDescription, string name, string qualifiedName, string shortDescription, string lastModifiedTS, long? createTime, string createdBy, long? updateTime, string updatedBy, IList categories, string language, IList terms, string usage) + { + Guid = guid; + Classifications = classifications; + LongDescription = longDescription; + Name = name; + QualifiedName = qualifiedName; + ShortDescription = shortDescription; + LastModifiedTS = lastModifiedTS; + CreateTime = createTime; + CreatedBy = createdBy; + UpdateTime = updateTime; + UpdatedBy = updatedBy; + Categories = categories; + Language = language; + Terms = terms; + Usage = usage; + } + + /// The GUID of the object. + public string Guid { get; set; } + /// An array of classifications. + public IList Classifications { get; } + /// The long version description. + public string LongDescription { get; set; } + /// The name of the glossary object. + public string Name { get; set; } + /// The qualified name of the glossary object. + public string QualifiedName { get; set; } + /// The short version of description. + public string ShortDescription { get; set; } + /// ETag for concurrency control. + public string LastModifiedTS { get; set; } + /// The created time of the record. + public long? CreateTime { get; set; } + /// The user who created the record. + public string CreatedBy { get; set; } + /// The update time of the record. + public long? UpdateTime { get; set; } + /// The user who updated the record. + public string UpdatedBy { get; set; } + /// An array of categories. + public IList Categories { get; } + /// The language of the glossary. + public string Language { get; set; } + /// An array of related term headers. + public IList Terms { get; } + /// The usage of the glossary. + public string Usage { get; set; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasGlossaryCategory.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasGlossaryCategory.Serialization.cs new file mode 100644 index 0000000000000..1ba00aef01b0f --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasGlossaryCategory.Serialization.cs @@ -0,0 +1,274 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using System.Text.Json; +using Azure; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class AtlasGlossaryCategory : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + if (Optional.IsDefined(Guid)) + { + writer.WritePropertyName("guid"u8); + writer.WriteStringValue(Guid); + } + if (Optional.IsCollectionDefined(Classifications)) + { + writer.WritePropertyName("classifications"u8); + writer.WriteStartArray(); + foreach (var item in Classifications) + { + writer.WriteObjectValue(item); + } + writer.WriteEndArray(); + } + if (Optional.IsDefined(LongDescription)) + { + writer.WritePropertyName("longDescription"u8); + writer.WriteStringValue(LongDescription); + } + if (Optional.IsDefined(Name)) + { + writer.WritePropertyName("name"u8); + writer.WriteStringValue(Name); + } + if (Optional.IsDefined(QualifiedName)) + { + writer.WritePropertyName("qualifiedName"u8); + writer.WriteStringValue(QualifiedName); + } + if (Optional.IsDefined(ShortDescription)) + { + writer.WritePropertyName("shortDescription"u8); + writer.WriteStringValue(ShortDescription); + } + if (Optional.IsDefined(LastModifiedTS)) + { + writer.WritePropertyName("lastModifiedTS"u8); + writer.WriteStringValue(LastModifiedTS); + } + if (Optional.IsDefined(CreateTime)) + { + writer.WritePropertyName("createTime"u8); + writer.WriteNumberValue(CreateTime.Value); + } + if (Optional.IsDefined(CreatedBy)) + { + writer.WritePropertyName("createdBy"u8); + writer.WriteStringValue(CreatedBy); + } + if (Optional.IsDefined(UpdateTime)) + { + writer.WritePropertyName("updateTime"u8); + writer.WriteNumberValue(UpdateTime.Value); + } + if (Optional.IsDefined(UpdatedBy)) + { + writer.WritePropertyName("updatedBy"u8); + writer.WriteStringValue(UpdatedBy); + } + if (Optional.IsDefined(Anchor)) + { + writer.WritePropertyName("anchor"u8); + writer.WriteObjectValue(Anchor); + } + if (Optional.IsCollectionDefined(ChildrenCategories)) + { + writer.WritePropertyName("childrenCategories"u8); + writer.WriteStartArray(); + foreach (var item in ChildrenCategories) + { + writer.WriteObjectValue(item); + } + writer.WriteEndArray(); + } + if (Optional.IsDefined(ParentCategory)) + { + writer.WritePropertyName("parentCategory"u8); + writer.WriteObjectValue(ParentCategory); + } + if (Optional.IsCollectionDefined(Terms)) + { + writer.WritePropertyName("terms"u8); + writer.WriteStartArray(); + foreach (var item in Terms) + { + writer.WriteObjectValue(item); + } + writer.WriteEndArray(); + } + writer.WriteEndObject(); + } + + internal static AtlasGlossaryCategory DeserializeAtlasGlossaryCategory(JsonElement element) + { + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + Optional guid = default; + Optional> classifications = default; + Optional longDescription = default; + Optional name = default; + Optional qualifiedName = default; + Optional shortDescription = default; + Optional lastModifiedTS = default; + Optional createTime = default; + Optional createdBy = default; + Optional updateTime = default; + Optional updatedBy = default; + Optional anchor = default; + Optional> childrenCategories = default; + Optional parentCategory = default; + Optional> terms = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("guid"u8)) + { + guid = property.Value.GetString(); + continue; + } + if (property.NameEquals("classifications"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(AtlasClassification.DeserializeAtlasClassification(item)); + } + classifications = array; + continue; + } + if (property.NameEquals("longDescription"u8)) + { + longDescription = property.Value.GetString(); + continue; + } + if (property.NameEquals("name"u8)) + { + name = property.Value.GetString(); + continue; + } + if (property.NameEquals("qualifiedName"u8)) + { + qualifiedName = property.Value.GetString(); + continue; + } + if (property.NameEquals("shortDescription"u8)) + { + shortDescription = property.Value.GetString(); + continue; + } + if (property.NameEquals("lastModifiedTS"u8)) + { + lastModifiedTS = property.Value.GetString(); + continue; + } + if (property.NameEquals("createTime"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + createTime = property.Value.GetInt64(); + continue; + } + if (property.NameEquals("createdBy"u8)) + { + createdBy = property.Value.GetString(); + continue; + } + if (property.NameEquals("updateTime"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + updateTime = property.Value.GetInt64(); + continue; + } + if (property.NameEquals("updatedBy"u8)) + { + updatedBy = property.Value.GetString(); + continue; + } + if (property.NameEquals("anchor"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + anchor = AtlasGlossaryHeader.DeserializeAtlasGlossaryHeader(property.Value); + continue; + } + if (property.NameEquals("childrenCategories"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(AtlasRelatedCategoryHeader.DeserializeAtlasRelatedCategoryHeader(item)); + } + childrenCategories = array; + continue; + } + if (property.NameEquals("parentCategory"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + parentCategory = AtlasRelatedCategoryHeader.DeserializeAtlasRelatedCategoryHeader(property.Value); + continue; + } + if (property.NameEquals("terms"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(AtlasRelatedTermHeader.DeserializeAtlasRelatedTermHeader(item)); + } + terms = array; + continue; + } + } + return new AtlasGlossaryCategory(guid.Value, Optional.ToList(classifications), longDescription.Value, name.Value, qualifiedName.Value, shortDescription.Value, lastModifiedTS.Value, Optional.ToNullable(createTime), createdBy.Value, Optional.ToNullable(updateTime), updatedBy.Value, anchor.Value, Optional.ToList(childrenCategories), parentCategory.Value, Optional.ToList(terms)); + } + + /// Deserializes the model from a raw response. + /// The response to deserialize the model from. + internal static AtlasGlossaryCategory FromResponse(Response response) + { + using var document = JsonDocument.Parse(response.Content); + return DeserializeAtlasGlossaryCategory(document.RootElement); + } + + /// Convert into a Utf8JsonRequestContent. + internal virtual RequestContent ToRequestContent() + { + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(this); + return content; + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasGlossaryCategory.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasGlossaryCategory.cs new file mode 100644 index 0000000000000..dbf7f52130e25 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasGlossaryCategory.cs @@ -0,0 +1,90 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + /// The glossary category. + public partial class AtlasGlossaryCategory + { + /// Initializes a new instance of . + public AtlasGlossaryCategory() + { + Classifications = new ChangeTrackingList(); + ChildrenCategories = new ChangeTrackingList(); + Terms = new ChangeTrackingList(); + } + + /// Initializes a new instance of . + /// The GUID of the object. + /// An array of classifications. + /// The long version description. + /// The name of the glossary object. + /// The qualified name of the glossary object. + /// The short version of description. + /// ETag for concurrency control. + /// The created time of the record. + /// The user who created the record. + /// The update time of the record. + /// The user who updated the record. + /// The glossary header with basic information. + /// An array of children categories. + /// The header of the related category. + /// An array of related term headers. + internal AtlasGlossaryCategory(string guid, IList classifications, string longDescription, string name, string qualifiedName, string shortDescription, string lastModifiedTS, long? createTime, string createdBy, long? updateTime, string updatedBy, AtlasGlossaryHeader anchor, IList childrenCategories, AtlasRelatedCategoryHeader parentCategory, IList terms) + { + Guid = guid; + Classifications = classifications; + LongDescription = longDescription; + Name = name; + QualifiedName = qualifiedName; + ShortDescription = shortDescription; + LastModifiedTS = lastModifiedTS; + CreateTime = createTime; + CreatedBy = createdBy; + UpdateTime = updateTime; + UpdatedBy = updatedBy; + Anchor = anchor; + ChildrenCategories = childrenCategories; + ParentCategory = parentCategory; + Terms = terms; + } + + /// The GUID of the object. + public string Guid { get; set; } + /// An array of classifications. + public IList Classifications { get; } + /// The long version description. + public string LongDescription { get; set; } + /// The name of the glossary object. + public string Name { get; set; } + /// The qualified name of the glossary object. + public string QualifiedName { get; set; } + /// The short version of description. + public string ShortDescription { get; set; } + /// ETag for concurrency control. + public string LastModifiedTS { get; set; } + /// The created time of the record. + public long? CreateTime { get; set; } + /// The user who created the record. + public string CreatedBy { get; set; } + /// The update time of the record. + public long? UpdateTime { get; set; } + /// The user who updated the record. + public string UpdatedBy { get; set; } + /// The glossary header with basic information. + public AtlasGlossaryHeader Anchor { get; set; } + /// An array of children categories. + public IList ChildrenCategories { get; } + /// The header of the related category. + public AtlasRelatedCategoryHeader ParentCategory { get; set; } + /// An array of related term headers. + public IList Terms { get; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasGlossaryExtInfo.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasGlossaryExtInfo.Serialization.cs new file mode 100644 index 0000000000000..b10bab4a61144 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasGlossaryExtInfo.Serialization.cs @@ -0,0 +1,192 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using System.Text.Json; +using Azure; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class AtlasGlossaryExtInfo + { + internal static AtlasGlossaryExtInfo DeserializeAtlasGlossaryExtInfo(JsonElement element) + { + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + Optional guid = default; + Optional> classifications = default; + Optional longDescription = default; + Optional name = default; + Optional qualifiedName = default; + Optional shortDescription = default; + Optional lastModifiedTS = default; + Optional createTime = default; + Optional createdBy = default; + Optional updateTime = default; + Optional updatedBy = default; + Optional> categories = default; + Optional language = default; + Optional> terms = default; + Optional usage = default; + Optional> categoryInfo = default; + Optional> termInfo = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("guid"u8)) + { + guid = property.Value.GetString(); + continue; + } + if (property.NameEquals("classifications"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(AtlasClassification.DeserializeAtlasClassification(item)); + } + classifications = array; + continue; + } + if (property.NameEquals("longDescription"u8)) + { + longDescription = property.Value.GetString(); + continue; + } + if (property.NameEquals("name"u8)) + { + name = property.Value.GetString(); + continue; + } + if (property.NameEquals("qualifiedName"u8)) + { + qualifiedName = property.Value.GetString(); + continue; + } + if (property.NameEquals("shortDescription"u8)) + { + shortDescription = property.Value.GetString(); + continue; + } + if (property.NameEquals("lastModifiedTS"u8)) + { + lastModifiedTS = property.Value.GetString(); + continue; + } + if (property.NameEquals("createTime"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + createTime = property.Value.GetInt64(); + continue; + } + if (property.NameEquals("createdBy"u8)) + { + createdBy = property.Value.GetString(); + continue; + } + if (property.NameEquals("updateTime"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + updateTime = property.Value.GetInt64(); + continue; + } + if (property.NameEquals("updatedBy"u8)) + { + updatedBy = property.Value.GetString(); + continue; + } + if (property.NameEquals("categories"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(AtlasRelatedCategoryHeader.DeserializeAtlasRelatedCategoryHeader(item)); + } + categories = array; + continue; + } + if (property.NameEquals("language"u8)) + { + language = property.Value.GetString(); + continue; + } + if (property.NameEquals("terms"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(AtlasRelatedTermHeader.DeserializeAtlasRelatedTermHeader(item)); + } + terms = array; + continue; + } + if (property.NameEquals("usage"u8)) + { + usage = property.Value.GetString(); + continue; + } + if (property.NameEquals("categoryInfo"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + Dictionary dictionary = new Dictionary(); + foreach (var property0 in property.Value.EnumerateObject()) + { + dictionary.Add(property0.Name, AtlasGlossaryCategory.DeserializeAtlasGlossaryCategory(property0.Value)); + } + categoryInfo = dictionary; + continue; + } + if (property.NameEquals("termInfo"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + Dictionary dictionary = new Dictionary(); + foreach (var property0 in property.Value.EnumerateObject()) + { + dictionary.Add(property0.Name, AtlasGlossaryTerm.DeserializeAtlasGlossaryTerm(property0.Value)); + } + termInfo = dictionary; + continue; + } + } + return new AtlasGlossaryExtInfo(guid.Value, Optional.ToList(classifications), longDescription.Value, name.Value, qualifiedName.Value, shortDescription.Value, lastModifiedTS.Value, Optional.ToNullable(createTime), createdBy.Value, Optional.ToNullable(updateTime), updatedBy.Value, Optional.ToList(categories), language.Value, Optional.ToList(terms), usage.Value, Optional.ToDictionary(categoryInfo), Optional.ToDictionary(termInfo)); + } + + /// Deserializes the model from a raw response. + /// The response to deserialize the model from. + internal static AtlasGlossaryExtInfo FromResponse(Response response) + { + using var document = JsonDocument.Parse(response.Content); + return DeserializeAtlasGlossaryExtInfo(document.RootElement); + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasGlossaryExtInfo.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasGlossaryExtInfo.cs new file mode 100644 index 0000000000000..93053c9b9d9b1 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasGlossaryExtInfo.cs @@ -0,0 +1,100 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + /// The extended information of glossary. + public partial class AtlasGlossaryExtInfo + { + /// Initializes a new instance of . + internal AtlasGlossaryExtInfo() + { + Classifications = new ChangeTrackingList(); + Categories = new ChangeTrackingList(); + Terms = new ChangeTrackingList(); + CategoryInfo = new ChangeTrackingDictionary(); + TermInfo = new ChangeTrackingDictionary(); + } + + /// Initializes a new instance of . + /// The GUID of the object. + /// An array of classifications. + /// The long version description. + /// The name of the glossary object. + /// The qualified name of the glossary object. + /// The short version of description. + /// ETag for concurrency control. + /// The created time of the record. + /// The user who created the record. + /// The update time of the record. + /// The user who updated the record. + /// An array of categories. + /// The language of the glossary. + /// An array of related term headers. + /// The usage of the glossary. + /// The glossary category information. + /// The glossary term information. + internal AtlasGlossaryExtInfo(string guid, IReadOnlyList classifications, string longDescription, string name, string qualifiedName, string shortDescription, string lastModifiedTS, long? createTime, string createdBy, long? updateTime, string updatedBy, IReadOnlyList categories, string language, IReadOnlyList terms, string usage, IReadOnlyDictionary categoryInfo, IReadOnlyDictionary termInfo) + { + Guid = guid; + Classifications = classifications; + LongDescription = longDescription; + Name = name; + QualifiedName = qualifiedName; + ShortDescription = shortDescription; + LastModifiedTS = lastModifiedTS; + CreateTime = createTime; + CreatedBy = createdBy; + UpdateTime = updateTime; + UpdatedBy = updatedBy; + Categories = categories; + Language = language; + Terms = terms; + Usage = usage; + CategoryInfo = categoryInfo; + TermInfo = termInfo; + } + + /// The GUID of the object. + public string Guid { get; } + /// An array of classifications. + public IReadOnlyList Classifications { get; } + /// The long version description. + public string LongDescription { get; } + /// The name of the glossary object. + public string Name { get; } + /// The qualified name of the glossary object. + public string QualifiedName { get; } + /// The short version of description. + public string ShortDescription { get; } + /// ETag for concurrency control. + public string LastModifiedTS { get; } + /// The created time of the record. + public long? CreateTime { get; } + /// The user who created the record. + public string CreatedBy { get; } + /// The update time of the record. + public long? UpdateTime { get; } + /// The user who updated the record. + public string UpdatedBy { get; } + /// An array of categories. + public IReadOnlyList Categories { get; } + /// The language of the glossary. + public string Language { get; } + /// An array of related term headers. + public IReadOnlyList Terms { get; } + /// The usage of the glossary. + public string Usage { get; } + /// The glossary category information. + public IReadOnlyDictionary CategoryInfo { get; } + /// The glossary term information. + public IReadOnlyDictionary TermInfo { get; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasGlossaryHeader.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasGlossaryHeader.Serialization.cs new file mode 100644 index 0000000000000..b6546a6ac63dc --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasGlossaryHeader.Serialization.cs @@ -0,0 +1,83 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class AtlasGlossaryHeader : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + if (Optional.IsDefined(DisplayText)) + { + writer.WritePropertyName("displayText"u8); + writer.WriteStringValue(DisplayText); + } + if (Optional.IsDefined(GlossaryGuid)) + { + writer.WritePropertyName("glossaryGuid"u8); + writer.WriteStringValue(GlossaryGuid); + } + if (Optional.IsDefined(RelationGuid)) + { + writer.WritePropertyName("relationGuid"u8); + writer.WriteStringValue(RelationGuid); + } + writer.WriteEndObject(); + } + + internal static AtlasGlossaryHeader DeserializeAtlasGlossaryHeader(JsonElement element) + { + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + Optional displayText = default; + Optional glossaryGuid = default; + Optional relationGuid = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("displayText"u8)) + { + displayText = property.Value.GetString(); + continue; + } + if (property.NameEquals("glossaryGuid"u8)) + { + glossaryGuid = property.Value.GetString(); + continue; + } + if (property.NameEquals("relationGuid"u8)) + { + relationGuid = property.Value.GetString(); + continue; + } + } + return new AtlasGlossaryHeader(displayText.Value, glossaryGuid.Value, relationGuid.Value); + } + + /// Deserializes the model from a raw response. + /// The response to deserialize the model from. + internal static AtlasGlossaryHeader FromResponse(Response response) + { + using var document = JsonDocument.Parse(response.Content); + return DeserializeAtlasGlossaryHeader(document.RootElement); + } + + /// Convert into a Utf8JsonRequestContent. + internal virtual RequestContent ToRequestContent() + { + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(this); + return content; + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasGlossaryHeader.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasGlossaryHeader.cs new file mode 100644 index 0000000000000..a6e643241826c --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasGlossaryHeader.cs @@ -0,0 +1,36 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +namespace Azure.Analytics.Purview.DataMap +{ + /// The glossary header with basic information. + public partial class AtlasGlossaryHeader + { + /// Initializes a new instance of . + public AtlasGlossaryHeader() + { + } + + /// Initializes a new instance of . + /// The display text. + /// The GUID of the glossary. + /// The GUID of the relationship. + internal AtlasGlossaryHeader(string displayText, string glossaryGuid, string relationGuid) + { + DisplayText = displayText; + GlossaryGuid = glossaryGuid; + RelationGuid = relationGuid; + } + + /// The display text. + public string DisplayText { get; set; } + /// The GUID of the glossary. + public string GlossaryGuid { get; set; } + /// The GUID of the relationship. + public string RelationGuid { get; set; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasGlossaryTerm.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasGlossaryTerm.Serialization.cs new file mode 100644 index 0000000000000..11c6183820728 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasGlossaryTerm.Serialization.cs @@ -0,0 +1,868 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Collections.Generic; +using System.Text.Json; +using Azure; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class AtlasGlossaryTerm : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + if (Optional.IsDefined(Guid)) + { + writer.WritePropertyName("guid"u8); + writer.WriteStringValue(Guid); + } + if (Optional.IsCollectionDefined(Classifications)) + { + writer.WritePropertyName("classifications"u8); + writer.WriteStartArray(); + foreach (var item in Classifications) + { + writer.WriteObjectValue(item); + } + writer.WriteEndArray(); + } + if (Optional.IsDefined(LongDescription)) + { + writer.WritePropertyName("longDescription"u8); + writer.WriteStringValue(LongDescription); + } + if (Optional.IsDefined(Name)) + { + writer.WritePropertyName("name"u8); + writer.WriteStringValue(Name); + } + if (Optional.IsDefined(QualifiedName)) + { + writer.WritePropertyName("qualifiedName"u8); + writer.WriteStringValue(QualifiedName); + } + if (Optional.IsDefined(ShortDescription)) + { + writer.WritePropertyName("shortDescription"u8); + writer.WriteStringValue(ShortDescription); + } + if (Optional.IsDefined(LastModifiedTS)) + { + writer.WritePropertyName("lastModifiedTS"u8); + writer.WriteStringValue(LastModifiedTS); + } + if (Optional.IsDefined(CreateTime)) + { + writer.WritePropertyName("createTime"u8); + writer.WriteNumberValue(CreateTime.Value); + } + if (Optional.IsDefined(CreatedBy)) + { + writer.WritePropertyName("createdBy"u8); + writer.WriteStringValue(CreatedBy); + } + if (Optional.IsDefined(UpdateTime)) + { + writer.WritePropertyName("updateTime"u8); + writer.WriteNumberValue(UpdateTime.Value); + } + if (Optional.IsDefined(UpdatedBy)) + { + writer.WritePropertyName("updatedBy"u8); + writer.WriteStringValue(UpdatedBy); + } + if (Optional.IsDefined(Abbreviation)) + { + writer.WritePropertyName("abbreviation"u8); + writer.WriteStringValue(Abbreviation); + } + if (Optional.IsCollectionDefined(TemplateName)) + { + writer.WritePropertyName("templateName"u8); + writer.WriteStartArray(); + foreach (var item in TemplateName) + { + if (item == null) + { + writer.WriteNullValue(); + continue; + } +#if NET6_0_OR_GREATER + writer.WriteRawValue(item); +#else + using (JsonDocument document = JsonDocument.Parse(item)) + { + JsonSerializer.Serialize(writer, document.RootElement); + } +#endif + } + writer.WriteEndArray(); + } + if (Optional.IsDefined(Anchor)) + { + writer.WritePropertyName("anchor"u8); + writer.WriteObjectValue(Anchor); + } + if (Optional.IsCollectionDefined(Antonyms)) + { + writer.WritePropertyName("antonyms"u8); + writer.WriteStartArray(); + foreach (var item in Antonyms) + { + writer.WriteObjectValue(item); + } + writer.WriteEndArray(); + } + if (Optional.IsDefined(Status)) + { + writer.WritePropertyName("status"u8); + writer.WriteStringValue(Status.Value.ToString()); + } + if (Optional.IsDefined(NickName)) + { + writer.WritePropertyName("nickName"u8); + writer.WriteStringValue(NickName); + } + if (Optional.IsCollectionDefined(HierarchyInfo)) + { + writer.WritePropertyName("hierarchyInfo"u8); + writer.WriteStartArray(); + foreach (var item in HierarchyInfo) + { + writer.WriteObjectValue(item); + } + writer.WriteEndArray(); + } + if (Optional.IsCollectionDefined(Resources)) + { + writer.WritePropertyName("resources"u8); + writer.WriteStartArray(); + foreach (var item in Resources) + { + writer.WriteObjectValue(item); + } + writer.WriteEndArray(); + } + if (Optional.IsCollectionDefined(Contacts)) + { + writer.WritePropertyName("contacts"u8); + writer.WriteStartObject(); + foreach (var item in Contacts) + { + writer.WritePropertyName(item.Key); + if (item.Value == null) + { + writer.WriteNullValue(); + continue; + } + writer.WriteStartArray(); + foreach (var item0 in item.Value) + { + writer.WriteObjectValue(item0); + } + writer.WriteEndArray(); + } + writer.WriteEndObject(); + } + if (Optional.IsCollectionDefined(Attributes)) + { + writer.WritePropertyName("attributes"u8); + writer.WriteStartObject(); + foreach (var item in Attributes) + { + writer.WritePropertyName(item.Key); + if (item.Value == null) + { + writer.WriteNullValue(); + continue; + } + writer.WriteStartObject(); + foreach (var item0 in item.Value) + { + writer.WritePropertyName(item0.Key); + if (item0.Value == null) + { + writer.WriteNullValue(); + continue; + } +#if NET6_0_OR_GREATER + writer.WriteRawValue(item0.Value); +#else + using (JsonDocument document = JsonDocument.Parse(item0.Value)) + { + JsonSerializer.Serialize(writer, document.RootElement); + } +#endif + } + writer.WriteEndObject(); + } + writer.WriteEndObject(); + } + if (Optional.IsCollectionDefined(AssignedEntities)) + { + writer.WritePropertyName("assignedEntities"u8); + writer.WriteStartArray(); + foreach (var item in AssignedEntities) + { + writer.WriteObjectValue(item); + } + writer.WriteEndArray(); + } + if (Optional.IsCollectionDefined(Categories)) + { + writer.WritePropertyName("categories"u8); + writer.WriteStartArray(); + foreach (var item in Categories) + { + writer.WriteObjectValue(item); + } + writer.WriteEndArray(); + } + if (Optional.IsCollectionDefined(Classifies)) + { + writer.WritePropertyName("classifies"u8); + writer.WriteStartArray(); + foreach (var item in Classifies) + { + writer.WriteObjectValue(item); + } + writer.WriteEndArray(); + } + if (Optional.IsCollectionDefined(Examples)) + { + writer.WritePropertyName("examples"u8); + writer.WriteStartArray(); + foreach (var item in Examples) + { + writer.WriteStringValue(item); + } + writer.WriteEndArray(); + } + if (Optional.IsCollectionDefined(IsA)) + { + writer.WritePropertyName("isA"u8); + writer.WriteStartArray(); + foreach (var item in IsA) + { + writer.WriteObjectValue(item); + } + writer.WriteEndArray(); + } + if (Optional.IsCollectionDefined(PreferredTerms)) + { + writer.WritePropertyName("preferredTerms"u8); + writer.WriteStartArray(); + foreach (var item in PreferredTerms) + { + writer.WriteObjectValue(item); + } + writer.WriteEndArray(); + } + if (Optional.IsCollectionDefined(PreferredToTerms)) + { + writer.WritePropertyName("preferredToTerms"u8); + writer.WriteStartArray(); + foreach (var item in PreferredToTerms) + { + writer.WriteObjectValue(item); + } + writer.WriteEndArray(); + } + if (Optional.IsCollectionDefined(ReplacedBy)) + { + writer.WritePropertyName("replacedBy"u8); + writer.WriteStartArray(); + foreach (var item in ReplacedBy) + { + writer.WriteObjectValue(item); + } + writer.WriteEndArray(); + } + if (Optional.IsCollectionDefined(ReplacementTerms)) + { + writer.WritePropertyName("replacementTerms"u8); + writer.WriteStartArray(); + foreach (var item in ReplacementTerms) + { + writer.WriteObjectValue(item); + } + writer.WriteEndArray(); + } + if (Optional.IsCollectionDefined(SeeAlso)) + { + writer.WritePropertyName("seeAlso"u8); + writer.WriteStartArray(); + foreach (var item in SeeAlso) + { + writer.WriteObjectValue(item); + } + writer.WriteEndArray(); + } + if (Optional.IsCollectionDefined(Synonyms)) + { + writer.WritePropertyName("synonyms"u8); + writer.WriteStartArray(); + foreach (var item in Synonyms) + { + writer.WriteObjectValue(item); + } + writer.WriteEndArray(); + } + if (Optional.IsCollectionDefined(TranslatedTerms)) + { + writer.WritePropertyName("translatedTerms"u8); + writer.WriteStartArray(); + foreach (var item in TranslatedTerms) + { + writer.WriteObjectValue(item); + } + writer.WriteEndArray(); + } + if (Optional.IsCollectionDefined(TranslationTerms)) + { + writer.WritePropertyName("translationTerms"u8); + writer.WriteStartArray(); + foreach (var item in TranslationTerms) + { + writer.WriteObjectValue(item); + } + writer.WriteEndArray(); + } + if (Optional.IsDefined(Usage)) + { + writer.WritePropertyName("usage"u8); + writer.WriteStringValue(Usage); + } + if (Optional.IsCollectionDefined(ValidValues)) + { + writer.WritePropertyName("validValues"u8); + writer.WriteStartArray(); + foreach (var item in ValidValues) + { + writer.WriteObjectValue(item); + } + writer.WriteEndArray(); + } + if (Optional.IsCollectionDefined(ValidValuesFor)) + { + writer.WritePropertyName("validValuesFor"u8); + writer.WriteStartArray(); + foreach (var item in ValidValuesFor) + { + writer.WriteObjectValue(item); + } + writer.WriteEndArray(); + } + writer.WriteEndObject(); + } + + internal static AtlasGlossaryTerm DeserializeAtlasGlossaryTerm(JsonElement element) + { + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + Optional guid = default; + Optional> classifications = default; + Optional longDescription = default; + Optional name = default; + Optional qualifiedName = default; + Optional shortDescription = default; + Optional lastModifiedTS = default; + Optional createTime = default; + Optional createdBy = default; + Optional updateTime = default; + Optional updatedBy = default; + Optional abbreviation = default; + Optional> templateName = default; + Optional anchor = default; + Optional> antonyms = default; + Optional status = default; + Optional nickName = default; + Optional> hierarchyInfo = default; + Optional> resources = default; + Optional>> contacts = default; + Optional>> attributes = default; + Optional> assignedEntities = default; + Optional> categories = default; + Optional> classifies = default; + Optional> examples = default; + Optional> isA = default; + Optional> preferredTerms = default; + Optional> preferredToTerms = default; + Optional> replacedBy = default; + Optional> replacementTerms = default; + Optional> seeAlso = default; + Optional> synonyms = default; + Optional> translatedTerms = default; + Optional> translationTerms = default; + Optional usage = default; + Optional> validValues = default; + Optional> validValuesFor = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("guid"u8)) + { + guid = property.Value.GetString(); + continue; + } + if (property.NameEquals("classifications"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(AtlasClassification.DeserializeAtlasClassification(item)); + } + classifications = array; + continue; + } + if (property.NameEquals("longDescription"u8)) + { + longDescription = property.Value.GetString(); + continue; + } + if (property.NameEquals("name"u8)) + { + name = property.Value.GetString(); + continue; + } + if (property.NameEquals("qualifiedName"u8)) + { + qualifiedName = property.Value.GetString(); + continue; + } + if (property.NameEquals("shortDescription"u8)) + { + shortDescription = property.Value.GetString(); + continue; + } + if (property.NameEquals("lastModifiedTS"u8)) + { + lastModifiedTS = property.Value.GetString(); + continue; + } + if (property.NameEquals("createTime"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + createTime = property.Value.GetInt64(); + continue; + } + if (property.NameEquals("createdBy"u8)) + { + createdBy = property.Value.GetString(); + continue; + } + if (property.NameEquals("updateTime"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + updateTime = property.Value.GetInt64(); + continue; + } + if (property.NameEquals("updatedBy"u8)) + { + updatedBy = property.Value.GetString(); + continue; + } + if (property.NameEquals("abbreviation"u8)) + { + abbreviation = property.Value.GetString(); + continue; + } + if (property.NameEquals("templateName"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + if (item.ValueKind == JsonValueKind.Null) + { + array.Add(null); + } + else + { + array.Add(BinaryData.FromString(item.GetRawText())); + } + } + templateName = array; + continue; + } + if (property.NameEquals("anchor"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + anchor = AtlasGlossaryHeader.DeserializeAtlasGlossaryHeader(property.Value); + continue; + } + if (property.NameEquals("antonyms"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(AtlasRelatedTermHeader.DeserializeAtlasRelatedTermHeader(item)); + } + antonyms = array; + continue; + } + if (property.NameEquals("status"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + status = new TermStatus(property.Value.GetString()); + continue; + } + if (property.NameEquals("nickName"u8)) + { + nickName = property.Value.GetString(); + continue; + } + if (property.NameEquals("hierarchyInfo"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(PurviewObjectId.DeserializePurviewObjectId(item)); + } + hierarchyInfo = array; + continue; + } + if (property.NameEquals("resources"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(ResourceLink.DeserializeResourceLink(item)); + } + resources = array; + continue; + } + if (property.NameEquals("contacts"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + Dictionary> dictionary = new Dictionary>(); + foreach (var property0 in property.Value.EnumerateObject()) + { + if (property0.Value.ValueKind == JsonValueKind.Null) + { + dictionary.Add(property0.Name, null); + } + else + { + List array = new List(); + foreach (var item in property0.Value.EnumerateArray()) + { + array.Add(ContactInfo.DeserializeContactInfo(item)); + } + dictionary.Add(property0.Name, array); + } + } + contacts = dictionary; + continue; + } + if (property.NameEquals("attributes"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + Dictionary> dictionary = new Dictionary>(); + foreach (var property0 in property.Value.EnumerateObject()) + { + if (property0.Value.ValueKind == JsonValueKind.Null) + { + dictionary.Add(property0.Name, null); + } + else + { + Dictionary dictionary0 = new Dictionary(); + foreach (var property1 in property0.Value.EnumerateObject()) + { + if (property1.Value.ValueKind == JsonValueKind.Null) + { + dictionary0.Add(property1.Name, null); + } + else + { + dictionary0.Add(property1.Name, BinaryData.FromString(property1.Value.GetRawText())); + } + } + dictionary.Add(property0.Name, dictionary0); + } + } + attributes = dictionary; + continue; + } + if (property.NameEquals("assignedEntities"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(AtlasRelatedObjectId.DeserializeAtlasRelatedObjectId(item)); + } + assignedEntities = array; + continue; + } + if (property.NameEquals("categories"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(AtlasTermCategorizationHeader.DeserializeAtlasTermCategorizationHeader(item)); + } + categories = array; + continue; + } + if (property.NameEquals("classifies"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(AtlasRelatedTermHeader.DeserializeAtlasRelatedTermHeader(item)); + } + classifies = array; + continue; + } + if (property.NameEquals("examples"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(item.GetString()); + } + examples = array; + continue; + } + if (property.NameEquals("isA"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(AtlasRelatedTermHeader.DeserializeAtlasRelatedTermHeader(item)); + } + isA = array; + continue; + } + if (property.NameEquals("preferredTerms"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(AtlasRelatedTermHeader.DeserializeAtlasRelatedTermHeader(item)); + } + preferredTerms = array; + continue; + } + if (property.NameEquals("preferredToTerms"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(AtlasRelatedTermHeader.DeserializeAtlasRelatedTermHeader(item)); + } + preferredToTerms = array; + continue; + } + if (property.NameEquals("replacedBy"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(AtlasRelatedTermHeader.DeserializeAtlasRelatedTermHeader(item)); + } + replacedBy = array; + continue; + } + if (property.NameEquals("replacementTerms"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(AtlasRelatedTermHeader.DeserializeAtlasRelatedTermHeader(item)); + } + replacementTerms = array; + continue; + } + if (property.NameEquals("seeAlso"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(AtlasRelatedTermHeader.DeserializeAtlasRelatedTermHeader(item)); + } + seeAlso = array; + continue; + } + if (property.NameEquals("synonyms"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(AtlasRelatedTermHeader.DeserializeAtlasRelatedTermHeader(item)); + } + synonyms = array; + continue; + } + if (property.NameEquals("translatedTerms"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(AtlasRelatedTermHeader.DeserializeAtlasRelatedTermHeader(item)); + } + translatedTerms = array; + continue; + } + if (property.NameEquals("translationTerms"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(AtlasRelatedTermHeader.DeserializeAtlasRelatedTermHeader(item)); + } + translationTerms = array; + continue; + } + if (property.NameEquals("usage"u8)) + { + usage = property.Value.GetString(); + continue; + } + if (property.NameEquals("validValues"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(AtlasRelatedTermHeader.DeserializeAtlasRelatedTermHeader(item)); + } + validValues = array; + continue; + } + if (property.NameEquals("validValuesFor"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(AtlasRelatedTermHeader.DeserializeAtlasRelatedTermHeader(item)); + } + validValuesFor = array; + continue; + } + } + return new AtlasGlossaryTerm(guid.Value, Optional.ToList(classifications), longDescription.Value, name.Value, qualifiedName.Value, shortDescription.Value, lastModifiedTS.Value, Optional.ToNullable(createTime), createdBy.Value, Optional.ToNullable(updateTime), updatedBy.Value, abbreviation.Value, Optional.ToList(templateName), anchor.Value, Optional.ToList(antonyms), Optional.ToNullable(status), nickName.Value, Optional.ToList(hierarchyInfo), Optional.ToList(resources), Optional.ToDictionary(contacts), Optional.ToDictionary(attributes), Optional.ToList(assignedEntities), Optional.ToList(categories), Optional.ToList(classifies), Optional.ToList(examples), Optional.ToList(isA), Optional.ToList(preferredTerms), Optional.ToList(preferredToTerms), Optional.ToList(replacedBy), Optional.ToList(replacementTerms), Optional.ToList(seeAlso), Optional.ToList(synonyms), Optional.ToList(translatedTerms), Optional.ToList(translationTerms), usage.Value, Optional.ToList(validValues), Optional.ToList(validValuesFor)); + } + + /// Deserializes the model from a raw response. + /// The response to deserialize the model from. + internal static AtlasGlossaryTerm FromResponse(Response response) + { + using var document = JsonDocument.Parse(response.Content); + return DeserializeAtlasGlossaryTerm(document.RootElement); + } + + /// Convert into a Utf8JsonRequestContent. + internal virtual RequestContent ToRequestContent() + { + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(this); + return content; + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasGlossaryTerm.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasGlossaryTerm.cs new file mode 100644 index 0000000000000..9d7e748caec08 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasGlossaryTerm.cs @@ -0,0 +1,235 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Collections.Generic; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + /// The glossary term. + public partial class AtlasGlossaryTerm + { + /// Initializes a new instance of . + public AtlasGlossaryTerm() + { + Classifications = new ChangeTrackingList(); + TemplateName = new ChangeTrackingList(); + Antonyms = new ChangeTrackingList(); + HierarchyInfo = new ChangeTrackingList(); + Resources = new ChangeTrackingList(); + Contacts = new ChangeTrackingDictionary>(); + Attributes = new ChangeTrackingDictionary>(); + AssignedEntities = new ChangeTrackingList(); + Categories = new ChangeTrackingList(); + Classifies = new ChangeTrackingList(); + Examples = new ChangeTrackingList(); + IsA = new ChangeTrackingList(); + PreferredTerms = new ChangeTrackingList(); + PreferredToTerms = new ChangeTrackingList(); + ReplacedBy = new ChangeTrackingList(); + ReplacementTerms = new ChangeTrackingList(); + SeeAlso = new ChangeTrackingList(); + Synonyms = new ChangeTrackingList(); + TranslatedTerms = new ChangeTrackingList(); + TranslationTerms = new ChangeTrackingList(); + ValidValues = new ChangeTrackingList(); + ValidValuesFor = new ChangeTrackingList(); + } + + /// Initializes a new instance of . + /// The GUID of the object. + /// An array of classifications. + /// The long version description. + /// The name of the glossary object. + /// The qualified name of the glossary object. + /// The short version of description. + /// ETag for concurrency control. + /// The created time of the record. + /// The user who created the record. + /// The update time of the record. + /// The user who updated the record. + /// The abbreviation of the term. + /// The name of the template. + /// The glossary header with basic information. + /// An array of related term headers as antonyms. + /// Status of the AtlasGlossaryTerm. + /// The nick name of the term. + /// The hierarchy information of the term. + /// An array of resource link for term. + /// The dictionary of contacts for terms. Key could be Expert or Steward. + /// + /// The custom attributes of the term, which is map<string,map<string,object>>. + /// The + /// key of the first layer map is term template name. + /// + /// An array of related object IDs. + /// An array of term categorization headers. + /// An array of related term headers. + /// An array of examples. + /// An array of related term headers indicating the is-a relationship. + /// An array of preferred related term headers. + /// An array of related term headers that are preferred to. + /// An array of related term headers that are replaced by. + /// An array of related term headers for replacement. + /// An array of related term headers for see also. + /// An array of related term headers as synonyms. + /// An array of translated related term headers. + /// An array of related term headers for translation. + /// The usage of the term. + /// An array of related term headers as valid values. + /// An array of related term headers as valid values for other records. + internal AtlasGlossaryTerm(string guid, IList classifications, string longDescription, string name, string qualifiedName, string shortDescription, string lastModifiedTS, long? createTime, string createdBy, long? updateTime, string updatedBy, string abbreviation, IList templateName, AtlasGlossaryHeader anchor, IList antonyms, TermStatus? status, string nickName, IList hierarchyInfo, IList resources, IDictionary> contacts, IDictionary> attributes, IList assignedEntities, IList categories, IList classifies, IList examples, IList isA, IList preferredTerms, IList preferredToTerms, IList replacedBy, IList replacementTerms, IList seeAlso, IList synonyms, IList translatedTerms, IList translationTerms, string usage, IList validValues, IList validValuesFor) + { + Guid = guid; + Classifications = classifications; + LongDescription = longDescription; + Name = name; + QualifiedName = qualifiedName; + ShortDescription = shortDescription; + LastModifiedTS = lastModifiedTS; + CreateTime = createTime; + CreatedBy = createdBy; + UpdateTime = updateTime; + UpdatedBy = updatedBy; + Abbreviation = abbreviation; + TemplateName = templateName; + Anchor = anchor; + Antonyms = antonyms; + Status = status; + NickName = nickName; + HierarchyInfo = hierarchyInfo; + Resources = resources; + Contacts = contacts; + Attributes = attributes; + AssignedEntities = assignedEntities; + Categories = categories; + Classifies = classifies; + Examples = examples; + IsA = isA; + PreferredTerms = preferredTerms; + PreferredToTerms = preferredToTerms; + ReplacedBy = replacedBy; + ReplacementTerms = replacementTerms; + SeeAlso = seeAlso; + Synonyms = synonyms; + TranslatedTerms = translatedTerms; + TranslationTerms = translationTerms; + Usage = usage; + ValidValues = validValues; + ValidValuesFor = validValuesFor; + } + + /// The GUID of the object. + public string Guid { get; set; } + /// An array of classifications. + public IList Classifications { get; } + /// The long version description. + public string LongDescription { get; set; } + /// The name of the glossary object. + public string Name { get; set; } + /// The qualified name of the glossary object. + public string QualifiedName { get; set; } + /// The short version of description. + public string ShortDescription { get; set; } + /// ETag for concurrency control. + public string LastModifiedTS { get; set; } + /// The created time of the record. + public long? CreateTime { get; set; } + /// The user who created the record. + public string CreatedBy { get; set; } + /// The update time of the record. + public long? UpdateTime { get; set; } + /// The user who updated the record. + public string UpdatedBy { get; set; } + /// The abbreviation of the term. + public string Abbreviation { get; set; } + /// + /// The name of the template. + /// + /// To assign an object to the element of this property use . + /// + /// + /// To assign an already formatted json string to this property use . + /// + /// + /// Examples: + /// + /// + /// BinaryData.FromObjectAsJson("foo") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromString("\"foo\"") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromObjectAsJson(new { key = "value" }) + /// Creates a payload of { "key": "value" }. + /// + /// + /// BinaryData.FromString("{\"key\": \"value\"}") + /// Creates a payload of { "key": "value" }. + /// + /// + /// + /// + public IList TemplateName { get; } + /// The glossary header with basic information. + public AtlasGlossaryHeader Anchor { get; set; } + /// An array of related term headers as antonyms. + public IList Antonyms { get; } + /// Status of the AtlasGlossaryTerm. + public TermStatus? Status { get; set; } + /// The nick name of the term. + public string NickName { get; set; } + /// The hierarchy information of the term. + public IList HierarchyInfo { get; } + /// An array of resource link for term. + public IList Resources { get; } + /// The dictionary of contacts for terms. Key could be Expert or Steward. + public IDictionary> Contacts { get; } + /// + /// The custom attributes of the term, which is map<string,map<string,object>>. + /// The + /// key of the first layer map is term template name. + /// + public IDictionary> Attributes { get; } + /// An array of related object IDs. + public IList AssignedEntities { get; } + /// An array of term categorization headers. + public IList Categories { get; } + /// An array of related term headers. + public IList Classifies { get; } + /// An array of examples. + public IList Examples { get; } + /// An array of related term headers indicating the is-a relationship. + public IList IsA { get; } + /// An array of preferred related term headers. + public IList PreferredTerms { get; } + /// An array of related term headers that are preferred to. + public IList PreferredToTerms { get; } + /// An array of related term headers that are replaced by. + public IList ReplacedBy { get; } + /// An array of related term headers for replacement. + public IList ReplacementTerms { get; } + /// An array of related term headers for see also. + public IList SeeAlso { get; } + /// An array of related term headers as synonyms. + public IList Synonyms { get; } + /// An array of translated related term headers. + public IList TranslatedTerms { get; } + /// An array of related term headers for translation. + public IList TranslationTerms { get; } + /// The usage of the term. + public string Usage { get; set; } + /// An array of related term headers as valid values. + public IList ValidValues { get; } + /// An array of related term headers as valid values for other records. + public IList ValidValuesFor { get; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasLineageInfo.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasLineageInfo.Serialization.cs new file mode 100644 index 0000000000000..d48cbb9baaa6a --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasLineageInfo.Serialization.cs @@ -0,0 +1,163 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Collections.Generic; +using System.Text.Json; +using Azure; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class AtlasLineageInfo + { + internal static AtlasLineageInfo DeserializeAtlasLineageInfo(JsonElement element) + { + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + Optional baseEntityGuid = default; + Optional> guidEntityMap = default; + Optional>> widthCounts = default; + Optional lineageDepth = default; + Optional lineageWidth = default; + Optional childrenCount = default; + Optional lineageDirection = default; + Optional> parentRelations = default; + Optional> relations = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("baseEntityGuid"u8)) + { + baseEntityGuid = property.Value.GetString(); + continue; + } + if (property.NameEquals("guidEntityMap"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + Dictionary dictionary = new Dictionary(); + foreach (var property0 in property.Value.EnumerateObject()) + { + dictionary.Add(property0.Name, AtlasEntityHeader.DeserializeAtlasEntityHeader(property0.Value)); + } + guidEntityMap = dictionary; + continue; + } + if (property.NameEquals("widthCounts"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + Dictionary> dictionary = new Dictionary>(); + foreach (var property0 in property.Value.EnumerateObject()) + { + if (property0.Value.ValueKind == JsonValueKind.Null) + { + dictionary.Add(property0.Name, null); + } + else + { + Dictionary dictionary0 = new Dictionary(); + foreach (var property1 in property0.Value.EnumerateObject()) + { + if (property1.Value.ValueKind == JsonValueKind.Null) + { + dictionary0.Add(property1.Name, null); + } + else + { + dictionary0.Add(property1.Name, BinaryData.FromString(property1.Value.GetRawText())); + } + } + dictionary.Add(property0.Name, dictionary0); + } + } + widthCounts = dictionary; + continue; + } + if (property.NameEquals("lineageDepth"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + lineageDepth = property.Value.GetInt32(); + continue; + } + if (property.NameEquals("lineageWidth"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + lineageWidth = property.Value.GetInt32(); + continue; + } + if (property.NameEquals("childrenCount"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + childrenCount = property.Value.GetInt32(); + continue; + } + if (property.NameEquals("lineageDirection"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + lineageDirection = new LineageDirection(property.Value.GetString()); + continue; + } + if (property.NameEquals("parentRelations"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(ParentRelation.DeserializeParentRelation(item)); + } + parentRelations = array; + continue; + } + if (property.NameEquals("relations"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(LineageRelation.DeserializeLineageRelation(item)); + } + relations = array; + continue; + } + } + return new AtlasLineageInfo(baseEntityGuid.Value, Optional.ToDictionary(guidEntityMap), Optional.ToDictionary(widthCounts), Optional.ToNullable(lineageDepth), Optional.ToNullable(lineageWidth), Optional.ToNullable(childrenCount), Optional.ToNullable(lineageDirection), Optional.ToList(parentRelations), Optional.ToList(relations)); + } + + /// Deserializes the model from a raw response. + /// The response to deserialize the model from. + internal static AtlasLineageInfo FromResponse(Response response) + { + using var document = JsonDocument.Parse(response.Content); + return DeserializeAtlasLineageInfo(document.RootElement); + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasLineageInfo.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasLineageInfo.cs new file mode 100644 index 0000000000000..e205193542bb3 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasLineageInfo.cs @@ -0,0 +1,68 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Collections.Generic; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + /// The lineage information. + public partial class AtlasLineageInfo + { + /// Initializes a new instance of . + internal AtlasLineageInfo() + { + GuidEntityMap = new ChangeTrackingDictionary(); + WidthCounts = new ChangeTrackingDictionary>(); + ParentRelations = new ChangeTrackingList(); + Relations = new ChangeTrackingList(); + } + + /// Initializes a new instance of . + /// The GUID of the base entity. + /// The GUID entity map. + /// The entity count in specific direction. + /// The depth of lineage. + /// The width of lineage. + /// The number of children node. + /// The enum of lineage direction. + /// An array of parentRelations relations. + /// An array of lineage relations. + internal AtlasLineageInfo(string baseEntityGuid, IReadOnlyDictionary guidEntityMap, IReadOnlyDictionary> widthCounts, int? lineageDepth, int? lineageWidth, int? childrenCount, LineageDirection? lineageDirection, IReadOnlyList parentRelations, IReadOnlyList relations) + { + BaseEntityGuid = baseEntityGuid; + GuidEntityMap = guidEntityMap; + WidthCounts = widthCounts; + LineageDepth = lineageDepth; + LineageWidth = lineageWidth; + ChildrenCount = childrenCount; + LineageDirection = lineageDirection; + ParentRelations = parentRelations; + Relations = relations; + } + + /// The GUID of the base entity. + public string BaseEntityGuid { get; } + /// The GUID entity map. + public IReadOnlyDictionary GuidEntityMap { get; } + /// The entity count in specific direction. + public IReadOnlyDictionary> WidthCounts { get; } + /// The depth of lineage. + public int? LineageDepth { get; } + /// The width of lineage. + public int? LineageWidth { get; } + /// The number of children node. + public int? ChildrenCount { get; } + /// The enum of lineage direction. + public LineageDirection? LineageDirection { get; } + /// An array of parentRelations relations. + public IReadOnlyList ParentRelations { get; } + /// An array of lineage relations. + public IReadOnlyList Relations { get; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasObjectId.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasObjectId.Serialization.cs new file mode 100644 index 0000000000000..8ee1cbe786841 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasObjectId.Serialization.cs @@ -0,0 +1,119 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Collections.Generic; +using System.Text.Json; +using Azure; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class AtlasObjectId : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + if (Optional.IsDefined(Guid)) + { + writer.WritePropertyName("guid"u8); + writer.WriteStringValue(Guid); + } + if (Optional.IsDefined(TypeName)) + { + writer.WritePropertyName("typeName"u8); + writer.WriteStringValue(TypeName); + } + if (Optional.IsCollectionDefined(UniqueAttributes)) + { + writer.WritePropertyName("uniqueAttributes"u8); + writer.WriteStartObject(); + foreach (var item in UniqueAttributes) + { + writer.WritePropertyName(item.Key); + if (item.Value == null) + { + writer.WriteNullValue(); + continue; + } +#if NET6_0_OR_GREATER + writer.WriteRawValue(item.Value); +#else + using (JsonDocument document = JsonDocument.Parse(item.Value)) + { + JsonSerializer.Serialize(writer, document.RootElement); + } +#endif + } + writer.WriteEndObject(); + } + writer.WriteEndObject(); + } + + internal static AtlasObjectId DeserializeAtlasObjectId(JsonElement element) + { + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + Optional guid = default; + Optional typeName = default; + Optional> uniqueAttributes = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("guid"u8)) + { + guid = property.Value.GetString(); + continue; + } + if (property.NameEquals("typeName"u8)) + { + typeName = property.Value.GetString(); + continue; + } + if (property.NameEquals("uniqueAttributes"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + Dictionary dictionary = new Dictionary(); + foreach (var property0 in property.Value.EnumerateObject()) + { + if (property0.Value.ValueKind == JsonValueKind.Null) + { + dictionary.Add(property0.Name, null); + } + else + { + dictionary.Add(property0.Name, BinaryData.FromString(property0.Value.GetRawText())); + } + } + uniqueAttributes = dictionary; + continue; + } + } + return new AtlasObjectId(guid.Value, typeName.Value, Optional.ToDictionary(uniqueAttributes)); + } + + /// Deserializes the model from a raw response. + /// The response to deserialize the model from. + internal static AtlasObjectId FromResponse(Response response) + { + using var document = JsonDocument.Parse(response.Content); + return DeserializeAtlasObjectId(document.RootElement); + } + + /// Convert into a Utf8JsonRequestContent. + internal virtual RequestContent ToRequestContent() + { + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(this); + return content; + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasObjectId.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasObjectId.cs new file mode 100644 index 0000000000000..05f51f1dbc10b --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasObjectId.cs @@ -0,0 +1,70 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Collections.Generic; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + /// Reference to an object-instance of a type - like entity. + public partial class AtlasObjectId + { + /// Initializes a new instance of . + public AtlasObjectId() + { + UniqueAttributes = new ChangeTrackingDictionary(); + } + + /// Initializes a new instance of . + /// The GUID of the object. + /// The name of the type. + /// The unique attributes of the object. + internal AtlasObjectId(string guid, string typeName, IDictionary uniqueAttributes) + { + Guid = guid; + TypeName = typeName; + UniqueAttributes = uniqueAttributes; + } + + /// The GUID of the object. + public string Guid { get; set; } + /// The name of the type. + public string TypeName { get; set; } + /// + /// The unique attributes of the object. + /// + /// To assign an object to the value of this property use . + /// + /// + /// To assign an already formatted json string to this property use . + /// + /// + /// Examples: + /// + /// + /// BinaryData.FromObjectAsJson("foo") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromString("\"foo\"") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromObjectAsJson(new { key = "value" }) + /// Creates a payload of { "key": "value" }. + /// + /// + /// BinaryData.FromString("{\"key\": \"value\"}") + /// Creates a payload of { "key": "value" }. + /// + /// + /// + /// + public IDictionary UniqueAttributes { get; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasRelatedCategoryHeader.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasRelatedCategoryHeader.Serialization.cs new file mode 100644 index 0000000000000..1135585d5d398 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasRelatedCategoryHeader.Serialization.cs @@ -0,0 +1,105 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class AtlasRelatedCategoryHeader : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + if (Optional.IsDefined(CategoryGuid)) + { + writer.WritePropertyName("categoryGuid"u8); + writer.WriteStringValue(CategoryGuid); + } + if (Optional.IsDefined(Description)) + { + writer.WritePropertyName("description"u8); + writer.WriteStringValue(Description); + } + if (Optional.IsDefined(DisplayText)) + { + writer.WritePropertyName("displayText"u8); + writer.WriteStringValue(DisplayText); + } + if (Optional.IsDefined(ParentCategoryGuid)) + { + writer.WritePropertyName("parentCategoryGuid"u8); + writer.WriteStringValue(ParentCategoryGuid); + } + if (Optional.IsDefined(RelationGuid)) + { + writer.WritePropertyName("relationGuid"u8); + writer.WriteStringValue(RelationGuid); + } + writer.WriteEndObject(); + } + + internal static AtlasRelatedCategoryHeader DeserializeAtlasRelatedCategoryHeader(JsonElement element) + { + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + Optional categoryGuid = default; + Optional description = default; + Optional displayText = default; + Optional parentCategoryGuid = default; + Optional relationGuid = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("categoryGuid"u8)) + { + categoryGuid = property.Value.GetString(); + continue; + } + if (property.NameEquals("description"u8)) + { + description = property.Value.GetString(); + continue; + } + if (property.NameEquals("displayText"u8)) + { + displayText = property.Value.GetString(); + continue; + } + if (property.NameEquals("parentCategoryGuid"u8)) + { + parentCategoryGuid = property.Value.GetString(); + continue; + } + if (property.NameEquals("relationGuid"u8)) + { + relationGuid = property.Value.GetString(); + continue; + } + } + return new AtlasRelatedCategoryHeader(categoryGuid.Value, description.Value, displayText.Value, parentCategoryGuid.Value, relationGuid.Value); + } + + /// Deserializes the model from a raw response. + /// The response to deserialize the model from. + internal static AtlasRelatedCategoryHeader FromResponse(Response response) + { + using var document = JsonDocument.Parse(response.Content); + return DeserializeAtlasRelatedCategoryHeader(document.RootElement); + } + + /// Convert into a Utf8JsonRequestContent. + internal virtual RequestContent ToRequestContent() + { + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(this); + return content; + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasRelatedCategoryHeader.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasRelatedCategoryHeader.cs new file mode 100644 index 0000000000000..947f97481ce8a --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasRelatedCategoryHeader.cs @@ -0,0 +1,44 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +namespace Azure.Analytics.Purview.DataMap +{ + /// The header of the related category. + public partial class AtlasRelatedCategoryHeader + { + /// Initializes a new instance of . + public AtlasRelatedCategoryHeader() + { + } + + /// Initializes a new instance of . + /// The GUID of the category. + /// The description of the category header. + /// The display text. + /// The GUID of the parent category. + /// The GUID of the relationship. + internal AtlasRelatedCategoryHeader(string categoryGuid, string description, string displayText, string parentCategoryGuid, string relationGuid) + { + CategoryGuid = categoryGuid; + Description = description; + DisplayText = displayText; + ParentCategoryGuid = parentCategoryGuid; + RelationGuid = relationGuid; + } + + /// The GUID of the category. + public string CategoryGuid { get; set; } + /// The description of the category header. + public string Description { get; set; } + /// The display text. + public string DisplayText { get; set; } + /// The GUID of the parent category. + public string ParentCategoryGuid { get; set; } + /// The GUID of the relationship. + public string RelationGuid { get; set; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasRelatedObjectId.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasRelatedObjectId.Serialization.cs new file mode 100644 index 0000000000000..ddb9ae22ab18a --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasRelatedObjectId.Serialization.cs @@ -0,0 +1,201 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Collections.Generic; +using System.Text.Json; +using Azure; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class AtlasRelatedObjectId : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + if (Optional.IsDefined(Guid)) + { + writer.WritePropertyName("guid"u8); + writer.WriteStringValue(Guid); + } + if (Optional.IsDefined(TypeName)) + { + writer.WritePropertyName("typeName"u8); + writer.WriteStringValue(TypeName); + } + if (Optional.IsCollectionDefined(UniqueAttributes)) + { + writer.WritePropertyName("uniqueAttributes"u8); + writer.WriteStartObject(); + foreach (var item in UniqueAttributes) + { + writer.WritePropertyName(item.Key); + if (item.Value == null) + { + writer.WriteNullValue(); + continue; + } +#if NET6_0_OR_GREATER + writer.WriteRawValue(item.Value); +#else + using (JsonDocument document = JsonDocument.Parse(item.Value)) + { + JsonSerializer.Serialize(writer, document.RootElement); + } +#endif + } + writer.WriteEndObject(); + } + if (Optional.IsDefined(DisplayText)) + { + writer.WritePropertyName("displayText"u8); + writer.WriteStringValue(DisplayText); + } + if (Optional.IsDefined(EntityStatus)) + { + writer.WritePropertyName("entityStatus"u8); + writer.WriteStringValue(EntityStatus.Value.ToString()); + } + if (Optional.IsDefined(RelationshipType)) + { + writer.WritePropertyName("relationshipType"u8); + writer.WriteStringValue(RelationshipType); + } + if (Optional.IsDefined(RelationshipAttributes)) + { + writer.WritePropertyName("relationshipAttributes"u8); + writer.WriteObjectValue(RelationshipAttributes); + } + if (Optional.IsDefined(RelationshipGuid)) + { + writer.WritePropertyName("relationshipGuid"u8); + writer.WriteStringValue(RelationshipGuid.Value); + } + if (Optional.IsDefined(RelationshipStatus)) + { + writer.WritePropertyName("relationshipStatus"u8); + writer.WriteStringValue(RelationshipStatus.Value.ToString()); + } + writer.WriteEndObject(); + } + + internal static AtlasRelatedObjectId DeserializeAtlasRelatedObjectId(JsonElement element) + { + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + Optional guid = default; + Optional typeName = default; + Optional> uniqueAttributes = default; + Optional displayText = default; + Optional entityStatus = default; + Optional relationshipType = default; + Optional relationshipAttributes = default; + Optional relationshipGuid = default; + Optional relationshipStatus = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("guid"u8)) + { + guid = property.Value.GetString(); + continue; + } + if (property.NameEquals("typeName"u8)) + { + typeName = property.Value.GetString(); + continue; + } + if (property.NameEquals("uniqueAttributes"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + Dictionary dictionary = new Dictionary(); + foreach (var property0 in property.Value.EnumerateObject()) + { + if (property0.Value.ValueKind == JsonValueKind.Null) + { + dictionary.Add(property0.Name, null); + } + else + { + dictionary.Add(property0.Name, BinaryData.FromString(property0.Value.GetRawText())); + } + } + uniqueAttributes = dictionary; + continue; + } + if (property.NameEquals("displayText"u8)) + { + displayText = property.Value.GetString(); + continue; + } + if (property.NameEquals("entityStatus"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + entityStatus = new EntityStatus(property.Value.GetString()); + continue; + } + if (property.NameEquals("relationshipType"u8)) + { + relationshipType = property.Value.GetString(); + continue; + } + if (property.NameEquals("relationshipAttributes"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + relationshipAttributes = AtlasStruct.DeserializeAtlasStruct(property.Value); + continue; + } + if (property.NameEquals("relationshipGuid"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + relationshipGuid = property.Value.GetGuid(); + continue; + } + if (property.NameEquals("relationshipStatus"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + relationshipStatus = new StatusAtlasRelationship(property.Value.GetString()); + continue; + } + } + return new AtlasRelatedObjectId(guid.Value, typeName.Value, Optional.ToDictionary(uniqueAttributes), displayText.Value, Optional.ToNullable(entityStatus), relationshipType.Value, relationshipAttributes.Value, Optional.ToNullable(relationshipGuid), Optional.ToNullable(relationshipStatus)); + } + + /// Deserializes the model from a raw response. + /// The response to deserialize the model from. + internal static AtlasRelatedObjectId FromResponse(Response response) + { + using var document = JsonDocument.Parse(response.Content); + return DeserializeAtlasRelatedObjectId(document.RootElement); + } + + /// Convert into a Utf8JsonRequestContent. + internal virtual RequestContent ToRequestContent() + { + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(this); + return content; + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasRelatedObjectId.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasRelatedObjectId.cs new file mode 100644 index 0000000000000..6ed5fdf2f70af --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasRelatedObjectId.cs @@ -0,0 +1,109 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Collections.Generic; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + /// + /// Reference to an object-instance of AtlasEntity type used in relationship + /// attribute values + /// + public partial class AtlasRelatedObjectId + { + /// Initializes a new instance of . + public AtlasRelatedObjectId() + { + UniqueAttributes = new ChangeTrackingDictionary(); + } + + /// Initializes a new instance of . + /// The GUID of the object. + /// The name of the type. + /// The unique attributes of the object. + /// The display text. + /// + /// Status of the entity - can be active or deleted. Deleted entities are not + /// removed. + /// + /// Relationship type. + /// + /// Captures details of struct contents. Not instantiated directly, used only via + /// AtlasEntity, AtlasClassification. + /// + /// The GUID of the relationship. + /// The enum of relationship status. + internal AtlasRelatedObjectId(string guid, string typeName, IDictionary uniqueAttributes, string displayText, EntityStatus? entityStatus, string relationshipType, AtlasStruct relationshipAttributes, Guid? relationshipGuid, StatusAtlasRelationship? relationshipStatus) + { + Guid = guid; + TypeName = typeName; + UniqueAttributes = uniqueAttributes; + DisplayText = displayText; + EntityStatus = entityStatus; + RelationshipType = relationshipType; + RelationshipAttributes = relationshipAttributes; + RelationshipGuid = relationshipGuid; + RelationshipStatus = relationshipStatus; + } + + /// The GUID of the object. + public string Guid { get; set; } + /// The name of the type. + public string TypeName { get; set; } + /// + /// The unique attributes of the object. + /// + /// To assign an object to the value of this property use . + /// + /// + /// To assign an already formatted json string to this property use . + /// + /// + /// Examples: + /// + /// + /// BinaryData.FromObjectAsJson("foo") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromString("\"foo\"") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromObjectAsJson(new { key = "value" }) + /// Creates a payload of { "key": "value" }. + /// + /// + /// BinaryData.FromString("{\"key\": \"value\"}") + /// Creates a payload of { "key": "value" }. + /// + /// + /// + /// + public IDictionary UniqueAttributes { get; } + /// The display text. + public string DisplayText { get; set; } + /// + /// Status of the entity - can be active or deleted. Deleted entities are not + /// removed. + /// + public EntityStatus? EntityStatus { get; set; } + /// Relationship type. + public string RelationshipType { get; set; } + /// + /// Captures details of struct contents. Not instantiated directly, used only via + /// AtlasEntity, AtlasClassification. + /// + public AtlasStruct RelationshipAttributes { get; set; } + /// The GUID of the relationship. + public Guid? RelationshipGuid { get; set; } + /// The enum of relationship status. + public StatusAtlasRelationship? RelationshipStatus { get; set; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasRelatedTermHeader.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasRelatedTermHeader.Serialization.cs new file mode 100644 index 0000000000000..609f06d2d4991 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasRelatedTermHeader.Serialization.cs @@ -0,0 +1,131 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class AtlasRelatedTermHeader : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + if (Optional.IsDefined(Description)) + { + writer.WritePropertyName("description"u8); + writer.WriteStringValue(Description); + } + if (Optional.IsDefined(DisplayText)) + { + writer.WritePropertyName("displayText"u8); + writer.WriteStringValue(DisplayText); + } + if (Optional.IsDefined(Expression)) + { + writer.WritePropertyName("expression"u8); + writer.WriteStringValue(Expression); + } + if (Optional.IsDefined(RelationGuid)) + { + writer.WritePropertyName("relationGuid"u8); + writer.WriteStringValue(RelationGuid); + } + if (Optional.IsDefined(Status)) + { + writer.WritePropertyName("status"u8); + writer.WriteStringValue(Status.Value.ToString()); + } + if (Optional.IsDefined(Steward)) + { + writer.WritePropertyName("steward"u8); + writer.WriteStringValue(Steward); + } + if (Optional.IsDefined(TermGuid)) + { + writer.WritePropertyName("termGuid"u8); + writer.WriteStringValue(TermGuid); + } + writer.WriteEndObject(); + } + + internal static AtlasRelatedTermHeader DeserializeAtlasRelatedTermHeader(JsonElement element) + { + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + Optional description = default; + Optional displayText = default; + Optional expression = default; + Optional relationGuid = default; + Optional status = default; + Optional steward = default; + Optional termGuid = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("description"u8)) + { + description = property.Value.GetString(); + continue; + } + if (property.NameEquals("displayText"u8)) + { + displayText = property.Value.GetString(); + continue; + } + if (property.NameEquals("expression"u8)) + { + expression = property.Value.GetString(); + continue; + } + if (property.NameEquals("relationGuid"u8)) + { + relationGuid = property.Value.GetString(); + continue; + } + if (property.NameEquals("status"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + status = new AtlasTermRelationshipStatus(property.Value.GetString()); + continue; + } + if (property.NameEquals("steward"u8)) + { + steward = property.Value.GetString(); + continue; + } + if (property.NameEquals("termGuid"u8)) + { + termGuid = property.Value.GetString(); + continue; + } + } + return new AtlasRelatedTermHeader(description.Value, displayText.Value, expression.Value, relationGuid.Value, Optional.ToNullable(status), steward.Value, termGuid.Value); + } + + /// Deserializes the model from a raw response. + /// The response to deserialize the model from. + internal static AtlasRelatedTermHeader FromResponse(Response response) + { + using var document = JsonDocument.Parse(response.Content); + return DeserializeAtlasRelatedTermHeader(document.RootElement); + } + + /// Convert into a Utf8JsonRequestContent. + internal virtual RequestContent ToRequestContent() + { + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(this); + return content; + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasRelatedTermHeader.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasRelatedTermHeader.cs new file mode 100644 index 0000000000000..47a2d91c966a0 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasRelatedTermHeader.cs @@ -0,0 +1,52 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +namespace Azure.Analytics.Purview.DataMap +{ + /// The header of the related term. + public partial class AtlasRelatedTermHeader + { + /// Initializes a new instance of . + public AtlasRelatedTermHeader() + { + } + + /// Initializes a new instance of . + /// The description of the related term. + /// The display text. + /// The expression of the term. + /// The GUID of the relationship. + /// The status of term relationship. + /// The steward of the term. + /// The GUID of the term. + internal AtlasRelatedTermHeader(string description, string displayText, string expression, string relationGuid, AtlasTermRelationshipStatus? status, string steward, string termGuid) + { + Description = description; + DisplayText = displayText; + Expression = expression; + RelationGuid = relationGuid; + Status = status; + Steward = steward; + TermGuid = termGuid; + } + + /// The description of the related term. + public string Description { get; set; } + /// The display text. + public string DisplayText { get; set; } + /// The expression of the term. + public string Expression { get; set; } + /// The GUID of the relationship. + public string RelationGuid { get; set; } + /// The status of term relationship. + public AtlasTermRelationshipStatus? Status { get; set; } + /// The steward of the term. + public string Steward { get; set; } + /// The GUID of the term. + public string TermGuid { get; set; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasRelationship.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasRelationship.Serialization.cs new file mode 100644 index 0000000000000..5fc9e0d22626b --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasRelationship.Serialization.cs @@ -0,0 +1,279 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Collections.Generic; +using System.Text.Json; +using Azure; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class AtlasRelationship : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + if (Optional.IsCollectionDefined(Attributes)) + { + writer.WritePropertyName("attributes"u8); + writer.WriteStartObject(); + foreach (var item in Attributes) + { + writer.WritePropertyName(item.Key); + if (item.Value == null) + { + writer.WriteNullValue(); + continue; + } +#if NET6_0_OR_GREATER + writer.WriteRawValue(item.Value); +#else + using (JsonDocument document = JsonDocument.Parse(item.Value)) + { + JsonSerializer.Serialize(writer, document.RootElement); + } +#endif + } + writer.WriteEndObject(); + } + if (Optional.IsDefined(TypeName)) + { + writer.WritePropertyName("typeName"u8); + writer.WriteStringValue(TypeName); + } + if (Optional.IsDefined(LastModifiedTS)) + { + writer.WritePropertyName("lastModifiedTS"u8); + writer.WriteStringValue(LastModifiedTS); + } + if (Optional.IsDefined(CreateTime)) + { + writer.WritePropertyName("createTime"u8); + writer.WriteNumberValue(CreateTime.Value); + } + if (Optional.IsDefined(CreatedBy)) + { + writer.WritePropertyName("createdBy"u8); + writer.WriteStringValue(CreatedBy); + } + if (Optional.IsDefined(End1)) + { + writer.WritePropertyName("end1"u8); + writer.WriteObjectValue(End1); + } + if (Optional.IsDefined(End2)) + { + writer.WritePropertyName("end2"u8); + writer.WriteObjectValue(End2); + } + if (Optional.IsDefined(Guid)) + { + writer.WritePropertyName("guid"u8); + writer.WriteStringValue(Guid); + } + if (Optional.IsDefined(HomeId)) + { + writer.WritePropertyName("homeId"u8); + writer.WriteStringValue(HomeId); + } + if (Optional.IsDefined(Label)) + { + writer.WritePropertyName("label"u8); + writer.WriteStringValue(Label); + } + if (Optional.IsDefined(ProvenanceType)) + { + writer.WritePropertyName("provenanceType"u8); + writer.WriteNumberValue(ProvenanceType.Value); + } + if (Optional.IsDefined(Status)) + { + writer.WritePropertyName("status"u8); + writer.WriteStringValue(Status.Value.ToString()); + } + if (Optional.IsDefined(UpdateTime)) + { + writer.WritePropertyName("updateTime"u8); + writer.WriteNumberValue(UpdateTime.Value); + } + if (Optional.IsDefined(UpdatedBy)) + { + writer.WritePropertyName("updatedBy"u8); + writer.WriteStringValue(UpdatedBy); + } + if (Optional.IsDefined(Version)) + { + writer.WritePropertyName("version"u8); + writer.WriteNumberValue(Version.Value); + } + writer.WriteEndObject(); + } + + internal static AtlasRelationship DeserializeAtlasRelationship(JsonElement element) + { + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + Optional> attributes = default; + Optional typeName = default; + Optional lastModifiedTS = default; + Optional createTime = default; + Optional createdBy = default; + Optional end1 = default; + Optional end2 = default; + Optional guid = default; + Optional homeId = default; + Optional label = default; + Optional provenanceType = default; + Optional status = default; + Optional updateTime = default; + Optional updatedBy = default; + Optional version = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("attributes"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + Dictionary dictionary = new Dictionary(); + foreach (var property0 in property.Value.EnumerateObject()) + { + if (property0.Value.ValueKind == JsonValueKind.Null) + { + dictionary.Add(property0.Name, null); + } + else + { + dictionary.Add(property0.Name, BinaryData.FromString(property0.Value.GetRawText())); + } + } + attributes = dictionary; + continue; + } + if (property.NameEquals("typeName"u8)) + { + typeName = property.Value.GetString(); + continue; + } + if (property.NameEquals("lastModifiedTS"u8)) + { + lastModifiedTS = property.Value.GetString(); + continue; + } + if (property.NameEquals("createTime"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + createTime = property.Value.GetInt64(); + continue; + } + if (property.NameEquals("createdBy"u8)) + { + createdBy = property.Value.GetString(); + continue; + } + if (property.NameEquals("end1"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + end1 = AtlasObjectId.DeserializeAtlasObjectId(property.Value); + continue; + } + if (property.NameEquals("end2"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + end2 = AtlasObjectId.DeserializeAtlasObjectId(property.Value); + continue; + } + if (property.NameEquals("guid"u8)) + { + guid = property.Value.GetString(); + continue; + } + if (property.NameEquals("homeId"u8)) + { + homeId = property.Value.GetString(); + continue; + } + if (property.NameEquals("label"u8)) + { + label = property.Value.GetString(); + continue; + } + if (property.NameEquals("provenanceType"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + provenanceType = property.Value.GetInt32(); + continue; + } + if (property.NameEquals("status"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + status = new StatusAtlasRelationship(property.Value.GetString()); + continue; + } + if (property.NameEquals("updateTime"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + updateTime = property.Value.GetInt64(); + continue; + } + if (property.NameEquals("updatedBy"u8)) + { + updatedBy = property.Value.GetString(); + continue; + } + if (property.NameEquals("version"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + version = property.Value.GetInt64(); + continue; + } + } + return new AtlasRelationship(Optional.ToDictionary(attributes), typeName.Value, lastModifiedTS.Value, Optional.ToNullable(createTime), createdBy.Value, end1.Value, end2.Value, guid.Value, homeId.Value, label.Value, Optional.ToNullable(provenanceType), Optional.ToNullable(status), Optional.ToNullable(updateTime), updatedBy.Value, Optional.ToNullable(version)); + } + + /// Deserializes the model from a raw response. + /// The response to deserialize the model from. + internal static AtlasRelationship FromResponse(Response response) + { + using var document = JsonDocument.Parse(response.Content); + return DeserializeAtlasRelationship(document.RootElement); + } + + /// Convert into a Utf8JsonRequestContent. + internal virtual RequestContent ToRequestContent() + { + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(this); + return content; + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasRelationship.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasRelationship.cs new file mode 100644 index 0000000000000..1bb137cb37e5b --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasRelationship.cs @@ -0,0 +1,118 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Collections.Generic; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + /// Atlas relationship instance. + public partial class AtlasRelationship + { + /// Initializes a new instance of . + public AtlasRelationship() + { + Attributes = new ChangeTrackingDictionary(); + } + + /// Initializes a new instance of . + /// The attributes of the struct. + /// The name of the type. + /// ETag for concurrency control. + /// The created time of the record. + /// The user who created the record. + /// Reference to an object-instance of a type - like entity. + /// Reference to an object-instance of a type - like entity. + /// The GUID of the relationship. + /// The home ID of the relationship. + /// The label of the relationship. + /// Used to record the provenance of an instance of an entity or relationship. + /// The enum of relationship status. + /// The update time of the record. + /// The user who updated the record. + /// The version of the relationship. + internal AtlasRelationship(IDictionary attributes, string typeName, string lastModifiedTS, long? createTime, string createdBy, AtlasObjectId end1, AtlasObjectId end2, string guid, string homeId, string label, int? provenanceType, StatusAtlasRelationship? status, long? updateTime, string updatedBy, long? version) + { + Attributes = attributes; + TypeName = typeName; + LastModifiedTS = lastModifiedTS; + CreateTime = createTime; + CreatedBy = createdBy; + End1 = end1; + End2 = end2; + Guid = guid; + HomeId = homeId; + Label = label; + ProvenanceType = provenanceType; + Status = status; + UpdateTime = updateTime; + UpdatedBy = updatedBy; + Version = version; + } + + /// + /// The attributes of the struct. + /// + /// To assign an object to the value of this property use . + /// + /// + /// To assign an already formatted json string to this property use . + /// + /// + /// Examples: + /// + /// + /// BinaryData.FromObjectAsJson("foo") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromString("\"foo\"") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromObjectAsJson(new { key = "value" }) + /// Creates a payload of { "key": "value" }. + /// + /// + /// BinaryData.FromString("{\"key\": \"value\"}") + /// Creates a payload of { "key": "value" }. + /// + /// + /// + /// + public IDictionary Attributes { get; } + /// The name of the type. + public string TypeName { get; set; } + /// ETag for concurrency control. + public string LastModifiedTS { get; set; } + /// The created time of the record. + public long? CreateTime { get; set; } + /// The user who created the record. + public string CreatedBy { get; set; } + /// Reference to an object-instance of a type - like entity. + public AtlasObjectId End1 { get; set; } + /// Reference to an object-instance of a type - like entity. + public AtlasObjectId End2 { get; set; } + /// The GUID of the relationship. + public string Guid { get; set; } + /// The home ID of the relationship. + public string HomeId { get; set; } + /// The label of the relationship. + public string Label { get; set; } + /// Used to record the provenance of an instance of an entity or relationship. + public int? ProvenanceType { get; set; } + /// The enum of relationship status. + public StatusAtlasRelationship? Status { get; set; } + /// The update time of the record. + public long? UpdateTime { get; set; } + /// The user who updated the record. + public string UpdatedBy { get; set; } + /// The version of the relationship. + public long? Version { get; set; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasRelationshipAttributeDef.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasRelationshipAttributeDef.Serialization.cs new file mode 100644 index 0000000000000..b713e01262544 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasRelationshipAttributeDef.Serialization.cs @@ -0,0 +1,277 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using System.Text.Json; +using Azure; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class AtlasRelationshipAttributeDef : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + if (Optional.IsDefined(Cardinality)) + { + writer.WritePropertyName("cardinality"u8); + writer.WriteStringValue(Cardinality.Value.ToString()); + } + if (Optional.IsCollectionDefined(Constraints)) + { + writer.WritePropertyName("constraints"u8); + writer.WriteStartArray(); + foreach (var item in Constraints) + { + writer.WriteObjectValue(item); + } + writer.WriteEndArray(); + } + if (Optional.IsDefined(DefaultValue)) + { + writer.WritePropertyName("defaultValue"u8); + writer.WriteStringValue(DefaultValue); + } + if (Optional.IsDefined(Description)) + { + writer.WritePropertyName("description"u8); + writer.WriteStringValue(Description); + } + if (Optional.IsDefined(IncludeInNotification)) + { + writer.WritePropertyName("includeInNotification"u8); + writer.WriteBooleanValue(IncludeInNotification.Value); + } + if (Optional.IsDefined(IsIndexable)) + { + writer.WritePropertyName("isIndexable"u8); + writer.WriteBooleanValue(IsIndexable.Value); + } + if (Optional.IsDefined(IsOptional)) + { + writer.WritePropertyName("isOptional"u8); + writer.WriteBooleanValue(IsOptional.Value); + } + if (Optional.IsDefined(IsUnique)) + { + writer.WritePropertyName("isUnique"u8); + writer.WriteBooleanValue(IsUnique.Value); + } + if (Optional.IsDefined(Name)) + { + writer.WritePropertyName("name"u8); + writer.WriteStringValue(Name); + } + if (Optional.IsCollectionDefined(Options)) + { + writer.WritePropertyName("options"u8); + writer.WriteStartObject(); + foreach (var item in Options) + { + writer.WritePropertyName(item.Key); + writer.WriteStringValue(item.Value); + } + writer.WriteEndObject(); + } + if (Optional.IsDefined(TypeName)) + { + writer.WritePropertyName("typeName"u8); + writer.WriteStringValue(TypeName); + } + if (Optional.IsDefined(ValuesMaxCount)) + { + writer.WritePropertyName("valuesMaxCount"u8); + writer.WriteNumberValue(ValuesMaxCount.Value); + } + if (Optional.IsDefined(ValuesMinCount)) + { + writer.WritePropertyName("valuesMinCount"u8); + writer.WriteNumberValue(ValuesMinCount.Value); + } + if (Optional.IsDefined(IsLegacyAttribute)) + { + writer.WritePropertyName("isLegacyAttribute"u8); + writer.WriteBooleanValue(IsLegacyAttribute.Value); + } + if (Optional.IsDefined(RelationshipTypeName)) + { + writer.WritePropertyName("relationshipTypeName"u8); + writer.WriteStringValue(RelationshipTypeName); + } + writer.WriteEndObject(); + } + + internal static AtlasRelationshipAttributeDef DeserializeAtlasRelationshipAttributeDef(JsonElement element) + { + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + Optional cardinality = default; + Optional> constraints = default; + Optional defaultValue = default; + Optional description = default; + Optional includeInNotification = default; + Optional isIndexable = default; + Optional isOptional = default; + Optional isUnique = default; + Optional name = default; + Optional> options = default; + Optional typeName = default; + Optional valuesMaxCount = default; + Optional valuesMinCount = default; + Optional isLegacyAttribute = default; + Optional relationshipTypeName = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("cardinality"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + cardinality = new CardinalityValue(property.Value.GetString()); + continue; + } + if (property.NameEquals("constraints"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(AtlasConstraintDef.DeserializeAtlasConstraintDef(item)); + } + constraints = array; + continue; + } + if (property.NameEquals("defaultValue"u8)) + { + defaultValue = property.Value.GetString(); + continue; + } + if (property.NameEquals("description"u8)) + { + description = property.Value.GetString(); + continue; + } + if (property.NameEquals("includeInNotification"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + includeInNotification = property.Value.GetBoolean(); + continue; + } + if (property.NameEquals("isIndexable"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + isIndexable = property.Value.GetBoolean(); + continue; + } + if (property.NameEquals("isOptional"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + isOptional = property.Value.GetBoolean(); + continue; + } + if (property.NameEquals("isUnique"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + isUnique = property.Value.GetBoolean(); + continue; + } + if (property.NameEquals("name"u8)) + { + name = property.Value.GetString(); + continue; + } + if (property.NameEquals("options"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + Dictionary dictionary = new Dictionary(); + foreach (var property0 in property.Value.EnumerateObject()) + { + dictionary.Add(property0.Name, property0.Value.GetString()); + } + options = dictionary; + continue; + } + if (property.NameEquals("typeName"u8)) + { + typeName = property.Value.GetString(); + continue; + } + if (property.NameEquals("valuesMaxCount"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + valuesMaxCount = property.Value.GetInt32(); + continue; + } + if (property.NameEquals("valuesMinCount"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + valuesMinCount = property.Value.GetInt32(); + continue; + } + if (property.NameEquals("isLegacyAttribute"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + isLegacyAttribute = property.Value.GetBoolean(); + continue; + } + if (property.NameEquals("relationshipTypeName"u8)) + { + relationshipTypeName = property.Value.GetString(); + continue; + } + } + return new AtlasRelationshipAttributeDef(Optional.ToNullable(cardinality), Optional.ToList(constraints), defaultValue.Value, description.Value, Optional.ToNullable(includeInNotification), Optional.ToNullable(isIndexable), Optional.ToNullable(isOptional), Optional.ToNullable(isUnique), name.Value, Optional.ToDictionary(options), typeName.Value, Optional.ToNullable(valuesMaxCount), Optional.ToNullable(valuesMinCount), Optional.ToNullable(isLegacyAttribute), relationshipTypeName.Value); + } + + /// Deserializes the model from a raw response. + /// The response to deserialize the model from. + internal static AtlasRelationshipAttributeDef FromResponse(Response response) + { + using var document = JsonDocument.Parse(response.Content); + return DeserializeAtlasRelationshipAttributeDef(document.RootElement); + } + + /// Convert into a Utf8JsonRequestContent. + internal virtual RequestContent ToRequestContent() + { + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(this); + return content; + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasRelationshipAttributeDef.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasRelationshipAttributeDef.cs new file mode 100644 index 0000000000000..c9ac57da650e8 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasRelationshipAttributeDef.cs @@ -0,0 +1,94 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + /// + /// The relationshipEndDef represents an end of the relationship. The end of the + /// relationship is defined by a type, an + /// attribute name, cardinality and whether + /// it is the container end of the relationship. + /// + public partial class AtlasRelationshipAttributeDef + { + /// Initializes a new instance of . + public AtlasRelationshipAttributeDef() + { + Constraints = new ChangeTrackingList(); + Options = new ChangeTrackingDictionary(); + } + + /// Initializes a new instance of . + /// single-valued attribute or multi-valued attribute. + /// An array of constraints. + /// The default value of the attribute. + /// The description of the attribute. + /// Determines if it is included in notification. + /// Determines if it is indexable. + /// Determines if it is optional. + /// Determines if it unique. + /// The name of the attribute. + /// The options for the attribute. + /// The name of the type. + /// The maximum count of the values. + /// The minimum count of the values. + /// Determines if it is a legacy attribute. + /// The name of the relationship type. + internal AtlasRelationshipAttributeDef(CardinalityValue? cardinality, IList constraints, string defaultValue, string description, bool? includeInNotification, bool? isIndexable, bool? isOptional, bool? isUnique, string name, IDictionary options, string typeName, int? valuesMaxCount, int? valuesMinCount, bool? isLegacyAttribute, string relationshipTypeName) + { + Cardinality = cardinality; + Constraints = constraints; + DefaultValue = defaultValue; + Description = description; + IncludeInNotification = includeInNotification; + IsIndexable = isIndexable; + IsOptional = isOptional; + IsUnique = isUnique; + Name = name; + Options = options; + TypeName = typeName; + ValuesMaxCount = valuesMaxCount; + ValuesMinCount = valuesMinCount; + IsLegacyAttribute = isLegacyAttribute; + RelationshipTypeName = relationshipTypeName; + } + + /// single-valued attribute or multi-valued attribute. + public CardinalityValue? Cardinality { get; set; } + /// An array of constraints. + public IList Constraints { get; } + /// The default value of the attribute. + public string DefaultValue { get; set; } + /// The description of the attribute. + public string Description { get; set; } + /// Determines if it is included in notification. + public bool? IncludeInNotification { get; set; } + /// Determines if it is indexable. + public bool? IsIndexable { get; set; } + /// Determines if it is optional. + public bool? IsOptional { get; set; } + /// Determines if it unique. + public bool? IsUnique { get; set; } + /// The name of the attribute. + public string Name { get; set; } + /// The options for the attribute. + public IDictionary Options { get; } + /// The name of the type. + public string TypeName { get; set; } + /// The maximum count of the values. + public int? ValuesMaxCount { get; set; } + /// The minimum count of the values. + public int? ValuesMinCount { get; set; } + /// Determines if it is a legacy attribute. + public bool? IsLegacyAttribute { get; set; } + /// The name of the relationship type. + public string RelationshipTypeName { get; set; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasRelationshipDef.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasRelationshipDef.Serialization.cs new file mode 100644 index 0000000000000..e312ddb3db18a --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasRelationshipDef.Serialization.cs @@ -0,0 +1,321 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using System.Text.Json; +using Azure; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class AtlasRelationshipDef : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + if (Optional.IsDefined(Category)) + { + writer.WritePropertyName("category"u8); + writer.WriteStringValue(Category.Value.ToString()); + } + if (Optional.IsDefined(CreateTime)) + { + writer.WritePropertyName("createTime"u8); + writer.WriteNumberValue(CreateTime.Value); + } + if (Optional.IsDefined(CreatedBy)) + { + writer.WritePropertyName("createdBy"u8); + writer.WriteStringValue(CreatedBy); + } + if (Optional.IsDefined(DateFormatter)) + { + writer.WritePropertyName("dateFormatter"u8); + writer.WriteObjectValue(DateFormatter); + } + if (Optional.IsDefined(Description)) + { + writer.WritePropertyName("description"u8); + writer.WriteStringValue(Description); + } + if (Optional.IsDefined(Guid)) + { + writer.WritePropertyName("guid"u8); + writer.WriteStringValue(Guid); + } + if (Optional.IsDefined(Name)) + { + writer.WritePropertyName("name"u8); + writer.WriteStringValue(Name); + } + if (Optional.IsCollectionDefined(Options)) + { + writer.WritePropertyName("options"u8); + writer.WriteStartObject(); + foreach (var item in Options) + { + writer.WritePropertyName(item.Key); + writer.WriteStringValue(item.Value); + } + writer.WriteEndObject(); + } + if (Optional.IsDefined(ServiceType)) + { + writer.WritePropertyName("serviceType"u8); + writer.WriteStringValue(ServiceType); + } + if (Optional.IsDefined(TypeVersion)) + { + writer.WritePropertyName("typeVersion"u8); + writer.WriteStringValue(TypeVersion); + } + if (Optional.IsDefined(UpdateTime)) + { + writer.WritePropertyName("updateTime"u8); + writer.WriteNumberValue(UpdateTime.Value); + } + if (Optional.IsDefined(UpdatedBy)) + { + writer.WritePropertyName("updatedBy"u8); + writer.WriteStringValue(UpdatedBy); + } + if (Optional.IsDefined(Version)) + { + writer.WritePropertyName("version"u8); + writer.WriteNumberValue(Version.Value); + } + if (Optional.IsDefined(LastModifiedTS)) + { + writer.WritePropertyName("lastModifiedTS"u8); + writer.WriteStringValue(LastModifiedTS); + } + if (Optional.IsCollectionDefined(AttributeDefs)) + { + writer.WritePropertyName("attributeDefs"u8); + writer.WriteStartArray(); + foreach (var item in AttributeDefs) + { + writer.WriteObjectValue(item); + } + writer.WriteEndArray(); + } + if (Optional.IsDefined(EndDef1)) + { + writer.WritePropertyName("endDef1"u8); + writer.WriteObjectValue(EndDef1); + } + if (Optional.IsDefined(EndDef2)) + { + writer.WritePropertyName("endDef2"u8); + writer.WriteObjectValue(EndDef2); + } + if (Optional.IsDefined(RelationshipCategory)) + { + writer.WritePropertyName("relationshipCategory"u8); + writer.WriteStringValue(RelationshipCategory.Value.ToString()); + } + if (Optional.IsDefined(RelationshipLabel)) + { + writer.WritePropertyName("relationshipLabel"u8); + writer.WriteStringValue(RelationshipLabel); + } + writer.WriteEndObject(); + } + + internal static AtlasRelationshipDef DeserializeAtlasRelationshipDef(JsonElement element) + { + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + Optional category = default; + Optional createTime = default; + Optional createdBy = default; + Optional dateFormatter = default; + Optional description = default; + Optional guid = default; + Optional name = default; + Optional> options = default; + Optional serviceType = default; + Optional typeVersion = default; + Optional updateTime = default; + Optional updatedBy = default; + Optional version = default; + Optional lastModifiedTS = default; + Optional> attributeDefs = default; + Optional endDef1 = default; + Optional endDef2 = default; + Optional relationshipCategory = default; + Optional relationshipLabel = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("category"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + category = new TypeCategory(property.Value.GetString()); + continue; + } + if (property.NameEquals("createTime"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + createTime = property.Value.GetInt64(); + continue; + } + if (property.NameEquals("createdBy"u8)) + { + createdBy = property.Value.GetString(); + continue; + } + if (property.NameEquals("dateFormatter"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + dateFormatter = DateFormat.DeserializeDateFormat(property.Value); + continue; + } + if (property.NameEquals("description"u8)) + { + description = property.Value.GetString(); + continue; + } + if (property.NameEquals("guid"u8)) + { + guid = property.Value.GetString(); + continue; + } + if (property.NameEquals("name"u8)) + { + name = property.Value.GetString(); + continue; + } + if (property.NameEquals("options"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + Dictionary dictionary = new Dictionary(); + foreach (var property0 in property.Value.EnumerateObject()) + { + dictionary.Add(property0.Name, property0.Value.GetString()); + } + options = dictionary; + continue; + } + if (property.NameEquals("serviceType"u8)) + { + serviceType = property.Value.GetString(); + continue; + } + if (property.NameEquals("typeVersion"u8)) + { + typeVersion = property.Value.GetString(); + continue; + } + if (property.NameEquals("updateTime"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + updateTime = property.Value.GetInt64(); + continue; + } + if (property.NameEquals("updatedBy"u8)) + { + updatedBy = property.Value.GetString(); + continue; + } + if (property.NameEquals("version"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + version = property.Value.GetInt64(); + continue; + } + if (property.NameEquals("lastModifiedTS"u8)) + { + lastModifiedTS = property.Value.GetString(); + continue; + } + if (property.NameEquals("attributeDefs"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(AtlasAttributeDef.DeserializeAtlasAttributeDef(item)); + } + attributeDefs = array; + continue; + } + if (property.NameEquals("endDef1"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + endDef1 = AtlasRelationshipEndDef.DeserializeAtlasRelationshipEndDef(property.Value); + continue; + } + if (property.NameEquals("endDef2"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + endDef2 = AtlasRelationshipEndDef.DeserializeAtlasRelationshipEndDef(property.Value); + continue; + } + if (property.NameEquals("relationshipCategory"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + relationshipCategory = new RelationshipCategory(property.Value.GetString()); + continue; + } + if (property.NameEquals("relationshipLabel"u8)) + { + relationshipLabel = property.Value.GetString(); + continue; + } + } + return new AtlasRelationshipDef(Optional.ToNullable(category), Optional.ToNullable(createTime), createdBy.Value, dateFormatter.Value, description.Value, guid.Value, name.Value, Optional.ToDictionary(options), serviceType.Value, typeVersion.Value, Optional.ToNullable(updateTime), updatedBy.Value, Optional.ToNullable(version), lastModifiedTS.Value, Optional.ToList(attributeDefs), endDef1.Value, endDef2.Value, Optional.ToNullable(relationshipCategory), relationshipLabel.Value); + } + + /// Deserializes the model from a raw response. + /// The response to deserialize the model from. + internal static AtlasRelationshipDef FromResponse(Response response) + { + using var document = JsonDocument.Parse(response.Content); + return DeserializeAtlasRelationshipDef(document.RootElement); + } + + /// Convert into a Utf8JsonRequestContent. + internal virtual RequestContent ToRequestContent() + { + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(this); + return content; + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasRelationshipDef.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasRelationshipDef.cs new file mode 100644 index 0000000000000..9800793dfe4af --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasRelationshipDef.cs @@ -0,0 +1,182 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + /// + /// AtlasRelationshipDef is a TypeDef that defines a relationship. + /// As with other typeDefs the AtlasRelationshipDef has a name. Once created the + /// RelationshipDef has a guid. + /// The name and the guid are the 2 ways that the + /// RelationshipDef is identified. + /// RelationshipDefs have 2 ends, each of which + /// specify cardinality, an EntityDef type name and name and optionally + /// whether the + /// end is a container. + /// RelationshipDefs can have AttributeDefs - though only + /// primitive types are allowed. + /// RelationshipDefs have a relationshipCategory + /// specifying the UML type of relationship required + /// The way EntityDefs and + /// RelationshipDefs are intended to be used is that EntityDefs will define + /// AttributeDefs these AttributeDefs + /// will not specify an EntityDef type name as + /// their types. + /// RelationshipDefs introduce new attributes to the entity + /// instances. For example + /// EntityDef A might have attributes attr1,attr2,attr3 + /// + /// EntityDef B might have attributes attr4,attr5,attr6 + /// RelationshipDef + /// AtoB might define 2 ends + /// + /// end1: type A, name attr7 + /// end2: type B, name attr8 + /// + /// When an instance of EntityDef A is created, it + /// will have attributes attr1,attr2,attr3,attr7 + /// When an instance of EntityDef + /// B is created, it will have attributes attr4,attr5,attr6,attr8 + /// + /// In this way + /// relationshipDefs can be authored separately from entityDefs and can inject + /// relationship attributes into + /// the entity instances + /// + public partial class AtlasRelationshipDef + { + /// Initializes a new instance of . + public AtlasRelationshipDef() + { + Options = new ChangeTrackingDictionary(); + AttributeDefs = new ChangeTrackingList(); + } + + /// Initializes a new instance of . + /// The enum of type category. + /// The created time of the record. + /// The user who created the record. + /// The date format. + /// The description of the type definition. + /// The GUID of the type definition. + /// The name of the type definition. + /// The options for the type definition. + /// The service type. + /// The version of the type. + /// The update time of the record. + /// The user who updated the record. + /// The version of the record. + /// ETag for concurrency control. + /// An array of attribute definitions. + /// + /// The relationshipEndDef represents an end of the relationship. The end of the + /// relationship is defined by a type, an + /// attribute name, cardinality and whether + /// it is the container end of the relationship. + /// + /// + /// The relationshipEndDef represents an end of the relationship. The end of the + /// relationship is defined by a type, an + /// attribute name, cardinality and whether + /// it is the container end of the relationship. + /// + /// + /// The Relationship category determines the style of relationship around + /// containment and lifecycle. + /// UML terminology is used for the values. + /// ASSOCIATION is a relationship with no containment. + /// COMPOSITION and AGGREGATION are containment relationships. + /// The difference being in the lifecycles of the container and its children. + /// In the COMPOSITION case, the children cannot exist without the container. + /// For AGGREGATION, the life cycles of the container and children are totally independent. + /// + /// The label of the relationship. + internal AtlasRelationshipDef(TypeCategory? category, long? createTime, string createdBy, DateFormat dateFormatter, string description, string guid, string name, IDictionary options, string serviceType, string typeVersion, long? updateTime, string updatedBy, long? version, string lastModifiedTS, IList attributeDefs, AtlasRelationshipEndDef endDef1, AtlasRelationshipEndDef endDef2, RelationshipCategory? relationshipCategory, string relationshipLabel) + { + Category = category; + CreateTime = createTime; + CreatedBy = createdBy; + DateFormatter = dateFormatter; + Description = description; + Guid = guid; + Name = name; + Options = options; + ServiceType = serviceType; + TypeVersion = typeVersion; + UpdateTime = updateTime; + UpdatedBy = updatedBy; + Version = version; + LastModifiedTS = lastModifiedTS; + AttributeDefs = attributeDefs; + EndDef1 = endDef1; + EndDef2 = endDef2; + RelationshipCategory = relationshipCategory; + RelationshipLabel = relationshipLabel; + } + + /// The enum of type category. + public TypeCategory? Category { get; set; } + /// The created time of the record. + public long? CreateTime { get; set; } + /// The user who created the record. + public string CreatedBy { get; set; } + /// The date format. + public DateFormat DateFormatter { get; set; } + /// The description of the type definition. + public string Description { get; set; } + /// The GUID of the type definition. + public string Guid { get; set; } + /// The name of the type definition. + public string Name { get; set; } + /// The options for the type definition. + public IDictionary Options { get; } + /// The service type. + public string ServiceType { get; set; } + /// The version of the type. + public string TypeVersion { get; set; } + /// The update time of the record. + public long? UpdateTime { get; set; } + /// The user who updated the record. + public string UpdatedBy { get; set; } + /// The version of the record. + public long? Version { get; set; } + /// ETag for concurrency control. + public string LastModifiedTS { get; set; } + /// An array of attribute definitions. + public IList AttributeDefs { get; } + /// + /// The relationshipEndDef represents an end of the relationship. The end of the + /// relationship is defined by a type, an + /// attribute name, cardinality and whether + /// it is the container end of the relationship. + /// + public AtlasRelationshipEndDef EndDef1 { get; set; } + /// + /// The relationshipEndDef represents an end of the relationship. The end of the + /// relationship is defined by a type, an + /// attribute name, cardinality and whether + /// it is the container end of the relationship. + /// + public AtlasRelationshipEndDef EndDef2 { get; set; } + /// + /// The Relationship category determines the style of relationship around + /// containment and lifecycle. + /// UML terminology is used for the values. + /// ASSOCIATION is a relationship with no containment. + /// COMPOSITION and AGGREGATION are containment relationships. + /// The difference being in the lifecycles of the container and its children. + /// In the COMPOSITION case, the children cannot exist without the container. + /// For AGGREGATION, the life cycles of the container and children are totally independent. + /// + public RelationshipCategory? RelationshipCategory { get; set; } + /// The label of the relationship. + public string RelationshipLabel { get; set; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasRelationshipEndDef.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasRelationshipEndDef.Serialization.cs new file mode 100644 index 0000000000000..4469d7f7a01ca --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasRelationshipEndDef.Serialization.cs @@ -0,0 +1,128 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class AtlasRelationshipEndDef : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + if (Optional.IsDefined(Cardinality)) + { + writer.WritePropertyName("cardinality"u8); + writer.WriteStringValue(Cardinality.Value.ToString()); + } + if (Optional.IsDefined(Description)) + { + writer.WritePropertyName("description"u8); + writer.WriteStringValue(Description); + } + if (Optional.IsDefined(IsContainer)) + { + writer.WritePropertyName("isContainer"u8); + writer.WriteBooleanValue(IsContainer.Value); + } + if (Optional.IsDefined(IsLegacyAttribute)) + { + writer.WritePropertyName("isLegacyAttribute"u8); + writer.WriteBooleanValue(IsLegacyAttribute.Value); + } + if (Optional.IsDefined(Name)) + { + writer.WritePropertyName("name"u8); + writer.WriteStringValue(Name); + } + if (Optional.IsDefined(Type)) + { + writer.WritePropertyName("type"u8); + writer.WriteStringValue(Type); + } + writer.WriteEndObject(); + } + + internal static AtlasRelationshipEndDef DeserializeAtlasRelationshipEndDef(JsonElement element) + { + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + Optional cardinality = default; + Optional description = default; + Optional isContainer = default; + Optional isLegacyAttribute = default; + Optional name = default; + Optional type = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("cardinality"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + cardinality = new CardinalityValue(property.Value.GetString()); + continue; + } + if (property.NameEquals("description"u8)) + { + description = property.Value.GetString(); + continue; + } + if (property.NameEquals("isContainer"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + isContainer = property.Value.GetBoolean(); + continue; + } + if (property.NameEquals("isLegacyAttribute"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + isLegacyAttribute = property.Value.GetBoolean(); + continue; + } + if (property.NameEquals("name"u8)) + { + name = property.Value.GetString(); + continue; + } + if (property.NameEquals("type"u8)) + { + type = property.Value.GetString(); + continue; + } + } + return new AtlasRelationshipEndDef(Optional.ToNullable(cardinality), description.Value, Optional.ToNullable(isContainer), Optional.ToNullable(isLegacyAttribute), name.Value, type.Value); + } + + /// Deserializes the model from a raw response. + /// The response to deserialize the model from. + internal static AtlasRelationshipEndDef FromResponse(Response response) + { + using var document = JsonDocument.Parse(response.Content); + return DeserializeAtlasRelationshipEndDef(document.RootElement); + } + + /// Convert into a Utf8JsonRequestContent. + internal virtual RequestContent ToRequestContent() + { + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(this); + return content; + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasRelationshipEndDef.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasRelationshipEndDef.cs new file mode 100644 index 0000000000000..a515ea56a808b --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasRelationshipEndDef.cs @@ -0,0 +1,53 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +namespace Azure.Analytics.Purview.DataMap +{ + /// + /// The relationshipEndDef represents an end of the relationship. The end of the + /// relationship is defined by a type, an + /// attribute name, cardinality and whether + /// it is the container end of the relationship. + /// + public partial class AtlasRelationshipEndDef + { + /// Initializes a new instance of . + public AtlasRelationshipEndDef() + { + } + + /// Initializes a new instance of . + /// single-valued attribute or multi-valued attribute. + /// The description of the relationship end definition. + /// Determines if it is container. + /// Determines if it is a legacy attribute. + /// The name of the relationship end definition. + /// The type of the relationship end. + internal AtlasRelationshipEndDef(CardinalityValue? cardinality, string description, bool? isContainer, bool? isLegacyAttribute, string name, string type) + { + Cardinality = cardinality; + Description = description; + IsContainer = isContainer; + IsLegacyAttribute = isLegacyAttribute; + Name = name; + Type = type; + } + + /// single-valued attribute or multi-valued attribute. + public CardinalityValue? Cardinality { get; set; } + /// The description of the relationship end definition. + public string Description { get; set; } + /// Determines if it is container. + public bool? IsContainer { get; set; } + /// Determines if it is a legacy attribute. + public bool? IsLegacyAttribute { get; set; } + /// The name of the relationship end definition. + public string Name { get; set; } + /// The type of the relationship end. + public string Type { get; set; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasRelationshipWithExtInfo.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasRelationshipWithExtInfo.Serialization.cs new file mode 100644 index 0000000000000..3c31f90f4a06f --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasRelationshipWithExtInfo.Serialization.cs @@ -0,0 +1,62 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using System.Text.Json; +using Azure; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class AtlasRelationshipWithExtInfo + { + internal static AtlasRelationshipWithExtInfo DeserializeAtlasRelationshipWithExtInfo(JsonElement element) + { + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + Optional> referredEntities = default; + Optional relationship = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("referredEntities"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + Dictionary dictionary = new Dictionary(); + foreach (var property0 in property.Value.EnumerateObject()) + { + dictionary.Add(property0.Name, AtlasEntityHeader.DeserializeAtlasEntityHeader(property0.Value)); + } + referredEntities = dictionary; + continue; + } + if (property.NameEquals("relationship"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + relationship = AtlasRelationship.DeserializeAtlasRelationship(property.Value); + continue; + } + } + return new AtlasRelationshipWithExtInfo(Optional.ToDictionary(referredEntities), relationship.Value); + } + + /// Deserializes the model from a raw response. + /// The response to deserialize the model from. + internal static AtlasRelationshipWithExtInfo FromResponse(Response response) + { + using var document = JsonDocument.Parse(response.Content); + return DeserializeAtlasRelationshipWithExtInfo(document.RootElement); + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasRelationshipWithExtInfo.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasRelationshipWithExtInfo.cs new file mode 100644 index 0000000000000..fba19d8203096 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasRelationshipWithExtInfo.cs @@ -0,0 +1,36 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + /// The relationship with extended information. + public partial class AtlasRelationshipWithExtInfo + { + /// Initializes a new instance of . + internal AtlasRelationshipWithExtInfo() + { + ReferredEntities = new ChangeTrackingDictionary(); + } + + /// Initializes a new instance of . + /// The referred entity header. + /// Atlas relationship instance. + internal AtlasRelationshipWithExtInfo(IReadOnlyDictionary referredEntities, AtlasRelationship relationship) + { + ReferredEntities = referredEntities; + Relationship = relationship; + } + + /// The referred entity header. + public IReadOnlyDictionary ReferredEntities { get; } + /// Atlas relationship instance. + public AtlasRelationship Relationship { get; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasStruct.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasStruct.Serialization.cs new file mode 100644 index 0000000000000..85887a02f3fc5 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasStruct.Serialization.cs @@ -0,0 +1,119 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Collections.Generic; +using System.Text.Json; +using Azure; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class AtlasStruct : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + if (Optional.IsCollectionDefined(Attributes)) + { + writer.WritePropertyName("attributes"u8); + writer.WriteStartObject(); + foreach (var item in Attributes) + { + writer.WritePropertyName(item.Key); + if (item.Value == null) + { + writer.WriteNullValue(); + continue; + } +#if NET6_0_OR_GREATER + writer.WriteRawValue(item.Value); +#else + using (JsonDocument document = JsonDocument.Parse(item.Value)) + { + JsonSerializer.Serialize(writer, document.RootElement); + } +#endif + } + writer.WriteEndObject(); + } + if (Optional.IsDefined(TypeName)) + { + writer.WritePropertyName("typeName"u8); + writer.WriteStringValue(TypeName); + } + if (Optional.IsDefined(LastModifiedTS)) + { + writer.WritePropertyName("lastModifiedTS"u8); + writer.WriteStringValue(LastModifiedTS); + } + writer.WriteEndObject(); + } + + internal static AtlasStruct DeserializeAtlasStruct(JsonElement element) + { + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + Optional> attributes = default; + Optional typeName = default; + Optional lastModifiedTS = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("attributes"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + Dictionary dictionary = new Dictionary(); + foreach (var property0 in property.Value.EnumerateObject()) + { + if (property0.Value.ValueKind == JsonValueKind.Null) + { + dictionary.Add(property0.Name, null); + } + else + { + dictionary.Add(property0.Name, BinaryData.FromString(property0.Value.GetRawText())); + } + } + attributes = dictionary; + continue; + } + if (property.NameEquals("typeName"u8)) + { + typeName = property.Value.GetString(); + continue; + } + if (property.NameEquals("lastModifiedTS"u8)) + { + lastModifiedTS = property.Value.GetString(); + continue; + } + } + return new AtlasStruct(Optional.ToDictionary(attributes), typeName.Value, lastModifiedTS.Value); + } + + /// Deserializes the model from a raw response. + /// The response to deserialize the model from. + internal static AtlasStruct FromResponse(Response response) + { + using var document = JsonDocument.Parse(response.Content); + return DeserializeAtlasStruct(document.RootElement); + } + + /// Convert into a Utf8JsonRequestContent. + internal virtual RequestContent ToRequestContent() + { + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(this); + return content; + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasStruct.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasStruct.cs new file mode 100644 index 0000000000000..c8619c4bf7306 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasStruct.cs @@ -0,0 +1,73 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Collections.Generic; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + /// + /// Captures details of struct contents. Not instantiated directly, used only via + /// AtlasEntity, AtlasClassification. + /// + public partial class AtlasStruct + { + /// Initializes a new instance of . + public AtlasStruct() + { + Attributes = new ChangeTrackingDictionary(); + } + + /// Initializes a new instance of . + /// The attributes of the struct. + /// The name of the type. + /// ETag for concurrency control. + internal AtlasStruct(IDictionary attributes, string typeName, string lastModifiedTS) + { + Attributes = attributes; + TypeName = typeName; + LastModifiedTS = lastModifiedTS; + } + + /// + /// The attributes of the struct. + /// + /// To assign an object to the value of this property use . + /// + /// + /// To assign an already formatted json string to this property use . + /// + /// + /// Examples: + /// + /// + /// BinaryData.FromObjectAsJson("foo") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromString("\"foo\"") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromObjectAsJson(new { key = "value" }) + /// Creates a payload of { "key": "value" }. + /// + /// + /// BinaryData.FromString("{\"key\": \"value\"}") + /// Creates a payload of { "key": "value" }. + /// + /// + /// + /// + public IDictionary Attributes { get; } + /// The name of the type. + public string TypeName { get; set; } + /// ETag for concurrency control. + public string LastModifiedTS { get; set; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasStructDef.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasStructDef.Serialization.cs new file mode 100644 index 0000000000000..246358dceea4a --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasStructDef.Serialization.cs @@ -0,0 +1,265 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using System.Text.Json; +using Azure; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class AtlasStructDef : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + if (Optional.IsDefined(Category)) + { + writer.WritePropertyName("category"u8); + writer.WriteStringValue(Category.Value.ToString()); + } + if (Optional.IsDefined(CreateTime)) + { + writer.WritePropertyName("createTime"u8); + writer.WriteNumberValue(CreateTime.Value); + } + if (Optional.IsDefined(CreatedBy)) + { + writer.WritePropertyName("createdBy"u8); + writer.WriteStringValue(CreatedBy); + } + if (Optional.IsDefined(DateFormatter)) + { + writer.WritePropertyName("dateFormatter"u8); + writer.WriteObjectValue(DateFormatter); + } + if (Optional.IsDefined(Description)) + { + writer.WritePropertyName("description"u8); + writer.WriteStringValue(Description); + } + if (Optional.IsDefined(Guid)) + { + writer.WritePropertyName("guid"u8); + writer.WriteStringValue(Guid); + } + if (Optional.IsDefined(Name)) + { + writer.WritePropertyName("name"u8); + writer.WriteStringValue(Name); + } + if (Optional.IsCollectionDefined(Options)) + { + writer.WritePropertyName("options"u8); + writer.WriteStartObject(); + foreach (var item in Options) + { + writer.WritePropertyName(item.Key); + writer.WriteStringValue(item.Value); + } + writer.WriteEndObject(); + } + if (Optional.IsDefined(ServiceType)) + { + writer.WritePropertyName("serviceType"u8); + writer.WriteStringValue(ServiceType); + } + if (Optional.IsDefined(TypeVersion)) + { + writer.WritePropertyName("typeVersion"u8); + writer.WriteStringValue(TypeVersion); + } + if (Optional.IsDefined(UpdateTime)) + { + writer.WritePropertyName("updateTime"u8); + writer.WriteNumberValue(UpdateTime.Value); + } + if (Optional.IsDefined(UpdatedBy)) + { + writer.WritePropertyName("updatedBy"u8); + writer.WriteStringValue(UpdatedBy); + } + if (Optional.IsDefined(Version)) + { + writer.WritePropertyName("version"u8); + writer.WriteNumberValue(Version.Value); + } + if (Optional.IsDefined(LastModifiedTS)) + { + writer.WritePropertyName("lastModifiedTS"u8); + writer.WriteStringValue(LastModifiedTS); + } + if (Optional.IsCollectionDefined(AttributeDefs)) + { + writer.WritePropertyName("attributeDefs"u8); + writer.WriteStartArray(); + foreach (var item in AttributeDefs) + { + writer.WriteObjectValue(item); + } + writer.WriteEndArray(); + } + writer.WriteEndObject(); + } + + internal static AtlasStructDef DeserializeAtlasStructDef(JsonElement element) + { + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + Optional category = default; + Optional createTime = default; + Optional createdBy = default; + Optional dateFormatter = default; + Optional description = default; + Optional guid = default; + Optional name = default; + Optional> options = default; + Optional serviceType = default; + Optional typeVersion = default; + Optional updateTime = default; + Optional updatedBy = default; + Optional version = default; + Optional lastModifiedTS = default; + Optional> attributeDefs = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("category"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + category = new TypeCategory(property.Value.GetString()); + continue; + } + if (property.NameEquals("createTime"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + createTime = property.Value.GetInt64(); + continue; + } + if (property.NameEquals("createdBy"u8)) + { + createdBy = property.Value.GetString(); + continue; + } + if (property.NameEquals("dateFormatter"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + dateFormatter = DateFormat.DeserializeDateFormat(property.Value); + continue; + } + if (property.NameEquals("description"u8)) + { + description = property.Value.GetString(); + continue; + } + if (property.NameEquals("guid"u8)) + { + guid = property.Value.GetString(); + continue; + } + if (property.NameEquals("name"u8)) + { + name = property.Value.GetString(); + continue; + } + if (property.NameEquals("options"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + Dictionary dictionary = new Dictionary(); + foreach (var property0 in property.Value.EnumerateObject()) + { + dictionary.Add(property0.Name, property0.Value.GetString()); + } + options = dictionary; + continue; + } + if (property.NameEquals("serviceType"u8)) + { + serviceType = property.Value.GetString(); + continue; + } + if (property.NameEquals("typeVersion"u8)) + { + typeVersion = property.Value.GetString(); + continue; + } + if (property.NameEquals("updateTime"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + updateTime = property.Value.GetInt64(); + continue; + } + if (property.NameEquals("updatedBy"u8)) + { + updatedBy = property.Value.GetString(); + continue; + } + if (property.NameEquals("version"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + version = property.Value.GetInt64(); + continue; + } + if (property.NameEquals("lastModifiedTS"u8)) + { + lastModifiedTS = property.Value.GetString(); + continue; + } + if (property.NameEquals("attributeDefs"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(AtlasAttributeDef.DeserializeAtlasAttributeDef(item)); + } + attributeDefs = array; + continue; + } + } + return new AtlasStructDef(Optional.ToNullable(category), Optional.ToNullable(createTime), createdBy.Value, dateFormatter.Value, description.Value, guid.Value, name.Value, Optional.ToDictionary(options), serviceType.Value, typeVersion.Value, Optional.ToNullable(updateTime), updatedBy.Value, Optional.ToNullable(version), lastModifiedTS.Value, Optional.ToList(attributeDefs)); + } + + /// Deserializes the model from a raw response. + /// The response to deserialize the model from. + internal static AtlasStructDef FromResponse(Response response) + { + using var document = JsonDocument.Parse(response.Content); + return DeserializeAtlasStructDef(document.RootElement); + } + + /// Convert into a Utf8JsonRequestContent. + internal virtual RequestContent ToRequestContent() + { + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(this); + return content; + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasStructDef.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasStructDef.cs new file mode 100644 index 0000000000000..b351d2c9f09a5 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasStructDef.cs @@ -0,0 +1,89 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + /// class that captures details of a struct-type. + public partial class AtlasStructDef + { + /// Initializes a new instance of . + public AtlasStructDef() + { + Options = new ChangeTrackingDictionary(); + AttributeDefs = new ChangeTrackingList(); + } + + /// Initializes a new instance of . + /// The enum of type category. + /// The created time of the record. + /// The user who created the record. + /// The date format. + /// The description of the type definition. + /// The GUID of the type definition. + /// The name of the type definition. + /// The options for the type definition. + /// The service type. + /// The version of the type. + /// The update time of the record. + /// The user who updated the record. + /// The version of the record. + /// ETag for concurrency control. + /// An array of attribute definitions. + internal AtlasStructDef(TypeCategory? category, long? createTime, string createdBy, DateFormat dateFormatter, string description, string guid, string name, IDictionary options, string serviceType, string typeVersion, long? updateTime, string updatedBy, long? version, string lastModifiedTS, IList attributeDefs) + { + Category = category; + CreateTime = createTime; + CreatedBy = createdBy; + DateFormatter = dateFormatter; + Description = description; + Guid = guid; + Name = name; + Options = options; + ServiceType = serviceType; + TypeVersion = typeVersion; + UpdateTime = updateTime; + UpdatedBy = updatedBy; + Version = version; + LastModifiedTS = lastModifiedTS; + AttributeDefs = attributeDefs; + } + + /// The enum of type category. + public TypeCategory? Category { get; set; } + /// The created time of the record. + public long? CreateTime { get; set; } + /// The user who created the record. + public string CreatedBy { get; set; } + /// The date format. + public DateFormat DateFormatter { get; set; } + /// The description of the type definition. + public string Description { get; set; } + /// The GUID of the type definition. + public string Guid { get; set; } + /// The name of the type definition. + public string Name { get; set; } + /// The options for the type definition. + public IDictionary Options { get; } + /// The service type. + public string ServiceType { get; set; } + /// The version of the type. + public string TypeVersion { get; set; } + /// The update time of the record. + public long? UpdateTime { get; set; } + /// The user who updated the record. + public string UpdatedBy { get; set; } + /// The version of the record. + public long? Version { get; set; } + /// ETag for concurrency control. + public string LastModifiedTS { get; set; } + /// An array of attribute definitions. + public IList AttributeDefs { get; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasTermAssignmentHeader.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasTermAssignmentHeader.Serialization.cs new file mode 100644 index 0000000000000..91fde14ea463d --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasTermAssignmentHeader.Serialization.cs @@ -0,0 +1,166 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Text.Json; +using Azure; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class AtlasTermAssignmentHeader : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + if (Optional.IsDefined(Confidence)) + { + writer.WritePropertyName("confidence"u8); + writer.WriteNumberValue(Confidence.Value); + } + if (Optional.IsDefined(CreatedBy)) + { + writer.WritePropertyName("createdBy"u8); + writer.WriteStringValue(CreatedBy); + } + if (Optional.IsDefined(Description)) + { + writer.WritePropertyName("description"u8); + writer.WriteStringValue(Description); + } + if (Optional.IsDefined(DisplayText)) + { + writer.WritePropertyName("displayText"u8); + writer.WriteStringValue(DisplayText); + } + if (Optional.IsDefined(Expression)) + { + writer.WritePropertyName("expression"u8); + writer.WriteStringValue(Expression); + } + if (Optional.IsDefined(RelationGuid)) + { + writer.WritePropertyName("relationGuid"u8); + writer.WriteStringValue(RelationGuid.Value); + } + if (Optional.IsDefined(Status)) + { + writer.WritePropertyName("status"u8); + writer.WriteStringValue(Status.Value.ToString()); + } + if (Optional.IsDefined(Steward)) + { + writer.WritePropertyName("steward"u8); + writer.WriteStringValue(Steward); + } + if (Optional.IsDefined(TermGuid)) + { + writer.WritePropertyName("termGuid"u8); + writer.WriteStringValue(TermGuid.Value); + } + writer.WriteEndObject(); + } + + internal static AtlasTermAssignmentHeader DeserializeAtlasTermAssignmentHeader(JsonElement element) + { + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + Optional confidence = default; + Optional createdBy = default; + Optional description = default; + Optional displayText = default; + Optional expression = default; + Optional relationGuid = default; + Optional status = default; + Optional steward = default; + Optional termGuid = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("confidence"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + confidence = property.Value.GetInt32(); + continue; + } + if (property.NameEquals("createdBy"u8)) + { + createdBy = property.Value.GetString(); + continue; + } + if (property.NameEquals("description"u8)) + { + description = property.Value.GetString(); + continue; + } + if (property.NameEquals("displayText"u8)) + { + displayText = property.Value.GetString(); + continue; + } + if (property.NameEquals("expression"u8)) + { + expression = property.Value.GetString(); + continue; + } + if (property.NameEquals("relationGuid"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + relationGuid = property.Value.GetGuid(); + continue; + } + if (property.NameEquals("status"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + status = new AtlasTermAssignmentStatus(property.Value.GetString()); + continue; + } + if (property.NameEquals("steward"u8)) + { + steward = property.Value.GetString(); + continue; + } + if (property.NameEquals("termGuid"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + termGuid = property.Value.GetGuid(); + continue; + } + } + return new AtlasTermAssignmentHeader(Optional.ToNullable(confidence), createdBy.Value, description.Value, displayText.Value, expression.Value, Optional.ToNullable(relationGuid), Optional.ToNullable(status), steward.Value, Optional.ToNullable(termGuid)); + } + + /// Deserializes the model from a raw response. + /// The response to deserialize the model from. + internal static AtlasTermAssignmentHeader FromResponse(Response response) + { + using var document = JsonDocument.Parse(response.Content); + return DeserializeAtlasTermAssignmentHeader(document.RootElement); + } + + /// Convert into a Utf8JsonRequestContent. + internal virtual RequestContent ToRequestContent() + { + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(this); + return content; + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasTermAssignmentHeader.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasTermAssignmentHeader.cs new file mode 100644 index 0000000000000..a0ef6a1f5749c --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasTermAssignmentHeader.cs @@ -0,0 +1,62 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; + +namespace Azure.Analytics.Purview.DataMap +{ + /// The header for term assignment. + public partial class AtlasTermAssignmentHeader + { + /// Initializes a new instance of . + public AtlasTermAssignmentHeader() + { + } + + /// Initializes a new instance of . + /// The confidence of the term assignment. + /// The user who created the record. + /// The description of the term assignment. + /// The display text. + /// The expression of the term assignment. + /// The GUID of the relationship. + /// The status of terms assignment. + /// The steward of the term. + /// The GUID of the term. + internal AtlasTermAssignmentHeader(int? confidence, string createdBy, string description, string displayText, string expression, Guid? relationGuid, AtlasTermAssignmentStatus? status, string steward, Guid? termGuid) + { + Confidence = confidence; + CreatedBy = createdBy; + Description = description; + DisplayText = displayText; + Expression = expression; + RelationGuid = relationGuid; + Status = status; + Steward = steward; + TermGuid = termGuid; + } + + /// The confidence of the term assignment. + public int? Confidence { get; set; } + /// The user who created the record. + public string CreatedBy { get; set; } + /// The description of the term assignment. + public string Description { get; set; } + /// The display text. + public string DisplayText { get; set; } + /// The expression of the term assignment. + public string Expression { get; set; } + /// The GUID of the relationship. + public Guid? RelationGuid { get; set; } + /// The status of terms assignment. + public AtlasTermAssignmentStatus? Status { get; set; } + /// The steward of the term. + public string Steward { get; set; } + /// The GUID of the term. + public Guid? TermGuid { get; set; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasTermAssignmentStatus.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasTermAssignmentStatus.cs new file mode 100644 index 0000000000000..8f1d17b9e3168 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasTermAssignmentStatus.cs @@ -0,0 +1,66 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.ComponentModel; + +namespace Azure.Analytics.Purview.DataMap +{ + /// Status for term assignment. + public readonly partial struct AtlasTermAssignmentStatus : IEquatable + { + private readonly string _value; + + /// Initializes a new instance of . + /// is null. + public AtlasTermAssignmentStatus(string value) + { + _value = value ?? throw new ArgumentNullException(nameof(value)); + } + + private const string DiscoveredValue = "DISCOVERED"; + private const string ProposedValue = "PROPOSED"; + private const string ImportedValue = "IMPORTED"; + private const string ValidatedValue = "VALIDATED"; + private const string DeprecatedValue = "DEPRECATED"; + private const string ObsoleteValue = "OBSOLETE"; + private const string OtherValue = "OTHER"; + + /// The status is discovered. + public static AtlasTermAssignmentStatus Discovered { get; } = new AtlasTermAssignmentStatus(DiscoveredValue); + /// The status is proposed. + public static AtlasTermAssignmentStatus Proposed { get; } = new AtlasTermAssignmentStatus(ProposedValue); + /// The status is imported. + public static AtlasTermAssignmentStatus Imported { get; } = new AtlasTermAssignmentStatus(ImportedValue); + /// The status is validated. + public static AtlasTermAssignmentStatus Validated { get; } = new AtlasTermAssignmentStatus(ValidatedValue); + /// The status is deprecated. + public static AtlasTermAssignmentStatus Deprecated { get; } = new AtlasTermAssignmentStatus(DeprecatedValue); + /// The status is obsolete. + public static AtlasTermAssignmentStatus Obsolete { get; } = new AtlasTermAssignmentStatus(ObsoleteValue); + /// Other status. + public static AtlasTermAssignmentStatus Other { get; } = new AtlasTermAssignmentStatus(OtherValue); + /// Determines if two values are the same. + public static bool operator ==(AtlasTermAssignmentStatus left, AtlasTermAssignmentStatus right) => left.Equals(right); + /// Determines if two values are not the same. + public static bool operator !=(AtlasTermAssignmentStatus left, AtlasTermAssignmentStatus right) => !left.Equals(right); + /// Converts a string to a . + public static implicit operator AtlasTermAssignmentStatus(string value) => new AtlasTermAssignmentStatus(value); + + /// + [EditorBrowsable(EditorBrowsableState.Never)] + public override bool Equals(object obj) => obj is AtlasTermAssignmentStatus other && Equals(other); + /// + public bool Equals(AtlasTermAssignmentStatus other) => string.Equals(_value, other._value, StringComparison.InvariantCultureIgnoreCase); + + /// + [EditorBrowsable(EditorBrowsableState.Never)] + public override int GetHashCode() => _value?.GetHashCode() ?? 0; + /// + public override string ToString() => _value; + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasTermCategorizationHeader.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasTermCategorizationHeader.Serialization.cs new file mode 100644 index 0000000000000..ea2fd45c643bd --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasTermCategorizationHeader.Serialization.cs @@ -0,0 +1,118 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Text.Json; +using Azure; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class AtlasTermCategorizationHeader : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + if (Optional.IsDefined(CategoryGuid)) + { + writer.WritePropertyName("categoryGuid"u8); + writer.WriteStringValue(CategoryGuid.Value); + } + if (Optional.IsDefined(Description)) + { + writer.WritePropertyName("description"u8); + writer.WriteStringValue(Description); + } + if (Optional.IsDefined(DisplayText)) + { + writer.WritePropertyName("displayText"u8); + writer.WriteStringValue(DisplayText); + } + if (Optional.IsDefined(RelationGuid)) + { + writer.WritePropertyName("relationGuid"u8); + writer.WriteStringValue(RelationGuid.Value); + } + if (Optional.IsDefined(Status)) + { + writer.WritePropertyName("status"u8); + writer.WriteStringValue(Status.Value.ToString()); + } + writer.WriteEndObject(); + } + + internal static AtlasTermCategorizationHeader DeserializeAtlasTermCategorizationHeader(JsonElement element) + { + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + Optional categoryGuid = default; + Optional description = default; + Optional displayText = default; + Optional relationGuid = default; + Optional status = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("categoryGuid"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + categoryGuid = property.Value.GetGuid(); + continue; + } + if (property.NameEquals("description"u8)) + { + description = property.Value.GetString(); + continue; + } + if (property.NameEquals("displayText"u8)) + { + displayText = property.Value.GetString(); + continue; + } + if (property.NameEquals("relationGuid"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + relationGuid = property.Value.GetGuid(); + continue; + } + if (property.NameEquals("status"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + status = new AtlasTermRelationshipStatus(property.Value.GetString()); + continue; + } + } + return new AtlasTermCategorizationHeader(Optional.ToNullable(categoryGuid), description.Value, displayText.Value, Optional.ToNullable(relationGuid), Optional.ToNullable(status)); + } + + /// Deserializes the model from a raw response. + /// The response to deserialize the model from. + internal static AtlasTermCategorizationHeader FromResponse(Response response) + { + using var document = JsonDocument.Parse(response.Content); + return DeserializeAtlasTermCategorizationHeader(document.RootElement); + } + + /// Convert into a Utf8JsonRequestContent. + internal virtual RequestContent ToRequestContent() + { + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(this); + return content; + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasTermCategorizationHeader.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasTermCategorizationHeader.cs new file mode 100644 index 0000000000000..07ad86fab1e27 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasTermCategorizationHeader.cs @@ -0,0 +1,46 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; + +namespace Azure.Analytics.Purview.DataMap +{ + /// The basic information for term categorization. + public partial class AtlasTermCategorizationHeader + { + /// Initializes a new instance of . + public AtlasTermCategorizationHeader() + { + } + + /// Initializes a new instance of . + /// The GUID of the category. + /// The description of the record. + /// The display text. + /// The GUID of the relationship. + /// The status of term relationship. + internal AtlasTermCategorizationHeader(Guid? categoryGuid, string description, string displayText, Guid? relationGuid, AtlasTermRelationshipStatus? status) + { + CategoryGuid = categoryGuid; + Description = description; + DisplayText = displayText; + RelationGuid = relationGuid; + Status = status; + } + + /// The GUID of the category. + public Guid? CategoryGuid { get; set; } + /// The description of the record. + public string Description { get; set; } + /// The display text. + public string DisplayText { get; set; } + /// The GUID of the relationship. + public Guid? RelationGuid { get; set; } + /// The status of term relationship. + public AtlasTermRelationshipStatus? Status { get; set; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasTermRelationshipStatus.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasTermRelationshipStatus.cs new file mode 100644 index 0000000000000..a9ed516965c8e --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasTermRelationshipStatus.cs @@ -0,0 +1,60 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.ComponentModel; + +namespace Azure.Analytics.Purview.DataMap +{ + /// Status for atlas term relationship. + public readonly partial struct AtlasTermRelationshipStatus : IEquatable + { + private readonly string _value; + + /// Initializes a new instance of . + /// is null. + public AtlasTermRelationshipStatus(string value) + { + _value = value ?? throw new ArgumentNullException(nameof(value)); + } + + private const string DraftValue = "DRAFT"; + private const string ActiveValue = "ACTIVE"; + private const string DeprecatedValue = "DEPRECATED"; + private const string ObsoleteValue = "OBSOLETE"; + private const string OtherValue = "OTHER"; + + /// draft. + public static AtlasTermRelationshipStatus Draft { get; } = new AtlasTermRelationshipStatus(DraftValue); + /// active. + public static AtlasTermRelationshipStatus Active { get; } = new AtlasTermRelationshipStatus(ActiveValue); + /// deprecated. + public static AtlasTermRelationshipStatus Deprecated { get; } = new AtlasTermRelationshipStatus(DeprecatedValue); + /// obsolete. + public static AtlasTermRelationshipStatus Obsolete { get; } = new AtlasTermRelationshipStatus(ObsoleteValue); + /// other. + public static AtlasTermRelationshipStatus Other { get; } = new AtlasTermRelationshipStatus(OtherValue); + /// Determines if two values are the same. + public static bool operator ==(AtlasTermRelationshipStatus left, AtlasTermRelationshipStatus right) => left.Equals(right); + /// Determines if two values are not the same. + public static bool operator !=(AtlasTermRelationshipStatus left, AtlasTermRelationshipStatus right) => !left.Equals(right); + /// Converts a string to a . + public static implicit operator AtlasTermRelationshipStatus(string value) => new AtlasTermRelationshipStatus(value); + + /// + [EditorBrowsable(EditorBrowsableState.Never)] + public override bool Equals(object obj) => obj is AtlasTermRelationshipStatus other && Equals(other); + /// + public bool Equals(AtlasTermRelationshipStatus other) => string.Equals(_value, other._value, StringComparison.InvariantCultureIgnoreCase); + + /// + [EditorBrowsable(EditorBrowsableState.Never)] + public override int GetHashCode() => _value?.GetHashCode() ?? 0; + /// + public override string ToString() => _value; + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasTypeDef.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasTypeDef.Serialization.cs new file mode 100644 index 0000000000000..4e85ec3adf6b9 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasTypeDef.Serialization.cs @@ -0,0 +1,282 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using System.Text.Json; +using Azure; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class AtlasTypeDef + { + internal static AtlasTypeDef DeserializeAtlasTypeDef(JsonElement element) + { + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + Optional category = default; + Optional createTime = default; + Optional createdBy = default; + Optional dateFormatter = default; + Optional description = default; + Optional guid = default; + Optional name = default; + Optional> options = default; + Optional serviceType = default; + Optional typeVersion = default; + Optional updateTime = default; + Optional updatedBy = default; + Optional version = default; + Optional lastModifiedTS = default; + Optional> entityTypes = default; + Optional> subTypes = default; + Optional> superTypes = default; + Optional> relationshipAttributeDefs = default; + Optional defaultValue = default; + Optional> elementDefs = default; + Optional endDef1 = default; + Optional endDef2 = default; + Optional relationshipCategory = default; + Optional relationshipLabel = default; + Optional> attributeDefs = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("category"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + category = new TypeCategory(property.Value.GetString()); + continue; + } + if (property.NameEquals("createTime"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + createTime = property.Value.GetInt64(); + continue; + } + if (property.NameEquals("createdBy"u8)) + { + createdBy = property.Value.GetString(); + continue; + } + if (property.NameEquals("dateFormatter"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + dateFormatter = DateFormat.DeserializeDateFormat(property.Value); + continue; + } + if (property.NameEquals("description"u8)) + { + description = property.Value.GetString(); + continue; + } + if (property.NameEquals("guid"u8)) + { + guid = property.Value.GetString(); + continue; + } + if (property.NameEquals("name"u8)) + { + name = property.Value.GetString(); + continue; + } + if (property.NameEquals("options"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + Dictionary dictionary = new Dictionary(); + foreach (var property0 in property.Value.EnumerateObject()) + { + dictionary.Add(property0.Name, property0.Value.GetString()); + } + options = dictionary; + continue; + } + if (property.NameEquals("serviceType"u8)) + { + serviceType = property.Value.GetString(); + continue; + } + if (property.NameEquals("typeVersion"u8)) + { + typeVersion = property.Value.GetString(); + continue; + } + if (property.NameEquals("updateTime"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + updateTime = property.Value.GetInt64(); + continue; + } + if (property.NameEquals("updatedBy"u8)) + { + updatedBy = property.Value.GetString(); + continue; + } + if (property.NameEquals("version"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + version = property.Value.GetInt64(); + continue; + } + if (property.NameEquals("lastModifiedTS"u8)) + { + lastModifiedTS = property.Value.GetString(); + continue; + } + if (property.NameEquals("entityTypes"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(item.GetString()); + } + entityTypes = array; + continue; + } + if (property.NameEquals("subTypes"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(item.GetString()); + } + subTypes = array; + continue; + } + if (property.NameEquals("superTypes"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(item.GetString()); + } + superTypes = array; + continue; + } + if (property.NameEquals("relationshipAttributeDefs"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(AtlasRelationshipAttributeDef.DeserializeAtlasRelationshipAttributeDef(item)); + } + relationshipAttributeDefs = array; + continue; + } + if (property.NameEquals("defaultValue"u8)) + { + defaultValue = property.Value.GetString(); + continue; + } + if (property.NameEquals("elementDefs"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(AtlasEnumElementDef.DeserializeAtlasEnumElementDef(item)); + } + elementDefs = array; + continue; + } + if (property.NameEquals("endDef1"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + endDef1 = AtlasRelationshipEndDef.DeserializeAtlasRelationshipEndDef(property.Value); + continue; + } + if (property.NameEquals("endDef2"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + endDef2 = AtlasRelationshipEndDef.DeserializeAtlasRelationshipEndDef(property.Value); + continue; + } + if (property.NameEquals("relationshipCategory"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + relationshipCategory = new RelationshipCategory(property.Value.GetString()); + continue; + } + if (property.NameEquals("relationshipLabel"u8)) + { + relationshipLabel = property.Value.GetString(); + continue; + } + if (property.NameEquals("attributeDefs"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(AtlasAttributeDef.DeserializeAtlasAttributeDef(item)); + } + attributeDefs = array; + continue; + } + } + return new AtlasTypeDef(Optional.ToNullable(category), Optional.ToNullable(createTime), createdBy.Value, dateFormatter.Value, description.Value, guid.Value, name.Value, Optional.ToDictionary(options), serviceType.Value, typeVersion.Value, Optional.ToNullable(updateTime), updatedBy.Value, Optional.ToNullable(version), lastModifiedTS.Value, Optional.ToList(entityTypes), Optional.ToList(subTypes), Optional.ToList(superTypes), Optional.ToList(relationshipAttributeDefs), defaultValue.Value, Optional.ToList(elementDefs), endDef1.Value, endDef2.Value, Optional.ToNullable(relationshipCategory), relationshipLabel.Value, Optional.ToList(attributeDefs)); + } + + /// Deserializes the model from a raw response. + /// The response to deserialize the model from. + internal static AtlasTypeDef FromResponse(Response response) + { + using var document = JsonDocument.Parse(response.Content); + return DeserializeAtlasTypeDef(document.RootElement); + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasTypeDef.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasTypeDef.cs new file mode 100644 index 0000000000000..e22c1c5b0e1ab --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasTypeDef.cs @@ -0,0 +1,222 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + /// The definitions of type. + public partial class AtlasTypeDef + { + /// Initializes a new instance of . + internal AtlasTypeDef() + { + Options = new ChangeTrackingDictionary(); + EntityTypes = new ChangeTrackingList(); + SubTypes = new ChangeTrackingList(); + SuperTypes = new ChangeTrackingList(); + RelationshipAttributeDefs = new ChangeTrackingList(); + ElementDefs = new ChangeTrackingList(); + AttributeDefs = new ChangeTrackingList(); + } + + /// Initializes a new instance of . + /// The enum of type category. + /// The created time of the record. + /// The user who created the record. + /// The date format. + /// The description of the type definition. + /// The GUID of the type definition. + /// The name of the type definition. + /// The options for the type definition. + /// The service type. + /// The version of the type. + /// The update time of the record. + /// The user who updated the record. + /// The version of the record. + /// ETag for concurrency control. + /// + /// Specifying a list of entityType names in the classificationDef, ensures that + /// classifications can + /// only be applied to those entityTypes. + /// + /// Any subtypes of the entity types inherit the restriction. + /// + /// Any classificationDef subtypes inherit the parents entityTypes restrictions. + /// + /// Any classificationDef subtypes can further restrict the parents entityTypes + /// restrictions by specifying a subset of the entityTypes. + /// + /// An empty entityTypes list when there are no parent restrictions means there are no + /// restrictions. + /// + /// An empty entityTypes list when there are parent + /// restrictions means that the subtype picks up the parents + /// restrictions. + /// + /// If a list of entityTypes are supplied, where one inherits + /// from another, this will be rejected. This should encourage cleaner + /// classificationsDefs. + /// + /// + /// An array of sub types. + /// An array of super types. + /// An array of relationship attributes. + /// The default value. + /// An array of enum element definitions. + /// + /// The relationshipEndDef represents an end of the relationship. The end of the + /// relationship is defined by a type, an + /// attribute name, cardinality and whether + /// it is the container end of the relationship. + /// + /// + /// The relationshipEndDef represents an end of the relationship. The end of the + /// relationship is defined by a type, an + /// attribute name, cardinality and whether + /// it is the container end of the relationship. + /// + /// + /// The Relationship category determines the style of relationship around + /// containment and lifecycle. + /// UML terminology is used for the values. + /// + /// ASSOCIATION is a relationship with no containment. + /// COMPOSITION and AGGREGATION are containment relationships. + /// + /// The difference being in the lifecycles of the container and its children. + /// In the COMPOSITION case, the children cannot exist without the container. + /// For AGGREGATION, the life cycles of the container and children are totally independent. + /// + /// The label of the relationship. + /// An array of attribute definitions. + internal AtlasTypeDef(TypeCategory? category, long? createTime, string createdBy, DateFormat dateFormatter, string description, string guid, string name, IReadOnlyDictionary options, string serviceType, string typeVersion, long? updateTime, string updatedBy, long? version, string lastModifiedTS, IReadOnlyList entityTypes, IReadOnlyList subTypes, IReadOnlyList superTypes, IReadOnlyList relationshipAttributeDefs, string defaultValue, IReadOnlyList elementDefs, AtlasRelationshipEndDef endDef1, AtlasRelationshipEndDef endDef2, RelationshipCategory? relationshipCategory, string relationshipLabel, IReadOnlyList attributeDefs) + { + Category = category; + CreateTime = createTime; + CreatedBy = createdBy; + DateFormatter = dateFormatter; + Description = description; + Guid = guid; + Name = name; + Options = options; + ServiceType = serviceType; + TypeVersion = typeVersion; + UpdateTime = updateTime; + UpdatedBy = updatedBy; + Version = version; + LastModifiedTS = lastModifiedTS; + EntityTypes = entityTypes; + SubTypes = subTypes; + SuperTypes = superTypes; + RelationshipAttributeDefs = relationshipAttributeDefs; + DefaultValue = defaultValue; + ElementDefs = elementDefs; + EndDef1 = endDef1; + EndDef2 = endDef2; + RelationshipCategory = relationshipCategory; + RelationshipLabel = relationshipLabel; + AttributeDefs = attributeDefs; + } + + /// The enum of type category. + public TypeCategory? Category { get; } + /// The created time of the record. + public long? CreateTime { get; } + /// The user who created the record. + public string CreatedBy { get; } + /// The date format. + public DateFormat DateFormatter { get; } + /// The description of the type definition. + public string Description { get; } + /// The GUID of the type definition. + public string Guid { get; } + /// The name of the type definition. + public string Name { get; } + /// The options for the type definition. + public IReadOnlyDictionary Options { get; } + /// The service type. + public string ServiceType { get; } + /// The version of the type. + public string TypeVersion { get; } + /// The update time of the record. + public long? UpdateTime { get; } + /// The user who updated the record. + public string UpdatedBy { get; } + /// The version of the record. + public long? Version { get; } + /// ETag for concurrency control. + public string LastModifiedTS { get; } + /// + /// Specifying a list of entityType names in the classificationDef, ensures that + /// classifications can + /// only be applied to those entityTypes. + /// + /// Any subtypes of the entity types inherit the restriction. + /// + /// Any classificationDef subtypes inherit the parents entityTypes restrictions. + /// + /// Any classificationDef subtypes can further restrict the parents entityTypes + /// restrictions by specifying a subset of the entityTypes. + /// + /// An empty entityTypes list when there are no parent restrictions means there are no + /// restrictions. + /// + /// An empty entityTypes list when there are parent + /// restrictions means that the subtype picks up the parents + /// restrictions. + /// + /// If a list of entityTypes are supplied, where one inherits + /// from another, this will be rejected. This should encourage cleaner + /// classificationsDefs. + /// + /// + public IReadOnlyList EntityTypes { get; } + /// An array of sub types. + public IReadOnlyList SubTypes { get; } + /// An array of super types. + public IReadOnlyList SuperTypes { get; } + /// An array of relationship attributes. + public IReadOnlyList RelationshipAttributeDefs { get; } + /// The default value. + public string DefaultValue { get; } + /// An array of enum element definitions. + public IReadOnlyList ElementDefs { get; } + /// + /// The relationshipEndDef represents an end of the relationship. The end of the + /// relationship is defined by a type, an + /// attribute name, cardinality and whether + /// it is the container end of the relationship. + /// + public AtlasRelationshipEndDef EndDef1 { get; } + /// + /// The relationshipEndDef represents an end of the relationship. The end of the + /// relationship is defined by a type, an + /// attribute name, cardinality and whether + /// it is the container end of the relationship. + /// + public AtlasRelationshipEndDef EndDef2 { get; } + /// + /// The Relationship category determines the style of relationship around + /// containment and lifecycle. + /// UML terminology is used for the values. + /// + /// ASSOCIATION is a relationship with no containment. + /// COMPOSITION and AGGREGATION are containment relationships. + /// + /// The difference being in the lifecycles of the container and its children. + /// In the COMPOSITION case, the children cannot exist without the container. + /// For AGGREGATION, the life cycles of the container and children are totally independent. + /// + public RelationshipCategory? RelationshipCategory { get; } + /// The label of the relationship. + public string RelationshipLabel { get; } + /// An array of attribute definitions. + public IReadOnlyList AttributeDefs { get; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasTypeDefHeader.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasTypeDefHeader.Serialization.cs new file mode 100644 index 0000000000000..b5409dd868c45 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasTypeDefHeader.Serialization.cs @@ -0,0 +1,58 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class AtlasTypeDefHeader + { + internal static AtlasTypeDefHeader DeserializeAtlasTypeDefHeader(JsonElement element) + { + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + Optional category = default; + Optional guid = default; + Optional name = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("category"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + category = new TypeCategory(property.Value.GetString()); + continue; + } + if (property.NameEquals("guid"u8)) + { + guid = property.Value.GetString(); + continue; + } + if (property.NameEquals("name"u8)) + { + name = property.Value.GetString(); + continue; + } + } + return new AtlasTypeDefHeader(Optional.ToNullable(category), guid.Value, name.Value); + } + + /// Deserializes the model from a raw response. + /// The response to deserialize the model from. + internal static AtlasTypeDefHeader FromResponse(Response response) + { + using var document = JsonDocument.Parse(response.Content); + return DeserializeAtlasTypeDefHeader(document.RootElement); + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasTypeDefHeader.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasTypeDefHeader.cs new file mode 100644 index 0000000000000..e2b1aab7e1c46 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasTypeDefHeader.cs @@ -0,0 +1,36 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +namespace Azure.Analytics.Purview.DataMap +{ + /// The basic information of the type definition. + public partial class AtlasTypeDefHeader + { + /// Initializes a new instance of . + internal AtlasTypeDefHeader() + { + } + + /// Initializes a new instance of . + /// The enum of type category. + /// The GUID of the type definition. + /// The name of the type definition. + internal AtlasTypeDefHeader(TypeCategory? category, string guid, string name) + { + Category = category; + Guid = guid; + Name = name; + } + + /// The enum of type category. + public TypeCategory? Category { get; } + /// The GUID of the type definition. + public string Guid { get; } + /// The name of the type definition. + public string Name { get; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasTypesDef.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasTypesDef.Serialization.cs new file mode 100644 index 0000000000000..cb06f4318ab7b --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasTypesDef.Serialization.cs @@ -0,0 +1,226 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using System.Text.Json; +using Azure; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class AtlasTypesDef : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + if (Optional.IsCollectionDefined(BusinessMetadataDefs)) + { + writer.WritePropertyName("businessMetadataDefs"u8); + writer.WriteStartArray(); + foreach (var item in BusinessMetadataDefs) + { + writer.WriteObjectValue(item); + } + writer.WriteEndArray(); + } + if (Optional.IsCollectionDefined(ClassificationDefs)) + { + writer.WritePropertyName("classificationDefs"u8); + writer.WriteStartArray(); + foreach (var item in ClassificationDefs) + { + writer.WriteObjectValue(item); + } + writer.WriteEndArray(); + } + if (Optional.IsCollectionDefined(EntityDefs)) + { + writer.WritePropertyName("entityDefs"u8); + writer.WriteStartArray(); + foreach (var item in EntityDefs) + { + writer.WriteObjectValue(item); + } + writer.WriteEndArray(); + } + if (Optional.IsCollectionDefined(EnumDefs)) + { + writer.WritePropertyName("enumDefs"u8); + writer.WriteStartArray(); + foreach (var item in EnumDefs) + { + writer.WriteObjectValue(item); + } + writer.WriteEndArray(); + } + if (Optional.IsCollectionDefined(RelationshipDefs)) + { + writer.WritePropertyName("relationshipDefs"u8); + writer.WriteStartArray(); + foreach (var item in RelationshipDefs) + { + writer.WriteObjectValue(item); + } + writer.WriteEndArray(); + } + if (Optional.IsCollectionDefined(StructDefs)) + { + writer.WritePropertyName("structDefs"u8); + writer.WriteStartArray(); + foreach (var item in StructDefs) + { + writer.WriteObjectValue(item); + } + writer.WriteEndArray(); + } + if (Optional.IsCollectionDefined(TermTemplateDefs)) + { + writer.WritePropertyName("termTemplateDefs"u8); + writer.WriteStartArray(); + foreach (var item in TermTemplateDefs) + { + writer.WriteObjectValue(item); + } + writer.WriteEndArray(); + } + writer.WriteEndObject(); + } + + internal static AtlasTypesDef DeserializeAtlasTypesDef(JsonElement element) + { + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + Optional> businessMetadataDefs = default; + Optional> classificationDefs = default; + Optional> entityDefs = default; + Optional> enumDefs = default; + Optional> relationshipDefs = default; + Optional> structDefs = default; + Optional> termTemplateDefs = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("businessMetadataDefs"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(AtlasBusinessMetadataDef.DeserializeAtlasBusinessMetadataDef(item)); + } + businessMetadataDefs = array; + continue; + } + if (property.NameEquals("classificationDefs"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(AtlasClassificationDef.DeserializeAtlasClassificationDef(item)); + } + classificationDefs = array; + continue; + } + if (property.NameEquals("entityDefs"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(AtlasEntityDef.DeserializeAtlasEntityDef(item)); + } + entityDefs = array; + continue; + } + if (property.NameEquals("enumDefs"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(AtlasEnumDef.DeserializeAtlasEnumDef(item)); + } + enumDefs = array; + continue; + } + if (property.NameEquals("relationshipDefs"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(AtlasRelationshipDef.DeserializeAtlasRelationshipDef(item)); + } + relationshipDefs = array; + continue; + } + if (property.NameEquals("structDefs"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(AtlasStructDef.DeserializeAtlasStructDef(item)); + } + structDefs = array; + continue; + } + if (property.NameEquals("termTemplateDefs"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(TermTemplateDef.DeserializeTermTemplateDef(item)); + } + termTemplateDefs = array; + continue; + } + } + return new AtlasTypesDef(Optional.ToList(businessMetadataDefs), Optional.ToList(classificationDefs), Optional.ToList(entityDefs), Optional.ToList(enumDefs), Optional.ToList(relationshipDefs), Optional.ToList(structDefs), Optional.ToList(termTemplateDefs)); + } + + /// Deserializes the model from a raw response. + /// The response to deserialize the model from. + internal static AtlasTypesDef FromResponse(Response response) + { + using var document = JsonDocument.Parse(response.Content); + return DeserializeAtlasTypesDef(document.RootElement); + } + + /// Convert into a Utf8JsonRequestContent. + internal virtual RequestContent ToRequestContent() + { + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(this); + return content; + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasTypesDef.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasTypesDef.cs new file mode 100644 index 0000000000000..38bd1cf253369 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AtlasTypesDef.cs @@ -0,0 +1,62 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + /// The definitions of types. + public partial class AtlasTypesDef + { + /// Initializes a new instance of . + public AtlasTypesDef() + { + BusinessMetadataDefs = new ChangeTrackingList(); + ClassificationDefs = new ChangeTrackingList(); + EntityDefs = new ChangeTrackingList(); + EnumDefs = new ChangeTrackingList(); + RelationshipDefs = new ChangeTrackingList(); + StructDefs = new ChangeTrackingList(); + TermTemplateDefs = new ChangeTrackingList(); + } + + /// Initializes a new instance of . + /// businessMetadataDefs. + /// An array of classification definitions. + /// An array of entity definitions. + /// An array of enum definitions. + /// An array of relationship definitions. + /// An array of struct definitions. + /// An array of term template definitions. + internal AtlasTypesDef(IList businessMetadataDefs, IList classificationDefs, IList entityDefs, IList enumDefs, IList relationshipDefs, IList structDefs, IList termTemplateDefs) + { + BusinessMetadataDefs = businessMetadataDefs; + ClassificationDefs = classificationDefs; + EntityDefs = entityDefs; + EnumDefs = enumDefs; + RelationshipDefs = relationshipDefs; + StructDefs = structDefs; + TermTemplateDefs = termTemplateDefs; + } + + /// businessMetadataDefs. + public IList BusinessMetadataDefs { get; } + /// An array of classification definitions. + public IList ClassificationDefs { get; } + /// An array of entity definitions. + public IList EntityDefs { get; } + /// An array of enum definitions. + public IList EnumDefs { get; } + /// An array of relationship definitions. + public IList RelationshipDefs { get; } + /// An array of struct definitions. + public IList StructDefs { get; } + /// An array of term template definitions. + public IList TermTemplateDefs { get; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AttributeFilter.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AttributeFilter.Serialization.cs new file mode 100644 index 0000000000000..eb68d135f4547 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AttributeFilter.Serialization.cs @@ -0,0 +1,44 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class AttributeFilter : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + writer.WritePropertyName("attributeName"u8); + writer.WriteStringValue(AttributeName); + writer.WritePropertyName("operator"u8); + writer.WriteStringValue(Operator.ToString()); + writer.WritePropertyName("attributeValue"u8); +#if NET6_0_OR_GREATER + writer.WriteRawValue(AttributeValue); +#else + using (JsonDocument document = JsonDocument.Parse(AttributeValue)) + { + JsonSerializer.Serialize(writer, document.RootElement); + } +#endif + writer.WritePropertyName("kind"u8); + writer.WriteStringValue(Kind); + writer.WriteEndObject(); + } + + /// Convert into a Utf8JsonRequestContent. + internal override RequestContent ToRequestContent() + { + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(this); + return content; + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AttributeFilter.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AttributeFilter.cs new file mode 100644 index 0000000000000..5f7b80fa183ed --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AttributeFilter.cs @@ -0,0 +1,80 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + /// Attribute filter for search. + public partial class AttributeFilter : SearchFilter + { + /// Initializes a new instance of . + /// Attribute name. + /// Operator. + /// Attribute value. + /// or is null. + public AttributeFilter(string attributeName, FilterOperator @operator, BinaryData attributeValue) + { + Argument.AssertNotNull(attributeName, nameof(attributeName)); + Argument.AssertNotNull(attributeValue, nameof(attributeValue)); + + Kind = "AttributeFilter"; + AttributeName = attributeName; + Operator = @operator; + AttributeValue = attributeValue; + } + + /// Initializes a new instance of . + /// Discriminator. + /// Attribute name. + /// Operator. + /// Attribute value. + internal AttributeFilter(string kind, string attributeName, FilterOperator @operator, BinaryData attributeValue) : base(kind) + { + AttributeName = attributeName; + Operator = @operator; + AttributeValue = attributeValue; + } + + /// Attribute name. + public string AttributeName { get; } + /// Operator. + public FilterOperator Operator { get; } + /// + /// Attribute value + /// + /// To assign an object to this property use . + /// + /// + /// To assign an already formatted json string to this property use . + /// + /// + /// Examples: + /// + /// + /// BinaryData.FromObjectAsJson("foo") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromString("\"foo\"") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromObjectAsJson(new { key = "value" }) + /// Creates a payload of { "key": "value" }. + /// + /// + /// BinaryData.FromString("{\"key\": \"value\"}") + /// Creates a payload of { "key": "value" }. + /// + /// + /// + /// + public BinaryData AttributeValue { get; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AutoCompleteOptions.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AutoCompleteOptions.Serialization.cs new file mode 100644 index 0000000000000..7d5ba6622a3f6 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AutoCompleteOptions.Serialization.cs @@ -0,0 +1,44 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class AutoCompleteOptions : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + if (Optional.IsDefined(Keywords)) + { + writer.WritePropertyName("keywords"u8); + writer.WriteStringValue(Keywords); + } + if (Optional.IsDefined(Limit)) + { + writer.WritePropertyName("limit"u8); + writer.WriteNumberValue(Limit.Value); + } + if (Optional.IsDefined(Filter)) + { + writer.WritePropertyName("filter"u8); + writer.WriteObjectValue(Filter); + } + writer.WriteEndObject(); + } + + /// Convert into a Utf8JsonRequestContent. + internal virtual RequestContent ToRequestContent() + { + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(this); + return content; + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AutoCompleteOptions.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AutoCompleteOptions.cs new file mode 100644 index 0000000000000..00117455c6c1d --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AutoCompleteOptions.cs @@ -0,0 +1,52 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +namespace Azure.Analytics.Purview.DataMap +{ + /// The query of autocomplete request. + public partial class AutoCompleteOptions + { + /// Initializes a new instance of . + public AutoCompleteOptions() + { + } + + /// Initializes a new instance of . + /// + /// The keywords applied to all fields that support autocomplete operation. It must + /// be at least 1 character, and no more than 100 characters. + /// + /// + /// The number of autocomplete results we hope to return. The default value is 50. + /// The value must be a number between 1 and 100. + /// + /// The filter for the autocomplete request. + internal AutoCompleteOptions(string keywords, int? limit, SearchFilter filter) + { + Keywords = keywords; + Limit = limit; + Filter = filter; + } + + /// + /// The keywords applied to all fields that support autocomplete operation. It must + /// be at least 1 character, and no more than 100 characters. + /// + public string Keywords { get; set; } + /// + /// The number of autocomplete results we hope to return. The default value is 50. + /// The value must be a number between 1 and 100. + /// + public int? Limit { get; set; } + /// + /// The filter for the autocomplete request. + /// Please note is the base class. According to the scenario, a derived class of the base class might need to be assigned here, or this property needs to be casted to one of the possible derived classes. + /// The available derived classes include , , , , , , , , , , , , , , , , , , , , and . + /// + public SearchFilter Filter { get; set; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AutoCompleteResult.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AutoCompleteResult.Serialization.cs new file mode 100644 index 0000000000000..602391606e3fb --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AutoCompleteResult.Serialization.cs @@ -0,0 +1,52 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using System.Text.Json; +using Azure; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class AutoCompleteResult + { + internal static AutoCompleteResult DeserializeAutoCompleteResult(JsonElement element) + { + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + Optional> value = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("value"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(AutoCompleteResultValue.DeserializeAutoCompleteResultValue(item)); + } + value = array; + continue; + } + } + return new AutoCompleteResult(Optional.ToList(value)); + } + + /// Deserializes the model from a raw response. + /// The response to deserialize the model from. + internal static AutoCompleteResult FromResponse(Response response) + { + using var document = JsonDocument.Parse(response.Content); + return DeserializeAutoCompleteResult(document.RootElement); + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AutoCompleteResult.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AutoCompleteResult.cs new file mode 100644 index 0000000000000..3a2436d76ae7d --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AutoCompleteResult.cs @@ -0,0 +1,32 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + /// The result of the autocomplete request. + public partial class AutoCompleteResult + { + /// Initializes a new instance of . + internal AutoCompleteResult() + { + Value = new ChangeTrackingList(); + } + + /// Initializes a new instance of . + /// The result value. + internal AutoCompleteResult(IReadOnlyList value) + { + Value = value; + } + + /// The result value. + public IReadOnlyList Value { get; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AutoCompleteResultValue.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AutoCompleteResultValue.Serialization.cs new file mode 100644 index 0000000000000..186bc60610181 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AutoCompleteResultValue.Serialization.cs @@ -0,0 +1,48 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class AutoCompleteResultValue + { + internal static AutoCompleteResultValue DeserializeAutoCompleteResultValue(JsonElement element) + { + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + Optional text = default; + Optional queryPlusText = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("text"u8)) + { + text = property.Value.GetString(); + continue; + } + if (property.NameEquals("queryPlusText"u8)) + { + queryPlusText = property.Value.GetString(); + continue; + } + } + return new AutoCompleteResultValue(text.Value, queryPlusText.Value); + } + + /// Deserializes the model from a raw response. + /// The response to deserialize the model from. + internal static AutoCompleteResultValue FromResponse(Response response) + { + using var document = JsonDocument.Parse(response.Content); + return DeserializeAutoCompleteResultValue(document.RootElement); + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AutoCompleteResultValue.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AutoCompleteResultValue.cs new file mode 100644 index 0000000000000..14f10d9a6023b --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/AutoCompleteResultValue.cs @@ -0,0 +1,32 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +namespace Azure.Analytics.Purview.DataMap +{ + /// The value item of the autocomplete suggest. + public partial class AutoCompleteResultValue + { + /// Initializes a new instance of . + internal AutoCompleteResultValue() + { + } + + /// Initializes a new instance of . + /// The completed term or phrase. + /// The completed search query text. + internal AutoCompleteResultValue(string text, string queryPlusText) + { + Text = text; + QueryPlusText = queryPlusText; + } + + /// The completed term or phrase. + public string Text { get; } + /// The completed search query text. + public string QueryPlusText { get; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/BulkImportResult.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/BulkImportResult.Serialization.cs new file mode 100644 index 0000000000000..35b79206f8f1c --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/BulkImportResult.Serialization.cs @@ -0,0 +1,67 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using System.Text.Json; +using Azure; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class BulkImportResult + { + internal static BulkImportResult DeserializeBulkImportResult(JsonElement element) + { + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + Optional> failedImportInfoList = default; + Optional> successImportInfoList = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("failedImportInfoList"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(ImportInfo.DeserializeImportInfo(item)); + } + failedImportInfoList = array; + continue; + } + if (property.NameEquals("successImportInfoList"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(ImportInfo.DeserializeImportInfo(item)); + } + successImportInfoList = array; + continue; + } + } + return new BulkImportResult(Optional.ToList(failedImportInfoList), Optional.ToList(successImportInfoList)); + } + + /// Deserializes the model from a raw response. + /// The response to deserialize the model from. + internal static BulkImportResult FromResponse(Response response) + { + using var document = JsonDocument.Parse(response.Content); + return DeserializeBulkImportResult(document.RootElement); + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/BulkImportResult.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/BulkImportResult.cs new file mode 100644 index 0000000000000..d62fe7e508b6d --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/BulkImportResult.cs @@ -0,0 +1,37 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + /// Bulk import result. + public partial class BulkImportResult + { + /// Initializes a new instance of . + internal BulkImportResult() + { + FailedImportInfoList = new ChangeTrackingList(); + SuccessImportInfoList = new ChangeTrackingList(); + } + + /// Initializes a new instance of . + /// failed importInfoList. + /// successful importInfoList. + internal BulkImportResult(IReadOnlyList failedImportInfoList, IReadOnlyList successImportInfoList) + { + FailedImportInfoList = failedImportInfoList; + SuccessImportInfoList = successImportInfoList; + } + + /// failed importInfoList. + public IReadOnlyList FailedImportInfoList { get; } + /// successful importInfoList. + public IReadOnlyList SuccessImportInfoList { get; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/BusinessAttributeUpdateBehavior.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/BusinessAttributeUpdateBehavior.cs new file mode 100644 index 0000000000000..3048584216d32 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/BusinessAttributeUpdateBehavior.cs @@ -0,0 +1,54 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.ComponentModel; + +namespace Azure.Analytics.Purview.DataMap +{ + /// Enum for business attribute update behavior. + public readonly partial struct BusinessAttributeUpdateBehavior : IEquatable + { + private readonly string _value; + + /// Initializes a new instance of . + /// is null. + public BusinessAttributeUpdateBehavior(string value) + { + _value = value ?? throw new ArgumentNullException(nameof(value)); + } + + private const string IgnoreValue = "ignore"; + private const string ReplaceValue = "replace"; + private const string MergeValue = "merge"; + + /// Ignore the business attribute payload for update. + public static BusinessAttributeUpdateBehavior Ignore { get; } = new BusinessAttributeUpdateBehavior(IgnoreValue); + /// Replace all the business attributes using the payload. + public static BusinessAttributeUpdateBehavior Replace { get; } = new BusinessAttributeUpdateBehavior(ReplaceValue); + /// Merge the business attributes. Business attributes will not be updated if not provided. + public static BusinessAttributeUpdateBehavior Merge { get; } = new BusinessAttributeUpdateBehavior(MergeValue); + /// Determines if two values are the same. + public static bool operator ==(BusinessAttributeUpdateBehavior left, BusinessAttributeUpdateBehavior right) => left.Equals(right); + /// Determines if two values are not the same. + public static bool operator !=(BusinessAttributeUpdateBehavior left, BusinessAttributeUpdateBehavior right) => !left.Equals(right); + /// Converts a string to a . + public static implicit operator BusinessAttributeUpdateBehavior(string value) => new BusinessAttributeUpdateBehavior(value); + + /// + [EditorBrowsable(EditorBrowsableState.Never)] + public override bool Equals(object obj) => obj is BusinessAttributeUpdateBehavior other && Equals(other); + /// + public bool Equals(BusinessAttributeUpdateBehavior other) => string.Equals(_value, other._value, StringComparison.InvariantCultureIgnoreCase); + + /// + [EditorBrowsable(EditorBrowsableState.Never)] + public override int GetHashCode() => _value?.GetHashCode() ?? 0; + /// + public override string ToString() => _value; + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/CardinalityValue.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/CardinalityValue.cs new file mode 100644 index 0000000000000..20708f920eb63 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/CardinalityValue.cs @@ -0,0 +1,54 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.ComponentModel; + +namespace Azure.Analytics.Purview.DataMap +{ + /// Cardinality. + public readonly partial struct CardinalityValue : IEquatable + { + private readonly string _value; + + /// Initializes a new instance of . + /// is null. + public CardinalityValue(string value) + { + _value = value ?? throw new ArgumentNullException(nameof(value)); + } + + private const string SingleValue = "SINGLE"; + private const string ListValue = "LIST"; + private const string SetValue = "SET"; + + /// single. + public static CardinalityValue Single { get; } = new CardinalityValue(SingleValue); + /// list. + public static CardinalityValue List { get; } = new CardinalityValue(ListValue); + /// set. + public static CardinalityValue Set { get; } = new CardinalityValue(SetValue); + /// Determines if two values are the same. + public static bool operator ==(CardinalityValue left, CardinalityValue right) => left.Equals(right); + /// Determines if two values are not the same. + public static bool operator !=(CardinalityValue left, CardinalityValue right) => !left.Equals(right); + /// Converts a string to a . + public static implicit operator CardinalityValue(string value) => new CardinalityValue(value); + + /// + [EditorBrowsable(EditorBrowsableState.Never)] + public override bool Equals(object obj) => obj is CardinalityValue other && Equals(other); + /// + public bool Equals(CardinalityValue other) => string.Equals(_value, other._value, StringComparison.InvariantCultureIgnoreCase); + + /// + [EditorBrowsable(EditorBrowsableState.Never)] + public override int GetHashCode() => _value?.GetHashCode() ?? 0; + /// + public override string ToString() => _value; + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ClassificationAssociateOptions.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ClassificationAssociateOptions.Serialization.cs new file mode 100644 index 0000000000000..329ea01dee93e --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ClassificationAssociateOptions.Serialization.cs @@ -0,0 +1,44 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class ClassificationAssociateOptions : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + if (Optional.IsDefined(Classification)) + { + writer.WritePropertyName("classification"u8); + writer.WriteObjectValue(Classification); + } + if (Optional.IsCollectionDefined(EntityGuids)) + { + writer.WritePropertyName("entityGuids"u8); + writer.WriteStartArray(); + foreach (var item in EntityGuids) + { + writer.WriteStringValue(item); + } + writer.WriteEndArray(); + } + writer.WriteEndObject(); + } + + /// Convert into a Utf8JsonRequestContent. + internal virtual RequestContent ToRequestContent() + { + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(this); + return content; + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ClassificationAssociateOptions.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ClassificationAssociateOptions.cs new file mode 100644 index 0000000000000..34caf4aca6106 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ClassificationAssociateOptions.cs @@ -0,0 +1,42 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + /// The request content for classification association. + public partial class ClassificationAssociateOptions + { + /// Initializes a new instance of . + public ClassificationAssociateOptions() + { + EntityGuids = new ChangeTrackingList(); + } + + /// Initializes a new instance of . + /// + /// An instance of a classification; it doesn't have an identity, this object + /// exists only when associated with an entity. + /// + /// The GUID of the entity. + internal ClassificationAssociateOptions(AtlasClassification classification, IList entityGuids) + { + Classification = classification; + EntityGuids = entityGuids; + } + + /// + /// An instance of a classification; it doesn't have an identity, this object + /// exists only when associated with an entity. + /// + public AtlasClassification Classification { get; set; } + /// The GUID of the entity. + public IList EntityGuids { get; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ClassificationCategoryFilter.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ClassificationCategoryFilter.Serialization.cs new file mode 100644 index 0000000000000..3676be7ef6fda --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ClassificationCategoryFilter.Serialization.cs @@ -0,0 +1,33 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class ClassificationCategoryFilter : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + writer.WritePropertyName("classificationCategory"u8); + writer.WriteStringValue(ClassificationCategory); + writer.WritePropertyName("kind"u8); + writer.WriteStringValue(Kind); + writer.WriteEndObject(); + } + + /// Convert into a Utf8JsonRequestContent. + internal override RequestContent ToRequestContent() + { + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(this); + return content; + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ClassificationCategoryFilter.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ClassificationCategoryFilter.cs new file mode 100644 index 0000000000000..3553c6009bf76 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ClassificationCategoryFilter.cs @@ -0,0 +1,38 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + /// Classification category filter for search. + public partial class ClassificationCategoryFilter : SearchFilter + { + /// Initializes a new instance of . + /// Classification category. + /// is null. + public ClassificationCategoryFilter(string classificationCategory) + { + Argument.AssertNotNull(classificationCategory, nameof(classificationCategory)); + + Kind = "ClassificationCategoryFilter"; + ClassificationCategory = classificationCategory; + } + + /// Initializes a new instance of . + /// Discriminator. + /// Classification category. + internal ClassificationCategoryFilter(string kind, string classificationCategory) : base(kind) + { + ClassificationCategory = classificationCategory; + } + + /// Classification category. + public string ClassificationCategory { get; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ClassificationFilter.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ClassificationFilter.Serialization.cs new file mode 100644 index 0000000000000..74bcbfe5a977a --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ClassificationFilter.Serialization.cs @@ -0,0 +1,38 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class ClassificationFilter : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + writer.WritePropertyName("classification"u8); + writer.WriteStringValue(Classification); + if (Optional.IsDefined(IncludeSubClassifications)) + { + writer.WritePropertyName("includeSubClassifications"u8); + writer.WriteBooleanValue(IncludeSubClassifications.Value); + } + writer.WritePropertyName("kind"u8); + writer.WriteStringValue(Kind); + writer.WriteEndObject(); + } + + /// Convert into a Utf8JsonRequestContent. + internal override RequestContent ToRequestContent() + { + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(this); + return content; + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ClassificationFilter.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ClassificationFilter.cs new file mode 100644 index 0000000000000..a9f04d870b11e --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ClassificationFilter.cs @@ -0,0 +1,42 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + /// Classification type filter for search. + public partial class ClassificationFilter : SearchFilter + { + /// Initializes a new instance of . + /// Classification name. + /// is null. + public ClassificationFilter(string classification) + { + Argument.AssertNotNull(classification, nameof(classification)); + + Kind = "ClassificationFilter"; + Classification = classification; + } + + /// Initializes a new instance of . + /// Discriminator. + /// Classification name. + /// Whether to include sub classifications. + internal ClassificationFilter(string kind, string classification, bool? includeSubClassifications) : base(kind) + { + Classification = classification; + IncludeSubClassifications = includeSubClassifications; + } + + /// Classification name. + public string Classification { get; } + /// Whether to include sub classifications. + public bool? IncludeSubClassifications { get; set; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/CollectionIdFilter.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/CollectionIdFilter.Serialization.cs new file mode 100644 index 0000000000000..9616a637ecc12 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/CollectionIdFilter.Serialization.cs @@ -0,0 +1,33 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class CollectionIdFilter : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + writer.WritePropertyName("collectionId"u8); + writer.WriteStringValue(CollectionId); + writer.WritePropertyName("kind"u8); + writer.WriteStringValue(Kind); + writer.WriteEndObject(); + } + + /// Convert into a Utf8JsonRequestContent. + internal override RequestContent ToRequestContent() + { + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(this); + return content; + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/CollectionIdFilter.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/CollectionIdFilter.cs new file mode 100644 index 0000000000000..5b5ed260cd61b --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/CollectionIdFilter.cs @@ -0,0 +1,38 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + /// Collection id filter for search. + public partial class CollectionIdFilter : SearchFilter + { + /// Initializes a new instance of . + /// Collection id. + /// is null. + public CollectionIdFilter(string collectionId) + { + Argument.AssertNotNull(collectionId, nameof(collectionId)); + + Kind = "CollectionIdFilter"; + CollectionId = collectionId; + } + + /// Initializes a new instance of . + /// Discriminator. + /// Collection id. + internal CollectionIdFilter(string kind, string collectionId) : base(kind) + { + CollectionId = collectionId; + } + + /// Collection id. + public string CollectionId { get; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ContactFilter.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ContactFilter.Serialization.cs new file mode 100644 index 0000000000000..8d2f8a06ada03 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ContactFilter.Serialization.cs @@ -0,0 +1,41 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class ContactFilter : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + if (Optional.IsDefined(ContactType)) + { + writer.WritePropertyName("contactType"u8); + writer.WriteStringValue(ContactType); + } + if (Optional.IsDefined(ContactId)) + { + writer.WritePropertyName("contactId"u8); + writer.WriteStringValue(ContactId); + } + writer.WritePropertyName("kind"u8); + writer.WriteStringValue(Kind); + writer.WriteEndObject(); + } + + /// Convert into a Utf8JsonRequestContent. + internal override RequestContent ToRequestContent() + { + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(this); + return content; + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ContactFilter.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ContactFilter.cs new file mode 100644 index 0000000000000..3559ac6f48c19 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ContactFilter.cs @@ -0,0 +1,34 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +namespace Azure.Analytics.Purview.DataMap +{ + /// Contact filter for search. + public partial class ContactFilter : SearchFilter + { + /// Initializes a new instance of . + public ContactFilter() + { + Kind = "ContactFilter"; + } + + /// Initializes a new instance of . + /// Discriminator. + /// Contact type. + /// Contact Id. + internal ContactFilter(string kind, string contactType, string contactId) : base(kind) + { + ContactType = contactType; + ContactId = contactId; + } + + /// Contact type. + public string ContactType { get; set; } + /// Contact Id. + public string ContactId { get; set; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ContactInfo.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ContactInfo.Serialization.cs new file mode 100644 index 0000000000000..4940a03258082 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ContactInfo.Serialization.cs @@ -0,0 +1,72 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class ContactInfo : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + if (Optional.IsDefined(Id)) + { + writer.WritePropertyName("id"u8); + writer.WriteStringValue(Id); + } + if (Optional.IsDefined(Info)) + { + writer.WritePropertyName("info"u8); + writer.WriteStringValue(Info); + } + writer.WriteEndObject(); + } + + internal static ContactInfo DeserializeContactInfo(JsonElement element) + { + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + Optional id = default; + Optional info = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("id"u8)) + { + id = property.Value.GetString(); + continue; + } + if (property.NameEquals("info"u8)) + { + info = property.Value.GetString(); + continue; + } + } + return new ContactInfo(id.Value, info.Value); + } + + /// Deserializes the model from a raw response. + /// The response to deserialize the model from. + internal static ContactInfo FromResponse(Response response) + { + using var document = JsonDocument.Parse(response.Content); + return DeserializeContactInfo(document.RootElement); + } + + /// Convert into a Utf8JsonRequestContent. + internal virtual RequestContent ToRequestContent() + { + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(this); + return content; + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ContactInfo.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ContactInfo.cs new file mode 100644 index 0000000000000..af2a911c8100a --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ContactInfo.cs @@ -0,0 +1,32 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +namespace Azure.Analytics.Purview.DataMap +{ + /// ContactInfo. + public partial class ContactInfo + { + /// Initializes a new instance of . + public ContactInfo() + { + } + + /// Initializes a new instance of . + /// Azure Active Directory object Id. + /// additional information to describe this contact. + internal ContactInfo(string id, string info) + { + Id = id; + Info = info; + } + + /// Azure Active Directory object Id. + public string Id { get; set; } + /// additional information to describe this contact. + public string Info { get; set; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ContactSearchResultValue.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ContactSearchResultValue.Serialization.cs new file mode 100644 index 0000000000000..02aa1de0a259e --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ContactSearchResultValue.Serialization.cs @@ -0,0 +1,54 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class ContactSearchResultValue + { + internal static ContactSearchResultValue DeserializeContactSearchResultValue(JsonElement element) + { + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + Optional id = default; + Optional info = default; + Optional contactType = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("id"u8)) + { + id = property.Value.GetString(); + continue; + } + if (property.NameEquals("info"u8)) + { + info = property.Value.GetString(); + continue; + } + if (property.NameEquals("contactType"u8)) + { + contactType = property.Value.GetString(); + continue; + } + } + return new ContactSearchResultValue(id.Value, info.Value, contactType.Value); + } + + /// Deserializes the model from a raw response. + /// The response to deserialize the model from. + internal static ContactSearchResultValue FromResponse(Response response) + { + using var document = JsonDocument.Parse(response.Content); + return DeserializeContactSearchResultValue(document.RootElement); + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ContactSearchResultValue.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ContactSearchResultValue.cs new file mode 100644 index 0000000000000..4216ee00710bf --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ContactSearchResultValue.cs @@ -0,0 +1,42 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +namespace Azure.Analytics.Purview.DataMap +{ + /// The contact in the search and suggest result. + public partial class ContactSearchResultValue + { + /// Initializes a new instance of . + internal ContactSearchResultValue() + { + } + + /// Initializes a new instance of . + /// The GUID of the contact. + /// The description of the contact. + /// + /// The type of the contact. It can be Expert or Owner for an entity. It can be + /// Expert or Steward for a glossary term. + /// + internal ContactSearchResultValue(string id, string info, string contactType) + { + Id = id; + Info = info; + ContactType = contactType; + } + + /// The GUID of the contact. + public string Id { get; } + /// The description of the contact. + public string Info { get; } + /// + /// The type of the contact. It can be Expert or Owner for an entity. It can be + /// Expert or Steward for a glossary term. + /// + public string ContactType { get; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/CreateTimeFilter.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/CreateTimeFilter.Serialization.cs new file mode 100644 index 0000000000000..22b1c84580263 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/CreateTimeFilter.Serialization.cs @@ -0,0 +1,40 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class CreateTimeFilter : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + writer.WritePropertyName("createTime"u8); +#if NET6_0_OR_GREATER + writer.WriteRawValue(CreateTime); +#else + using (JsonDocument document = JsonDocument.Parse(CreateTime)) + { + JsonSerializer.Serialize(writer, document.RootElement); + } +#endif + writer.WritePropertyName("kind"u8); + writer.WriteStringValue(Kind); + writer.WriteEndObject(); + } + + /// Convert into a Utf8JsonRequestContent. + internal override RequestContent ToRequestContent() + { + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(this); + return content; + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/CreateTimeFilter.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/CreateTimeFilter.cs new file mode 100644 index 0000000000000..7ca382e645253 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/CreateTimeFilter.cs @@ -0,0 +1,86 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + /// Create time filter for search. + public partial class CreateTimeFilter : SearchFilter + { + /// Initializes a new instance of . + /// + /// Either using a string 'LAST_24H|LAST_7D|LAST_30D|LAST_365D|MORE_THAN_365D', or using a map for example + /// { + /// "operator": "lt", + /// "timeThreshold": 1545580800000 + /// } + /// to represent the time filter, operator must be one of gt/lt/gte/lte + /// + /// is null. + public CreateTimeFilter(BinaryData createTime) + { + Argument.AssertNotNull(createTime, nameof(createTime)); + + Kind = "CreateTimeFilter"; + CreateTime = createTime; + } + + /// Initializes a new instance of . + /// Discriminator. + /// + /// Either using a string 'LAST_24H|LAST_7D|LAST_30D|LAST_365D|MORE_THAN_365D', or using a map for example + /// { + /// "operator": "lt", + /// "timeThreshold": 1545580800000 + /// } + /// to represent the time filter, operator must be one of gt/lt/gte/lte + /// + internal CreateTimeFilter(string kind, BinaryData createTime) : base(kind) + { + CreateTime = createTime; + } + + /// + /// Either using a string 'LAST_24H|LAST_7D|LAST_30D|LAST_365D|MORE_THAN_365D', or using a map for example + /// { + /// "operator": "lt", + /// "timeThreshold": 1545580800000 + /// } + /// to represent the time filter, operator must be one of gt/lt/gte/lte + /// + /// To assign an object to this property use . + /// + /// + /// To assign an already formatted json string to this property use . + /// + /// + /// Examples: + /// + /// + /// BinaryData.FromObjectAsJson("foo") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromString("\"foo\"") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromObjectAsJson(new { key = "value" }) + /// Creates a payload of { "key": "value" }. + /// + /// + /// BinaryData.FromString("{\"key\": \"value\"}") + /// Creates a payload of { "key": "value" }. + /// + /// + /// + /// + public BinaryData CreateTime { get; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/DataMapClient.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/DataMapClient.cs new file mode 100644 index 0000000000000..6247cce02d801 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/DataMapClient.cs @@ -0,0 +1,119 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using Azure.Core; +using Azure.Core.Pipeline; + +namespace Azure.Analytics.Purview.DataMap +{ + // Data plane generated client. + /// The DataMap service client. + public partial class DataMapClient + { + private static readonly string[] AuthorizationScopes = new string[] { "https://purview.azure.net/.default" }; + private readonly TokenCredential _tokenCredential; + private readonly HttpPipeline _pipeline; + private readonly Uri _endpoint; + + /// The ClientDiagnostics is used to provide tracing support for the client library. + internal ClientDiagnostics ClientDiagnostics { get; } + + /// The HTTP pipeline for sending and receiving REST requests and responses. + public virtual HttpPipeline Pipeline => _pipeline; + + /// Initializes a new instance of DataMapClient for mocking. + protected DataMapClient() + { + } + + /// Initializes a new instance of DataMapClient. + /// The to use. + /// A credential used to authenticate to an Azure Service. + /// or is null. + public DataMapClient(Uri endpoint, TokenCredential credential) : this(endpoint, credential, new DataMapClientOptions()) + { + } + + /// Initializes a new instance of DataMapClient. + /// The to use. + /// A credential used to authenticate to an Azure Service. + /// The options for configuring the client. + /// or is null. + public DataMapClient(Uri endpoint, TokenCredential credential, DataMapClientOptions options) + { + Argument.AssertNotNull(endpoint, nameof(endpoint)); + Argument.AssertNotNull(credential, nameof(credential)); + options ??= new DataMapClientOptions(); + + ClientDiagnostics = new ClientDiagnostics(options, true); + _tokenCredential = credential; + _pipeline = HttpPipelineBuilder.Build(options, Array.Empty(), new HttpPipelinePolicy[] { new BearerTokenAuthenticationPolicy(_tokenCredential, AuthorizationScopes) }, new ResponseClassifier()); + _endpoint = endpoint; + } + + /// Initializes a new instance of Entity. + /// The to use. + /// is null. + public virtual Entity GetEntityClient(string apiVersion = "2023-09-01") + { + Argument.AssertNotNull(apiVersion, nameof(apiVersion)); + + return new Entity(ClientDiagnostics, _pipeline, _tokenCredential, _endpoint, apiVersion); + } + + /// Initializes a new instance of Glossary. + /// The to use. + /// is null. + public virtual Glossary GetGlossaryClient(string apiVersion = "2023-09-01") + { + Argument.AssertNotNull(apiVersion, nameof(apiVersion)); + + return new Glossary(ClientDiagnostics, _pipeline, _tokenCredential, _endpoint, apiVersion); + } + + /// Initializes a new instance of Discovery. + /// The to use. + /// is null. + public virtual Discovery GetDiscoveryClient(string apiVersion = "2023-09-01") + { + Argument.AssertNotNull(apiVersion, nameof(apiVersion)); + + return new Discovery(ClientDiagnostics, _pipeline, _tokenCredential, _endpoint, apiVersion); + } + + /// Initializes a new instance of Lineage. + /// The to use. + /// is null. + public virtual Lineage GetLineageClient(string apiVersion = "2023-09-01") + { + Argument.AssertNotNull(apiVersion, nameof(apiVersion)); + + return new Lineage(ClientDiagnostics, _pipeline, _tokenCredential, _endpoint, apiVersion); + } + + /// Initializes a new instance of Relationship. + /// The to use. + /// is null. + public virtual Relationship GetRelationshipClient(string apiVersion = "2023-09-01") + { + Argument.AssertNotNull(apiVersion, nameof(apiVersion)); + + return new Relationship(ClientDiagnostics, _pipeline, _tokenCredential, _endpoint, apiVersion); + } + + /// Initializes a new instance of TypeDefinition. + /// The to use. + /// is null. + public virtual TypeDefinition GetTypeDefinitionClient(string apiVersion = "2023-09-01") + { + Argument.AssertNotNull(apiVersion, nameof(apiVersion)); + + return new TypeDefinition(ClientDiagnostics, _pipeline, _tokenCredential, _endpoint, apiVersion); + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/DataMapClientOptions.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/DataMapClientOptions.cs new file mode 100644 index 0000000000000..95298168ed12b --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/DataMapClientOptions.cs @@ -0,0 +1,37 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + /// Client options for DataMapClient. + public partial class DataMapClientOptions : ClientOptions + { + private const ServiceVersion LatestVersion = ServiceVersion.V2023_09_01; + + /// The version of the service to use. + public enum ServiceVersion + { + /// Service version "2023-09-01". + V2023_09_01 = 1, + } + + internal string Version { get; } + + /// Initializes new instance of DataMapClientOptions. + public DataMapClientOptions(ServiceVersion version = LatestVersion) + { + Version = version switch + { + ServiceVersion.V2023_09_01 => "2023-09-01", + _ => throw new NotSupportedException() + }; + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/DateFormat.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/DateFormat.Serialization.cs new file mode 100644 index 0000000000000..48bf13c90b6a3 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/DateFormat.Serialization.cs @@ -0,0 +1,196 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using System.Text.Json; +using Azure; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class DateFormat : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + if (Optional.IsCollectionDefined(AvailableLocales)) + { + writer.WritePropertyName("availableLocales"u8); + writer.WriteStartArray(); + foreach (var item in AvailableLocales) + { + writer.WriteStringValue(item); + } + writer.WriteEndArray(); + } + if (Optional.IsDefined(Calendar)) + { + writer.WritePropertyName("calendar"u8); + writer.WriteNumberValue(Calendar.Value); + } + if (Optional.IsDefined(DateInstance)) + { + writer.WritePropertyName("dateInstance"u8); + writer.WriteObjectValue(DateInstance); + } + if (Optional.IsDefined(DateTimeInstance)) + { + writer.WritePropertyName("dateTimeInstance"u8); + writer.WriteObjectValue(DateTimeInstance); + } + if (Optional.IsDefined(Instance)) + { + writer.WritePropertyName("instance"u8); + writer.WriteObjectValue(Instance); + } + if (Optional.IsDefined(Lenient)) + { + writer.WritePropertyName("lenient"u8); + writer.WriteBooleanValue(Lenient.Value); + } + if (Optional.IsDefined(NumberFormat)) + { + writer.WritePropertyName("numberFormat"u8); + writer.WriteObjectValue(NumberFormat); + } + if (Optional.IsDefined(TimeInstance)) + { + writer.WritePropertyName("timeInstance"u8); + writer.WriteObjectValue(TimeInstance); + } + if (Optional.IsDefined(TimeZone)) + { + writer.WritePropertyName("timeZone"u8); + writer.WriteObjectValue(TimeZone); + } + writer.WriteEndObject(); + } + + internal static DateFormat DeserializeDateFormat(JsonElement element) + { + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + Optional> availableLocales = default; + Optional calendar = default; + Optional dateInstance = default; + Optional dateTimeInstance = default; + Optional instance = default; + Optional lenient = default; + Optional numberFormat = default; + Optional timeInstance = default; + Optional timeZone = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("availableLocales"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(item.GetString()); + } + availableLocales = array; + continue; + } + if (property.NameEquals("calendar"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + calendar = property.Value.GetSingle(); + continue; + } + if (property.NameEquals("dateInstance"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + dateInstance = DeserializeDateFormat(property.Value); + continue; + } + if (property.NameEquals("dateTimeInstance"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + dateTimeInstance = DeserializeDateFormat(property.Value); + continue; + } + if (property.NameEquals("instance"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + instance = DeserializeDateFormat(property.Value); + continue; + } + if (property.NameEquals("lenient"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + lenient = property.Value.GetBoolean(); + continue; + } + if (property.NameEquals("numberFormat"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + numberFormat = NumberFormat.DeserializeNumberFormat(property.Value); + continue; + } + if (property.NameEquals("timeInstance"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + timeInstance = DeserializeDateFormat(property.Value); + continue; + } + if (property.NameEquals("timeZone"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + timeZone = TimeZone.DeserializeTimeZone(property.Value); + continue; + } + } + return new DateFormat(Optional.ToList(availableLocales), Optional.ToNullable(calendar), dateInstance.Value, dateTimeInstance.Value, instance.Value, Optional.ToNullable(lenient), numberFormat.Value, timeInstance.Value, timeZone.Value); + } + + /// Deserializes the model from a raw response. + /// The response to deserialize the model from. + internal static DateFormat FromResponse(Response response) + { + using var document = JsonDocument.Parse(response.Content); + return DeserializeDateFormat(document.RootElement); + } + + /// Convert into a Utf8JsonRequestContent. + internal virtual RequestContent ToRequestContent() + { + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(this); + return content; + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/DateFormat.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/DateFormat.cs new file mode 100644 index 0000000000000..0fe28557fada6 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/DateFormat.cs @@ -0,0 +1,64 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + /// The date format. + public partial class DateFormat + { + /// Initializes a new instance of . + public DateFormat() + { + AvailableLocales = new ChangeTrackingList(); + } + + /// Initializes a new instance of . + /// An array of available locales. + /// Calendar. + /// The date format. + /// The date format. + /// The date format. + /// Determines the leniency of the date format. + /// The number format. + /// The date format. + /// The timezone information. + internal DateFormat(IList availableLocales, float? calendar, DateFormat dateInstance, DateFormat dateTimeInstance, DateFormat instance, bool? lenient, NumberFormat numberFormat, DateFormat timeInstance, TimeZone timeZone) + { + AvailableLocales = availableLocales; + Calendar = calendar; + DateInstance = dateInstance; + DateTimeInstance = dateTimeInstance; + Instance = instance; + Lenient = lenient; + NumberFormat = numberFormat; + TimeInstance = timeInstance; + TimeZone = timeZone; + } + + /// An array of available locales. + public IList AvailableLocales { get; } + /// Calendar. + public float? Calendar { get; set; } + /// The date format. + public DateFormat DateInstance { get; set; } + /// The date format. + public DateFormat DateTimeInstance { get; set; } + /// The date format. + public DateFormat Instance { get; set; } + /// Determines the leniency of the date format. + public bool? Lenient { get; set; } + /// The number format. + public NumberFormat NumberFormat { get; set; } + /// The date format. + public DateFormat TimeInstance { get; set; } + /// The timezone information. + public TimeZone TimeZone { get; set; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/Discovery.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/Discovery.cs new file mode 100644 index 0000000000000..21b4a775b8631 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/Discovery.cs @@ -0,0 +1,442 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Threading; +using System.Threading.Tasks; +using Azure; +using Azure.Core; +using Azure.Core.Pipeline; + +namespace Azure.Analytics.Purview.DataMap +{ + // Data plane generated sub-client. + /// The Discovery sub-client. + public partial class Discovery + { + private static readonly string[] AuthorizationScopes = new string[] { "https://purview.azure.net/.default" }; + private readonly TokenCredential _tokenCredential; + private readonly HttpPipeline _pipeline; + private readonly Uri _endpoint; + private readonly string _apiVersion; + + /// The ClientDiagnostics is used to provide tracing support for the client library. + internal ClientDiagnostics ClientDiagnostics { get; } + + /// The HTTP pipeline for sending and receiving REST requests and responses. + public virtual HttpPipeline Pipeline => _pipeline; + + /// Initializes a new instance of Discovery for mocking. + protected Discovery() + { + } + + /// Initializes a new instance of Discovery. + /// The handler for diagnostic messaging in the client. + /// The HTTP pipeline for sending and receiving REST requests and responses. + /// The token credential to copy. + /// The to use. + /// The to use. + internal Discovery(ClientDiagnostics clientDiagnostics, HttpPipeline pipeline, TokenCredential tokenCredential, Uri endpoint, string apiVersion) + { + ClientDiagnostics = clientDiagnostics; + _pipeline = pipeline; + _tokenCredential = tokenCredential; + _endpoint = endpoint; + _apiVersion = apiVersion; + } + + /// Get data using search. + /// An object specifying the search criteria. + /// The cancellation token to use. + /// is null. + /// + public virtual async Task> QueryAsync(SearchOptions searchRequest, CancellationToken cancellationToken = default) + { + Argument.AssertNotNull(searchRequest, nameof(searchRequest)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = searchRequest.ToRequestContent(); + Response response = await QueryAsync(content, context).ConfigureAwait(false); + return Response.FromValue(SearchResult.FromResponse(response), response); + } + + /// Get data using search. + /// An object specifying the search criteria. + /// The cancellation token to use. + /// is null. + /// + public virtual Response Query(SearchOptions searchRequest, CancellationToken cancellationToken = default) + { + Argument.AssertNotNull(searchRequest, nameof(searchRequest)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = searchRequest.ToRequestContent(); + Response response = Query(content, context); + return Response.FromValue(SearchResult.FromResponse(response), response); + } + + /// + /// [Protocol Method] Get data using search. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The content to send as the body of the request. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task QueryAsync(RequestContent content, RequestContext context = null) + { + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Discovery.Query"); + scope.Start(); + try + { + using HttpMessage message = CreateQueryRequest(content, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Get data using search. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The content to send as the body of the request. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response Query(RequestContent content, RequestContext context = null) + { + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Discovery.Query"); + scope.Start(); + try + { + using HttpMessage message = CreateQueryRequest(content, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Get search suggestions by query criteria. + /// An object specifying the suggest criteria. + /// The cancellation token to use. + /// is null. + /// + public virtual async Task> SuggestAsync(SuggestOptions suggestRequest, CancellationToken cancellationToken = default) + { + Argument.AssertNotNull(suggestRequest, nameof(suggestRequest)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = suggestRequest.ToRequestContent(); + Response response = await SuggestAsync(content, context).ConfigureAwait(false); + return Response.FromValue(SuggestResult.FromResponse(response), response); + } + + /// Get search suggestions by query criteria. + /// An object specifying the suggest criteria. + /// The cancellation token to use. + /// is null. + /// + public virtual Response Suggest(SuggestOptions suggestRequest, CancellationToken cancellationToken = default) + { + Argument.AssertNotNull(suggestRequest, nameof(suggestRequest)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = suggestRequest.ToRequestContent(); + Response response = Suggest(content, context); + return Response.FromValue(SuggestResult.FromResponse(response), response); + } + + /// + /// [Protocol Method] Get search suggestions by query criteria. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The content to send as the body of the request. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task SuggestAsync(RequestContent content, RequestContext context = null) + { + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Discovery.Suggest"); + scope.Start(); + try + { + using HttpMessage message = CreateSuggestRequest(content, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Get search suggestions by query criteria. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The content to send as the body of the request. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response Suggest(RequestContent content, RequestContext context = null) + { + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Discovery.Suggest"); + scope.Start(); + try + { + using HttpMessage message = CreateSuggestRequest(content, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Get auto complete options. + /// An object specifying the autocomplete criteria. + /// The cancellation token to use. + /// is null. + /// + public virtual async Task> AutoCompleteAsync(AutoCompleteOptions autoCompleteRequest, CancellationToken cancellationToken = default) + { + Argument.AssertNotNull(autoCompleteRequest, nameof(autoCompleteRequest)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = autoCompleteRequest.ToRequestContent(); + Response response = await AutoCompleteAsync(content, context).ConfigureAwait(false); + return Response.FromValue(AutoCompleteResult.FromResponse(response), response); + } + + /// Get auto complete options. + /// An object specifying the autocomplete criteria. + /// The cancellation token to use. + /// is null. + /// + public virtual Response AutoComplete(AutoCompleteOptions autoCompleteRequest, CancellationToken cancellationToken = default) + { + Argument.AssertNotNull(autoCompleteRequest, nameof(autoCompleteRequest)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = autoCompleteRequest.ToRequestContent(); + Response response = AutoComplete(content, context); + return Response.FromValue(AutoCompleteResult.FromResponse(response), response); + } + + /// + /// [Protocol Method] Get auto complete options. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The content to send as the body of the request. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task AutoCompleteAsync(RequestContent content, RequestContext context = null) + { + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Discovery.AutoComplete"); + scope.Start(); + try + { + using HttpMessage message = CreateAutoCompleteRequest(content, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Get auto complete options. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The content to send as the body of the request. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response AutoComplete(RequestContent content, RequestContext context = null) + { + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Discovery.AutoComplete"); + scope.Start(); + try + { + using HttpMessage message = CreateAutoCompleteRequest(content, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + internal HttpMessage CreateQueryRequest(RequestContent content, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier200); + var request = message.Request; + request.Method = RequestMethod.Post; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/search/query", false); + uri.AppendQuery("api-version", _apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + request.Headers.Add("Content-Type", "application/json"); + request.Content = content; + return message; + } + + internal HttpMessage CreateSuggestRequest(RequestContent content, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier200); + var request = message.Request; + request.Method = RequestMethod.Post; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/search/suggest", false); + uri.AppendQuery("api-version", _apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + request.Headers.Add("Content-Type", "application/json"); + request.Content = content; + return message; + } + + internal HttpMessage CreateAutoCompleteRequest(RequestContent content, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier200); + var request = message.Request; + request.Method = RequestMethod.Post; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/search/autocomplete", false); + uri.AppendQuery("api-version", _apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + request.Headers.Add("Content-Type", "application/json"); + request.Content = content; + return message; + } + + private static RequestContext DefaultRequestContext = new RequestContext(); + internal static RequestContext FromCancellationToken(CancellationToken cancellationToken = default) + { + if (!cancellationToken.CanBeCanceled) + { + return DefaultRequestContext; + } + + return new RequestContext() { CancellationToken = cancellationToken }; + } + + private static ResponseClassifier _responseClassifier200; + private static ResponseClassifier ResponseClassifier200 => _responseClassifier200 ??= new StatusCodeClassifier(stackalloc ushort[] { 200 }); + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/Docs/Discovery.xml b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/Docs/Discovery.xml new file mode 100644 index 0000000000000..7fadecddb45e6 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/Docs/Discovery.xml @@ -0,0 +1,633 @@ + + + + + +This sample shows how to call QueryAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Discovery client = new DataMapClient(endpoint, credential).GetDiscoveryClient(apiVersion: "2023-09-01"); + +SearchOptions searchRequest = new SearchOptions(); +Response response = await client.QueryAsync(searchRequest); +]]> +This sample shows how to call QueryAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Discovery client = new DataMapClient(endpoint, credential).GetDiscoveryClient(apiVersion: "2023-09-01"); + +SearchOptions searchRequest = new SearchOptions +{ + Keywords = "", + Limit = 1234, + ContinuationToken = "", + Orderby = { BinaryData.FromObjectAsJson(new object()) }, + Filter = BinaryData.FromObjectAsJson(new object()), + Facets = {new SearchFacetItem + { + Count = 1234, + Facet = "", + Sort = new SearchFacetSort + { + Count = SearchSortOrder.Ascend, + Value = SearchSortOrder.Ascend, + }, + }}, + TaxonomySetting = new SearchTaxonomySetting + { + AssetTypes = { "" }, + Facet = default, + }, +}; +Response response = await client.QueryAsync(searchRequest); +]]> + + + +This sample shows how to call Query. +"); +TokenCredential credential = new DefaultAzureCredential(); +Discovery client = new DataMapClient(endpoint, credential).GetDiscoveryClient(apiVersion: "2023-09-01"); + +SearchOptions searchRequest = new SearchOptions(); +Response response = client.Query(searchRequest); +]]> +This sample shows how to call Query with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Discovery client = new DataMapClient(endpoint, credential).GetDiscoveryClient(apiVersion: "2023-09-01"); + +SearchOptions searchRequest = new SearchOptions +{ + Keywords = "", + Limit = 1234, + ContinuationToken = "", + Orderby = { BinaryData.FromObjectAsJson(new object()) }, + Filter = BinaryData.FromObjectAsJson(new object()), + Facets = {new SearchFacetItem + { + Count = 1234, + Facet = "", + Sort = new SearchFacetSort + { + Count = SearchSortOrder.Ascend, + Value = SearchSortOrder.Ascend, + }, + }}, + TaxonomySetting = new SearchTaxonomySetting + { + AssetTypes = { "" }, + Facet = default, + }, +}; +Response response = client.Query(searchRequest); +]]> + + + +This sample shows how to call QueryAsync and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Discovery client = new DataMapClient(endpoint, credential).GetDiscoveryClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object()); +Response response = await client.QueryAsync(content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call QueryAsync with all request content and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Discovery client = new DataMapClient(endpoint, credential).GetDiscoveryClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new +{ + keywords = "", + limit = 1234, + continuationToken = "", + orderby = new object[] + { + new object() + }, + filter = new object(), + facets = new object[] + { + new + { + count = 1234, + facet = "", + sort = new + { + count = "asc", + value = "asc", + }, + } + }, + taxonomySetting = new + { + assetTypes = new object[] + { + "" + }, + }, +}); +Response response = await client.QueryAsync(content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("@search.count").ToString()); +Console.WriteLine(result.GetProperty("@search.count.approximate").ToString()); +Console.WriteLine(result.GetProperty("continuationToken").ToString()); +Console.WriteLine(result.GetProperty("@search.facets").GetProperty("entityType")[0].GetProperty("count").ToString()); +Console.WriteLine(result.GetProperty("@search.facets").GetProperty("entityType")[0].GetProperty("value").ToString()); +Console.WriteLine(result.GetProperty("@search.facets").GetProperty("assetType")[0].GetProperty("count").ToString()); +Console.WriteLine(result.GetProperty("@search.facets").GetProperty("assetType")[0].GetProperty("value").ToString()); +Console.WriteLine(result.GetProperty("@search.facets").GetProperty("classification")[0].GetProperty("count").ToString()); +Console.WriteLine(result.GetProperty("@search.facets").GetProperty("classification")[0].GetProperty("value").ToString()); +Console.WriteLine(result.GetProperty("@search.facets").GetProperty("term")[0].GetProperty("count").ToString()); +Console.WriteLine(result.GetProperty("@search.facets").GetProperty("term")[0].GetProperty("value").ToString()); +Console.WriteLine(result.GetProperty("@search.facets").GetProperty("contactId")[0].GetProperty("count").ToString()); +Console.WriteLine(result.GetProperty("@search.facets").GetProperty("contactId")[0].GetProperty("value").ToString()); +Console.WriteLine(result.GetProperty("@search.facets").GetProperty("contactType")[0].GetProperty("count").ToString()); +Console.WriteLine(result.GetProperty("@search.facets").GetProperty("contactType")[0].GetProperty("value").ToString()); +Console.WriteLine(result.GetProperty("@search.facets").GetProperty("label")[0].GetProperty("count").ToString()); +Console.WriteLine(result.GetProperty("@search.facets").GetProperty("label")[0].GetProperty("value").ToString()); +Console.WriteLine(result.GetProperty("@search.facets").GetProperty("glossaryType")[0].GetProperty("count").ToString()); +Console.WriteLine(result.GetProperty("@search.facets").GetProperty("glossaryType")[0].GetProperty("value").ToString()); +Console.WriteLine(result.GetProperty("@search.facets").GetProperty("termStatus")[0].GetProperty("count").ToString()); +Console.WriteLine(result.GetProperty("@search.facets").GetProperty("termStatus")[0].GetProperty("value").ToString()); +Console.WriteLine(result.GetProperty("@search.facets").GetProperty("termTemplate")[0].GetProperty("count").ToString()); +Console.WriteLine(result.GetProperty("@search.facets").GetProperty("termTemplate")[0].GetProperty("value").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("@search.score").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("@search.highlights").GetProperty("id")[0].ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("@search.highlights").GetProperty("qualifiedName")[0].ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("@search.highlights").GetProperty("name")[0].ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("@search.highlights").GetProperty("description")[0].ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("@search.highlights").GetProperty("entityType")[0].ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("objectType").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("qualifiedName").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("entityType").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("endorsement").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("owner").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("classification")[0].ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("label")[0].ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("term")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("term")[0].GetProperty("glossaryName").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("term")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("contact")[0].GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("contact")[0].GetProperty("info").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("contact")[0].GetProperty("contactType").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("assetType")[0].ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("glossaryType").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("glossary").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("termStatus").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("termTemplate")[0].ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("longDescription").ToString()); +]]> + + + +This sample shows how to call Query and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Discovery client = new DataMapClient(endpoint, credential).GetDiscoveryClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object()); +Response response = client.Query(content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call Query with all request content and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Discovery client = new DataMapClient(endpoint, credential).GetDiscoveryClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new +{ + keywords = "", + limit = 1234, + continuationToken = "", + orderby = new object[] + { + new object() + }, + filter = new object(), + facets = new object[] + { + new + { + count = 1234, + facet = "", + sort = new + { + count = "asc", + value = "asc", + }, + } + }, + taxonomySetting = new + { + assetTypes = new object[] + { + "" + }, + }, +}); +Response response = client.Query(content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("@search.count").ToString()); +Console.WriteLine(result.GetProperty("@search.count.approximate").ToString()); +Console.WriteLine(result.GetProperty("continuationToken").ToString()); +Console.WriteLine(result.GetProperty("@search.facets").GetProperty("entityType")[0].GetProperty("count").ToString()); +Console.WriteLine(result.GetProperty("@search.facets").GetProperty("entityType")[0].GetProperty("value").ToString()); +Console.WriteLine(result.GetProperty("@search.facets").GetProperty("assetType")[0].GetProperty("count").ToString()); +Console.WriteLine(result.GetProperty("@search.facets").GetProperty("assetType")[0].GetProperty("value").ToString()); +Console.WriteLine(result.GetProperty("@search.facets").GetProperty("classification")[0].GetProperty("count").ToString()); +Console.WriteLine(result.GetProperty("@search.facets").GetProperty("classification")[0].GetProperty("value").ToString()); +Console.WriteLine(result.GetProperty("@search.facets").GetProperty("term")[0].GetProperty("count").ToString()); +Console.WriteLine(result.GetProperty("@search.facets").GetProperty("term")[0].GetProperty("value").ToString()); +Console.WriteLine(result.GetProperty("@search.facets").GetProperty("contactId")[0].GetProperty("count").ToString()); +Console.WriteLine(result.GetProperty("@search.facets").GetProperty("contactId")[0].GetProperty("value").ToString()); +Console.WriteLine(result.GetProperty("@search.facets").GetProperty("contactType")[0].GetProperty("count").ToString()); +Console.WriteLine(result.GetProperty("@search.facets").GetProperty("contactType")[0].GetProperty("value").ToString()); +Console.WriteLine(result.GetProperty("@search.facets").GetProperty("label")[0].GetProperty("count").ToString()); +Console.WriteLine(result.GetProperty("@search.facets").GetProperty("label")[0].GetProperty("value").ToString()); +Console.WriteLine(result.GetProperty("@search.facets").GetProperty("glossaryType")[0].GetProperty("count").ToString()); +Console.WriteLine(result.GetProperty("@search.facets").GetProperty("glossaryType")[0].GetProperty("value").ToString()); +Console.WriteLine(result.GetProperty("@search.facets").GetProperty("termStatus")[0].GetProperty("count").ToString()); +Console.WriteLine(result.GetProperty("@search.facets").GetProperty("termStatus")[0].GetProperty("value").ToString()); +Console.WriteLine(result.GetProperty("@search.facets").GetProperty("termTemplate")[0].GetProperty("count").ToString()); +Console.WriteLine(result.GetProperty("@search.facets").GetProperty("termTemplate")[0].GetProperty("value").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("@search.score").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("@search.highlights").GetProperty("id")[0].ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("@search.highlights").GetProperty("qualifiedName")[0].ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("@search.highlights").GetProperty("name")[0].ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("@search.highlights").GetProperty("description")[0].ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("@search.highlights").GetProperty("entityType")[0].ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("objectType").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("qualifiedName").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("entityType").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("endorsement").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("owner").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("classification")[0].ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("label")[0].ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("term")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("term")[0].GetProperty("glossaryName").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("term")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("contact")[0].GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("contact")[0].GetProperty("info").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("contact")[0].GetProperty("contactType").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("assetType")[0].ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("glossaryType").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("glossary").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("termStatus").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("termTemplate")[0].ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("longDescription").ToString()); +]]> + + + +This sample shows how to call SuggestAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Discovery client = new DataMapClient(endpoint, credential).GetDiscoveryClient(apiVersion: "2023-09-01"); + +SuggestOptions suggestRequest = new SuggestOptions(); +Response response = await client.SuggestAsync(suggestRequest); +]]> +This sample shows how to call SuggestAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Discovery client = new DataMapClient(endpoint, credential).GetDiscoveryClient(apiVersion: "2023-09-01"); + +SuggestOptions suggestRequest = new SuggestOptions +{ + Keywords = "", + Limit = 1234, + Filter = new AndFilter(new SearchFilter[] + { + default + }), +}; +Response response = await client.SuggestAsync(suggestRequest); +]]> + + + +This sample shows how to call Suggest. +"); +TokenCredential credential = new DefaultAzureCredential(); +Discovery client = new DataMapClient(endpoint, credential).GetDiscoveryClient(apiVersion: "2023-09-01"); + +SuggestOptions suggestRequest = new SuggestOptions(); +Response response = client.Suggest(suggestRequest); +]]> +This sample shows how to call Suggest with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Discovery client = new DataMapClient(endpoint, credential).GetDiscoveryClient(apiVersion: "2023-09-01"); + +SuggestOptions suggestRequest = new SuggestOptions +{ + Keywords = "", + Limit = 1234, + Filter = new AndFilter(new SearchFilter[] + { + default + }), +}; +Response response = client.Suggest(suggestRequest); +]]> + + + +This sample shows how to call SuggestAsync and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Discovery client = new DataMapClient(endpoint, credential).GetDiscoveryClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object()); +Response response = await client.SuggestAsync(content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call SuggestAsync with all request content and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Discovery client = new DataMapClient(endpoint, credential).GetDiscoveryClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new +{ + keywords = "", + limit = 1234, + filter = new + { + and = new object[] + { + null + }, + kind = "AndFilter", + }, +}); +Response response = await client.SuggestAsync(content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("value")[0].GetProperty("@search.score").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("@search.text").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("objectType").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("qualifiedName").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("entityType").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("endorsement").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("owner").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("classification")[0].ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("label")[0].ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("term")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("term")[0].GetProperty("glossaryName").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("term")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("contact")[0].GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("contact")[0].GetProperty("info").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("contact")[0].GetProperty("contactType").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("assetType")[0].ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("glossaryType").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("glossary").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("termStatus").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("termTemplate")[0].ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("longDescription").ToString()); +]]> + + + +This sample shows how to call Suggest and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Discovery client = new DataMapClient(endpoint, credential).GetDiscoveryClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object()); +Response response = client.Suggest(content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call Suggest with all request content and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Discovery client = new DataMapClient(endpoint, credential).GetDiscoveryClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new +{ + keywords = "", + limit = 1234, + filter = new + { + and = new object[] + { + null + }, + kind = "AndFilter", + }, +}); +Response response = client.Suggest(content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("value")[0].GetProperty("@search.score").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("@search.text").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("objectType").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("qualifiedName").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("entityType").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("endorsement").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("owner").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("classification")[0].ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("label")[0].ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("term")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("term")[0].GetProperty("glossaryName").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("term")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("contact")[0].GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("contact")[0].GetProperty("info").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("contact")[0].GetProperty("contactType").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("assetType")[0].ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("glossaryType").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("glossary").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("termStatus").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("termTemplate")[0].ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("longDescription").ToString()); +]]> + + + +This sample shows how to call AutoCompleteAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Discovery client = new DataMapClient(endpoint, credential).GetDiscoveryClient(apiVersion: "2023-09-01"); + +AutoCompleteOptions autoCompleteRequest = new AutoCompleteOptions(); +Response response = await client.AutoCompleteAsync(autoCompleteRequest); +]]> +This sample shows how to call AutoCompleteAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Discovery client = new DataMapClient(endpoint, credential).GetDiscoveryClient(apiVersion: "2023-09-01"); + +AutoCompleteOptions autoCompleteRequest = new AutoCompleteOptions +{ + Keywords = "", + Limit = 1234, + Filter = new AndFilter(new SearchFilter[] + { + default + }), +}; +Response response = await client.AutoCompleteAsync(autoCompleteRequest); +]]> + + + +This sample shows how to call AutoComplete. +"); +TokenCredential credential = new DefaultAzureCredential(); +Discovery client = new DataMapClient(endpoint, credential).GetDiscoveryClient(apiVersion: "2023-09-01"); + +AutoCompleteOptions autoCompleteRequest = new AutoCompleteOptions(); +Response response = client.AutoComplete(autoCompleteRequest); +]]> +This sample shows how to call AutoComplete with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Discovery client = new DataMapClient(endpoint, credential).GetDiscoveryClient(apiVersion: "2023-09-01"); + +AutoCompleteOptions autoCompleteRequest = new AutoCompleteOptions +{ + Keywords = "", + Limit = 1234, + Filter = new AndFilter(new SearchFilter[] + { + default + }), +}; +Response response = client.AutoComplete(autoCompleteRequest); +]]> + + + +This sample shows how to call AutoCompleteAsync and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Discovery client = new DataMapClient(endpoint, credential).GetDiscoveryClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object()); +Response response = await client.AutoCompleteAsync(content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call AutoCompleteAsync with all request content and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Discovery client = new DataMapClient(endpoint, credential).GetDiscoveryClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new +{ + keywords = "", + limit = 1234, + filter = new + { + and = new object[] + { + null + }, + kind = "AndFilter", + }, +}); +Response response = await client.AutoCompleteAsync(content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("value")[0].GetProperty("text").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("queryPlusText").ToString()); +]]> + + + +This sample shows how to call AutoComplete and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Discovery client = new DataMapClient(endpoint, credential).GetDiscoveryClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object()); +Response response = client.AutoComplete(content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call AutoComplete with all request content and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Discovery client = new DataMapClient(endpoint, credential).GetDiscoveryClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new +{ + keywords = "", + limit = 1234, + filter = new + { + and = new object[] + { + null + }, + kind = "AndFilter", + }, +}); +Response response = client.AutoComplete(content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("value")[0].GetProperty("text").ToString()); +Console.WriteLine(result.GetProperty("value")[0].GetProperty("queryPlusText").ToString()); +]]> + + + \ No newline at end of file diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/Docs/Entity.xml b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/Docs/Entity.xml new file mode 100644 index 0000000000000..f0320ea4bd36d --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/Docs/Entity.xml @@ -0,0 +1,6649 @@ + + + + + +This sample shows how to call CreateOrUpdateAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +AtlasEntityWithExtInfo entity = new AtlasEntityWithExtInfo(); +Response response = await client.CreateOrUpdateAsync(entity); +]]> +This sample shows how to call CreateOrUpdateAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +AtlasEntityWithExtInfo entity = new AtlasEntityWithExtInfo +{ + ReferredEntities = + { + ["key"] = new AtlasEntity + { + Attributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + TypeName = "", + LastModifiedTS = "", + BusinessAttributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + Classifications = {new AtlasClassification + { + Attributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + TypeName = "", + LastModifiedTS = "", + EntityGuid = "", + EntityStatus = EntityStatus.Active, + RemovePropagationsOnEntityDelete = true, + ValidityPeriods = {new TimeBoundary + { + EndTime = "", + StartTime = "", + TimeZone = "", + }}, + }}, + CreateTime = 1234L, + CreatedBy = "", + CustomAttributes = + { + ["key"] = "" + }, + Guid = "", + HomeId = "", + IsIncomplete = true, + Labels = {""}, + Meanings = {new AtlasTermAssignmentHeader + { + Confidence = 1234, + CreatedBy = "", + Description = "", + DisplayText = "", + Expression = "", + RelationGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), + Status = AtlasTermAssignmentStatus.Discovered, + Steward = "", + TermGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), + }}, + ProvenanceType = 1234, + Proxy = true, + RelationshipAttributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + Status = EntityStatus.Active, + UpdateTime = 1234L, + UpdatedBy = "", + Version = 1234L, + Contacts = + { + ["key"] = {new ContactInfo + { + Id = "", + Info = "", + }} + }, + } + }, + Entity = default, +}; +Response response = await client.CreateOrUpdateAsync(entity, businessAttributeUpdateBehavior: BusinessAttributeUpdateBehavior.Ignore, collectionId: ""); +]]> + + + +This sample shows how to call CreateOrUpdate. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +AtlasEntityWithExtInfo entity = new AtlasEntityWithExtInfo(); +Response response = client.CreateOrUpdate(entity); +]]> +This sample shows how to call CreateOrUpdate with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +AtlasEntityWithExtInfo entity = new AtlasEntityWithExtInfo +{ + ReferredEntities = + { + ["key"] = new AtlasEntity + { + Attributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + TypeName = "", + LastModifiedTS = "", + BusinessAttributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + Classifications = {new AtlasClassification + { + Attributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + TypeName = "", + LastModifiedTS = "", + EntityGuid = "", + EntityStatus = EntityStatus.Active, + RemovePropagationsOnEntityDelete = true, + ValidityPeriods = {new TimeBoundary + { + EndTime = "", + StartTime = "", + TimeZone = "", + }}, + }}, + CreateTime = 1234L, + CreatedBy = "", + CustomAttributes = + { + ["key"] = "" + }, + Guid = "", + HomeId = "", + IsIncomplete = true, + Labels = {""}, + Meanings = {new AtlasTermAssignmentHeader + { + Confidence = 1234, + CreatedBy = "", + Description = "", + DisplayText = "", + Expression = "", + RelationGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), + Status = AtlasTermAssignmentStatus.Discovered, + Steward = "", + TermGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), + }}, + ProvenanceType = 1234, + Proxy = true, + RelationshipAttributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + Status = EntityStatus.Active, + UpdateTime = 1234L, + UpdatedBy = "", + Version = 1234L, + Contacts = + { + ["key"] = {new ContactInfo + { + Id = "", + Info = "", + }} + }, + } + }, + Entity = default, +}; +Response response = client.CreateOrUpdate(entity, businessAttributeUpdateBehavior: BusinessAttributeUpdateBehavior.Ignore, collectionId: ""); +]]> + + + +This sample shows how to call CreateOrUpdateAsync and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object()); +Response response = await client.CreateOrUpdateAsync(content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call CreateOrUpdateAsync with all parameters and request content and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new +{ + referredEntities = new + { + key = new + { + attributes = new + { + key = new object(), + }, + typeName = "", + lastModifiedTS = "", + businessAttributes = new + { + key = new object(), + }, + classifications = new object[] + { + new + { + attributes = new + { + key = new object(), + }, + typeName = "", + lastModifiedTS = "", + entityGuid = "", + entityStatus = "ACTIVE", + removePropagationsOnEntityDelete = true, + validityPeriods = new object[] + { + new + { + endTime = "", + startTime = "", + timeZone = "", + } + }, + } + }, + createTime = 1234L, + createdBy = "", + customAttributes = new + { + key = "", + }, + guid = "", + homeId = "", + isIncomplete = true, + labels = new object[] + { + "" + }, + meanings = new object[] + { + new + { + confidence = 1234, + createdBy = "", + description = "", + displayText = "", + expression = "", + relationGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", + status = "DISCOVERED", + steward = "", + termGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", + } + }, + provenanceType = 1234, + proxy = true, + relationshipAttributes = new + { + key = new object(), + }, + status = "ACTIVE", + updateTime = 1234L, + updatedBy = "", + version = 1234L, + contacts = new + { + key = new object[] + { + new + { + id = "", + info = "", + } + }, + }, + }, + }, +}); +Response response = await client.CreateOrUpdateAsync(content, businessAttributeUpdateBehavior: "ignore", collectionId: ""); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("guidAssignments").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classificationNames")[0].ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("isIncomplete").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("labels")[0].ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meaningNames")[0].ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("confidence").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classificationNames")[0].ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("isIncomplete").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("labels")[0].ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meaningNames")[0].ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("confidence").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("status").ToString()); +]]> + + + +This sample shows how to call CreateOrUpdate and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object()); +Response response = client.CreateOrUpdate(content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call CreateOrUpdate with all parameters and request content and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new +{ + referredEntities = new + { + key = new + { + attributes = new + { + key = new object(), + }, + typeName = "", + lastModifiedTS = "", + businessAttributes = new + { + key = new object(), + }, + classifications = new object[] + { + new + { + attributes = new + { + key = new object(), + }, + typeName = "", + lastModifiedTS = "", + entityGuid = "", + entityStatus = "ACTIVE", + removePropagationsOnEntityDelete = true, + validityPeriods = new object[] + { + new + { + endTime = "", + startTime = "", + timeZone = "", + } + }, + } + }, + createTime = 1234L, + createdBy = "", + customAttributes = new + { + key = "", + }, + guid = "", + homeId = "", + isIncomplete = true, + labels = new object[] + { + "" + }, + meanings = new object[] + { + new + { + confidence = 1234, + createdBy = "", + description = "", + displayText = "", + expression = "", + relationGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", + status = "DISCOVERED", + steward = "", + termGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", + } + }, + provenanceType = 1234, + proxy = true, + relationshipAttributes = new + { + key = new object(), + }, + status = "ACTIVE", + updateTime = 1234L, + updatedBy = "", + version = 1234L, + contacts = new + { + key = new object[] + { + new + { + id = "", + info = "", + } + }, + }, + }, + }, +}); +Response response = client.CreateOrUpdate(content, businessAttributeUpdateBehavior: "ignore", collectionId: ""); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("guidAssignments").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classificationNames")[0].ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("isIncomplete").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("labels")[0].ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meaningNames")[0].ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("confidence").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classificationNames")[0].ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("isIncomplete").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("labels")[0].ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meaningNames")[0].ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("confidence").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("status").ToString()); +]]> + + + +This sample shows how to call GetByIdsAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.GetByIdsAsync(new string[] { "" }); +]]> +This sample shows how to call GetByIdsAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.GetByIdsAsync(new string[] { "" }, minExtInfo: true, ignoreRelationships: true); +]]> + + + +This sample shows how to call GetByIds. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.GetByIds(new string[] { "" }); +]]> +This sample shows how to call GetByIds with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.GetByIds(new string[] { "" }, minExtInfo: true, ignoreRelationships: true); +]]> + + + +This sample shows how to call GetByIdsAsync and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.GetByIdsAsync(new string[] { "" }, null, null, null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call GetByIdsAsync with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.GetByIdsAsync(new string[] { "" }, true, true, null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("businessAttributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("customAttributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("homeId").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("collectionId").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("isIncomplete").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("labels")[0].ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("confidence").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("provenanceType").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("proxy").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("relationshipAttributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("contacts").GetProperty("")[0].GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("contacts").GetProperty("")[0].GetProperty("info").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("businessAttributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("customAttributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("homeId").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("collectionId").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("isIncomplete").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("labels")[0].ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("meanings")[0].GetProperty("confidence").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("meanings")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("meanings")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("meanings")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("meanings")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("meanings")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("meanings")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("meanings")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("provenanceType").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("proxy").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("relationshipAttributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("contacts").GetProperty("")[0].GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("contacts").GetProperty("")[0].GetProperty("info").ToString()); +]]> + + + +This sample shows how to call GetByIds and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.GetByIds(new string[] { "" }, null, null, null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call GetByIds with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.GetByIds(new string[] { "" }, true, true, null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("businessAttributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("customAttributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("homeId").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("collectionId").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("isIncomplete").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("labels")[0].ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("confidence").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("provenanceType").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("proxy").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("relationshipAttributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("contacts").GetProperty("")[0].GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("contacts").GetProperty("")[0].GetProperty("info").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("businessAttributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("customAttributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("homeId").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("collectionId").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("isIncomplete").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("labels")[0].ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("meanings")[0].GetProperty("confidence").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("meanings")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("meanings")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("meanings")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("meanings")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("meanings")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("meanings")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("meanings")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("provenanceType").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("proxy").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("relationshipAttributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("contacts").GetProperty("")[0].GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("contacts").GetProperty("")[0].GetProperty("info").ToString()); +]]> + + + +This sample shows how to call BatchCreateOrUpdateAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +AtlasEntitiesWithExtInfo entities = new AtlasEntitiesWithExtInfo(); +Response response = await client.BatchCreateOrUpdateAsync(entities); +]]> +This sample shows how to call BatchCreateOrUpdateAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +AtlasEntitiesWithExtInfo entities = new AtlasEntitiesWithExtInfo +{ + ReferredEntities = + { + ["key"] = new AtlasEntity + { + Attributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + TypeName = "", + LastModifiedTS = "", + BusinessAttributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + Classifications = {new AtlasClassification + { + Attributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + TypeName = "", + LastModifiedTS = "", + EntityGuid = "", + EntityStatus = EntityStatus.Active, + RemovePropagationsOnEntityDelete = true, + ValidityPeriods = {new TimeBoundary + { + EndTime = "", + StartTime = "", + TimeZone = "", + }}, + }}, + CreateTime = 1234L, + CreatedBy = "", + CustomAttributes = + { + ["key"] = "" + }, + Guid = "", + HomeId = "", + IsIncomplete = true, + Labels = {""}, + Meanings = {new AtlasTermAssignmentHeader + { + Confidence = 1234, + CreatedBy = "", + Description = "", + DisplayText = "", + Expression = "", + RelationGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), + Status = AtlasTermAssignmentStatus.Discovered, + Steward = "", + TermGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), + }}, + ProvenanceType = 1234, + Proxy = true, + RelationshipAttributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + Status = EntityStatus.Active, + UpdateTime = 1234L, + UpdatedBy = "", + Version = 1234L, + Contacts = + { + ["key"] = {new ContactInfo + { + Id = "", + Info = "", + }} + }, + } + }, + Entities = { default }, +}; +Response response = await client.BatchCreateOrUpdateAsync(entities, collectionId: "", businessAttributeUpdateBehavior: BusinessAttributeUpdateBehavior.Ignore); +]]> + + + +This sample shows how to call BatchCreateOrUpdate. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +AtlasEntitiesWithExtInfo entities = new AtlasEntitiesWithExtInfo(); +Response response = client.BatchCreateOrUpdate(entities); +]]> +This sample shows how to call BatchCreateOrUpdate with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +AtlasEntitiesWithExtInfo entities = new AtlasEntitiesWithExtInfo +{ + ReferredEntities = + { + ["key"] = new AtlasEntity + { + Attributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + TypeName = "", + LastModifiedTS = "", + BusinessAttributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + Classifications = {new AtlasClassification + { + Attributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + TypeName = "", + LastModifiedTS = "", + EntityGuid = "", + EntityStatus = EntityStatus.Active, + RemovePropagationsOnEntityDelete = true, + ValidityPeriods = {new TimeBoundary + { + EndTime = "", + StartTime = "", + TimeZone = "", + }}, + }}, + CreateTime = 1234L, + CreatedBy = "", + CustomAttributes = + { + ["key"] = "" + }, + Guid = "", + HomeId = "", + IsIncomplete = true, + Labels = {""}, + Meanings = {new AtlasTermAssignmentHeader + { + Confidence = 1234, + CreatedBy = "", + Description = "", + DisplayText = "", + Expression = "", + RelationGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), + Status = AtlasTermAssignmentStatus.Discovered, + Steward = "", + TermGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), + }}, + ProvenanceType = 1234, + Proxy = true, + RelationshipAttributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + Status = EntityStatus.Active, + UpdateTime = 1234L, + UpdatedBy = "", + Version = 1234L, + Contacts = + { + ["key"] = {new ContactInfo + { + Id = "", + Info = "", + }} + }, + } + }, + Entities = { default }, +}; +Response response = client.BatchCreateOrUpdate(entities, collectionId: "", businessAttributeUpdateBehavior: BusinessAttributeUpdateBehavior.Ignore); +]]> + + + +This sample shows how to call BatchCreateOrUpdateAsync and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object()); +Response response = await client.BatchCreateOrUpdateAsync(content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call BatchCreateOrUpdateAsync with all parameters and request content and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new +{ + referredEntities = new + { + key = new + { + attributes = new + { + key = new object(), + }, + typeName = "", + lastModifiedTS = "", + businessAttributes = new + { + key = new object(), + }, + classifications = new object[] + { + new + { + attributes = new + { + key = new object(), + }, + typeName = "", + lastModifiedTS = "", + entityGuid = "", + entityStatus = "ACTIVE", + removePropagationsOnEntityDelete = true, + validityPeriods = new object[] + { + new + { + endTime = "", + startTime = "", + timeZone = "", + } + }, + } + }, + createTime = 1234L, + createdBy = "", + customAttributes = new + { + key = "", + }, + guid = "", + homeId = "", + isIncomplete = true, + labels = new object[] + { + "" + }, + meanings = new object[] + { + new + { + confidence = 1234, + createdBy = "", + description = "", + displayText = "", + expression = "", + relationGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", + status = "DISCOVERED", + steward = "", + termGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", + } + }, + provenanceType = 1234, + proxy = true, + relationshipAttributes = new + { + key = new object(), + }, + status = "ACTIVE", + updateTime = 1234L, + updatedBy = "", + version = 1234L, + contacts = new + { + key = new object[] + { + new + { + id = "", + info = "", + } + }, + }, + }, + }, + entities = new object[] + { + null + }, +}); +Response response = await client.BatchCreateOrUpdateAsync(content, collectionId: "", businessAttributeUpdateBehavior: "ignore"); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("guidAssignments").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classificationNames")[0].ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("isIncomplete").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("labels")[0].ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meaningNames")[0].ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("confidence").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classificationNames")[0].ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("isIncomplete").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("labels")[0].ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meaningNames")[0].ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("confidence").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("status").ToString()); +]]> + + + +This sample shows how to call BatchCreateOrUpdate and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object()); +Response response = client.BatchCreateOrUpdate(content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call BatchCreateOrUpdate with all parameters and request content and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new +{ + referredEntities = new + { + key = new + { + attributes = new + { + key = new object(), + }, + typeName = "", + lastModifiedTS = "", + businessAttributes = new + { + key = new object(), + }, + classifications = new object[] + { + new + { + attributes = new + { + key = new object(), + }, + typeName = "", + lastModifiedTS = "", + entityGuid = "", + entityStatus = "ACTIVE", + removePropagationsOnEntityDelete = true, + validityPeriods = new object[] + { + new + { + endTime = "", + startTime = "", + timeZone = "", + } + }, + } + }, + createTime = 1234L, + createdBy = "", + customAttributes = new + { + key = "", + }, + guid = "", + homeId = "", + isIncomplete = true, + labels = new object[] + { + "" + }, + meanings = new object[] + { + new + { + confidence = 1234, + createdBy = "", + description = "", + displayText = "", + expression = "", + relationGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", + status = "DISCOVERED", + steward = "", + termGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", + } + }, + provenanceType = 1234, + proxy = true, + relationshipAttributes = new + { + key = new object(), + }, + status = "ACTIVE", + updateTime = 1234L, + updatedBy = "", + version = 1234L, + contacts = new + { + key = new object[] + { + new + { + id = "", + info = "", + } + }, + }, + }, + }, + entities = new object[] + { + null + }, +}); +Response response = client.BatchCreateOrUpdate(content, collectionId: "", businessAttributeUpdateBehavior: "ignore"); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("guidAssignments").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classificationNames")[0].ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("isIncomplete").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("labels")[0].ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meaningNames")[0].ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("confidence").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classificationNames")[0].ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("isIncomplete").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("labels")[0].ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meaningNames")[0].ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("confidence").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("status").ToString()); +]]> + + + +This sample shows how to call BatchDeleteAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.BatchDeleteAsync(new string[] { "" }); +]]> +This sample shows how to call BatchDeleteAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.BatchDeleteAsync(new string[] { "" }); +]]> + + + +This sample shows how to call BatchDelete. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.BatchDelete(new string[] { "" }); +]]> +This sample shows how to call BatchDelete with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.BatchDelete(new string[] { "" }); +]]> + + + +This sample shows how to call BatchDeleteAsync and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.BatchDeleteAsync(new string[] { "" }, null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call BatchDeleteAsync with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.BatchDeleteAsync(new string[] { "" }, null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("guidAssignments").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classificationNames")[0].ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("isIncomplete").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("labels")[0].ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meaningNames")[0].ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("confidence").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classificationNames")[0].ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("isIncomplete").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("labels")[0].ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meaningNames")[0].ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("confidence").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("status").ToString()); +]]> + + + +This sample shows how to call BatchDelete and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.BatchDelete(new string[] { "" }, null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call BatchDelete with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.BatchDelete(new string[] { "" }, null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("guidAssignments").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classificationNames")[0].ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("isIncomplete").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("labels")[0].ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meaningNames")[0].ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("confidence").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classificationNames")[0].ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("isIncomplete").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("labels")[0].ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meaningNames")[0].ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("confidence").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("status").ToString()); +]]> + + + +This sample shows how to call AddClassificationAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +ClassificationAssociateOptions request = new ClassificationAssociateOptions(); +Response response = await client.AddClassificationAsync(request); +]]> +This sample shows how to call AddClassificationAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +ClassificationAssociateOptions request = new ClassificationAssociateOptions +{ + Classification = new AtlasClassification + { + Attributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + TypeName = "", + LastModifiedTS = "", + EntityGuid = "", + EntityStatus = EntityStatus.Active, + RemovePropagationsOnEntityDelete = true, + ValidityPeriods = {new TimeBoundary + { + EndTime = "", + StartTime = "", + TimeZone = "", + }}, + }, + EntityGuids = { "" }, +}; +Response response = await client.AddClassificationAsync(request); +]]> + + + +This sample shows how to call AddClassification. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +ClassificationAssociateOptions request = new ClassificationAssociateOptions(); +Response response = client.AddClassification(request); +]]> +This sample shows how to call AddClassification with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +ClassificationAssociateOptions request = new ClassificationAssociateOptions +{ + Classification = new AtlasClassification + { + Attributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + TypeName = "", + LastModifiedTS = "", + EntityGuid = "", + EntityStatus = EntityStatus.Active, + RemovePropagationsOnEntityDelete = true, + ValidityPeriods = {new TimeBoundary + { + EndTime = "", + StartTime = "", + TimeZone = "", + }}, + }, + EntityGuids = { "" }, +}; +Response response = client.AddClassification(request); +]]> + + + +This sample shows how to call AddClassificationAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object()); +Response response = await client.AddClassificationAsync(content); + +Console.WriteLine(response.Status); +]]> +This sample shows how to call AddClassificationAsync with all request content. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new +{ + classification = new + { + attributes = new + { + key = new object(), + }, + typeName = "", + lastModifiedTS = "", + entityGuid = "", + entityStatus = "ACTIVE", + removePropagationsOnEntityDelete = true, + validityPeriods = new object[] + { + new + { + endTime = "", + startTime = "", + timeZone = "", + } + }, + }, + entityGuids = new object[] + { + "" + }, +}); +Response response = await client.AddClassificationAsync(content); + +Console.WriteLine(response.Status); +]]> + + + +This sample shows how to call AddClassification. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object()); +Response response = client.AddClassification(content); + +Console.WriteLine(response.Status); +]]> +This sample shows how to call AddClassification with all request content. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new +{ + classification = new + { + attributes = new + { + key = new object(), + }, + typeName = "", + lastModifiedTS = "", + entityGuid = "", + entityStatus = "ACTIVE", + removePropagationsOnEntityDelete = true, + validityPeriods = new object[] + { + new + { + endTime = "", + startTime = "", + timeZone = "", + } + }, + }, + entityGuids = new object[] + { + "" + }, +}); +Response response = client.AddClassification(content); + +Console.WriteLine(response.Status); +]]> + + + +This sample shows how to call GetEntityAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.GetEntityAsync(""); +]]> +This sample shows how to call GetEntityAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.GetEntityAsync("", minExtInfo: true, ignoreRelationships: true); +]]> + + + +This sample shows how to call GetEntity. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.GetEntity(""); +]]> +This sample shows how to call GetEntity with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.GetEntity("", minExtInfo: true, ignoreRelationships: true); +]]> + + + +This sample shows how to call GetEntityAsync and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.GetEntityAsync("", null, null, null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call GetEntityAsync with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.GetEntityAsync("", true, true, null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("businessAttributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("customAttributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("homeId").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("collectionId").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("isIncomplete").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("labels")[0].ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("confidence").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("provenanceType").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("proxy").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("relationshipAttributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("contacts").GetProperty("")[0].GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("contacts").GetProperty("")[0].GetProperty("info").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("businessAttributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("customAttributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("homeId").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("collectionId").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("isIncomplete").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("labels")[0].ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("meanings")[0].GetProperty("confidence").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("meanings")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("meanings")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("meanings")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("meanings")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("meanings")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("meanings")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("meanings")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("provenanceType").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("proxy").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("relationshipAttributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("contacts").GetProperty("")[0].GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("contacts").GetProperty("")[0].GetProperty("info").ToString()); +]]> + + + +This sample shows how to call GetEntity and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.GetEntity("", null, null, null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call GetEntity with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.GetEntity("", true, true, null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("businessAttributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("customAttributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("homeId").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("collectionId").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("isIncomplete").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("labels")[0].ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("confidence").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("provenanceType").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("proxy").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("relationshipAttributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("contacts").GetProperty("")[0].GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("contacts").GetProperty("")[0].GetProperty("info").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("businessAttributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("customAttributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("homeId").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("collectionId").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("isIncomplete").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("labels")[0].ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("meanings")[0].GetProperty("confidence").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("meanings")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("meanings")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("meanings")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("meanings")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("meanings")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("meanings")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("meanings")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("provenanceType").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("proxy").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("relationshipAttributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("contacts").GetProperty("")[0].GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("contacts").GetProperty("")[0].GetProperty("info").ToString()); +]]> + + + +This sample shows how to call PartialUpdateAttributeByIdAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.PartialUpdateAttributeByIdAsync("", "", BinaryData.FromObjectAsJson(new object())); +]]> +This sample shows how to call PartialUpdateAttributeByIdAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.PartialUpdateAttributeByIdAsync("", "", BinaryData.FromObjectAsJson(new object())); +]]> + + + +This sample shows how to call PartialUpdateAttributeById. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.PartialUpdateAttributeById("", "", BinaryData.FromObjectAsJson(new object())); +]]> +This sample shows how to call PartialUpdateAttributeById with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.PartialUpdateAttributeById("", "", BinaryData.FromObjectAsJson(new object())); +]]> + + + +This sample shows how to call PartialUpdateAttributeByIdAsync and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object()); +Response response = await client.PartialUpdateAttributeByIdAsync("", "", content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call PartialUpdateAttributeByIdAsync with all parameters and request content and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object()); +Response response = await client.PartialUpdateAttributeByIdAsync("", "", content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("guidAssignments").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classificationNames")[0].ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("isIncomplete").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("labels")[0].ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meaningNames")[0].ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("confidence").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classificationNames")[0].ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("isIncomplete").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("labels")[0].ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meaningNames")[0].ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("confidence").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("status").ToString()); +]]> + + + +This sample shows how to call PartialUpdateAttributeById and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object()); +Response response = client.PartialUpdateAttributeById("", "", content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call PartialUpdateAttributeById with all parameters and request content and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object()); +Response response = client.PartialUpdateAttributeById("", "", content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("guidAssignments").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classificationNames")[0].ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("isIncomplete").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("labels")[0].ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meaningNames")[0].ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("confidence").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classificationNames")[0].ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("isIncomplete").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("labels")[0].ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meaningNames")[0].ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("confidence").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("status").ToString()); +]]> + + + +This sample shows how to call DeleteAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.DeleteAsync(""); +]]> +This sample shows how to call DeleteAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.DeleteAsync(""); +]]> + + + +This sample shows how to call Delete. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.Delete(""); +]]> +This sample shows how to call Delete with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.Delete(""); +]]> + + + +This sample shows how to call DeleteAsync and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.DeleteAsync("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call DeleteAsync with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.DeleteAsync("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("guidAssignments").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classificationNames")[0].ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("isIncomplete").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("labels")[0].ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meaningNames")[0].ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("confidence").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classificationNames")[0].ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("isIncomplete").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("labels")[0].ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meaningNames")[0].ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("confidence").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("status").ToString()); +]]> + + + +This sample shows how to call Delete and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.Delete("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call Delete with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.Delete("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("guidAssignments").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classificationNames")[0].ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("isIncomplete").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("labels")[0].ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meaningNames")[0].ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("confidence").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classificationNames")[0].ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("isIncomplete").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("labels")[0].ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meaningNames")[0].ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("confidence").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("status").ToString()); +]]> + + + +This sample shows how to call GetClassificationAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.GetClassificationAsync("", ""); +]]> +This sample shows how to call GetClassificationAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.GetClassificationAsync("", ""); +]]> + + + +This sample shows how to call GetClassification. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.GetClassification("", ""); +]]> +This sample shows how to call GetClassification with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.GetClassification("", ""); +]]> + + + +This sample shows how to call GetClassificationAsync and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.GetClassificationAsync("", "", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call GetClassificationAsync with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.GetClassificationAsync("", "", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +]]> + + + +This sample shows how to call GetClassification and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.GetClassification("", "", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call GetClassification with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.GetClassification("", "", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +]]> + + + +This sample shows how to call RemoveClassificationAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.RemoveClassificationAsync("", ""); + +Console.WriteLine(response.Status); +]]> +This sample shows how to call RemoveClassificationAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.RemoveClassificationAsync("", ""); + +Console.WriteLine(response.Status); +]]> + + + +This sample shows how to call RemoveClassification. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.RemoveClassification("", ""); + +Console.WriteLine(response.Status); +]]> +This sample shows how to call RemoveClassification with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.RemoveClassification("", ""); + +Console.WriteLine(response.Status); +]]> + + + +This sample shows how to call GetClassificationsAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.GetClassificationsAsync(""); +]]> +This sample shows how to call GetClassificationsAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.GetClassificationsAsync(""); +]]> + + + +This sample shows how to call GetClassifications. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.GetClassifications(""); +]]> +This sample shows how to call GetClassifications with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.GetClassifications(""); +]]> + + + +This sample shows how to call GetClassificationsAsync and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.GetClassificationsAsync("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call GetClassificationsAsync with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.GetClassificationsAsync("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("list")[0].ToString()); +Console.WriteLine(result.GetProperty("pageSize").ToString()); +Console.WriteLine(result.GetProperty("sortBy").ToString()); +Console.WriteLine(result.GetProperty("sortType").ToString()); +Console.WriteLine(result.GetProperty("startIndex").ToString()); +Console.WriteLine(result.GetProperty("totalCount").ToString()); +]]> + + + +This sample shows how to call GetClassifications and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.GetClassifications("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call GetClassifications with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.GetClassifications("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("list")[0].ToString()); +Console.WriteLine(result.GetProperty("pageSize").ToString()); +Console.WriteLine(result.GetProperty("sortBy").ToString()); +Console.WriteLine(result.GetProperty("sortType").ToString()); +Console.WriteLine(result.GetProperty("startIndex").ToString()); +Console.WriteLine(result.GetProperty("totalCount").ToString()); +]]> + + + +This sample shows how to call AddClassificationsAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.AddClassificationsAsync("", new AtlasClassification[] +{ + new AtlasClassification() +}); +]]> +This sample shows how to call AddClassificationsAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.AddClassificationsAsync("", new AtlasClassification[] +{ + new AtlasClassification + { + Attributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + TypeName = "", + LastModifiedTS = "", + EntityGuid = "", + EntityStatus = EntityStatus.Active, + RemovePropagationsOnEntityDelete = true, + ValidityPeriods = {new TimeBoundary + { + EndTime = "", + StartTime = "", + TimeZone = "", + }}, + } +}); +]]> + + + +This sample shows how to call AddClassifications. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.AddClassifications("", new AtlasClassification[] +{ + new AtlasClassification() +}); +]]> +This sample shows how to call AddClassifications with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.AddClassifications("", new AtlasClassification[] +{ + new AtlasClassification + { + Attributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + TypeName = "", + LastModifiedTS = "", + EntityGuid = "", + EntityStatus = EntityStatus.Active, + RemovePropagationsOnEntityDelete = true, + ValidityPeriods = {new TimeBoundary + { + EndTime = "", + StartTime = "", + TimeZone = "", + }}, + } +}); +]]> + + + +This sample shows how to call AddClassificationsAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object[] +{ + new object() +}); +Response response = await client.AddClassificationsAsync("", content); + +Console.WriteLine(response.Status); +]]> +This sample shows how to call AddClassificationsAsync with all parameters and request content. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object[] +{ + new + { + attributes = new + { + key = new object(), + }, + typeName = "", + lastModifiedTS = "", + entityGuid = "", + entityStatus = "ACTIVE", + removePropagationsOnEntityDelete = true, + validityPeriods = new object[] + { + new + { + endTime = "", + startTime = "", + timeZone = "", + } + }, + } +}); +Response response = await client.AddClassificationsAsync("", content); + +Console.WriteLine(response.Status); +]]> + + + +This sample shows how to call AddClassifications. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object[] +{ + new object() +}); +Response response = client.AddClassifications("", content); + +Console.WriteLine(response.Status); +]]> +This sample shows how to call AddClassifications with all parameters and request content. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object[] +{ + new + { + attributes = new + { + key = new object(), + }, + typeName = "", + lastModifiedTS = "", + entityGuid = "", + entityStatus = "ACTIVE", + removePropagationsOnEntityDelete = true, + validityPeriods = new object[] + { + new + { + endTime = "", + startTime = "", + timeZone = "", + } + }, + } +}); +Response response = client.AddClassifications("", content); + +Console.WriteLine(response.Status); +]]> + + + +This sample shows how to call UpdateClassificationsAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.UpdateClassificationsAsync("", new AtlasClassification[] +{ + new AtlasClassification() +}); +]]> +This sample shows how to call UpdateClassificationsAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.UpdateClassificationsAsync("", new AtlasClassification[] +{ + new AtlasClassification + { + Attributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + TypeName = "", + LastModifiedTS = "", + EntityGuid = "", + EntityStatus = EntityStatus.Active, + RemovePropagationsOnEntityDelete = true, + ValidityPeriods = {new TimeBoundary + { + EndTime = "", + StartTime = "", + TimeZone = "", + }}, + } +}); +]]> + + + +This sample shows how to call UpdateClassifications. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.UpdateClassifications("", new AtlasClassification[] +{ + new AtlasClassification() +}); +]]> +This sample shows how to call UpdateClassifications with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.UpdateClassifications("", new AtlasClassification[] +{ + new AtlasClassification + { + Attributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + TypeName = "", + LastModifiedTS = "", + EntityGuid = "", + EntityStatus = EntityStatus.Active, + RemovePropagationsOnEntityDelete = true, + ValidityPeriods = {new TimeBoundary + { + EndTime = "", + StartTime = "", + TimeZone = "", + }}, + } +}); +]]> + + + +This sample shows how to call UpdateClassificationsAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object[] +{ + new object() +}); +Response response = await client.UpdateClassificationsAsync("", content); + +Console.WriteLine(response.Status); +]]> +This sample shows how to call UpdateClassificationsAsync with all parameters and request content. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object[] +{ + new + { + attributes = new + { + key = new object(), + }, + typeName = "", + lastModifiedTS = "", + entityGuid = "", + entityStatus = "ACTIVE", + removePropagationsOnEntityDelete = true, + validityPeriods = new object[] + { + new + { + endTime = "", + startTime = "", + timeZone = "", + } + }, + } +}); +Response response = await client.UpdateClassificationsAsync("", content); + +Console.WriteLine(response.Status); +]]> + + + +This sample shows how to call UpdateClassifications. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object[] +{ + new object() +}); +Response response = client.UpdateClassifications("", content); + +Console.WriteLine(response.Status); +]]> +This sample shows how to call UpdateClassifications with all parameters and request content. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object[] +{ + new + { + attributes = new + { + key = new object(), + }, + typeName = "", + lastModifiedTS = "", + entityGuid = "", + entityStatus = "ACTIVE", + removePropagationsOnEntityDelete = true, + validityPeriods = new object[] + { + new + { + endTime = "", + startTime = "", + timeZone = "", + } + }, + } +}); +Response response = client.UpdateClassifications("", content); + +Console.WriteLine(response.Status); +]]> + + + +This sample shows how to call GetByAttributesAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.GetByAttributesAsync(""); +]]> +This sample shows how to call GetByAttributesAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.GetByAttributesAsync("", minExtInfo: true, ignoreRelationships: true, attr: ""); +]]> + + + +This sample shows how to call GetByAttributes. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.GetByAttributes(""); +]]> +This sample shows how to call GetByAttributes with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.GetByAttributes("", minExtInfo: true, ignoreRelationships: true, attr: ""); +]]> + + + +This sample shows how to call GetByAttributesAsync and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.GetByAttributesAsync("", null, null, null, null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call GetByAttributesAsync with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.GetByAttributesAsync("", true, true, "", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("businessAttributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("customAttributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("homeId").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("collectionId").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("isIncomplete").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("labels")[0].ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("confidence").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("provenanceType").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("proxy").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("relationshipAttributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("contacts").GetProperty("")[0].GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("contacts").GetProperty("")[0].GetProperty("info").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("businessAttributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("customAttributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("homeId").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("collectionId").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("isIncomplete").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("labels")[0].ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("meanings")[0].GetProperty("confidence").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("meanings")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("meanings")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("meanings")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("meanings")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("meanings")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("meanings")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("meanings")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("provenanceType").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("proxy").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("relationshipAttributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("contacts").GetProperty("")[0].GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("contacts").GetProperty("")[0].GetProperty("info").ToString()); +]]> + + + +This sample shows how to call GetByAttributes and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.GetByAttributes("", null, null, null, null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call GetByAttributes with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.GetByAttributes("", true, true, "", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("businessAttributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("customAttributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("homeId").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("collectionId").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("isIncomplete").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("labels")[0].ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("confidence").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("provenanceType").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("proxy").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("relationshipAttributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("contacts").GetProperty("")[0].GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("contacts").GetProperty("")[0].GetProperty("info").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("businessAttributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("customAttributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("homeId").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("collectionId").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("isIncomplete").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("labels")[0].ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("meanings")[0].GetProperty("confidence").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("meanings")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("meanings")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("meanings")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("meanings")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("meanings")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("meanings")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("meanings")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("provenanceType").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("proxy").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("relationshipAttributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("contacts").GetProperty("")[0].GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("entity").GetProperty("contacts").GetProperty("")[0].GetProperty("info").ToString()); +]]> + + + +This sample shows how to call PartialUpdateByAttributesAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +AtlasEntityWithExtInfo atlasEntityWithExtInfo = new AtlasEntityWithExtInfo(); +Response response = await client.PartialUpdateByAttributesAsync("", atlasEntityWithExtInfo); +]]> +This sample shows how to call PartialUpdateByAttributesAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +AtlasEntityWithExtInfo atlasEntityWithExtInfo = new AtlasEntityWithExtInfo +{ + ReferredEntities = + { + ["key"] = new AtlasEntity + { + Attributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + TypeName = "", + LastModifiedTS = "", + BusinessAttributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + Classifications = {new AtlasClassification + { + Attributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + TypeName = "", + LastModifiedTS = "", + EntityGuid = "", + EntityStatus = EntityStatus.Active, + RemovePropagationsOnEntityDelete = true, + ValidityPeriods = {new TimeBoundary + { + EndTime = "", + StartTime = "", + TimeZone = "", + }}, + }}, + CreateTime = 1234L, + CreatedBy = "", + CustomAttributes = + { + ["key"] = "" + }, + Guid = "", + HomeId = "", + IsIncomplete = true, + Labels = {""}, + Meanings = {new AtlasTermAssignmentHeader + { + Confidence = 1234, + CreatedBy = "", + Description = "", + DisplayText = "", + Expression = "", + RelationGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), + Status = AtlasTermAssignmentStatus.Discovered, + Steward = "", + TermGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), + }}, + ProvenanceType = 1234, + Proxy = true, + RelationshipAttributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + Status = EntityStatus.Active, + UpdateTime = 1234L, + UpdatedBy = "", + Version = 1234L, + Contacts = + { + ["key"] = {new ContactInfo + { + Id = "", + Info = "", + }} + }, + } + }, + Entity = default, +}; +Response response = await client.PartialUpdateByAttributesAsync("", atlasEntityWithExtInfo, attr: ""); +]]> + + + +This sample shows how to call PartialUpdateByAttributes. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +AtlasEntityWithExtInfo atlasEntityWithExtInfo = new AtlasEntityWithExtInfo(); +Response response = client.PartialUpdateByAttributes("", atlasEntityWithExtInfo); +]]> +This sample shows how to call PartialUpdateByAttributes with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +AtlasEntityWithExtInfo atlasEntityWithExtInfo = new AtlasEntityWithExtInfo +{ + ReferredEntities = + { + ["key"] = new AtlasEntity + { + Attributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + TypeName = "", + LastModifiedTS = "", + BusinessAttributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + Classifications = {new AtlasClassification + { + Attributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + TypeName = "", + LastModifiedTS = "", + EntityGuid = "", + EntityStatus = EntityStatus.Active, + RemovePropagationsOnEntityDelete = true, + ValidityPeriods = {new TimeBoundary + { + EndTime = "", + StartTime = "", + TimeZone = "", + }}, + }}, + CreateTime = 1234L, + CreatedBy = "", + CustomAttributes = + { + ["key"] = "" + }, + Guid = "", + HomeId = "", + IsIncomplete = true, + Labels = {""}, + Meanings = {new AtlasTermAssignmentHeader + { + Confidence = 1234, + CreatedBy = "", + Description = "", + DisplayText = "", + Expression = "", + RelationGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), + Status = AtlasTermAssignmentStatus.Discovered, + Steward = "", + TermGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), + }}, + ProvenanceType = 1234, + Proxy = true, + RelationshipAttributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + Status = EntityStatus.Active, + UpdateTime = 1234L, + UpdatedBy = "", + Version = 1234L, + Contacts = + { + ["key"] = {new ContactInfo + { + Id = "", + Info = "", + }} + }, + } + }, + Entity = default, +}; +Response response = client.PartialUpdateByAttributes("", atlasEntityWithExtInfo, attr: ""); +]]> + + + +This sample shows how to call PartialUpdateByAttributesAsync and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object()); +Response response = await client.PartialUpdateByAttributesAsync("", content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call PartialUpdateByAttributesAsync with all parameters and request content and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new +{ + referredEntities = new + { + key = new + { + attributes = new + { + key = new object(), + }, + typeName = "", + lastModifiedTS = "", + businessAttributes = new + { + key = new object(), + }, + classifications = new object[] + { + new + { + attributes = new + { + key = new object(), + }, + typeName = "", + lastModifiedTS = "", + entityGuid = "", + entityStatus = "ACTIVE", + removePropagationsOnEntityDelete = true, + validityPeriods = new object[] + { + new + { + endTime = "", + startTime = "", + timeZone = "", + } + }, + } + }, + createTime = 1234L, + createdBy = "", + customAttributes = new + { + key = "", + }, + guid = "", + homeId = "", + isIncomplete = true, + labels = new object[] + { + "" + }, + meanings = new object[] + { + new + { + confidence = 1234, + createdBy = "", + description = "", + displayText = "", + expression = "", + relationGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", + status = "DISCOVERED", + steward = "", + termGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", + } + }, + provenanceType = 1234, + proxy = true, + relationshipAttributes = new + { + key = new object(), + }, + status = "ACTIVE", + updateTime = 1234L, + updatedBy = "", + version = 1234L, + contacts = new + { + key = new object[] + { + new + { + id = "", + info = "", + } + }, + }, + }, + }, +}); +Response response = await client.PartialUpdateByAttributesAsync("", content, attr: ""); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("guidAssignments").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classificationNames")[0].ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("isIncomplete").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("labels")[0].ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meaningNames")[0].ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("confidence").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classificationNames")[0].ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("isIncomplete").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("labels")[0].ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meaningNames")[0].ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("confidence").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("status").ToString()); +]]> + + + +This sample shows how to call PartialUpdateByAttributes and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object()); +Response response = client.PartialUpdateByAttributes("", content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call PartialUpdateByAttributes with all parameters and request content and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new +{ + referredEntities = new + { + key = new + { + attributes = new + { + key = new object(), + }, + typeName = "", + lastModifiedTS = "", + businessAttributes = new + { + key = new object(), + }, + classifications = new object[] + { + new + { + attributes = new + { + key = new object(), + }, + typeName = "", + lastModifiedTS = "", + entityGuid = "", + entityStatus = "ACTIVE", + removePropagationsOnEntityDelete = true, + validityPeriods = new object[] + { + new + { + endTime = "", + startTime = "", + timeZone = "", + } + }, + } + }, + createTime = 1234L, + createdBy = "", + customAttributes = new + { + key = "", + }, + guid = "", + homeId = "", + isIncomplete = true, + labels = new object[] + { + "" + }, + meanings = new object[] + { + new + { + confidence = 1234, + createdBy = "", + description = "", + displayText = "", + expression = "", + relationGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", + status = "DISCOVERED", + steward = "", + termGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", + } + }, + provenanceType = 1234, + proxy = true, + relationshipAttributes = new + { + key = new object(), + }, + status = "ACTIVE", + updateTime = 1234L, + updatedBy = "", + version = 1234L, + contacts = new + { + key = new object[] + { + new + { + id = "", + info = "", + } + }, + }, + }, + }, +}); +Response response = client.PartialUpdateByAttributes("", content, attr: ""); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("guidAssignments").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classificationNames")[0].ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("isIncomplete").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("labels")[0].ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meaningNames")[0].ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("confidence").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classificationNames")[0].ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("isIncomplete").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("labels")[0].ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meaningNames")[0].ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("confidence").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("status").ToString()); +]]> + + + +This sample shows how to call DeleteByAttributeAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.DeleteByAttributeAsync(""); +]]> +This sample shows how to call DeleteByAttributeAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.DeleteByAttributeAsync("", attr: ""); +]]> + + + +This sample shows how to call DeleteByAttribute. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.DeleteByAttribute(""); +]]> +This sample shows how to call DeleteByAttribute with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.DeleteByAttribute("", attr: ""); +]]> + + + +This sample shows how to call DeleteByAttributeAsync and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.DeleteByAttributeAsync("", null, null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call DeleteByAttributeAsync with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.DeleteByAttributeAsync("", "", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("guidAssignments").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classificationNames")[0].ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("isIncomplete").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("labels")[0].ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meaningNames")[0].ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("confidence").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classificationNames")[0].ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("isIncomplete").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("labels")[0].ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meaningNames")[0].ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("confidence").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("status").ToString()); +]]> + + + +This sample shows how to call DeleteByAttribute and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.DeleteByAttribute("", null, null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call DeleteByAttribute with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.DeleteByAttribute("", "", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("guidAssignments").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classificationNames")[0].ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("isIncomplete").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("labels")[0].ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meaningNames")[0].ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("confidence").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classificationNames")[0].ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("isIncomplete").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("labels")[0].ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meaningNames")[0].ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("confidence").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("status").ToString()); +]]> + + + +This sample shows how to call RemoveClassificationByAttributeAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.RemoveClassificationByAttributeAsync("", ""); + +Console.WriteLine(response.Status); +]]> +This sample shows how to call RemoveClassificationByAttributeAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.RemoveClassificationByAttributeAsync("", "", attr: ""); + +Console.WriteLine(response.Status); +]]> + + + +This sample shows how to call RemoveClassificationByAttribute. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.RemoveClassificationByAttribute("", ""); + +Console.WriteLine(response.Status); +]]> +This sample shows how to call RemoveClassificationByAttribute with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.RemoveClassificationByAttribute("", "", attr: ""); + +Console.WriteLine(response.Status); +]]> + + + +This sample shows how to call AddClassificationsByAttributeAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.AddClassificationsByAttributeAsync("", new AtlasClassification[] +{ + new AtlasClassification() +}); +]]> +This sample shows how to call AddClassificationsByAttributeAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.AddClassificationsByAttributeAsync("", new AtlasClassification[] +{ + new AtlasClassification + { + Attributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + TypeName = "", + LastModifiedTS = "", + EntityGuid = "", + EntityStatus = EntityStatus.Active, + RemovePropagationsOnEntityDelete = true, + ValidityPeriods = {new TimeBoundary + { + EndTime = "", + StartTime = "", + TimeZone = "", + }}, + } +}, attr: ""); +]]> + + + +This sample shows how to call AddClassificationsByAttribute. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.AddClassificationsByAttribute("", new AtlasClassification[] +{ + new AtlasClassification() +}); +]]> +This sample shows how to call AddClassificationsByAttribute with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.AddClassificationsByAttribute("", new AtlasClassification[] +{ + new AtlasClassification + { + Attributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + TypeName = "", + LastModifiedTS = "", + EntityGuid = "", + EntityStatus = EntityStatus.Active, + RemovePropagationsOnEntityDelete = true, + ValidityPeriods = {new TimeBoundary + { + EndTime = "", + StartTime = "", + TimeZone = "", + }}, + } +}, attr: ""); +]]> + + + +This sample shows how to call AddClassificationsByAttributeAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object[] +{ + new object() +}); +Response response = await client.AddClassificationsByAttributeAsync("", content); + +Console.WriteLine(response.Status); +]]> +This sample shows how to call AddClassificationsByAttributeAsync with all parameters and request content. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object[] +{ + new + { + attributes = new + { + key = new object(), + }, + typeName = "", + lastModifiedTS = "", + entityGuid = "", + entityStatus = "ACTIVE", + removePropagationsOnEntityDelete = true, + validityPeriods = new object[] + { + new + { + endTime = "", + startTime = "", + timeZone = "", + } + }, + } +}); +Response response = await client.AddClassificationsByAttributeAsync("", content, attr: ""); + +Console.WriteLine(response.Status); +]]> + + + +This sample shows how to call AddClassificationsByAttribute. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object[] +{ + new object() +}); +Response response = client.AddClassificationsByAttribute("", content); + +Console.WriteLine(response.Status); +]]> +This sample shows how to call AddClassificationsByAttribute with all parameters and request content. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object[] +{ + new + { + attributes = new + { + key = new object(), + }, + typeName = "", + lastModifiedTS = "", + entityGuid = "", + entityStatus = "ACTIVE", + removePropagationsOnEntityDelete = true, + validityPeriods = new object[] + { + new + { + endTime = "", + startTime = "", + timeZone = "", + } + }, + } +}); +Response response = client.AddClassificationsByAttribute("", content, attr: ""); + +Console.WriteLine(response.Status); +]]> + + + +This sample shows how to call UpdateClassificationsByAttributeAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.UpdateClassificationsByAttributeAsync("", new AtlasClassification[] +{ + new AtlasClassification() +}); +]]> +This sample shows how to call UpdateClassificationsByAttributeAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.UpdateClassificationsByAttributeAsync("", new AtlasClassification[] +{ + new AtlasClassification + { + Attributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + TypeName = "", + LastModifiedTS = "", + EntityGuid = "", + EntityStatus = EntityStatus.Active, + RemovePropagationsOnEntityDelete = true, + ValidityPeriods = {new TimeBoundary + { + EndTime = "", + StartTime = "", + TimeZone = "", + }}, + } +}, attr: ""); +]]> + + + +This sample shows how to call UpdateClassificationsByAttribute. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.UpdateClassificationsByAttribute("", new AtlasClassification[] +{ + new AtlasClassification() +}); +]]> +This sample shows how to call UpdateClassificationsByAttribute with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.UpdateClassificationsByAttribute("", new AtlasClassification[] +{ + new AtlasClassification + { + Attributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + TypeName = "", + LastModifiedTS = "", + EntityGuid = "", + EntityStatus = EntityStatus.Active, + RemovePropagationsOnEntityDelete = true, + ValidityPeriods = {new TimeBoundary + { + EndTime = "", + StartTime = "", + TimeZone = "", + }}, + } +}, attr: ""); +]]> + + + +This sample shows how to call UpdateClassificationsByAttributeAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object[] +{ + new object() +}); +Response response = await client.UpdateClassificationsByAttributeAsync("", content); + +Console.WriteLine(response.Status); +]]> +This sample shows how to call UpdateClassificationsByAttributeAsync with all parameters and request content. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object[] +{ + new + { + attributes = new + { + key = new object(), + }, + typeName = "", + lastModifiedTS = "", + entityGuid = "", + entityStatus = "ACTIVE", + removePropagationsOnEntityDelete = true, + validityPeriods = new object[] + { + new + { + endTime = "", + startTime = "", + timeZone = "", + } + }, + } +}); +Response response = await client.UpdateClassificationsByAttributeAsync("", content, attr: ""); + +Console.WriteLine(response.Status); +]]> + + + +This sample shows how to call UpdateClassificationsByAttribute. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object[] +{ + new object() +}); +Response response = client.UpdateClassificationsByAttribute("", content); + +Console.WriteLine(response.Status); +]]> +This sample shows how to call UpdateClassificationsByAttribute with all parameters and request content. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object[] +{ + new + { + attributes = new + { + key = new object(), + }, + typeName = "", + lastModifiedTS = "", + entityGuid = "", + entityStatus = "ACTIVE", + removePropagationsOnEntityDelete = true, + validityPeriods = new object[] + { + new + { + endTime = "", + startTime = "", + timeZone = "", + } + }, + } +}); +Response response = client.UpdateClassificationsByAttribute("", content, attr: ""); + +Console.WriteLine(response.Status); +]]> + + + +This sample shows how to call BatchSetClassificationsAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +AtlasEntityHeaders entityHeaders = new AtlasEntityHeaders(); +Response> response = await client.BatchSetClassificationsAsync(entityHeaders); +]]> +This sample shows how to call BatchSetClassificationsAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +AtlasEntityHeaders entityHeaders = new AtlasEntityHeaders +{ + GuidHeaderMap = + { + ["key"] = new AtlasEntityHeader + { + Attributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + TypeName = "", + LastModifiedTS = "", + ClassificationNames = {""}, + Classifications = {new AtlasClassification + { + Attributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + TypeName = "", + LastModifiedTS = "", + EntityGuid = "", + EntityStatus = EntityStatus.Active, + RemovePropagationsOnEntityDelete = true, + ValidityPeriods = {new TimeBoundary + { + EndTime = "", + StartTime = "", + TimeZone = "", + }}, + }}, + DisplayText = "", + Guid = "", + IsIncomplete = true, + Labels = {""}, + MeaningNames = {""}, + Meanings = {new AtlasTermAssignmentHeader + { + Confidence = 1234, + CreatedBy = "", + Description = "", + DisplayText = "", + Expression = "", + RelationGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), + Status = AtlasTermAssignmentStatus.Discovered, + Steward = "", + TermGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), + }}, + Status = EntityStatus.Active, + } + }, +}; +Response> response = await client.BatchSetClassificationsAsync(entityHeaders); +]]> + + + +This sample shows how to call BatchSetClassifications. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +AtlasEntityHeaders entityHeaders = new AtlasEntityHeaders(); +Response> response = client.BatchSetClassifications(entityHeaders); +]]> +This sample shows how to call BatchSetClassifications with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +AtlasEntityHeaders entityHeaders = new AtlasEntityHeaders +{ + GuidHeaderMap = + { + ["key"] = new AtlasEntityHeader + { + Attributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + TypeName = "", + LastModifiedTS = "", + ClassificationNames = {""}, + Classifications = {new AtlasClassification + { + Attributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + TypeName = "", + LastModifiedTS = "", + EntityGuid = "", + EntityStatus = EntityStatus.Active, + RemovePropagationsOnEntityDelete = true, + ValidityPeriods = {new TimeBoundary + { + EndTime = "", + StartTime = "", + TimeZone = "", + }}, + }}, + DisplayText = "", + Guid = "", + IsIncomplete = true, + Labels = {""}, + MeaningNames = {""}, + Meanings = {new AtlasTermAssignmentHeader + { + Confidence = 1234, + CreatedBy = "", + Description = "", + DisplayText = "", + Expression = "", + RelationGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), + Status = AtlasTermAssignmentStatus.Discovered, + Steward = "", + TermGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), + }}, + Status = EntityStatus.Active, + } + }, +}; +Response> response = client.BatchSetClassifications(entityHeaders); +]]> + + + +This sample shows how to call BatchSetClassificationsAsync and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object()); +Response response = await client.BatchSetClassificationsAsync(content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result[0].ToString()); +]]> +This sample shows how to call BatchSetClassificationsAsync with all request content and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new +{ + guidHeaderMap = new + { + key = new + { + attributes = new + { + key = new object(), + }, + typeName = "", + lastModifiedTS = "", + classificationNames = new object[] + { + "" + }, + classifications = new object[] + { + new + { + attributes = new + { + key = new object(), + }, + typeName = "", + lastModifiedTS = "", + entityGuid = "", + entityStatus = "ACTIVE", + removePropagationsOnEntityDelete = true, + validityPeriods = new object[] + { + new + { + endTime = "", + startTime = "", + timeZone = "", + } + }, + } + }, + displayText = "", + guid = "", + isIncomplete = true, + labels = new object[] + { + "" + }, + meaningNames = new object[] + { + "" + }, + meanings = new object[] + { + new + { + confidence = 1234, + createdBy = "", + description = "", + displayText = "", + expression = "", + relationGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", + status = "DISCOVERED", + steward = "", + termGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", + } + }, + status = "ACTIVE", + }, + }, +}); +Response response = await client.BatchSetClassificationsAsync(content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result[0].ToString()); +]]> + + + +This sample shows how to call BatchSetClassifications and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object()); +Response response = client.BatchSetClassifications(content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result[0].ToString()); +]]> +This sample shows how to call BatchSetClassifications with all request content and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new +{ + guidHeaderMap = new + { + key = new + { + attributes = new + { + key = new object(), + }, + typeName = "", + lastModifiedTS = "", + classificationNames = new object[] + { + "" + }, + classifications = new object[] + { + new + { + attributes = new + { + key = new object(), + }, + typeName = "", + lastModifiedTS = "", + entityGuid = "", + entityStatus = "ACTIVE", + removePropagationsOnEntityDelete = true, + validityPeriods = new object[] + { + new + { + endTime = "", + startTime = "", + timeZone = "", + } + }, + } + }, + displayText = "", + guid = "", + isIncomplete = true, + labels = new object[] + { + "" + }, + meaningNames = new object[] + { + "" + }, + meanings = new object[] + { + new + { + confidence = 1234, + createdBy = "", + description = "", + displayText = "", + expression = "", + relationGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", + status = "DISCOVERED", + steward = "", + termGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", + } + }, + status = "ACTIVE", + }, + }, +}); +Response response = client.BatchSetClassifications(content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result[0].ToString()); +]]> + + + +This sample shows how to call BatchGetByAttributesAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.BatchGetByAttributesAsync(""); +]]> +This sample shows how to call BatchGetByAttributesAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.BatchGetByAttributesAsync("", minExtInfo: true, ignoreRelationships: true, attrNQualifiedName: ""); +]]> + + + +This sample shows how to call BatchGetByAttributes. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.BatchGetByAttributes(""); +]]> +This sample shows how to call BatchGetByAttributes with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.BatchGetByAttributes("", minExtInfo: true, ignoreRelationships: true, attrNQualifiedName: ""); +]]> + + + +This sample shows how to call BatchGetByAttributesAsync and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.BatchGetByAttributesAsync("", null, null, null, null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call BatchGetByAttributesAsync with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.BatchGetByAttributesAsync("", true, true, "", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("businessAttributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("customAttributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("homeId").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("collectionId").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("isIncomplete").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("labels")[0].ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("confidence").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("provenanceType").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("proxy").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("relationshipAttributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("contacts").GetProperty("")[0].GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("contacts").GetProperty("")[0].GetProperty("info").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("businessAttributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("customAttributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("homeId").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("collectionId").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("isIncomplete").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("labels")[0].ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("meanings")[0].GetProperty("confidence").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("meanings")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("meanings")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("meanings")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("meanings")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("meanings")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("meanings")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("meanings")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("provenanceType").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("proxy").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("relationshipAttributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("contacts").GetProperty("")[0].GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("contacts").GetProperty("")[0].GetProperty("info").ToString()); +]]> + + + +This sample shows how to call BatchGetByAttributes and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.BatchGetByAttributes("", null, null, null, null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call BatchGetByAttributes with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.BatchGetByAttributes("", true, true, "", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("businessAttributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("customAttributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("homeId").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("collectionId").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("isIncomplete").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("labels")[0].ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("confidence").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("provenanceType").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("proxy").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("relationshipAttributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("contacts").GetProperty("")[0].GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("contacts").GetProperty("")[0].GetProperty("info").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("businessAttributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("customAttributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("homeId").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("collectionId").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("isIncomplete").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("labels")[0].ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("meanings")[0].GetProperty("confidence").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("meanings")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("meanings")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("meanings")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("meanings")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("meanings")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("meanings")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("meanings")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("provenanceType").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("proxy").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("relationshipAttributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("contacts").GetProperty("")[0].GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("entities")[0].GetProperty("contacts").GetProperty("")[0].GetProperty("info").ToString()); +]]> + + + +This sample shows how to call GetHeaderAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.GetHeaderAsync(""); +]]> +This sample shows how to call GetHeaderAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.GetHeaderAsync(""); +]]> + + + +This sample shows how to call GetHeader. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.GetHeader(""); +]]> +This sample shows how to call GetHeader with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.GetHeader(""); +]]> + + + +This sample shows how to call GetHeaderAsync and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.GetHeaderAsync("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call GetHeaderAsync with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.GetHeaderAsync("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("classificationNames")[0].ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("isIncomplete").ToString()); +Console.WriteLine(result.GetProperty("labels")[0].ToString()); +Console.WriteLine(result.GetProperty("meaningNames")[0].ToString()); +Console.WriteLine(result.GetProperty("meanings")[0].GetProperty("confidence").ToString()); +Console.WriteLine(result.GetProperty("meanings")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("meanings")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("meanings")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("meanings")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("meanings")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("meanings")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("meanings")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("status").ToString()); +]]> + + + +This sample shows how to call GetHeader and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.GetHeader("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call GetHeader with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.GetHeader("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("classificationNames")[0].ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("isIncomplete").ToString()); +Console.WriteLine(result.GetProperty("labels")[0].ToString()); +Console.WriteLine(result.GetProperty("meaningNames")[0].ToString()); +Console.WriteLine(result.GetProperty("meanings")[0].GetProperty("confidence").ToString()); +Console.WriteLine(result.GetProperty("meanings")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("meanings")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("meanings")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("meanings")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("meanings")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("meanings")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("meanings")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("status").ToString()); +]]> + + + +This sample shows how to call RemoveBusinessMetadataAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.RemoveBusinessMetadataAsync("", new Dictionary> +{ + ["key"] = new Dictionary + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + } +}); +]]> +This sample shows how to call RemoveBusinessMetadataAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.RemoveBusinessMetadataAsync("", new Dictionary> +{ + ["key"] = new Dictionary + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + } +}); +]]> + + + +This sample shows how to call RemoveBusinessMetadata. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.RemoveBusinessMetadata("", new Dictionary> +{ + ["key"] = new Dictionary + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + } +}); +]]> +This sample shows how to call RemoveBusinessMetadata with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.RemoveBusinessMetadata("", new Dictionary> +{ + ["key"] = new Dictionary + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + } +}); +]]> + + + +This sample shows how to call RemoveBusinessMetadataAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new +{ + key = new + { + key = new object(), + }, +}); +Response response = await client.RemoveBusinessMetadataAsync("", content); + +Console.WriteLine(response.Status); +]]> +This sample shows how to call RemoveBusinessMetadataAsync with all parameters and request content. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new +{ + key = new + { + key = new object(), + }, +}); +Response response = await client.RemoveBusinessMetadataAsync("", content); + +Console.WriteLine(response.Status); +]]> + + + +This sample shows how to call RemoveBusinessMetadata. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new +{ + key = new + { + key = new object(), + }, +}); +Response response = client.RemoveBusinessMetadata("", content); + +Console.WriteLine(response.Status); +]]> +This sample shows how to call RemoveBusinessMetadata with all parameters and request content. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new +{ + key = new + { + key = new object(), + }, +}); +Response response = client.RemoveBusinessMetadata("", content); + +Console.WriteLine(response.Status); +]]> + + + +This sample shows how to call AddOrUpdateBusinessMetadataAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.AddOrUpdateBusinessMetadataAsync("", new Dictionary> +{ + ["key"] = new Dictionary + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + } +}); +]]> +This sample shows how to call AddOrUpdateBusinessMetadataAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.AddOrUpdateBusinessMetadataAsync("", new Dictionary> +{ + ["key"] = new Dictionary + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + } +}, isOverwrite: true); +]]> + + + +This sample shows how to call AddOrUpdateBusinessMetadata. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.AddOrUpdateBusinessMetadata("", new Dictionary> +{ + ["key"] = new Dictionary + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + } +}); +]]> +This sample shows how to call AddOrUpdateBusinessMetadata with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.AddOrUpdateBusinessMetadata("", new Dictionary> +{ + ["key"] = new Dictionary + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + } +}, isOverwrite: true); +]]> + + + +This sample shows how to call AddOrUpdateBusinessMetadataAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new +{ + key = new + { + key = new object(), + }, +}); +Response response = await client.AddOrUpdateBusinessMetadataAsync("", content); + +Console.WriteLine(response.Status); +]]> +This sample shows how to call AddOrUpdateBusinessMetadataAsync with all parameters and request content. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new +{ + key = new + { + key = new object(), + }, +}); +Response response = await client.AddOrUpdateBusinessMetadataAsync("", content, isOverwrite: true); + +Console.WriteLine(response.Status); +]]> + + + +This sample shows how to call AddOrUpdateBusinessMetadata. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new +{ + key = new + { + key = new object(), + }, +}); +Response response = client.AddOrUpdateBusinessMetadata("", content); + +Console.WriteLine(response.Status); +]]> +This sample shows how to call AddOrUpdateBusinessMetadata with all parameters and request content. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new +{ + key = new + { + key = new object(), + }, +}); +Response response = client.AddOrUpdateBusinessMetadata("", content, isOverwrite: true); + +Console.WriteLine(response.Status); +]]> + + + +This sample shows how to call RemoveBusinessMetadataAttributesAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.RemoveBusinessMetadataAttributesAsync("", "", new Dictionary +{ + ["key"] = BinaryData.FromObjectAsJson(new object()) +}); +]]> +This sample shows how to call RemoveBusinessMetadataAttributesAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.RemoveBusinessMetadataAttributesAsync("", "", new Dictionary +{ + ["key"] = BinaryData.FromObjectAsJson(new object()) +}); +]]> + + + +This sample shows how to call RemoveBusinessMetadataAttributes. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.RemoveBusinessMetadataAttributes("", "", new Dictionary +{ + ["key"] = BinaryData.FromObjectAsJson(new object()) +}); +]]> +This sample shows how to call RemoveBusinessMetadataAttributes with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.RemoveBusinessMetadataAttributes("", "", new Dictionary +{ + ["key"] = BinaryData.FromObjectAsJson(new object()) +}); +]]> + + + +This sample shows how to call RemoveBusinessMetadataAttributesAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new +{ + key = new object(), +}); +Response response = await client.RemoveBusinessMetadataAttributesAsync("", "", content); + +Console.WriteLine(response.Status); +]]> +This sample shows how to call RemoveBusinessMetadataAttributesAsync with all parameters and request content. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new +{ + key = new object(), +}); +Response response = await client.RemoveBusinessMetadataAttributesAsync("", "", content); + +Console.WriteLine(response.Status); +]]> + + + +This sample shows how to call RemoveBusinessMetadataAttributes. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new +{ + key = new object(), +}); +Response response = client.RemoveBusinessMetadataAttributes("", "", content); + +Console.WriteLine(response.Status); +]]> +This sample shows how to call RemoveBusinessMetadataAttributes with all parameters and request content. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new +{ + key = new object(), +}); +Response response = client.RemoveBusinessMetadataAttributes("", "", content); + +Console.WriteLine(response.Status); +]]> + + + +This sample shows how to call AddOrUpdateBusinessMetadataAttributesAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.AddOrUpdateBusinessMetadataAttributesAsync("", "", new Dictionary +{ + ["key"] = BinaryData.FromObjectAsJson(new object()) +}); +]]> +This sample shows how to call AddOrUpdateBusinessMetadataAttributesAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.AddOrUpdateBusinessMetadataAttributesAsync("", "", new Dictionary +{ + ["key"] = BinaryData.FromObjectAsJson(new object()) +}); +]]> + + + +This sample shows how to call AddOrUpdateBusinessMetadataAttributes. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.AddOrUpdateBusinessMetadataAttributes("", "", new Dictionary +{ + ["key"] = BinaryData.FromObjectAsJson(new object()) +}); +]]> +This sample shows how to call AddOrUpdateBusinessMetadataAttributes with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.AddOrUpdateBusinessMetadataAttributes("", "", new Dictionary +{ + ["key"] = BinaryData.FromObjectAsJson(new object()) +}); +]]> + + + +This sample shows how to call AddOrUpdateBusinessMetadataAttributesAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new +{ + key = new object(), +}); +Response response = await client.AddOrUpdateBusinessMetadataAttributesAsync("", "", content); + +Console.WriteLine(response.Status); +]]> +This sample shows how to call AddOrUpdateBusinessMetadataAttributesAsync with all parameters and request content. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new +{ + key = new object(), +}); +Response response = await client.AddOrUpdateBusinessMetadataAttributesAsync("", "", content); + +Console.WriteLine(response.Status); +]]> + + + +This sample shows how to call AddOrUpdateBusinessMetadataAttributes. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new +{ + key = new object(), +}); +Response response = client.AddOrUpdateBusinessMetadataAttributes("", "", content); + +Console.WriteLine(response.Status); +]]> +This sample shows how to call AddOrUpdateBusinessMetadataAttributes with all parameters and request content. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new +{ + key = new object(), +}); +Response response = client.AddOrUpdateBusinessMetadataAttributes("", "", content); + +Console.WriteLine(response.Status); +]]> + + + +This sample shows how to call GetSampleBusinessMetadataTemplateAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.GetSampleBusinessMetadataTemplateAsync(); +]]> +This sample shows how to call GetSampleBusinessMetadataTemplateAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.GetSampleBusinessMetadataTemplateAsync(); +]]> + + + +This sample shows how to call GetSampleBusinessMetadataTemplate. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.GetSampleBusinessMetadataTemplate(); +]]> +This sample shows how to call GetSampleBusinessMetadataTemplate with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.GetSampleBusinessMetadataTemplate(); +]]> + + + +This sample shows how to call GetSampleBusinessMetadataTemplateAsync and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.GetSampleBusinessMetadataTemplateAsync(null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call GetSampleBusinessMetadataTemplateAsync with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.GetSampleBusinessMetadataTemplateAsync(null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> + + + +This sample shows how to call GetSampleBusinessMetadataTemplate and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.GetSampleBusinessMetadataTemplate(null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call GetSampleBusinessMetadataTemplate with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.GetSampleBusinessMetadataTemplate(null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> + + + +This sample shows how to call ImportBusinessMetadataAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.ImportBusinessMetadataAsync(BinaryData.FromObjectAsJson(new object())); +]]> +This sample shows how to call ImportBusinessMetadataAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.ImportBusinessMetadataAsync(BinaryData.FromObjectAsJson(new object())); +]]> + + + +This sample shows how to call ImportBusinessMetadata. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.ImportBusinessMetadata(BinaryData.FromObjectAsJson(new object())); +]]> +This sample shows how to call ImportBusinessMetadata with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.ImportBusinessMetadata(BinaryData.FromObjectAsJson(new object())); +]]> + + + +This sample shows how to call ImportBusinessMetadataAsync and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new +{ + uploadedInputStream = new object(), +}); +Response response = await client.ImportBusinessMetadataAsync(content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call ImportBusinessMetadataAsync with all request content and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new +{ + uploadedInputStream = new object(), +}); +Response response = await client.ImportBusinessMetadataAsync(content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("failedImportInfoList")[0].GetProperty("childObjectName").ToString()); +Console.WriteLine(result.GetProperty("failedImportInfoList")[0].GetProperty("importStatus").ToString()); +Console.WriteLine(result.GetProperty("failedImportInfoList")[0].GetProperty("parentObjectName").ToString()); +Console.WriteLine(result.GetProperty("failedImportInfoList")[0].GetProperty("remarks").ToString()); +Console.WriteLine(result.GetProperty("successImportInfoList")[0].GetProperty("childObjectName").ToString()); +Console.WriteLine(result.GetProperty("successImportInfoList")[0].GetProperty("importStatus").ToString()); +Console.WriteLine(result.GetProperty("successImportInfoList")[0].GetProperty("parentObjectName").ToString()); +Console.WriteLine(result.GetProperty("successImportInfoList")[0].GetProperty("remarks").ToString()); +]]> + + + +This sample shows how to call ImportBusinessMetadata and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new +{ + uploadedInputStream = new object(), +}); +Response response = client.ImportBusinessMetadata(content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call ImportBusinessMetadata with all request content and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new +{ + uploadedInputStream = new object(), +}); +Response response = client.ImportBusinessMetadata(content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("failedImportInfoList")[0].GetProperty("childObjectName").ToString()); +Console.WriteLine(result.GetProperty("failedImportInfoList")[0].GetProperty("importStatus").ToString()); +Console.WriteLine(result.GetProperty("failedImportInfoList")[0].GetProperty("parentObjectName").ToString()); +Console.WriteLine(result.GetProperty("failedImportInfoList")[0].GetProperty("remarks").ToString()); +Console.WriteLine(result.GetProperty("successImportInfoList")[0].GetProperty("childObjectName").ToString()); +Console.WriteLine(result.GetProperty("successImportInfoList")[0].GetProperty("importStatus").ToString()); +Console.WriteLine(result.GetProperty("successImportInfoList")[0].GetProperty("parentObjectName").ToString()); +Console.WriteLine(result.GetProperty("successImportInfoList")[0].GetProperty("remarks").ToString()); +]]> + + + +This sample shows how to call RemoveLabelsAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.RemoveLabelsAsync("", new string[] { "" }); +]]> +This sample shows how to call RemoveLabelsAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.RemoveLabelsAsync("", new string[] { "" }); +]]> + + + +This sample shows how to call RemoveLabels. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.RemoveLabels("", new string[] { "" }); +]]> +This sample shows how to call RemoveLabels with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.RemoveLabels("", new string[] { "" }); +]]> + + + +This sample shows how to call RemoveLabelsAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object[] +{ + "" +}); +Response response = await client.RemoveLabelsAsync("", content); + +Console.WriteLine(response.Status); +]]> +This sample shows how to call RemoveLabelsAsync with all parameters and request content. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object[] +{ + "" +}); +Response response = await client.RemoveLabelsAsync("", content); + +Console.WriteLine(response.Status); +]]> + + + +This sample shows how to call RemoveLabels. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object[] +{ + "" +}); +Response response = client.RemoveLabels("", content); + +Console.WriteLine(response.Status); +]]> +This sample shows how to call RemoveLabels with all parameters and request content. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object[] +{ + "" +}); +Response response = client.RemoveLabels("", content); + +Console.WriteLine(response.Status); +]]> + + + +This sample shows how to call SetLabelsAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.SetLabelsAsync("", new string[] { "" }); +]]> +This sample shows how to call SetLabelsAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.SetLabelsAsync("", new string[] { "" }); +]]> + + + +This sample shows how to call SetLabels. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.SetLabels("", new string[] { "" }); +]]> +This sample shows how to call SetLabels with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.SetLabels("", new string[] { "" }); +]]> + + + +This sample shows how to call SetLabelsAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object[] +{ + "" +}); +Response response = await client.SetLabelsAsync("", content); + +Console.WriteLine(response.Status); +]]> +This sample shows how to call SetLabelsAsync with all parameters and request content. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object[] +{ + "" +}); +Response response = await client.SetLabelsAsync("", content); + +Console.WriteLine(response.Status); +]]> + + + +This sample shows how to call SetLabels. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object[] +{ + "" +}); +Response response = client.SetLabels("", content); + +Console.WriteLine(response.Status); +]]> +This sample shows how to call SetLabels with all parameters and request content. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object[] +{ + "" +}); +Response response = client.SetLabels("", content); + +Console.WriteLine(response.Status); +]]> + + + +This sample shows how to call AddLabelAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.AddLabelAsync("", new string[] { "" }); +]]> +This sample shows how to call AddLabelAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.AddLabelAsync("", new string[] { "" }); +]]> + + + +This sample shows how to call AddLabel. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.AddLabel("", new string[] { "" }); +]]> +This sample shows how to call AddLabel with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.AddLabel("", new string[] { "" }); +]]> + + + +This sample shows how to call AddLabelAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object[] +{ + "" +}); +Response response = await client.AddLabelAsync("", content); + +Console.WriteLine(response.Status); +]]> +This sample shows how to call AddLabelAsync with all parameters and request content. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object[] +{ + "" +}); +Response response = await client.AddLabelAsync("", content); + +Console.WriteLine(response.Status); +]]> + + + +This sample shows how to call AddLabel. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object[] +{ + "" +}); +Response response = client.AddLabel("", content); + +Console.WriteLine(response.Status); +]]> +This sample shows how to call AddLabel with all parameters and request content. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object[] +{ + "" +}); +Response response = client.AddLabel("", content); + +Console.WriteLine(response.Status); +]]> + + + +This sample shows how to call RemoveLabelsByAttributeAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.RemoveLabelsByAttributeAsync("", new string[] { "" }); +]]> +This sample shows how to call RemoveLabelsByAttributeAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.RemoveLabelsByAttributeAsync("", new string[] { "" }, attr: ""); +]]> + + + +This sample shows how to call RemoveLabelsByAttribute. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.RemoveLabelsByAttribute("", new string[] { "" }); +]]> +This sample shows how to call RemoveLabelsByAttribute with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.RemoveLabelsByAttribute("", new string[] { "" }, attr: ""); +]]> + + + +This sample shows how to call RemoveLabelsByAttributeAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object[] +{ + "" +}); +Response response = await client.RemoveLabelsByAttributeAsync("", content); + +Console.WriteLine(response.Status); +]]> +This sample shows how to call RemoveLabelsByAttributeAsync with all parameters and request content. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object[] +{ + "" +}); +Response response = await client.RemoveLabelsByAttributeAsync("", content, attr: ""); + +Console.WriteLine(response.Status); +]]> + + + +This sample shows how to call RemoveLabelsByAttribute. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object[] +{ + "" +}); +Response response = client.RemoveLabelsByAttribute("", content); + +Console.WriteLine(response.Status); +]]> +This sample shows how to call RemoveLabelsByAttribute with all parameters and request content. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object[] +{ + "" +}); +Response response = client.RemoveLabelsByAttribute("", content, attr: ""); + +Console.WriteLine(response.Status); +]]> + + + +This sample shows how to call SetLabelsByAttributeAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.SetLabelsByAttributeAsync("", new string[] { "" }); +]]> +This sample shows how to call SetLabelsByAttributeAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.SetLabelsByAttributeAsync("", new string[] { "" }, attr: ""); +]]> + + + +This sample shows how to call SetLabelsByAttribute. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.SetLabelsByAttribute("", new string[] { "" }); +]]> +This sample shows how to call SetLabelsByAttribute with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.SetLabelsByAttribute("", new string[] { "" }, attr: ""); +]]> + + + +This sample shows how to call SetLabelsByAttributeAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object[] +{ + "" +}); +Response response = await client.SetLabelsByAttributeAsync("", content); + +Console.WriteLine(response.Status); +]]> +This sample shows how to call SetLabelsByAttributeAsync with all parameters and request content. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object[] +{ + "" +}); +Response response = await client.SetLabelsByAttributeAsync("", content, attr: ""); + +Console.WriteLine(response.Status); +]]> + + + +This sample shows how to call SetLabelsByAttribute. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object[] +{ + "" +}); +Response response = client.SetLabelsByAttribute("", content); + +Console.WriteLine(response.Status); +]]> +This sample shows how to call SetLabelsByAttribute with all parameters and request content. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object[] +{ + "" +}); +Response response = client.SetLabelsByAttribute("", content, attr: ""); + +Console.WriteLine(response.Status); +]]> + + + +This sample shows how to call AddLabelsByAttributeAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.AddLabelsByAttributeAsync("", new string[] { "" }); +]]> +This sample shows how to call AddLabelsByAttributeAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = await client.AddLabelsByAttributeAsync("", new string[] { "" }, attr: ""); +]]> + + + +This sample shows how to call AddLabelsByAttribute. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.AddLabelsByAttribute("", new string[] { "" }); +]]> +This sample shows how to call AddLabelsByAttribute with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +Response response = client.AddLabelsByAttribute("", new string[] { "" }, attr: ""); +]]> + + + +This sample shows how to call AddLabelsByAttributeAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object[] +{ + "" +}); +Response response = await client.AddLabelsByAttributeAsync("", content); + +Console.WriteLine(response.Status); +]]> +This sample shows how to call AddLabelsByAttributeAsync with all parameters and request content. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object[] +{ + "" +}); +Response response = await client.AddLabelsByAttributeAsync("", content, attr: ""); + +Console.WriteLine(response.Status); +]]> + + + +This sample shows how to call AddLabelsByAttribute. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object[] +{ + "" +}); +Response response = client.AddLabelsByAttribute("", content); + +Console.WriteLine(response.Status); +]]> +This sample shows how to call AddLabelsByAttribute with all parameters and request content. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object[] +{ + "" +}); +Response response = client.AddLabelsByAttribute("", content, attr: ""); + +Console.WriteLine(response.Status); +]]> + + + +This sample shows how to call MoveEntitiesToCollectionAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +MoveEntitiesOptions moveEntitiesRequest = new MoveEntitiesOptions(); +Response response = await client.MoveEntitiesToCollectionAsync("", moveEntitiesRequest); +]]> +This sample shows how to call MoveEntitiesToCollectionAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +MoveEntitiesOptions moveEntitiesRequest = new MoveEntitiesOptions +{ + EntityGuids = { "" }, +}; +Response response = await client.MoveEntitiesToCollectionAsync("", moveEntitiesRequest); +]]> + + + +This sample shows how to call MoveEntitiesToCollection. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +MoveEntitiesOptions moveEntitiesRequest = new MoveEntitiesOptions(); +Response response = client.MoveEntitiesToCollection("", moveEntitiesRequest); +]]> +This sample shows how to call MoveEntitiesToCollection with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +MoveEntitiesOptions moveEntitiesRequest = new MoveEntitiesOptions +{ + EntityGuids = { "" }, +}; +Response response = client.MoveEntitiesToCollection("", moveEntitiesRequest); +]]> + + + +This sample shows how to call MoveEntitiesToCollectionAsync and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object()); +Response response = await client.MoveEntitiesToCollectionAsync("", content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call MoveEntitiesToCollectionAsync with all parameters and request content and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new +{ + entityGuids = new object[] + { + "" + }, +}); +Response response = await client.MoveEntitiesToCollectionAsync("", content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("guidAssignments").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classificationNames")[0].ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("isIncomplete").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("labels")[0].ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meaningNames")[0].ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("confidence").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classificationNames")[0].ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("isIncomplete").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("labels")[0].ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meaningNames")[0].ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("confidence").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("status").ToString()); +]]> + + + +This sample shows how to call MoveEntitiesToCollection and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object()); +Response response = client.MoveEntitiesToCollection("", content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call MoveEntitiesToCollection with all parameters and request content and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new +{ + entityGuids = new object[] + { + "" + }, +}); +Response response = client.MoveEntitiesToCollection("", content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("guidAssignments").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classificationNames")[0].ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("isIncomplete").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("labels")[0].ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meaningNames")[0].ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("confidence").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classificationNames")[0].ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("isIncomplete").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("labels")[0].ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meaningNames")[0].ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("confidence").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("status").ToString()); +]]> + + + \ No newline at end of file diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/Docs/Glossary.xml b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/Docs/Glossary.xml new file mode 100644 index 0000000000000..025901e05865a --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/Docs/Glossary.xml @@ -0,0 +1,8975 @@ + + + + + +This sample shows how to call BatchGetAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response> response = await client.BatchGetAsync(); +]]> +This sample shows how to call BatchGetAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response> response = await client.BatchGetAsync(limit: 1234, offset: 1234, sort: "", ignoreTermsAndCategories: true); +]]> + + + +This sample shows how to call BatchGet. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response> response = client.BatchGet(); +]]> +This sample shows how to call BatchGet with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response> response = client.BatchGet(limit: 1234, offset: 1234, sort: "", ignoreTermsAndCategories: true); +]]> + + + +This sample shows how to call BatchGetAsync and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = await client.BatchGetAsync(null, null, null, null, null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result[0].ToString()); +]]> +This sample shows how to call BatchGetAsync with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = await client.BatchGetAsync(1234, 1234, "", true, null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result[0].GetProperty("guid").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result[0].GetProperty("longDescription").ToString()); +Console.WriteLine(result[0].GetProperty("name").ToString()); +Console.WriteLine(result[0].GetProperty("qualifiedName").ToString()); +Console.WriteLine(result[0].GetProperty("shortDescription").ToString()); +Console.WriteLine(result[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result[0].GetProperty("createTime").ToString()); +Console.WriteLine(result[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result[0].GetProperty("updateTime").ToString()); +Console.WriteLine(result[0].GetProperty("updatedBy").ToString()); +Console.WriteLine(result[0].GetProperty("categories")[0].GetProperty("categoryGuid").ToString()); +Console.WriteLine(result[0].GetProperty("categories")[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("categories")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("categories")[0].GetProperty("parentCategoryGuid").ToString()); +Console.WriteLine(result[0].GetProperty("categories")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("language").ToString()); +Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("status").ToString()); +Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result[0].GetProperty("usage").ToString()); +]]> + + + +This sample shows how to call BatchGet and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = client.BatchGet(null, null, null, null, null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result[0].ToString()); +]]> +This sample shows how to call BatchGet with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = client.BatchGet(1234, 1234, "", true, null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result[0].GetProperty("guid").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result[0].GetProperty("longDescription").ToString()); +Console.WriteLine(result[0].GetProperty("name").ToString()); +Console.WriteLine(result[0].GetProperty("qualifiedName").ToString()); +Console.WriteLine(result[0].GetProperty("shortDescription").ToString()); +Console.WriteLine(result[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result[0].GetProperty("createTime").ToString()); +Console.WriteLine(result[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result[0].GetProperty("updateTime").ToString()); +Console.WriteLine(result[0].GetProperty("updatedBy").ToString()); +Console.WriteLine(result[0].GetProperty("categories")[0].GetProperty("categoryGuid").ToString()); +Console.WriteLine(result[0].GetProperty("categories")[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("categories")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("categories")[0].GetProperty("parentCategoryGuid").ToString()); +Console.WriteLine(result[0].GetProperty("categories")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("language").ToString()); +Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("status").ToString()); +Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result[0].GetProperty("usage").ToString()); +]]> + + + +This sample shows how to call CreateAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +AtlasGlossary atlasGlossary = new AtlasGlossary(); +Response response = await client.CreateAsync(atlasGlossary); +]]> +This sample shows how to call CreateAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +AtlasGlossary atlasGlossary = new AtlasGlossary +{ + Guid = "", + Classifications = {new AtlasClassification + { + Attributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + TypeName = "", + LastModifiedTS = "", + EntityGuid = "", + EntityStatus = EntityStatus.Active, + RemovePropagationsOnEntityDelete = true, + ValidityPeriods = {new TimeBoundary + { + EndTime = "", + StartTime = "", + TimeZone = "", + }}, + }}, + LongDescription = "", + Name = "", + QualifiedName = "", + ShortDescription = "", + LastModifiedTS = "", + CreateTime = 1234L, + CreatedBy = "", + UpdateTime = 1234L, + UpdatedBy = "", + Categories = {new AtlasRelatedCategoryHeader + { + CategoryGuid = "", + Description = "", + DisplayText = "", + ParentCategoryGuid = "", + RelationGuid = "", + }}, + Language = "", + Terms = {new AtlasRelatedTermHeader + { + Description = "", + DisplayText = "", + Expression = "", + RelationGuid = "", + Status = AtlasTermRelationshipStatus.Draft, + Steward = "", + TermGuid = "", + }}, + Usage = "", +}; +Response response = await client.CreateAsync(atlasGlossary); +]]> + + + +This sample shows how to call Create. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +AtlasGlossary atlasGlossary = new AtlasGlossary(); +Response response = client.Create(atlasGlossary); +]]> +This sample shows how to call Create with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +AtlasGlossary atlasGlossary = new AtlasGlossary +{ + Guid = "", + Classifications = {new AtlasClassification + { + Attributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + TypeName = "", + LastModifiedTS = "", + EntityGuid = "", + EntityStatus = EntityStatus.Active, + RemovePropagationsOnEntityDelete = true, + ValidityPeriods = {new TimeBoundary + { + EndTime = "", + StartTime = "", + TimeZone = "", + }}, + }}, + LongDescription = "", + Name = "", + QualifiedName = "", + ShortDescription = "", + LastModifiedTS = "", + CreateTime = 1234L, + CreatedBy = "", + UpdateTime = 1234L, + UpdatedBy = "", + Categories = {new AtlasRelatedCategoryHeader + { + CategoryGuid = "", + Description = "", + DisplayText = "", + ParentCategoryGuid = "", + RelationGuid = "", + }}, + Language = "", + Terms = {new AtlasRelatedTermHeader + { + Description = "", + DisplayText = "", + Expression = "", + RelationGuid = "", + Status = AtlasTermRelationshipStatus.Draft, + Steward = "", + TermGuid = "", + }}, + Usage = "", +}; +Response response = client.Create(atlasGlossary); +]]> + + + +This sample shows how to call CreateAsync and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object()); +Response response = await client.CreateAsync(content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call CreateAsync with all request content and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new +{ + guid = "", + classifications = new object[] + { + new + { + attributes = new + { + key = new object(), + }, + typeName = "", + lastModifiedTS = "", + entityGuid = "", + entityStatus = "ACTIVE", + removePropagationsOnEntityDelete = true, + validityPeriods = new object[] + { + new + { + endTime = "", + startTime = "", + timeZone = "", + } + }, + } + }, + longDescription = "", + name = "", + qualifiedName = "", + shortDescription = "", + lastModifiedTS = "", + createTime = 1234L, + createdBy = "", + updateTime = 1234L, + updatedBy = "", + categories = new object[] + { + new + { + categoryGuid = "", + description = "", + displayText = "", + parentCategoryGuid = "", + relationGuid = "", + } + }, + language = "", + terms = new object[] + { + new + { + description = "", + displayText = "", + expression = "", + relationGuid = "", + status = "DRAFT", + steward = "", + termGuid = "", + } + }, + usage = "", +}); +Response response = await client.CreateAsync(content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("longDescription").ToString()); +Console.WriteLine(result.GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("qualifiedName").ToString()); +Console.WriteLine(result.GetProperty("shortDescription").ToString()); +Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("categoryGuid").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("parentCategoryGuid").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("language").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("usage").ToString()); +]]> + + + +This sample shows how to call Create and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object()); +Response response = client.Create(content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call Create with all request content and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new +{ + guid = "", + classifications = new object[] + { + new + { + attributes = new + { + key = new object(), + }, + typeName = "", + lastModifiedTS = "", + entityGuid = "", + entityStatus = "ACTIVE", + removePropagationsOnEntityDelete = true, + validityPeriods = new object[] + { + new + { + endTime = "", + startTime = "", + timeZone = "", + } + }, + } + }, + longDescription = "", + name = "", + qualifiedName = "", + shortDescription = "", + lastModifiedTS = "", + createTime = 1234L, + createdBy = "", + updateTime = 1234L, + updatedBy = "", + categories = new object[] + { + new + { + categoryGuid = "", + description = "", + displayText = "", + parentCategoryGuid = "", + relationGuid = "", + } + }, + language = "", + terms = new object[] + { + new + { + description = "", + displayText = "", + expression = "", + relationGuid = "", + status = "DRAFT", + steward = "", + termGuid = "", + } + }, + usage = "", +}); +Response response = client.Create(content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("longDescription").ToString()); +Console.WriteLine(result.GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("qualifiedName").ToString()); +Console.WriteLine(result.GetProperty("shortDescription").ToString()); +Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("categoryGuid").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("parentCategoryGuid").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("language").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("usage").ToString()); +]]> + + + +This sample shows how to call CreateCategoriesAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response> response = await client.CreateCategoriesAsync(new AtlasGlossaryCategory[] +{ + new AtlasGlossaryCategory() +}); +]]> +This sample shows how to call CreateCategoriesAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response> response = await client.CreateCategoriesAsync(new AtlasGlossaryCategory[] +{ + new AtlasGlossaryCategory + { + Guid = "", + Classifications = {new AtlasClassification + { + Attributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + TypeName = "", + LastModifiedTS = "", + EntityGuid = "", + EntityStatus = EntityStatus.Active, + RemovePropagationsOnEntityDelete = true, + ValidityPeriods = {new TimeBoundary + { + EndTime = "", + StartTime = "", + TimeZone = "", + }}, + }}, + LongDescription = "", + Name = "", + QualifiedName = "", + ShortDescription = "", + LastModifiedTS = "", + CreateTime = 1234L, + CreatedBy = "", + UpdateTime = 1234L, + UpdatedBy = "", + Anchor = new AtlasGlossaryHeader + { + DisplayText = "", + GlossaryGuid = "", + RelationGuid = "", + }, + ChildrenCategories = {new AtlasRelatedCategoryHeader + { + CategoryGuid = "", + Description = "", + DisplayText = "", + ParentCategoryGuid = "", + RelationGuid = "", + }}, + ParentCategory = default, + Terms = {new AtlasRelatedTermHeader + { + Description = "", + DisplayText = "", + Expression = "", + RelationGuid = "", + Status = AtlasTermRelationshipStatus.Draft, + Steward = "", + TermGuid = "", + }}, + } +}); +]]> + + + +This sample shows how to call CreateCategories. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response> response = client.CreateCategories(new AtlasGlossaryCategory[] +{ + new AtlasGlossaryCategory() +}); +]]> +This sample shows how to call CreateCategories with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response> response = client.CreateCategories(new AtlasGlossaryCategory[] +{ + new AtlasGlossaryCategory + { + Guid = "", + Classifications = {new AtlasClassification + { + Attributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + TypeName = "", + LastModifiedTS = "", + EntityGuid = "", + EntityStatus = EntityStatus.Active, + RemovePropagationsOnEntityDelete = true, + ValidityPeriods = {new TimeBoundary + { + EndTime = "", + StartTime = "", + TimeZone = "", + }}, + }}, + LongDescription = "", + Name = "", + QualifiedName = "", + ShortDescription = "", + LastModifiedTS = "", + CreateTime = 1234L, + CreatedBy = "", + UpdateTime = 1234L, + UpdatedBy = "", + Anchor = new AtlasGlossaryHeader + { + DisplayText = "", + GlossaryGuid = "", + RelationGuid = "", + }, + ChildrenCategories = {new AtlasRelatedCategoryHeader + { + CategoryGuid = "", + Description = "", + DisplayText = "", + ParentCategoryGuid = "", + RelationGuid = "", + }}, + ParentCategory = default, + Terms = {new AtlasRelatedTermHeader + { + Description = "", + DisplayText = "", + Expression = "", + RelationGuid = "", + Status = AtlasTermRelationshipStatus.Draft, + Steward = "", + TermGuid = "", + }}, + } +}); +]]> + + + +This sample shows how to call CreateCategoriesAsync and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object[] +{ + new object() +}); +Response response = await client.CreateCategoriesAsync(content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result[0].ToString()); +]]> +This sample shows how to call CreateCategoriesAsync with all request content and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object[] +{ + new + { + guid = "", + classifications = new object[] + { + new + { + attributes = new + { + key = new object(), + }, + typeName = "", + lastModifiedTS = "", + entityGuid = "", + entityStatus = "ACTIVE", + removePropagationsOnEntityDelete = true, + validityPeriods = new object[] + { + new + { + endTime = "", + startTime = "", + timeZone = "", + } + }, + } + }, + longDescription = "", + name = "", + qualifiedName = "", + shortDescription = "", + lastModifiedTS = "", + createTime = 1234L, + createdBy = "", + updateTime = 1234L, + updatedBy = "", + anchor = new + { + displayText = "", + glossaryGuid = "", + relationGuid = "", + }, + childrenCategories = new object[] + { + new + { + categoryGuid = "", + description = "", + displayText = "", + parentCategoryGuid = "", + relationGuid = "", + } + }, + terms = new object[] + { + new + { + description = "", + displayText = "", + expression = "", + relationGuid = "", + status = "DRAFT", + steward = "", + termGuid = "", + } + }, + } +}); +Response response = await client.CreateCategoriesAsync(content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result[0].GetProperty("guid").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result[0].GetProperty("longDescription").ToString()); +Console.WriteLine(result[0].GetProperty("name").ToString()); +Console.WriteLine(result[0].GetProperty("qualifiedName").ToString()); +Console.WriteLine(result[0].GetProperty("shortDescription").ToString()); +Console.WriteLine(result[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result[0].GetProperty("createTime").ToString()); +Console.WriteLine(result[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result[0].GetProperty("updateTime").ToString()); +Console.WriteLine(result[0].GetProperty("updatedBy").ToString()); +Console.WriteLine(result[0].GetProperty("anchor").GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("anchor").GetProperty("glossaryGuid").ToString()); +Console.WriteLine(result[0].GetProperty("anchor").GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("childrenCategories")[0].GetProperty("categoryGuid").ToString()); +Console.WriteLine(result[0].GetProperty("childrenCategories")[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("childrenCategories")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("childrenCategories")[0].GetProperty("parentCategoryGuid").ToString()); +Console.WriteLine(result[0].GetProperty("childrenCategories")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("parentCategory").GetProperty("categoryGuid").ToString()); +Console.WriteLine(result[0].GetProperty("parentCategory").GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("parentCategory").GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("parentCategory").GetProperty("parentCategoryGuid").ToString()); +Console.WriteLine(result[0].GetProperty("parentCategory").GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("status").ToString()); +Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("termGuid").ToString()); +]]> + + + +This sample shows how to call CreateCategories and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object[] +{ + new object() +}); +Response response = client.CreateCategories(content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result[0].ToString()); +]]> +This sample shows how to call CreateCategories with all request content and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object[] +{ + new + { + guid = "", + classifications = new object[] + { + new + { + attributes = new + { + key = new object(), + }, + typeName = "", + lastModifiedTS = "", + entityGuid = "", + entityStatus = "ACTIVE", + removePropagationsOnEntityDelete = true, + validityPeriods = new object[] + { + new + { + endTime = "", + startTime = "", + timeZone = "", + } + }, + } + }, + longDescription = "", + name = "", + qualifiedName = "", + shortDescription = "", + lastModifiedTS = "", + createTime = 1234L, + createdBy = "", + updateTime = 1234L, + updatedBy = "", + anchor = new + { + displayText = "", + glossaryGuid = "", + relationGuid = "", + }, + childrenCategories = new object[] + { + new + { + categoryGuid = "", + description = "", + displayText = "", + parentCategoryGuid = "", + relationGuid = "", + } + }, + terms = new object[] + { + new + { + description = "", + displayText = "", + expression = "", + relationGuid = "", + status = "DRAFT", + steward = "", + termGuid = "", + } + }, + } +}); +Response response = client.CreateCategories(content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result[0].GetProperty("guid").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result[0].GetProperty("longDescription").ToString()); +Console.WriteLine(result[0].GetProperty("name").ToString()); +Console.WriteLine(result[0].GetProperty("qualifiedName").ToString()); +Console.WriteLine(result[0].GetProperty("shortDescription").ToString()); +Console.WriteLine(result[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result[0].GetProperty("createTime").ToString()); +Console.WriteLine(result[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result[0].GetProperty("updateTime").ToString()); +Console.WriteLine(result[0].GetProperty("updatedBy").ToString()); +Console.WriteLine(result[0].GetProperty("anchor").GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("anchor").GetProperty("glossaryGuid").ToString()); +Console.WriteLine(result[0].GetProperty("anchor").GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("childrenCategories")[0].GetProperty("categoryGuid").ToString()); +Console.WriteLine(result[0].GetProperty("childrenCategories")[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("childrenCategories")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("childrenCategories")[0].GetProperty("parentCategoryGuid").ToString()); +Console.WriteLine(result[0].GetProperty("childrenCategories")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("parentCategory").GetProperty("categoryGuid").ToString()); +Console.WriteLine(result[0].GetProperty("parentCategory").GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("parentCategory").GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("parentCategory").GetProperty("parentCategoryGuid").ToString()); +Console.WriteLine(result[0].GetProperty("parentCategory").GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("status").ToString()); +Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("termGuid").ToString()); +]]> + + + +This sample shows how to call CreateCategoryAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +AtlasGlossaryCategory glossaryCategory = new AtlasGlossaryCategory(); +Response response = await client.CreateCategoryAsync(glossaryCategory); +]]> +This sample shows how to call CreateCategoryAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +AtlasGlossaryCategory glossaryCategory = new AtlasGlossaryCategory +{ + Guid = "", + Classifications = {new AtlasClassification + { + Attributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + TypeName = "", + LastModifiedTS = "", + EntityGuid = "", + EntityStatus = EntityStatus.Active, + RemovePropagationsOnEntityDelete = true, + ValidityPeriods = {new TimeBoundary + { + EndTime = "", + StartTime = "", + TimeZone = "", + }}, + }}, + LongDescription = "", + Name = "", + QualifiedName = "", + ShortDescription = "", + LastModifiedTS = "", + CreateTime = 1234L, + CreatedBy = "", + UpdateTime = 1234L, + UpdatedBy = "", + Anchor = new AtlasGlossaryHeader + { + DisplayText = "", + GlossaryGuid = "", + RelationGuid = "", + }, + ChildrenCategories = {new AtlasRelatedCategoryHeader + { + CategoryGuid = "", + Description = "", + DisplayText = "", + ParentCategoryGuid = "", + RelationGuid = "", + }}, + ParentCategory = default, + Terms = {new AtlasRelatedTermHeader + { + Description = "", + DisplayText = "", + Expression = "", + RelationGuid = "", + Status = AtlasTermRelationshipStatus.Draft, + Steward = "", + TermGuid = "", + }}, +}; +Response response = await client.CreateCategoryAsync(glossaryCategory); +]]> + + + +This sample shows how to call CreateCategory. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +AtlasGlossaryCategory glossaryCategory = new AtlasGlossaryCategory(); +Response response = client.CreateCategory(glossaryCategory); +]]> +This sample shows how to call CreateCategory with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +AtlasGlossaryCategory glossaryCategory = new AtlasGlossaryCategory +{ + Guid = "", + Classifications = {new AtlasClassification + { + Attributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + TypeName = "", + LastModifiedTS = "", + EntityGuid = "", + EntityStatus = EntityStatus.Active, + RemovePropagationsOnEntityDelete = true, + ValidityPeriods = {new TimeBoundary + { + EndTime = "", + StartTime = "", + TimeZone = "", + }}, + }}, + LongDescription = "", + Name = "", + QualifiedName = "", + ShortDescription = "", + LastModifiedTS = "", + CreateTime = 1234L, + CreatedBy = "", + UpdateTime = 1234L, + UpdatedBy = "", + Anchor = new AtlasGlossaryHeader + { + DisplayText = "", + GlossaryGuid = "", + RelationGuid = "", + }, + ChildrenCategories = {new AtlasRelatedCategoryHeader + { + CategoryGuid = "", + Description = "", + DisplayText = "", + ParentCategoryGuid = "", + RelationGuid = "", + }}, + ParentCategory = default, + Terms = {new AtlasRelatedTermHeader + { + Description = "", + DisplayText = "", + Expression = "", + RelationGuid = "", + Status = AtlasTermRelationshipStatus.Draft, + Steward = "", + TermGuid = "", + }}, +}; +Response response = client.CreateCategory(glossaryCategory); +]]> + + + +This sample shows how to call CreateCategoryAsync and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object()); +Response response = await client.CreateCategoryAsync(content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call CreateCategoryAsync with all request content and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new +{ + guid = "", + classifications = new object[] + { + new + { + attributes = new + { + key = new object(), + }, + typeName = "", + lastModifiedTS = "", + entityGuid = "", + entityStatus = "ACTIVE", + removePropagationsOnEntityDelete = true, + validityPeriods = new object[] + { + new + { + endTime = "", + startTime = "", + timeZone = "", + } + }, + } + }, + longDescription = "", + name = "", + qualifiedName = "", + shortDescription = "", + lastModifiedTS = "", + createTime = 1234L, + createdBy = "", + updateTime = 1234L, + updatedBy = "", + anchor = new + { + displayText = "", + glossaryGuid = "", + relationGuid = "", + }, + childrenCategories = new object[] + { + new + { + categoryGuid = "", + description = "", + displayText = "", + parentCategoryGuid = "", + relationGuid = "", + } + }, + terms = new object[] + { + new + { + description = "", + displayText = "", + expression = "", + relationGuid = "", + status = "DRAFT", + steward = "", + termGuid = "", + } + }, +}); +Response response = await client.CreateCategoryAsync(content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("longDescription").ToString()); +Console.WriteLine(result.GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("qualifiedName").ToString()); +Console.WriteLine(result.GetProperty("shortDescription").ToString()); +Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("anchor").GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("anchor").GetProperty("glossaryGuid").ToString()); +Console.WriteLine(result.GetProperty("anchor").GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("categoryGuid").ToString()); +Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("parentCategoryGuid").ToString()); +Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("parentCategory").GetProperty("categoryGuid").ToString()); +Console.WriteLine(result.GetProperty("parentCategory").GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("parentCategory").GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("parentCategory").GetProperty("parentCategoryGuid").ToString()); +Console.WriteLine(result.GetProperty("parentCategory").GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("termGuid").ToString()); +]]> + + + +This sample shows how to call CreateCategory and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object()); +Response response = client.CreateCategory(content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call CreateCategory with all request content and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new +{ + guid = "", + classifications = new object[] + { + new + { + attributes = new + { + key = new object(), + }, + typeName = "", + lastModifiedTS = "", + entityGuid = "", + entityStatus = "ACTIVE", + removePropagationsOnEntityDelete = true, + validityPeriods = new object[] + { + new + { + endTime = "", + startTime = "", + timeZone = "", + } + }, + } + }, + longDescription = "", + name = "", + qualifiedName = "", + shortDescription = "", + lastModifiedTS = "", + createTime = 1234L, + createdBy = "", + updateTime = 1234L, + updatedBy = "", + anchor = new + { + displayText = "", + glossaryGuid = "", + relationGuid = "", + }, + childrenCategories = new object[] + { + new + { + categoryGuid = "", + description = "", + displayText = "", + parentCategoryGuid = "", + relationGuid = "", + } + }, + terms = new object[] + { + new + { + description = "", + displayText = "", + expression = "", + relationGuid = "", + status = "DRAFT", + steward = "", + termGuid = "", + } + }, +}); +Response response = client.CreateCategory(content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("longDescription").ToString()); +Console.WriteLine(result.GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("qualifiedName").ToString()); +Console.WriteLine(result.GetProperty("shortDescription").ToString()); +Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("anchor").GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("anchor").GetProperty("glossaryGuid").ToString()); +Console.WriteLine(result.GetProperty("anchor").GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("categoryGuid").ToString()); +Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("parentCategoryGuid").ToString()); +Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("parentCategory").GetProperty("categoryGuid").ToString()); +Console.WriteLine(result.GetProperty("parentCategory").GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("parentCategory").GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("parentCategory").GetProperty("parentCategoryGuid").ToString()); +Console.WriteLine(result.GetProperty("parentCategory").GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("termGuid").ToString()); +]]> + + + +This sample shows how to call GetCategoryAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = await client.GetCategoryAsync(""); +]]> +This sample shows how to call GetCategoryAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = await client.GetCategoryAsync(""); +]]> + + + +This sample shows how to call GetCategory. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = client.GetCategory(""); +]]> +This sample shows how to call GetCategory with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = client.GetCategory(""); +]]> + + + +This sample shows how to call GetCategoryAsync and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = await client.GetCategoryAsync("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call GetCategoryAsync with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = await client.GetCategoryAsync("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("longDescription").ToString()); +Console.WriteLine(result.GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("qualifiedName").ToString()); +Console.WriteLine(result.GetProperty("shortDescription").ToString()); +Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("anchor").GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("anchor").GetProperty("glossaryGuid").ToString()); +Console.WriteLine(result.GetProperty("anchor").GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("categoryGuid").ToString()); +Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("parentCategoryGuid").ToString()); +Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("parentCategory").GetProperty("categoryGuid").ToString()); +Console.WriteLine(result.GetProperty("parentCategory").GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("parentCategory").GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("parentCategory").GetProperty("parentCategoryGuid").ToString()); +Console.WriteLine(result.GetProperty("parentCategory").GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("termGuid").ToString()); +]]> + + + +This sample shows how to call GetCategory and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = client.GetCategory("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call GetCategory with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = client.GetCategory("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("longDescription").ToString()); +Console.WriteLine(result.GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("qualifiedName").ToString()); +Console.WriteLine(result.GetProperty("shortDescription").ToString()); +Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("anchor").GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("anchor").GetProperty("glossaryGuid").ToString()); +Console.WriteLine(result.GetProperty("anchor").GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("categoryGuid").ToString()); +Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("parentCategoryGuid").ToString()); +Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("parentCategory").GetProperty("categoryGuid").ToString()); +Console.WriteLine(result.GetProperty("parentCategory").GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("parentCategory").GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("parentCategory").GetProperty("parentCategoryGuid").ToString()); +Console.WriteLine(result.GetProperty("parentCategory").GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("termGuid").ToString()); +]]> + + + +This sample shows how to call UpdateCategoryAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +AtlasGlossaryCategory glossaryCategory = new AtlasGlossaryCategory(); +Response response = await client.UpdateCategoryAsync("", glossaryCategory); +]]> +This sample shows how to call UpdateCategoryAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +AtlasGlossaryCategory glossaryCategory = new AtlasGlossaryCategory +{ + Guid = "", + Classifications = {new AtlasClassification + { + Attributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + TypeName = "", + LastModifiedTS = "", + EntityGuid = "", + EntityStatus = EntityStatus.Active, + RemovePropagationsOnEntityDelete = true, + ValidityPeriods = {new TimeBoundary + { + EndTime = "", + StartTime = "", + TimeZone = "", + }}, + }}, + LongDescription = "", + Name = "", + QualifiedName = "", + ShortDescription = "", + LastModifiedTS = "", + CreateTime = 1234L, + CreatedBy = "", + UpdateTime = 1234L, + UpdatedBy = "", + Anchor = new AtlasGlossaryHeader + { + DisplayText = "", + GlossaryGuid = "", + RelationGuid = "", + }, + ChildrenCategories = {new AtlasRelatedCategoryHeader + { + CategoryGuid = "", + Description = "", + DisplayText = "", + ParentCategoryGuid = "", + RelationGuid = "", + }}, + ParentCategory = default, + Terms = {new AtlasRelatedTermHeader + { + Description = "", + DisplayText = "", + Expression = "", + RelationGuid = "", + Status = AtlasTermRelationshipStatus.Draft, + Steward = "", + TermGuid = "", + }}, +}; +Response response = await client.UpdateCategoryAsync("", glossaryCategory); +]]> + + + +This sample shows how to call UpdateCategory. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +AtlasGlossaryCategory glossaryCategory = new AtlasGlossaryCategory(); +Response response = client.UpdateCategory("", glossaryCategory); +]]> +This sample shows how to call UpdateCategory with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +AtlasGlossaryCategory glossaryCategory = new AtlasGlossaryCategory +{ + Guid = "", + Classifications = {new AtlasClassification + { + Attributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + TypeName = "", + LastModifiedTS = "", + EntityGuid = "", + EntityStatus = EntityStatus.Active, + RemovePropagationsOnEntityDelete = true, + ValidityPeriods = {new TimeBoundary + { + EndTime = "", + StartTime = "", + TimeZone = "", + }}, + }}, + LongDescription = "", + Name = "", + QualifiedName = "", + ShortDescription = "", + LastModifiedTS = "", + CreateTime = 1234L, + CreatedBy = "", + UpdateTime = 1234L, + UpdatedBy = "", + Anchor = new AtlasGlossaryHeader + { + DisplayText = "", + GlossaryGuid = "", + RelationGuid = "", + }, + ChildrenCategories = {new AtlasRelatedCategoryHeader + { + CategoryGuid = "", + Description = "", + DisplayText = "", + ParentCategoryGuid = "", + RelationGuid = "", + }}, + ParentCategory = default, + Terms = {new AtlasRelatedTermHeader + { + Description = "", + DisplayText = "", + Expression = "", + RelationGuid = "", + Status = AtlasTermRelationshipStatus.Draft, + Steward = "", + TermGuid = "", + }}, +}; +Response response = client.UpdateCategory("", glossaryCategory); +]]> + + + +This sample shows how to call UpdateCategoryAsync and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object()); +Response response = await client.UpdateCategoryAsync("", content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call UpdateCategoryAsync with all parameters and request content and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new +{ + guid = "", + classifications = new object[] + { + new + { + attributes = new + { + key = new object(), + }, + typeName = "", + lastModifiedTS = "", + entityGuid = "", + entityStatus = "ACTIVE", + removePropagationsOnEntityDelete = true, + validityPeriods = new object[] + { + new + { + endTime = "", + startTime = "", + timeZone = "", + } + }, + } + }, + longDescription = "", + name = "", + qualifiedName = "", + shortDescription = "", + lastModifiedTS = "", + createTime = 1234L, + createdBy = "", + updateTime = 1234L, + updatedBy = "", + anchor = new + { + displayText = "", + glossaryGuid = "", + relationGuid = "", + }, + childrenCategories = new object[] + { + new + { + categoryGuid = "", + description = "", + displayText = "", + parentCategoryGuid = "", + relationGuid = "", + } + }, + terms = new object[] + { + new + { + description = "", + displayText = "", + expression = "", + relationGuid = "", + status = "DRAFT", + steward = "", + termGuid = "", + } + }, +}); +Response response = await client.UpdateCategoryAsync("", content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("longDescription").ToString()); +Console.WriteLine(result.GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("qualifiedName").ToString()); +Console.WriteLine(result.GetProperty("shortDescription").ToString()); +Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("anchor").GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("anchor").GetProperty("glossaryGuid").ToString()); +Console.WriteLine(result.GetProperty("anchor").GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("categoryGuid").ToString()); +Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("parentCategoryGuid").ToString()); +Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("parentCategory").GetProperty("categoryGuid").ToString()); +Console.WriteLine(result.GetProperty("parentCategory").GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("parentCategory").GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("parentCategory").GetProperty("parentCategoryGuid").ToString()); +Console.WriteLine(result.GetProperty("parentCategory").GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("termGuid").ToString()); +]]> + + + +This sample shows how to call UpdateCategory and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object()); +Response response = client.UpdateCategory("", content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call UpdateCategory with all parameters and request content and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new +{ + guid = "", + classifications = new object[] + { + new + { + attributes = new + { + key = new object(), + }, + typeName = "", + lastModifiedTS = "", + entityGuid = "", + entityStatus = "ACTIVE", + removePropagationsOnEntityDelete = true, + validityPeriods = new object[] + { + new + { + endTime = "", + startTime = "", + timeZone = "", + } + }, + } + }, + longDescription = "", + name = "", + qualifiedName = "", + shortDescription = "", + lastModifiedTS = "", + createTime = 1234L, + createdBy = "", + updateTime = 1234L, + updatedBy = "", + anchor = new + { + displayText = "", + glossaryGuid = "", + relationGuid = "", + }, + childrenCategories = new object[] + { + new + { + categoryGuid = "", + description = "", + displayText = "", + parentCategoryGuid = "", + relationGuid = "", + } + }, + terms = new object[] + { + new + { + description = "", + displayText = "", + expression = "", + relationGuid = "", + status = "DRAFT", + steward = "", + termGuid = "", + } + }, +}); +Response response = client.UpdateCategory("", content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("longDescription").ToString()); +Console.WriteLine(result.GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("qualifiedName").ToString()); +Console.WriteLine(result.GetProperty("shortDescription").ToString()); +Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("anchor").GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("anchor").GetProperty("glossaryGuid").ToString()); +Console.WriteLine(result.GetProperty("anchor").GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("categoryGuid").ToString()); +Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("parentCategoryGuid").ToString()); +Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("parentCategory").GetProperty("categoryGuid").ToString()); +Console.WriteLine(result.GetProperty("parentCategory").GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("parentCategory").GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("parentCategory").GetProperty("parentCategoryGuid").ToString()); +Console.WriteLine(result.GetProperty("parentCategory").GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("termGuid").ToString()); +]]> + + + +This sample shows how to call DeleteCategoryAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = await client.DeleteCategoryAsync(""); + +Console.WriteLine(response.Status); +]]> +This sample shows how to call DeleteCategoryAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = await client.DeleteCategoryAsync(""); + +Console.WriteLine(response.Status); +]]> + + + +This sample shows how to call DeleteCategory. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = client.DeleteCategory(""); + +Console.WriteLine(response.Status); +]]> +This sample shows how to call DeleteCategory with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = client.DeleteCategory(""); + +Console.WriteLine(response.Status); +]]> + + + +This sample shows how to call PartialUpdateCategoryAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = await client.PartialUpdateCategoryAsync("", BinaryData.FromObjectAsJson(new object())); +]]> +This sample shows how to call PartialUpdateCategoryAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = await client.PartialUpdateCategoryAsync("", BinaryData.FromObjectAsJson(new object())); +]]> + + + +This sample shows how to call PartialUpdateCategory. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = client.PartialUpdateCategory("", BinaryData.FromObjectAsJson(new object())); +]]> +This sample shows how to call PartialUpdateCategory with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = client.PartialUpdateCategory("", BinaryData.FromObjectAsJson(new object())); +]]> + + + +This sample shows how to call PartialUpdateCategoryAsync and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object()); +Response response = await client.PartialUpdateCategoryAsync("", content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call PartialUpdateCategoryAsync with all parameters and request content and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object()); +Response response = await client.PartialUpdateCategoryAsync("", content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("longDescription").ToString()); +Console.WriteLine(result.GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("qualifiedName").ToString()); +Console.WriteLine(result.GetProperty("shortDescription").ToString()); +Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("anchor").GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("anchor").GetProperty("glossaryGuid").ToString()); +Console.WriteLine(result.GetProperty("anchor").GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("categoryGuid").ToString()); +Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("parentCategoryGuid").ToString()); +Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("parentCategory").GetProperty("categoryGuid").ToString()); +Console.WriteLine(result.GetProperty("parentCategory").GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("parentCategory").GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("parentCategory").GetProperty("parentCategoryGuid").ToString()); +Console.WriteLine(result.GetProperty("parentCategory").GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("termGuid").ToString()); +]]> + + + +This sample shows how to call PartialUpdateCategory and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object()); +Response response = client.PartialUpdateCategory("", content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call PartialUpdateCategory with all parameters and request content and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object()); +Response response = client.PartialUpdateCategory("", content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("longDescription").ToString()); +Console.WriteLine(result.GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("qualifiedName").ToString()); +Console.WriteLine(result.GetProperty("shortDescription").ToString()); +Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("anchor").GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("anchor").GetProperty("glossaryGuid").ToString()); +Console.WriteLine(result.GetProperty("anchor").GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("categoryGuid").ToString()); +Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("parentCategoryGuid").ToString()); +Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("parentCategory").GetProperty("categoryGuid").ToString()); +Console.WriteLine(result.GetProperty("parentCategory").GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("parentCategory").GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("parentCategory").GetProperty("parentCategoryGuid").ToString()); +Console.WriteLine(result.GetProperty("parentCategory").GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("termGuid").ToString()); +]]> + + + +This sample shows how to call GetRelatedCategoriesAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response>> response = await client.GetRelatedCategoriesAsync(""); +]]> +This sample shows how to call GetRelatedCategoriesAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response>> response = await client.GetRelatedCategoriesAsync("", limit: 1234, offset: 1234, sort: ""); +]]> + + + +This sample shows how to call GetRelatedCategories. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response>> response = client.GetRelatedCategories(""); +]]> +This sample shows how to call GetRelatedCategories with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response>> response = client.GetRelatedCategories("", limit: 1234, offset: 1234, sort: ""); +]]> + + + +This sample shows how to call GetRelatedCategoriesAsync and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = await client.GetRelatedCategoriesAsync("", null, null, null, null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("")[0].ToString()); +]]> +This sample shows how to call GetRelatedCategoriesAsync with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = await client.GetRelatedCategoriesAsync("", 1234, 1234, "", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("")[0].GetProperty("categoryGuid").ToString()); +Console.WriteLine(result.GetProperty("")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("")[0].GetProperty("parentCategoryGuid").ToString()); +Console.WriteLine(result.GetProperty("")[0].GetProperty("relationGuid").ToString()); +]]> + + + +This sample shows how to call GetRelatedCategories and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = client.GetRelatedCategories("", null, null, null, null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("")[0].ToString()); +]]> +This sample shows how to call GetRelatedCategories with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = client.GetRelatedCategories("", 1234, 1234, "", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("")[0].GetProperty("categoryGuid").ToString()); +Console.WriteLine(result.GetProperty("")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("")[0].GetProperty("parentCategoryGuid").ToString()); +Console.WriteLine(result.GetProperty("")[0].GetProperty("relationGuid").ToString()); +]]> + + + +This sample shows how to call GetCategoryTermsAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response> response = await client.GetCategoryTermsAsync(""); +]]> +This sample shows how to call GetCategoryTermsAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response> response = await client.GetCategoryTermsAsync("", limit: 1234, offset: 1234, sort: ""); +]]> + + + +This sample shows how to call GetCategoryTerms. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response> response = client.GetCategoryTerms(""); +]]> +This sample shows how to call GetCategoryTerms with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response> response = client.GetCategoryTerms("", limit: 1234, offset: 1234, sort: ""); +]]> + + + +This sample shows how to call GetCategoryTermsAsync and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = await client.GetCategoryTermsAsync("", null, null, null, null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result[0].ToString()); +]]> +This sample shows how to call GetCategoryTermsAsync with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = await client.GetCategoryTermsAsync("", 1234, 1234, "", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("expression").ToString()); +Console.WriteLine(result[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("status").ToString()); +Console.WriteLine(result[0].GetProperty("steward").ToString()); +Console.WriteLine(result[0].GetProperty("termGuid").ToString()); +]]> + + + +This sample shows how to call GetCategoryTerms and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = client.GetCategoryTerms("", null, null, null, null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result[0].ToString()); +]]> +This sample shows how to call GetCategoryTerms with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = client.GetCategoryTerms("", 1234, 1234, "", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("expression").ToString()); +Console.WriteLine(result[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("status").ToString()); +Console.WriteLine(result[0].GetProperty("steward").ToString()); +Console.WriteLine(result[0].GetProperty("termGuid").ToString()); +]]> + + + +This sample shows how to call CreateTermAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +AtlasGlossaryTerm glossaryTerm = new AtlasGlossaryTerm(); +Response response = await client.CreateTermAsync(glossaryTerm); +]]> +This sample shows how to call CreateTermAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +AtlasGlossaryTerm glossaryTerm = new AtlasGlossaryTerm +{ + Guid = "", + Classifications = {new AtlasClassification + { + Attributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + TypeName = "", + LastModifiedTS = "", + EntityGuid = "", + EntityStatus = EntityStatus.Active, + RemovePropagationsOnEntityDelete = true, + ValidityPeriods = {new TimeBoundary + { + EndTime = "", + StartTime = "", + TimeZone = "", + }}, + }}, + LongDescription = "", + Name = "", + QualifiedName = "", + ShortDescription = "", + LastModifiedTS = "", + CreateTime = 1234L, + CreatedBy = "", + UpdateTime = 1234L, + UpdatedBy = "", + Abbreviation = "", + TemplateName = { BinaryData.FromObjectAsJson(new object()) }, + Anchor = new AtlasGlossaryHeader + { + DisplayText = "", + GlossaryGuid = "", + RelationGuid = "", + }, + Antonyms = {new AtlasRelatedTermHeader + { + Description = "", + DisplayText = "", + Expression = "", + RelationGuid = "", + Status = AtlasTermRelationshipStatus.Draft, + Steward = "", + TermGuid = "", + }}, + Status = TermStatus.Draft, + NickName = "", + HierarchyInfo = {new PurviewObjectId + { + Guid = "", + TypeName = "", + UniqueAttributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + Name = "", + DisplayText = "", + ItemPath = "", + ResourceId = "", + Properties = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + }}, + Resources = {new ResourceLink + { + DisplayName = "", + Url = "", + }}, + Contacts = + { + ["key"] = {new ContactInfo + { + Id = "", + Info = "", + }} + }, + Attributes = + { + ["key"] = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + } + }, + AssignedEntities = {new AtlasRelatedObjectId + { + Guid = "", + TypeName = "", + UniqueAttributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + DisplayText = "", + EntityStatus = EntityStatus.Active, + RelationshipType = "", + RelationshipAttributes = new AtlasStruct + { + Attributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + TypeName = "", + LastModifiedTS = "", + }, + RelationshipGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), + RelationshipStatus = StatusAtlasRelationship.Active, + }}, + Categories = {new AtlasTermCategorizationHeader + { + CategoryGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), + Description = "", + DisplayText = "", + RelationGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), + Status = AtlasTermRelationshipStatus.Draft, + }}, + Classifies = { default }, + Examples = { "" }, + IsA = { default }, + PreferredTerms = { default }, + PreferredToTerms = { default }, + ReplacedBy = { default }, + ReplacementTerms = { default }, + SeeAlso = { default }, + Synonyms = { default }, + TranslatedTerms = { default }, + TranslationTerms = { default }, + Usage = "", + ValidValues = { default }, + ValidValuesFor = { default }, +}; +Response response = await client.CreateTermAsync(glossaryTerm, includeTermHierarchy: true); +]]> + + + +This sample shows how to call CreateTerm. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +AtlasGlossaryTerm glossaryTerm = new AtlasGlossaryTerm(); +Response response = client.CreateTerm(glossaryTerm); +]]> +This sample shows how to call CreateTerm with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +AtlasGlossaryTerm glossaryTerm = new AtlasGlossaryTerm +{ + Guid = "", + Classifications = {new AtlasClassification + { + Attributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + TypeName = "", + LastModifiedTS = "", + EntityGuid = "", + EntityStatus = EntityStatus.Active, + RemovePropagationsOnEntityDelete = true, + ValidityPeriods = {new TimeBoundary + { + EndTime = "", + StartTime = "", + TimeZone = "", + }}, + }}, + LongDescription = "", + Name = "", + QualifiedName = "", + ShortDescription = "", + LastModifiedTS = "", + CreateTime = 1234L, + CreatedBy = "", + UpdateTime = 1234L, + UpdatedBy = "", + Abbreviation = "", + TemplateName = { BinaryData.FromObjectAsJson(new object()) }, + Anchor = new AtlasGlossaryHeader + { + DisplayText = "", + GlossaryGuid = "", + RelationGuid = "", + }, + Antonyms = {new AtlasRelatedTermHeader + { + Description = "", + DisplayText = "", + Expression = "", + RelationGuid = "", + Status = AtlasTermRelationshipStatus.Draft, + Steward = "", + TermGuid = "", + }}, + Status = TermStatus.Draft, + NickName = "", + HierarchyInfo = {new PurviewObjectId + { + Guid = "", + TypeName = "", + UniqueAttributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + Name = "", + DisplayText = "", + ItemPath = "", + ResourceId = "", + Properties = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + }}, + Resources = {new ResourceLink + { + DisplayName = "", + Url = "", + }}, + Contacts = + { + ["key"] = {new ContactInfo + { + Id = "", + Info = "", + }} + }, + Attributes = + { + ["key"] = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + } + }, + AssignedEntities = {new AtlasRelatedObjectId + { + Guid = "", + TypeName = "", + UniqueAttributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + DisplayText = "", + EntityStatus = EntityStatus.Active, + RelationshipType = "", + RelationshipAttributes = new AtlasStruct + { + Attributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + TypeName = "", + LastModifiedTS = "", + }, + RelationshipGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), + RelationshipStatus = StatusAtlasRelationship.Active, + }}, + Categories = {new AtlasTermCategorizationHeader + { + CategoryGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), + Description = "", + DisplayText = "", + RelationGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), + Status = AtlasTermRelationshipStatus.Draft, + }}, + Classifies = { default }, + Examples = { "" }, + IsA = { default }, + PreferredTerms = { default }, + PreferredToTerms = { default }, + ReplacedBy = { default }, + ReplacementTerms = { default }, + SeeAlso = { default }, + Synonyms = { default }, + TranslatedTerms = { default }, + TranslationTerms = { default }, + Usage = "", + ValidValues = { default }, + ValidValuesFor = { default }, +}; +Response response = client.CreateTerm(glossaryTerm, includeTermHierarchy: true); +]]> + + + +This sample shows how to call CreateTermAsync and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object()); +Response response = await client.CreateTermAsync(content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call CreateTermAsync with all parameters and request content and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new +{ + guid = "", + classifications = new object[] + { + new + { + attributes = new + { + key = new object(), + }, + typeName = "", + lastModifiedTS = "", + entityGuid = "", + entityStatus = "ACTIVE", + removePropagationsOnEntityDelete = true, + validityPeriods = new object[] + { + new + { + endTime = "", + startTime = "", + timeZone = "", + } + }, + } + }, + longDescription = "", + name = "", + qualifiedName = "", + shortDescription = "", + lastModifiedTS = "", + createTime = 1234L, + createdBy = "", + updateTime = 1234L, + updatedBy = "", + abbreviation = "", + templateName = new object[] + { + new object() + }, + anchor = new + { + displayText = "", + glossaryGuid = "", + relationGuid = "", + }, + antonyms = new object[] + { + new + { + description = "", + displayText = "", + expression = "", + relationGuid = "", + status = "DRAFT", + steward = "", + termGuid = "", + } + }, + status = "Draft", + nickName = "", + hierarchyInfo = new object[] + { + new + { + guid = "", + typeName = "", + uniqueAttributes = new + { + key = new object(), + }, + name = "", + displayText = "", + itemPath = "", + resourceId = "", + properties = new + { + key = new object(), + }, + } + }, + resources = new object[] + { + new + { + displayName = "", + url = "", + } + }, + contacts = new + { + key = new object[] + { + new + { + id = "", + info = "", + } + }, + }, + attributes = new + { + key = new + { + key = new object(), + }, + }, + assignedEntities = new object[] + { + new + { + guid = "", + typeName = "", + uniqueAttributes = new + { + key = new object(), + }, + displayText = "", + entityStatus = "ACTIVE", + relationshipType = "", + relationshipAttributes = new + { + attributes = new + { + key = new object(), + }, + typeName = "", + lastModifiedTS = "", + }, + relationshipGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", + relationshipStatus = "ACTIVE", + } + }, + categories = new object[] + { + new + { + categoryGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", + description = "", + displayText = "", + relationGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", + status = "DRAFT", + } + }, + classifies = new object[] + { + null + }, + examples = new object[] + { + "" + }, + isA = new object[] + { + null + }, + preferredTerms = new object[] + { + null + }, + preferredToTerms = new object[] + { + null + }, + replacedBy = new object[] + { + null + }, + replacementTerms = new object[] + { + null + }, + seeAlso = new object[] + { + null + }, + synonyms = new object[] + { + null + }, + translatedTerms = new object[] + { + null + }, + translationTerms = new object[] + { + null + }, + usage = "", + validValues = new object[] + { + null + }, + validValuesFor = new object[] + { + null + }, +}); +Response response = await client.CreateTermAsync(content, includeTermHierarchy: true); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("longDescription").ToString()); +Console.WriteLine(result.GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("qualifiedName").ToString()); +Console.WriteLine(result.GetProperty("shortDescription").ToString()); +Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("abbreviation").ToString()); +Console.WriteLine(result.GetProperty("templateName")[0].ToString()); +Console.WriteLine(result.GetProperty("anchor").GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("anchor").GetProperty("glossaryGuid").ToString()); +Console.WriteLine(result.GetProperty("anchor").GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("nickName").ToString()); +Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("uniqueAttributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("itemPath").ToString()); +Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("resourceId").ToString()); +Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("properties").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("resources")[0].GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("resources")[0].GetProperty("url").ToString()); +Console.WriteLine(result.GetProperty("contacts").GetProperty("")[0].GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("contacts").GetProperty("")[0].GetProperty("info").ToString()); +Console.WriteLine(result.GetProperty("attributes").GetProperty("").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("uniqueAttributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipType").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipGuid").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipStatus").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("categoryGuid").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("examples")[0].ToString()); +Console.WriteLine(result.GetProperty("isA")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("isA")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("isA")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("isA")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("isA")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("isA")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("isA")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("usage").ToString()); +Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("termGuid").ToString()); +]]> + + + +This sample shows how to call CreateTerm and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object()); +Response response = client.CreateTerm(content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call CreateTerm with all parameters and request content and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new +{ + guid = "", + classifications = new object[] + { + new + { + attributes = new + { + key = new object(), + }, + typeName = "", + lastModifiedTS = "", + entityGuid = "", + entityStatus = "ACTIVE", + removePropagationsOnEntityDelete = true, + validityPeriods = new object[] + { + new + { + endTime = "", + startTime = "", + timeZone = "", + } + }, + } + }, + longDescription = "", + name = "", + qualifiedName = "", + shortDescription = "", + lastModifiedTS = "", + createTime = 1234L, + createdBy = "", + updateTime = 1234L, + updatedBy = "", + abbreviation = "", + templateName = new object[] + { + new object() + }, + anchor = new + { + displayText = "", + glossaryGuid = "", + relationGuid = "", + }, + antonyms = new object[] + { + new + { + description = "", + displayText = "", + expression = "", + relationGuid = "", + status = "DRAFT", + steward = "", + termGuid = "", + } + }, + status = "Draft", + nickName = "", + hierarchyInfo = new object[] + { + new + { + guid = "", + typeName = "", + uniqueAttributes = new + { + key = new object(), + }, + name = "", + displayText = "", + itemPath = "", + resourceId = "", + properties = new + { + key = new object(), + }, + } + }, + resources = new object[] + { + new + { + displayName = "", + url = "", + } + }, + contacts = new + { + key = new object[] + { + new + { + id = "", + info = "", + } + }, + }, + attributes = new + { + key = new + { + key = new object(), + }, + }, + assignedEntities = new object[] + { + new + { + guid = "", + typeName = "", + uniqueAttributes = new + { + key = new object(), + }, + displayText = "", + entityStatus = "ACTIVE", + relationshipType = "", + relationshipAttributes = new + { + attributes = new + { + key = new object(), + }, + typeName = "", + lastModifiedTS = "", + }, + relationshipGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", + relationshipStatus = "ACTIVE", + } + }, + categories = new object[] + { + new + { + categoryGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", + description = "", + displayText = "", + relationGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", + status = "DRAFT", + } + }, + classifies = new object[] + { + null + }, + examples = new object[] + { + "" + }, + isA = new object[] + { + null + }, + preferredTerms = new object[] + { + null + }, + preferredToTerms = new object[] + { + null + }, + replacedBy = new object[] + { + null + }, + replacementTerms = new object[] + { + null + }, + seeAlso = new object[] + { + null + }, + synonyms = new object[] + { + null + }, + translatedTerms = new object[] + { + null + }, + translationTerms = new object[] + { + null + }, + usage = "", + validValues = new object[] + { + null + }, + validValuesFor = new object[] + { + null + }, +}); +Response response = client.CreateTerm(content, includeTermHierarchy: true); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("longDescription").ToString()); +Console.WriteLine(result.GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("qualifiedName").ToString()); +Console.WriteLine(result.GetProperty("shortDescription").ToString()); +Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("abbreviation").ToString()); +Console.WriteLine(result.GetProperty("templateName")[0].ToString()); +Console.WriteLine(result.GetProperty("anchor").GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("anchor").GetProperty("glossaryGuid").ToString()); +Console.WriteLine(result.GetProperty("anchor").GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("nickName").ToString()); +Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("uniqueAttributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("itemPath").ToString()); +Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("resourceId").ToString()); +Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("properties").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("resources")[0].GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("resources")[0].GetProperty("url").ToString()); +Console.WriteLine(result.GetProperty("contacts").GetProperty("")[0].GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("contacts").GetProperty("")[0].GetProperty("info").ToString()); +Console.WriteLine(result.GetProperty("attributes").GetProperty("").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("uniqueAttributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipType").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipGuid").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipStatus").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("categoryGuid").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("examples")[0].ToString()); +Console.WriteLine(result.GetProperty("isA")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("isA")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("isA")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("isA")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("isA")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("isA")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("isA")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("usage").ToString()); +Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("termGuid").ToString()); +]]> + + + +This sample shows how to call GetTermAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = await client.GetTermAsync(""); +]]> +This sample shows how to call GetTermAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = await client.GetTermAsync(""); +]]> + + + +This sample shows how to call GetTerm. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = client.GetTerm(""); +]]> +This sample shows how to call GetTerm with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = client.GetTerm(""); +]]> + + + +This sample shows how to call GetTermAsync and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = await client.GetTermAsync("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call GetTermAsync with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = await client.GetTermAsync("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("longDescription").ToString()); +Console.WriteLine(result.GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("qualifiedName").ToString()); +Console.WriteLine(result.GetProperty("shortDescription").ToString()); +Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("abbreviation").ToString()); +Console.WriteLine(result.GetProperty("templateName")[0].ToString()); +Console.WriteLine(result.GetProperty("anchor").GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("anchor").GetProperty("glossaryGuid").ToString()); +Console.WriteLine(result.GetProperty("anchor").GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("nickName").ToString()); +Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("uniqueAttributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("itemPath").ToString()); +Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("resourceId").ToString()); +Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("properties").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("resources")[0].GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("resources")[0].GetProperty("url").ToString()); +Console.WriteLine(result.GetProperty("contacts").GetProperty("")[0].GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("contacts").GetProperty("")[0].GetProperty("info").ToString()); +Console.WriteLine(result.GetProperty("attributes").GetProperty("").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("uniqueAttributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipType").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipGuid").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipStatus").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("categoryGuid").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("examples")[0].ToString()); +Console.WriteLine(result.GetProperty("isA")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("isA")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("isA")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("isA")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("isA")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("isA")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("isA")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("usage").ToString()); +Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("termGuid").ToString()); +]]> + + + +This sample shows how to call GetTerm and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = client.GetTerm("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call GetTerm with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = client.GetTerm("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("longDescription").ToString()); +Console.WriteLine(result.GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("qualifiedName").ToString()); +Console.WriteLine(result.GetProperty("shortDescription").ToString()); +Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("abbreviation").ToString()); +Console.WriteLine(result.GetProperty("templateName")[0].ToString()); +Console.WriteLine(result.GetProperty("anchor").GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("anchor").GetProperty("glossaryGuid").ToString()); +Console.WriteLine(result.GetProperty("anchor").GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("nickName").ToString()); +Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("uniqueAttributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("itemPath").ToString()); +Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("resourceId").ToString()); +Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("properties").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("resources")[0].GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("resources")[0].GetProperty("url").ToString()); +Console.WriteLine(result.GetProperty("contacts").GetProperty("")[0].GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("contacts").GetProperty("")[0].GetProperty("info").ToString()); +Console.WriteLine(result.GetProperty("attributes").GetProperty("").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("uniqueAttributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipType").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipGuid").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipStatus").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("categoryGuid").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("examples")[0].ToString()); +Console.WriteLine(result.GetProperty("isA")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("isA")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("isA")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("isA")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("isA")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("isA")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("isA")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("usage").ToString()); +Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("termGuid").ToString()); +]]> + + + +This sample shows how to call UpdateTermAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +AtlasGlossaryTerm glossaryTerm = new AtlasGlossaryTerm(); +Response response = await client.UpdateTermAsync("", glossaryTerm); +]]> +This sample shows how to call UpdateTermAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +AtlasGlossaryTerm glossaryTerm = new AtlasGlossaryTerm +{ + Guid = "", + Classifications = {new AtlasClassification + { + Attributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + TypeName = "", + LastModifiedTS = "", + EntityGuid = "", + EntityStatus = EntityStatus.Active, + RemovePropagationsOnEntityDelete = true, + ValidityPeriods = {new TimeBoundary + { + EndTime = "", + StartTime = "", + TimeZone = "", + }}, + }}, + LongDescription = "", + Name = "", + QualifiedName = "", + ShortDescription = "", + LastModifiedTS = "", + CreateTime = 1234L, + CreatedBy = "", + UpdateTime = 1234L, + UpdatedBy = "", + Abbreviation = "", + TemplateName = { BinaryData.FromObjectAsJson(new object()) }, + Anchor = new AtlasGlossaryHeader + { + DisplayText = "", + GlossaryGuid = "", + RelationGuid = "", + }, + Antonyms = {new AtlasRelatedTermHeader + { + Description = "", + DisplayText = "", + Expression = "", + RelationGuid = "", + Status = AtlasTermRelationshipStatus.Draft, + Steward = "", + TermGuid = "", + }}, + Status = TermStatus.Draft, + NickName = "", + HierarchyInfo = {new PurviewObjectId + { + Guid = "", + TypeName = "", + UniqueAttributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + Name = "", + DisplayText = "", + ItemPath = "", + ResourceId = "", + Properties = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + }}, + Resources = {new ResourceLink + { + DisplayName = "", + Url = "", + }}, + Contacts = + { + ["key"] = {new ContactInfo + { + Id = "", + Info = "", + }} + }, + Attributes = + { + ["key"] = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + } + }, + AssignedEntities = {new AtlasRelatedObjectId + { + Guid = "", + TypeName = "", + UniqueAttributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + DisplayText = "", + EntityStatus = EntityStatus.Active, + RelationshipType = "", + RelationshipAttributes = new AtlasStruct + { + Attributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + TypeName = "", + LastModifiedTS = "", + }, + RelationshipGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), + RelationshipStatus = StatusAtlasRelationship.Active, + }}, + Categories = {new AtlasTermCategorizationHeader + { + CategoryGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), + Description = "", + DisplayText = "", + RelationGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), + Status = AtlasTermRelationshipStatus.Draft, + }}, + Classifies = { default }, + Examples = { "" }, + IsA = { default }, + PreferredTerms = { default }, + PreferredToTerms = { default }, + ReplacedBy = { default }, + ReplacementTerms = { default }, + SeeAlso = { default }, + Synonyms = { default }, + TranslatedTerms = { default }, + TranslationTerms = { default }, + Usage = "", + ValidValues = { default }, + ValidValuesFor = { default }, +}; +Response response = await client.UpdateTermAsync("", glossaryTerm, includeTermHierarchy: true); +]]> + + + +This sample shows how to call UpdateTerm. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +AtlasGlossaryTerm glossaryTerm = new AtlasGlossaryTerm(); +Response response = client.UpdateTerm("", glossaryTerm); +]]> +This sample shows how to call UpdateTerm with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +AtlasGlossaryTerm glossaryTerm = new AtlasGlossaryTerm +{ + Guid = "", + Classifications = {new AtlasClassification + { + Attributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + TypeName = "", + LastModifiedTS = "", + EntityGuid = "", + EntityStatus = EntityStatus.Active, + RemovePropagationsOnEntityDelete = true, + ValidityPeriods = {new TimeBoundary + { + EndTime = "", + StartTime = "", + TimeZone = "", + }}, + }}, + LongDescription = "", + Name = "", + QualifiedName = "", + ShortDescription = "", + LastModifiedTS = "", + CreateTime = 1234L, + CreatedBy = "", + UpdateTime = 1234L, + UpdatedBy = "", + Abbreviation = "", + TemplateName = { BinaryData.FromObjectAsJson(new object()) }, + Anchor = new AtlasGlossaryHeader + { + DisplayText = "", + GlossaryGuid = "", + RelationGuid = "", + }, + Antonyms = {new AtlasRelatedTermHeader + { + Description = "", + DisplayText = "", + Expression = "", + RelationGuid = "", + Status = AtlasTermRelationshipStatus.Draft, + Steward = "", + TermGuid = "", + }}, + Status = TermStatus.Draft, + NickName = "", + HierarchyInfo = {new PurviewObjectId + { + Guid = "", + TypeName = "", + UniqueAttributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + Name = "", + DisplayText = "", + ItemPath = "", + ResourceId = "", + Properties = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + }}, + Resources = {new ResourceLink + { + DisplayName = "", + Url = "", + }}, + Contacts = + { + ["key"] = {new ContactInfo + { + Id = "", + Info = "", + }} + }, + Attributes = + { + ["key"] = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + } + }, + AssignedEntities = {new AtlasRelatedObjectId + { + Guid = "", + TypeName = "", + UniqueAttributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + DisplayText = "", + EntityStatus = EntityStatus.Active, + RelationshipType = "", + RelationshipAttributes = new AtlasStruct + { + Attributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + TypeName = "", + LastModifiedTS = "", + }, + RelationshipGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), + RelationshipStatus = StatusAtlasRelationship.Active, + }}, + Categories = {new AtlasTermCategorizationHeader + { + CategoryGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), + Description = "", + DisplayText = "", + RelationGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), + Status = AtlasTermRelationshipStatus.Draft, + }}, + Classifies = { default }, + Examples = { "" }, + IsA = { default }, + PreferredTerms = { default }, + PreferredToTerms = { default }, + ReplacedBy = { default }, + ReplacementTerms = { default }, + SeeAlso = { default }, + Synonyms = { default }, + TranslatedTerms = { default }, + TranslationTerms = { default }, + Usage = "", + ValidValues = { default }, + ValidValuesFor = { default }, +}; +Response response = client.UpdateTerm("", glossaryTerm, includeTermHierarchy: true); +]]> + + + +This sample shows how to call UpdateTermAsync and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object()); +Response response = await client.UpdateTermAsync("", content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call UpdateTermAsync with all parameters and request content and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new +{ + guid = "", + classifications = new object[] + { + new + { + attributes = new + { + key = new object(), + }, + typeName = "", + lastModifiedTS = "", + entityGuid = "", + entityStatus = "ACTIVE", + removePropagationsOnEntityDelete = true, + validityPeriods = new object[] + { + new + { + endTime = "", + startTime = "", + timeZone = "", + } + }, + } + }, + longDescription = "", + name = "", + qualifiedName = "", + shortDescription = "", + lastModifiedTS = "", + createTime = 1234L, + createdBy = "", + updateTime = 1234L, + updatedBy = "", + abbreviation = "", + templateName = new object[] + { + new object() + }, + anchor = new + { + displayText = "", + glossaryGuid = "", + relationGuid = "", + }, + antonyms = new object[] + { + new + { + description = "", + displayText = "", + expression = "", + relationGuid = "", + status = "DRAFT", + steward = "", + termGuid = "", + } + }, + status = "Draft", + nickName = "", + hierarchyInfo = new object[] + { + new + { + guid = "", + typeName = "", + uniqueAttributes = new + { + key = new object(), + }, + name = "", + displayText = "", + itemPath = "", + resourceId = "", + properties = new + { + key = new object(), + }, + } + }, + resources = new object[] + { + new + { + displayName = "", + url = "", + } + }, + contacts = new + { + key = new object[] + { + new + { + id = "", + info = "", + } + }, + }, + attributes = new + { + key = new + { + key = new object(), + }, + }, + assignedEntities = new object[] + { + new + { + guid = "", + typeName = "", + uniqueAttributes = new + { + key = new object(), + }, + displayText = "", + entityStatus = "ACTIVE", + relationshipType = "", + relationshipAttributes = new + { + attributes = new + { + key = new object(), + }, + typeName = "", + lastModifiedTS = "", + }, + relationshipGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", + relationshipStatus = "ACTIVE", + } + }, + categories = new object[] + { + new + { + categoryGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", + description = "", + displayText = "", + relationGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", + status = "DRAFT", + } + }, + classifies = new object[] + { + null + }, + examples = new object[] + { + "" + }, + isA = new object[] + { + null + }, + preferredTerms = new object[] + { + null + }, + preferredToTerms = new object[] + { + null + }, + replacedBy = new object[] + { + null + }, + replacementTerms = new object[] + { + null + }, + seeAlso = new object[] + { + null + }, + synonyms = new object[] + { + null + }, + translatedTerms = new object[] + { + null + }, + translationTerms = new object[] + { + null + }, + usage = "", + validValues = new object[] + { + null + }, + validValuesFor = new object[] + { + null + }, +}); +Response response = await client.UpdateTermAsync("", content, includeTermHierarchy: true); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("longDescription").ToString()); +Console.WriteLine(result.GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("qualifiedName").ToString()); +Console.WriteLine(result.GetProperty("shortDescription").ToString()); +Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("abbreviation").ToString()); +Console.WriteLine(result.GetProperty("templateName")[0].ToString()); +Console.WriteLine(result.GetProperty("anchor").GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("anchor").GetProperty("glossaryGuid").ToString()); +Console.WriteLine(result.GetProperty("anchor").GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("nickName").ToString()); +Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("uniqueAttributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("itemPath").ToString()); +Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("resourceId").ToString()); +Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("properties").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("resources")[0].GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("resources")[0].GetProperty("url").ToString()); +Console.WriteLine(result.GetProperty("contacts").GetProperty("")[0].GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("contacts").GetProperty("")[0].GetProperty("info").ToString()); +Console.WriteLine(result.GetProperty("attributes").GetProperty("").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("uniqueAttributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipType").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipGuid").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipStatus").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("categoryGuid").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("examples")[0].ToString()); +Console.WriteLine(result.GetProperty("isA")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("isA")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("isA")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("isA")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("isA")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("isA")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("isA")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("usage").ToString()); +Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("termGuid").ToString()); +]]> + + + +This sample shows how to call UpdateTerm and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object()); +Response response = client.UpdateTerm("", content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call UpdateTerm with all parameters and request content and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new +{ + guid = "", + classifications = new object[] + { + new + { + attributes = new + { + key = new object(), + }, + typeName = "", + lastModifiedTS = "", + entityGuid = "", + entityStatus = "ACTIVE", + removePropagationsOnEntityDelete = true, + validityPeriods = new object[] + { + new + { + endTime = "", + startTime = "", + timeZone = "", + } + }, + } + }, + longDescription = "", + name = "", + qualifiedName = "", + shortDescription = "", + lastModifiedTS = "", + createTime = 1234L, + createdBy = "", + updateTime = 1234L, + updatedBy = "", + abbreviation = "", + templateName = new object[] + { + new object() + }, + anchor = new + { + displayText = "", + glossaryGuid = "", + relationGuid = "", + }, + antonyms = new object[] + { + new + { + description = "", + displayText = "", + expression = "", + relationGuid = "", + status = "DRAFT", + steward = "", + termGuid = "", + } + }, + status = "Draft", + nickName = "", + hierarchyInfo = new object[] + { + new + { + guid = "", + typeName = "", + uniqueAttributes = new + { + key = new object(), + }, + name = "", + displayText = "", + itemPath = "", + resourceId = "", + properties = new + { + key = new object(), + }, + } + }, + resources = new object[] + { + new + { + displayName = "", + url = "", + } + }, + contacts = new + { + key = new object[] + { + new + { + id = "", + info = "", + } + }, + }, + attributes = new + { + key = new + { + key = new object(), + }, + }, + assignedEntities = new object[] + { + new + { + guid = "", + typeName = "", + uniqueAttributes = new + { + key = new object(), + }, + displayText = "", + entityStatus = "ACTIVE", + relationshipType = "", + relationshipAttributes = new + { + attributes = new + { + key = new object(), + }, + typeName = "", + lastModifiedTS = "", + }, + relationshipGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", + relationshipStatus = "ACTIVE", + } + }, + categories = new object[] + { + new + { + categoryGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", + description = "", + displayText = "", + relationGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", + status = "DRAFT", + } + }, + classifies = new object[] + { + null + }, + examples = new object[] + { + "" + }, + isA = new object[] + { + null + }, + preferredTerms = new object[] + { + null + }, + preferredToTerms = new object[] + { + null + }, + replacedBy = new object[] + { + null + }, + replacementTerms = new object[] + { + null + }, + seeAlso = new object[] + { + null + }, + synonyms = new object[] + { + null + }, + translatedTerms = new object[] + { + null + }, + translationTerms = new object[] + { + null + }, + usage = "", + validValues = new object[] + { + null + }, + validValuesFor = new object[] + { + null + }, +}); +Response response = client.UpdateTerm("", content, includeTermHierarchy: true); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("longDescription").ToString()); +Console.WriteLine(result.GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("qualifiedName").ToString()); +Console.WriteLine(result.GetProperty("shortDescription").ToString()); +Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("abbreviation").ToString()); +Console.WriteLine(result.GetProperty("templateName")[0].ToString()); +Console.WriteLine(result.GetProperty("anchor").GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("anchor").GetProperty("glossaryGuid").ToString()); +Console.WriteLine(result.GetProperty("anchor").GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("nickName").ToString()); +Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("uniqueAttributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("itemPath").ToString()); +Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("resourceId").ToString()); +Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("properties").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("resources")[0].GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("resources")[0].GetProperty("url").ToString()); +Console.WriteLine(result.GetProperty("contacts").GetProperty("")[0].GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("contacts").GetProperty("")[0].GetProperty("info").ToString()); +Console.WriteLine(result.GetProperty("attributes").GetProperty("").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("uniqueAttributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipType").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipGuid").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipStatus").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("categoryGuid").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("examples")[0].ToString()); +Console.WriteLine(result.GetProperty("isA")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("isA")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("isA")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("isA")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("isA")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("isA")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("isA")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("usage").ToString()); +Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("termGuid").ToString()); +]]> + + + +This sample shows how to call DeleteTermAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = await client.DeleteTermAsync(""); + +Console.WriteLine(response.Status); +]]> +This sample shows how to call DeleteTermAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = await client.DeleteTermAsync(""); + +Console.WriteLine(response.Status); +]]> + + + +This sample shows how to call DeleteTerm. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = client.DeleteTerm(""); + +Console.WriteLine(response.Status); +]]> +This sample shows how to call DeleteTerm with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = client.DeleteTerm(""); + +Console.WriteLine(response.Status); +]]> + + + +This sample shows how to call PartialUpdateTermAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = await client.PartialUpdateTermAsync("", BinaryData.FromObjectAsJson(new object())); +]]> +This sample shows how to call PartialUpdateTermAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = await client.PartialUpdateTermAsync("", BinaryData.FromObjectAsJson(new object()), includeTermHierarchy: true); +]]> + + + +This sample shows how to call PartialUpdateTerm. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = client.PartialUpdateTerm("", BinaryData.FromObjectAsJson(new object())); +]]> +This sample shows how to call PartialUpdateTerm with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = client.PartialUpdateTerm("", BinaryData.FromObjectAsJson(new object()), includeTermHierarchy: true); +]]> + + + +This sample shows how to call PartialUpdateTermAsync and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object()); +Response response = await client.PartialUpdateTermAsync("", content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call PartialUpdateTermAsync with all parameters and request content and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object()); +Response response = await client.PartialUpdateTermAsync("", content, includeTermHierarchy: true); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("longDescription").ToString()); +Console.WriteLine(result.GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("qualifiedName").ToString()); +Console.WriteLine(result.GetProperty("shortDescription").ToString()); +Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("abbreviation").ToString()); +Console.WriteLine(result.GetProperty("templateName")[0].ToString()); +Console.WriteLine(result.GetProperty("anchor").GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("anchor").GetProperty("glossaryGuid").ToString()); +Console.WriteLine(result.GetProperty("anchor").GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("nickName").ToString()); +Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("uniqueAttributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("itemPath").ToString()); +Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("resourceId").ToString()); +Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("properties").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("resources")[0].GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("resources")[0].GetProperty("url").ToString()); +Console.WriteLine(result.GetProperty("contacts").GetProperty("")[0].GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("contacts").GetProperty("")[0].GetProperty("info").ToString()); +Console.WriteLine(result.GetProperty("attributes").GetProperty("").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("uniqueAttributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipType").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipGuid").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipStatus").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("categoryGuid").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("examples")[0].ToString()); +Console.WriteLine(result.GetProperty("isA")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("isA")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("isA")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("isA")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("isA")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("isA")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("isA")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("usage").ToString()); +Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("termGuid").ToString()); +]]> + + + +This sample shows how to call PartialUpdateTerm and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object()); +Response response = client.PartialUpdateTerm("", content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call PartialUpdateTerm with all parameters and request content and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object()); +Response response = client.PartialUpdateTerm("", content, includeTermHierarchy: true); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("longDescription").ToString()); +Console.WriteLine(result.GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("qualifiedName").ToString()); +Console.WriteLine(result.GetProperty("shortDescription").ToString()); +Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("abbreviation").ToString()); +Console.WriteLine(result.GetProperty("templateName")[0].ToString()); +Console.WriteLine(result.GetProperty("anchor").GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("anchor").GetProperty("glossaryGuid").ToString()); +Console.WriteLine(result.GetProperty("anchor").GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("nickName").ToString()); +Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("uniqueAttributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("itemPath").ToString()); +Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("resourceId").ToString()); +Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("properties").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("resources")[0].GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("resources")[0].GetProperty("url").ToString()); +Console.WriteLine(result.GetProperty("contacts").GetProperty("")[0].GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("contacts").GetProperty("")[0].GetProperty("info").ToString()); +Console.WriteLine(result.GetProperty("attributes").GetProperty("").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("uniqueAttributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipType").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipGuid").ToString()); +Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipStatus").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("categoryGuid").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("examples")[0].ToString()); +Console.WriteLine(result.GetProperty("isA")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("isA")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("isA")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("isA")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("isA")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("isA")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("isA")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("usage").ToString()); +Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("termGuid").ToString()); +]]> + + + +This sample shows how to call CreateTermsAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response> response = await client.CreateTermsAsync(new AtlasGlossaryTerm[] +{ + new AtlasGlossaryTerm() +}); +]]> +This sample shows how to call CreateTermsAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response> response = await client.CreateTermsAsync(new AtlasGlossaryTerm[] +{ + new AtlasGlossaryTerm + { + Guid = "", + Classifications = {new AtlasClassification + { + Attributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + TypeName = "", + LastModifiedTS = "", + EntityGuid = "", + EntityStatus = EntityStatus.Active, + RemovePropagationsOnEntityDelete = true, + ValidityPeriods = {new TimeBoundary + { + EndTime = "", + StartTime = "", + TimeZone = "", + }}, + }}, + LongDescription = "", + Name = "", + QualifiedName = "", + ShortDescription = "", + LastModifiedTS = "", + CreateTime = 1234L, + CreatedBy = "", + UpdateTime = 1234L, + UpdatedBy = "", + Abbreviation = "", + TemplateName = {BinaryData.FromObjectAsJson(new object())}, + Anchor = new AtlasGlossaryHeader + { + DisplayText = "", + GlossaryGuid = "", + RelationGuid = "", + }, + Antonyms = {new AtlasRelatedTermHeader + { + Description = "", + DisplayText = "", + Expression = "", + RelationGuid = "", + Status = AtlasTermRelationshipStatus.Draft, + Steward = "", + TermGuid = "", + }}, + Status = TermStatus.Draft, + NickName = "", + HierarchyInfo = {new PurviewObjectId + { + Guid = "", + TypeName = "", + UniqueAttributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + Name = "", + DisplayText = "", + ItemPath = "", + ResourceId = "", + Properties = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + }}, + Resources = {new ResourceLink + { + DisplayName = "", + Url = "", + }}, + Contacts = + { + ["key"] = {new ContactInfo + { + Id = "", + Info = "", + }} + }, + Attributes = + { + ["key"] = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + } + }, + AssignedEntities = {new AtlasRelatedObjectId + { + Guid = "", + TypeName = "", + UniqueAttributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + DisplayText = "", + EntityStatus = EntityStatus.Active, + RelationshipType = "", + RelationshipAttributes = new AtlasStruct + { + Attributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + TypeName = "", + LastModifiedTS = "", + }, + RelationshipGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), + RelationshipStatus = StatusAtlasRelationship.Active, + }}, + Categories = {new AtlasTermCategorizationHeader + { + CategoryGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), + Description = "", + DisplayText = "", + RelationGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), + Status = AtlasTermRelationshipStatus.Draft, + }}, + Classifies = {default}, + Examples = {""}, + IsA = {default}, + PreferredTerms = {default}, + PreferredToTerms = {default}, + ReplacedBy = {default}, + ReplacementTerms = {default}, + SeeAlso = {default}, + Synonyms = {default}, + TranslatedTerms = {default}, + TranslationTerms = {default}, + Usage = "", + ValidValues = {default}, + ValidValuesFor = {default}, + } +}, includeTermHierarchy: true); +]]> + + + +This sample shows how to call CreateTerms. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response> response = client.CreateTerms(new AtlasGlossaryTerm[] +{ + new AtlasGlossaryTerm() +}); +]]> +This sample shows how to call CreateTerms with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response> response = client.CreateTerms(new AtlasGlossaryTerm[] +{ + new AtlasGlossaryTerm + { + Guid = "", + Classifications = {new AtlasClassification + { + Attributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + TypeName = "", + LastModifiedTS = "", + EntityGuid = "", + EntityStatus = EntityStatus.Active, + RemovePropagationsOnEntityDelete = true, + ValidityPeriods = {new TimeBoundary + { + EndTime = "", + StartTime = "", + TimeZone = "", + }}, + }}, + LongDescription = "", + Name = "", + QualifiedName = "", + ShortDescription = "", + LastModifiedTS = "", + CreateTime = 1234L, + CreatedBy = "", + UpdateTime = 1234L, + UpdatedBy = "", + Abbreviation = "", + TemplateName = {BinaryData.FromObjectAsJson(new object())}, + Anchor = new AtlasGlossaryHeader + { + DisplayText = "", + GlossaryGuid = "", + RelationGuid = "", + }, + Antonyms = {new AtlasRelatedTermHeader + { + Description = "", + DisplayText = "", + Expression = "", + RelationGuid = "", + Status = AtlasTermRelationshipStatus.Draft, + Steward = "", + TermGuid = "", + }}, + Status = TermStatus.Draft, + NickName = "", + HierarchyInfo = {new PurviewObjectId + { + Guid = "", + TypeName = "", + UniqueAttributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + Name = "", + DisplayText = "", + ItemPath = "", + ResourceId = "", + Properties = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + }}, + Resources = {new ResourceLink + { + DisplayName = "", + Url = "", + }}, + Contacts = + { + ["key"] = {new ContactInfo + { + Id = "", + Info = "", + }} + }, + Attributes = + { + ["key"] = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + } + }, + AssignedEntities = {new AtlasRelatedObjectId + { + Guid = "", + TypeName = "", + UniqueAttributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + DisplayText = "", + EntityStatus = EntityStatus.Active, + RelationshipType = "", + RelationshipAttributes = new AtlasStruct + { + Attributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + TypeName = "", + LastModifiedTS = "", + }, + RelationshipGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), + RelationshipStatus = StatusAtlasRelationship.Active, + }}, + Categories = {new AtlasTermCategorizationHeader + { + CategoryGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), + Description = "", + DisplayText = "", + RelationGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), + Status = AtlasTermRelationshipStatus.Draft, + }}, + Classifies = {default}, + Examples = {""}, + IsA = {default}, + PreferredTerms = {default}, + PreferredToTerms = {default}, + ReplacedBy = {default}, + ReplacementTerms = {default}, + SeeAlso = {default}, + Synonyms = {default}, + TranslatedTerms = {default}, + TranslationTerms = {default}, + Usage = "", + ValidValues = {default}, + ValidValuesFor = {default}, + } +}, includeTermHierarchy: true); +]]> + + + +This sample shows how to call CreateTermsAsync and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object[] +{ + new object() +}); +Response response = await client.CreateTermsAsync(content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result[0].ToString()); +]]> +This sample shows how to call CreateTermsAsync with all parameters and request content and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object[] +{ + new + { + guid = "", + classifications = new object[] + { + new + { + attributes = new + { + key = new object(), + }, + typeName = "", + lastModifiedTS = "", + entityGuid = "", + entityStatus = "ACTIVE", + removePropagationsOnEntityDelete = true, + validityPeriods = new object[] + { + new + { + endTime = "", + startTime = "", + timeZone = "", + } + }, + } + }, + longDescription = "", + name = "", + qualifiedName = "", + shortDescription = "", + lastModifiedTS = "", + createTime = 1234L, + createdBy = "", + updateTime = 1234L, + updatedBy = "", + abbreviation = "", + templateName = new object[] + { + new object() + }, + anchor = new + { + displayText = "", + glossaryGuid = "", + relationGuid = "", + }, + antonyms = new object[] + { + new + { + description = "", + displayText = "", + expression = "", + relationGuid = "", + status = "DRAFT", + steward = "", + termGuid = "", + } + }, + status = "Draft", + nickName = "", + hierarchyInfo = new object[] + { + new + { + guid = "", + typeName = "", + uniqueAttributes = new + { + key = new object(), + }, + name = "", + displayText = "", + itemPath = "", + resourceId = "", + properties = new + { + key = new object(), + }, + } + }, + resources = new object[] + { + new + { + displayName = "", + url = "", + } + }, + contacts = new + { + key = new object[] + { + new + { + id = "", + info = "", + } + }, + }, + attributes = new + { + key = new + { + key = new object(), + }, + }, + assignedEntities = new object[] + { + new + { + guid = "", + typeName = "", + uniqueAttributes = new + { + key = new object(), + }, + displayText = "", + entityStatus = "ACTIVE", + relationshipType = "", + relationshipAttributes = new + { + attributes = new + { + key = new object(), + }, + typeName = "", + lastModifiedTS = "", + }, + relationshipGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", + relationshipStatus = "ACTIVE", + } + }, + categories = new object[] + { + new + { + categoryGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", + description = "", + displayText = "", + relationGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", + status = "DRAFT", + } + }, + classifies = new object[] + { + null + }, + examples = new object[] + { + "" + }, + isA = new object[] + { + null + }, + preferredTerms = new object[] + { + null + }, + preferredToTerms = new object[] + { + null + }, + replacedBy = new object[] + { + null + }, + replacementTerms = new object[] + { + null + }, + seeAlso = new object[] + { + null + }, + synonyms = new object[] + { + null + }, + translatedTerms = new object[] + { + null + }, + translationTerms = new object[] + { + null + }, + usage = "", + validValues = new object[] + { + null + }, + validValuesFor = new object[] + { + null + }, + } +}); +Response response = await client.CreateTermsAsync(content, includeTermHierarchy: true); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result[0].GetProperty("guid").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result[0].GetProperty("longDescription").ToString()); +Console.WriteLine(result[0].GetProperty("name").ToString()); +Console.WriteLine(result[0].GetProperty("qualifiedName").ToString()); +Console.WriteLine(result[0].GetProperty("shortDescription").ToString()); +Console.WriteLine(result[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result[0].GetProperty("createTime").ToString()); +Console.WriteLine(result[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result[0].GetProperty("updateTime").ToString()); +Console.WriteLine(result[0].GetProperty("updatedBy").ToString()); +Console.WriteLine(result[0].GetProperty("abbreviation").ToString()); +Console.WriteLine(result[0].GetProperty("templateName")[0].ToString()); +Console.WriteLine(result[0].GetProperty("anchor").GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("anchor").GetProperty("glossaryGuid").ToString()); +Console.WriteLine(result[0].GetProperty("anchor").GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("antonyms")[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("antonyms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("antonyms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result[0].GetProperty("antonyms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("antonyms")[0].GetProperty("status").ToString()); +Console.WriteLine(result[0].GetProperty("antonyms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result[0].GetProperty("antonyms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result[0].GetProperty("status").ToString()); +Console.WriteLine(result[0].GetProperty("nickName").ToString()); +Console.WriteLine(result[0].GetProperty("hierarchyInfo")[0].GetProperty("guid").ToString()); +Console.WriteLine(result[0].GetProperty("hierarchyInfo")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result[0].GetProperty("hierarchyInfo")[0].GetProperty("uniqueAttributes").GetProperty("").ToString()); +Console.WriteLine(result[0].GetProperty("hierarchyInfo")[0].GetProperty("name").ToString()); +Console.WriteLine(result[0].GetProperty("hierarchyInfo")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("hierarchyInfo")[0].GetProperty("itemPath").ToString()); +Console.WriteLine(result[0].GetProperty("hierarchyInfo")[0].GetProperty("resourceId").ToString()); +Console.WriteLine(result[0].GetProperty("hierarchyInfo")[0].GetProperty("properties").GetProperty("").ToString()); +Console.WriteLine(result[0].GetProperty("resources")[0].GetProperty("displayName").ToString()); +Console.WriteLine(result[0].GetProperty("resources")[0].GetProperty("url").ToString()); +Console.WriteLine(result[0].GetProperty("contacts").GetProperty("")[0].GetProperty("id").ToString()); +Console.WriteLine(result[0].GetProperty("contacts").GetProperty("")[0].GetProperty("info").ToString()); +Console.WriteLine(result[0].GetProperty("attributes").GetProperty("").GetProperty("").ToString()); +Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("guid").ToString()); +Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("uniqueAttributes").GetProperty("").ToString()); +Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("relationshipType").ToString()); +Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("typeName").ToString()); +Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("relationshipGuid").ToString()); +Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("relationshipStatus").ToString()); +Console.WriteLine(result[0].GetProperty("categories")[0].GetProperty("categoryGuid").ToString()); +Console.WriteLine(result[0].GetProperty("categories")[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("categories")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("categories")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("categories")[0].GetProperty("status").ToString()); +Console.WriteLine(result[0].GetProperty("classifies")[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("classifies")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("classifies")[0].GetProperty("expression").ToString()); +Console.WriteLine(result[0].GetProperty("classifies")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("classifies")[0].GetProperty("status").ToString()); +Console.WriteLine(result[0].GetProperty("classifies")[0].GetProperty("steward").ToString()); +Console.WriteLine(result[0].GetProperty("classifies")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result[0].GetProperty("examples")[0].ToString()); +Console.WriteLine(result[0].GetProperty("isA")[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("isA")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("isA")[0].GetProperty("expression").ToString()); +Console.WriteLine(result[0].GetProperty("isA")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("isA")[0].GetProperty("status").ToString()); +Console.WriteLine(result[0].GetProperty("isA")[0].GetProperty("steward").ToString()); +Console.WriteLine(result[0].GetProperty("isA")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result[0].GetProperty("preferredTerms")[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("preferredTerms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("preferredTerms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result[0].GetProperty("preferredTerms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("preferredTerms")[0].GetProperty("status").ToString()); +Console.WriteLine(result[0].GetProperty("preferredTerms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result[0].GetProperty("preferredTerms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result[0].GetProperty("preferredToTerms")[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("preferredToTerms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("preferredToTerms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result[0].GetProperty("preferredToTerms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("preferredToTerms")[0].GetProperty("status").ToString()); +Console.WriteLine(result[0].GetProperty("preferredToTerms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result[0].GetProperty("preferredToTerms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result[0].GetProperty("replacedBy")[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("replacedBy")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("replacedBy")[0].GetProperty("expression").ToString()); +Console.WriteLine(result[0].GetProperty("replacedBy")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("replacedBy")[0].GetProperty("status").ToString()); +Console.WriteLine(result[0].GetProperty("replacedBy")[0].GetProperty("steward").ToString()); +Console.WriteLine(result[0].GetProperty("replacedBy")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result[0].GetProperty("replacementTerms")[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("replacementTerms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("replacementTerms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result[0].GetProperty("replacementTerms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("replacementTerms")[0].GetProperty("status").ToString()); +Console.WriteLine(result[0].GetProperty("replacementTerms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result[0].GetProperty("replacementTerms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result[0].GetProperty("seeAlso")[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("seeAlso")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("seeAlso")[0].GetProperty("expression").ToString()); +Console.WriteLine(result[0].GetProperty("seeAlso")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("seeAlso")[0].GetProperty("status").ToString()); +Console.WriteLine(result[0].GetProperty("seeAlso")[0].GetProperty("steward").ToString()); +Console.WriteLine(result[0].GetProperty("seeAlso")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result[0].GetProperty("synonyms")[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("synonyms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("synonyms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result[0].GetProperty("synonyms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("synonyms")[0].GetProperty("status").ToString()); +Console.WriteLine(result[0].GetProperty("synonyms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result[0].GetProperty("synonyms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result[0].GetProperty("translatedTerms")[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("translatedTerms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("translatedTerms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result[0].GetProperty("translatedTerms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("translatedTerms")[0].GetProperty("status").ToString()); +Console.WriteLine(result[0].GetProperty("translatedTerms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result[0].GetProperty("translatedTerms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result[0].GetProperty("translationTerms")[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("translationTerms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("translationTerms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result[0].GetProperty("translationTerms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("translationTerms")[0].GetProperty("status").ToString()); +Console.WriteLine(result[0].GetProperty("translationTerms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result[0].GetProperty("translationTerms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result[0].GetProperty("usage").ToString()); +Console.WriteLine(result[0].GetProperty("validValues")[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("validValues")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("validValues")[0].GetProperty("expression").ToString()); +Console.WriteLine(result[0].GetProperty("validValues")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("validValues")[0].GetProperty("status").ToString()); +Console.WriteLine(result[0].GetProperty("validValues")[0].GetProperty("steward").ToString()); +Console.WriteLine(result[0].GetProperty("validValues")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result[0].GetProperty("validValuesFor")[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("validValuesFor")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("validValuesFor")[0].GetProperty("expression").ToString()); +Console.WriteLine(result[0].GetProperty("validValuesFor")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("validValuesFor")[0].GetProperty("status").ToString()); +Console.WriteLine(result[0].GetProperty("validValuesFor")[0].GetProperty("steward").ToString()); +Console.WriteLine(result[0].GetProperty("validValuesFor")[0].GetProperty("termGuid").ToString()); +]]> + + + +This sample shows how to call CreateTerms and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object[] +{ + new object() +}); +Response response = client.CreateTerms(content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result[0].ToString()); +]]> +This sample shows how to call CreateTerms with all parameters and request content and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object[] +{ + new + { + guid = "", + classifications = new object[] + { + new + { + attributes = new + { + key = new object(), + }, + typeName = "", + lastModifiedTS = "", + entityGuid = "", + entityStatus = "ACTIVE", + removePropagationsOnEntityDelete = true, + validityPeriods = new object[] + { + new + { + endTime = "", + startTime = "", + timeZone = "", + } + }, + } + }, + longDescription = "", + name = "", + qualifiedName = "", + shortDescription = "", + lastModifiedTS = "", + createTime = 1234L, + createdBy = "", + updateTime = 1234L, + updatedBy = "", + abbreviation = "", + templateName = new object[] + { + new object() + }, + anchor = new + { + displayText = "", + glossaryGuid = "", + relationGuid = "", + }, + antonyms = new object[] + { + new + { + description = "", + displayText = "", + expression = "", + relationGuid = "", + status = "DRAFT", + steward = "", + termGuid = "", + } + }, + status = "Draft", + nickName = "", + hierarchyInfo = new object[] + { + new + { + guid = "", + typeName = "", + uniqueAttributes = new + { + key = new object(), + }, + name = "", + displayText = "", + itemPath = "", + resourceId = "", + properties = new + { + key = new object(), + }, + } + }, + resources = new object[] + { + new + { + displayName = "", + url = "", + } + }, + contacts = new + { + key = new object[] + { + new + { + id = "", + info = "", + } + }, + }, + attributes = new + { + key = new + { + key = new object(), + }, + }, + assignedEntities = new object[] + { + new + { + guid = "", + typeName = "", + uniqueAttributes = new + { + key = new object(), + }, + displayText = "", + entityStatus = "ACTIVE", + relationshipType = "", + relationshipAttributes = new + { + attributes = new + { + key = new object(), + }, + typeName = "", + lastModifiedTS = "", + }, + relationshipGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", + relationshipStatus = "ACTIVE", + } + }, + categories = new object[] + { + new + { + categoryGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", + description = "", + displayText = "", + relationGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", + status = "DRAFT", + } + }, + classifies = new object[] + { + null + }, + examples = new object[] + { + "" + }, + isA = new object[] + { + null + }, + preferredTerms = new object[] + { + null + }, + preferredToTerms = new object[] + { + null + }, + replacedBy = new object[] + { + null + }, + replacementTerms = new object[] + { + null + }, + seeAlso = new object[] + { + null + }, + synonyms = new object[] + { + null + }, + translatedTerms = new object[] + { + null + }, + translationTerms = new object[] + { + null + }, + usage = "", + validValues = new object[] + { + null + }, + validValuesFor = new object[] + { + null + }, + } +}); +Response response = client.CreateTerms(content, includeTermHierarchy: true); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result[0].GetProperty("guid").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result[0].GetProperty("longDescription").ToString()); +Console.WriteLine(result[0].GetProperty("name").ToString()); +Console.WriteLine(result[0].GetProperty("qualifiedName").ToString()); +Console.WriteLine(result[0].GetProperty("shortDescription").ToString()); +Console.WriteLine(result[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result[0].GetProperty("createTime").ToString()); +Console.WriteLine(result[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result[0].GetProperty("updateTime").ToString()); +Console.WriteLine(result[0].GetProperty("updatedBy").ToString()); +Console.WriteLine(result[0].GetProperty("abbreviation").ToString()); +Console.WriteLine(result[0].GetProperty("templateName")[0].ToString()); +Console.WriteLine(result[0].GetProperty("anchor").GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("anchor").GetProperty("glossaryGuid").ToString()); +Console.WriteLine(result[0].GetProperty("anchor").GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("antonyms")[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("antonyms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("antonyms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result[0].GetProperty("antonyms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("antonyms")[0].GetProperty("status").ToString()); +Console.WriteLine(result[0].GetProperty("antonyms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result[0].GetProperty("antonyms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result[0].GetProperty("status").ToString()); +Console.WriteLine(result[0].GetProperty("nickName").ToString()); +Console.WriteLine(result[0].GetProperty("hierarchyInfo")[0].GetProperty("guid").ToString()); +Console.WriteLine(result[0].GetProperty("hierarchyInfo")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result[0].GetProperty("hierarchyInfo")[0].GetProperty("uniqueAttributes").GetProperty("").ToString()); +Console.WriteLine(result[0].GetProperty("hierarchyInfo")[0].GetProperty("name").ToString()); +Console.WriteLine(result[0].GetProperty("hierarchyInfo")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("hierarchyInfo")[0].GetProperty("itemPath").ToString()); +Console.WriteLine(result[0].GetProperty("hierarchyInfo")[0].GetProperty("resourceId").ToString()); +Console.WriteLine(result[0].GetProperty("hierarchyInfo")[0].GetProperty("properties").GetProperty("").ToString()); +Console.WriteLine(result[0].GetProperty("resources")[0].GetProperty("displayName").ToString()); +Console.WriteLine(result[0].GetProperty("resources")[0].GetProperty("url").ToString()); +Console.WriteLine(result[0].GetProperty("contacts").GetProperty("")[0].GetProperty("id").ToString()); +Console.WriteLine(result[0].GetProperty("contacts").GetProperty("")[0].GetProperty("info").ToString()); +Console.WriteLine(result[0].GetProperty("attributes").GetProperty("").GetProperty("").ToString()); +Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("guid").ToString()); +Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("uniqueAttributes").GetProperty("").ToString()); +Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("relationshipType").ToString()); +Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("typeName").ToString()); +Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("relationshipGuid").ToString()); +Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("relationshipStatus").ToString()); +Console.WriteLine(result[0].GetProperty("categories")[0].GetProperty("categoryGuid").ToString()); +Console.WriteLine(result[0].GetProperty("categories")[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("categories")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("categories")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("categories")[0].GetProperty("status").ToString()); +Console.WriteLine(result[0].GetProperty("classifies")[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("classifies")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("classifies")[0].GetProperty("expression").ToString()); +Console.WriteLine(result[0].GetProperty("classifies")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("classifies")[0].GetProperty("status").ToString()); +Console.WriteLine(result[0].GetProperty("classifies")[0].GetProperty("steward").ToString()); +Console.WriteLine(result[0].GetProperty("classifies")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result[0].GetProperty("examples")[0].ToString()); +Console.WriteLine(result[0].GetProperty("isA")[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("isA")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("isA")[0].GetProperty("expression").ToString()); +Console.WriteLine(result[0].GetProperty("isA")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("isA")[0].GetProperty("status").ToString()); +Console.WriteLine(result[0].GetProperty("isA")[0].GetProperty("steward").ToString()); +Console.WriteLine(result[0].GetProperty("isA")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result[0].GetProperty("preferredTerms")[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("preferredTerms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("preferredTerms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result[0].GetProperty("preferredTerms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("preferredTerms")[0].GetProperty("status").ToString()); +Console.WriteLine(result[0].GetProperty("preferredTerms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result[0].GetProperty("preferredTerms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result[0].GetProperty("preferredToTerms")[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("preferredToTerms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("preferredToTerms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result[0].GetProperty("preferredToTerms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("preferredToTerms")[0].GetProperty("status").ToString()); +Console.WriteLine(result[0].GetProperty("preferredToTerms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result[0].GetProperty("preferredToTerms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result[0].GetProperty("replacedBy")[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("replacedBy")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("replacedBy")[0].GetProperty("expression").ToString()); +Console.WriteLine(result[0].GetProperty("replacedBy")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("replacedBy")[0].GetProperty("status").ToString()); +Console.WriteLine(result[0].GetProperty("replacedBy")[0].GetProperty("steward").ToString()); +Console.WriteLine(result[0].GetProperty("replacedBy")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result[0].GetProperty("replacementTerms")[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("replacementTerms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("replacementTerms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result[0].GetProperty("replacementTerms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("replacementTerms")[0].GetProperty("status").ToString()); +Console.WriteLine(result[0].GetProperty("replacementTerms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result[0].GetProperty("replacementTerms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result[0].GetProperty("seeAlso")[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("seeAlso")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("seeAlso")[0].GetProperty("expression").ToString()); +Console.WriteLine(result[0].GetProperty("seeAlso")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("seeAlso")[0].GetProperty("status").ToString()); +Console.WriteLine(result[0].GetProperty("seeAlso")[0].GetProperty("steward").ToString()); +Console.WriteLine(result[0].GetProperty("seeAlso")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result[0].GetProperty("synonyms")[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("synonyms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("synonyms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result[0].GetProperty("synonyms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("synonyms")[0].GetProperty("status").ToString()); +Console.WriteLine(result[0].GetProperty("synonyms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result[0].GetProperty("synonyms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result[0].GetProperty("translatedTerms")[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("translatedTerms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("translatedTerms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result[0].GetProperty("translatedTerms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("translatedTerms")[0].GetProperty("status").ToString()); +Console.WriteLine(result[0].GetProperty("translatedTerms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result[0].GetProperty("translatedTerms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result[0].GetProperty("translationTerms")[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("translationTerms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("translationTerms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result[0].GetProperty("translationTerms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("translationTerms")[0].GetProperty("status").ToString()); +Console.WriteLine(result[0].GetProperty("translationTerms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result[0].GetProperty("translationTerms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result[0].GetProperty("usage").ToString()); +Console.WriteLine(result[0].GetProperty("validValues")[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("validValues")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("validValues")[0].GetProperty("expression").ToString()); +Console.WriteLine(result[0].GetProperty("validValues")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("validValues")[0].GetProperty("status").ToString()); +Console.WriteLine(result[0].GetProperty("validValues")[0].GetProperty("steward").ToString()); +Console.WriteLine(result[0].GetProperty("validValues")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result[0].GetProperty("validValuesFor")[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("validValuesFor")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("validValuesFor")[0].GetProperty("expression").ToString()); +Console.WriteLine(result[0].GetProperty("validValuesFor")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("validValuesFor")[0].GetProperty("status").ToString()); +Console.WriteLine(result[0].GetProperty("validValuesFor")[0].GetProperty("steward").ToString()); +Console.WriteLine(result[0].GetProperty("validValuesFor")[0].GetProperty("termGuid").ToString()); +]]> + + + +This sample shows how to call GetEntitiesAssignedWithTermAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response> response = await client.GetEntitiesAssignedWithTermAsync(""); +]]> +This sample shows how to call GetEntitiesAssignedWithTermAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response> response = await client.GetEntitiesAssignedWithTermAsync("", limit: 1234, offset: 1234, sort: ""); +]]> + + + +This sample shows how to call GetEntitiesAssignedWithTerm. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response> response = client.GetEntitiesAssignedWithTerm(""); +]]> +This sample shows how to call GetEntitiesAssignedWithTerm with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response> response = client.GetEntitiesAssignedWithTerm("", limit: 1234, offset: 1234, sort: ""); +]]> + + + +This sample shows how to call GetEntitiesAssignedWithTermAsync and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = await client.GetEntitiesAssignedWithTermAsync("", null, null, null, null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result[0].ToString()); +]]> +This sample shows how to call GetEntitiesAssignedWithTermAsync with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = await client.GetEntitiesAssignedWithTermAsync("", 1234, 1234, "", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result[0].GetProperty("guid").ToString()); +Console.WriteLine(result[0].GetProperty("typeName").ToString()); +Console.WriteLine(result[0].GetProperty("uniqueAttributes").GetProperty("").ToString()); +Console.WriteLine(result[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result[0].GetProperty("relationshipType").ToString()); +Console.WriteLine(result[0].GetProperty("relationshipAttributes").GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result[0].GetProperty("relationshipAttributes").GetProperty("typeName").ToString()); +Console.WriteLine(result[0].GetProperty("relationshipAttributes").GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result[0].GetProperty("relationshipGuid").ToString()); +Console.WriteLine(result[0].GetProperty("relationshipStatus").ToString()); +]]> + + + +This sample shows how to call GetEntitiesAssignedWithTerm and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = client.GetEntitiesAssignedWithTerm("", null, null, null, null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result[0].ToString()); +]]> +This sample shows how to call GetEntitiesAssignedWithTerm with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = client.GetEntitiesAssignedWithTerm("", 1234, 1234, "", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result[0].GetProperty("guid").ToString()); +Console.WriteLine(result[0].GetProperty("typeName").ToString()); +Console.WriteLine(result[0].GetProperty("uniqueAttributes").GetProperty("").ToString()); +Console.WriteLine(result[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result[0].GetProperty("relationshipType").ToString()); +Console.WriteLine(result[0].GetProperty("relationshipAttributes").GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result[0].GetProperty("relationshipAttributes").GetProperty("typeName").ToString()); +Console.WriteLine(result[0].GetProperty("relationshipAttributes").GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result[0].GetProperty("relationshipGuid").ToString()); +Console.WriteLine(result[0].GetProperty("relationshipStatus").ToString()); +]]> + + + +This sample shows how to call AssignTermToEntitiesAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = await client.AssignTermToEntitiesAsync("", new AtlasRelatedObjectId[] +{ + new AtlasRelatedObjectId() +}); +]]> +This sample shows how to call AssignTermToEntitiesAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = await client.AssignTermToEntitiesAsync("", new AtlasRelatedObjectId[] +{ + new AtlasRelatedObjectId + { + Guid = "", + TypeName = "", + UniqueAttributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + DisplayText = "", + EntityStatus = EntityStatus.Active, + RelationshipType = "", + RelationshipAttributes = new AtlasStruct + { + Attributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + TypeName = "", + LastModifiedTS = "", + }, + RelationshipGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), + RelationshipStatus = StatusAtlasRelationship.Active, + } +}); +]]> + + + +This sample shows how to call AssignTermToEntities. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = client.AssignTermToEntities("", new AtlasRelatedObjectId[] +{ + new AtlasRelatedObjectId() +}); +]]> +This sample shows how to call AssignTermToEntities with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = client.AssignTermToEntities("", new AtlasRelatedObjectId[] +{ + new AtlasRelatedObjectId + { + Guid = "", + TypeName = "", + UniqueAttributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + DisplayText = "", + EntityStatus = EntityStatus.Active, + RelationshipType = "", + RelationshipAttributes = new AtlasStruct + { + Attributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + TypeName = "", + LastModifiedTS = "", + }, + RelationshipGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), + RelationshipStatus = StatusAtlasRelationship.Active, + } +}); +]]> + + + +This sample shows how to call AssignTermToEntitiesAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object[] +{ + new object() +}); +Response response = await client.AssignTermToEntitiesAsync("", content); + +Console.WriteLine(response.Status); +]]> +This sample shows how to call AssignTermToEntitiesAsync with all parameters and request content. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object[] +{ + new + { + guid = "", + typeName = "", + uniqueAttributes = new + { + key = new object(), + }, + displayText = "", + entityStatus = "ACTIVE", + relationshipType = "", + relationshipAttributes = new + { + attributes = new + { + key = new object(), + }, + typeName = "", + lastModifiedTS = "", + }, + relationshipGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", + relationshipStatus = "ACTIVE", + } +}); +Response response = await client.AssignTermToEntitiesAsync("", content); + +Console.WriteLine(response.Status); +]]> + + + +This sample shows how to call AssignTermToEntities. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object[] +{ + new object() +}); +Response response = client.AssignTermToEntities("", content); + +Console.WriteLine(response.Status); +]]> +This sample shows how to call AssignTermToEntities with all parameters and request content. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object[] +{ + new + { + guid = "", + typeName = "", + uniqueAttributes = new + { + key = new object(), + }, + displayText = "", + entityStatus = "ACTIVE", + relationshipType = "", + relationshipAttributes = new + { + attributes = new + { + key = new object(), + }, + typeName = "", + lastModifiedTS = "", + }, + relationshipGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", + relationshipStatus = "ACTIVE", + } +}); +Response response = client.AssignTermToEntities("", content); + +Console.WriteLine(response.Status); +]]> + + + +This sample shows how to call DeleteTermAssignmentFromEntitiesAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = await client.DeleteTermAssignmentFromEntitiesAsync("", new AtlasRelatedObjectId[] +{ + new AtlasRelatedObjectId() +}); +]]> +This sample shows how to call DeleteTermAssignmentFromEntitiesAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = await client.DeleteTermAssignmentFromEntitiesAsync("", new AtlasRelatedObjectId[] +{ + new AtlasRelatedObjectId + { + Guid = "", + TypeName = "", + UniqueAttributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + DisplayText = "", + EntityStatus = EntityStatus.Active, + RelationshipType = "", + RelationshipAttributes = new AtlasStruct + { + Attributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + TypeName = "", + LastModifiedTS = "", + }, + RelationshipGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), + RelationshipStatus = StatusAtlasRelationship.Active, + } +}); +]]> + + + +This sample shows how to call DeleteTermAssignmentFromEntities. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = client.DeleteTermAssignmentFromEntities("", new AtlasRelatedObjectId[] +{ + new AtlasRelatedObjectId() +}); +]]> +This sample shows how to call DeleteTermAssignmentFromEntities with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = client.DeleteTermAssignmentFromEntities("", new AtlasRelatedObjectId[] +{ + new AtlasRelatedObjectId + { + Guid = "", + TypeName = "", + UniqueAttributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + DisplayText = "", + EntityStatus = EntityStatus.Active, + RelationshipType = "", + RelationshipAttributes = new AtlasStruct + { + Attributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + TypeName = "", + LastModifiedTS = "", + }, + RelationshipGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), + RelationshipStatus = StatusAtlasRelationship.Active, + } +}); +]]> + + + +This sample shows how to call DeleteTermAssignmentFromEntitiesAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object[] +{ + new object() +}); +Response response = await client.DeleteTermAssignmentFromEntitiesAsync("", content); + +Console.WriteLine(response.Status); +]]> +This sample shows how to call DeleteTermAssignmentFromEntitiesAsync with all parameters and request content. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object[] +{ + new + { + guid = "", + typeName = "", + uniqueAttributes = new + { + key = new object(), + }, + displayText = "", + entityStatus = "ACTIVE", + relationshipType = "", + relationshipAttributes = new + { + attributes = new + { + key = new object(), + }, + typeName = "", + lastModifiedTS = "", + }, + relationshipGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", + relationshipStatus = "ACTIVE", + } +}); +Response response = await client.DeleteTermAssignmentFromEntitiesAsync("", content); + +Console.WriteLine(response.Status); +]]> + + + +This sample shows how to call DeleteTermAssignmentFromEntities. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object[] +{ + new object() +}); +Response response = client.DeleteTermAssignmentFromEntities("", content); + +Console.WriteLine(response.Status); +]]> +This sample shows how to call DeleteTermAssignmentFromEntities with all parameters and request content. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object[] +{ + new + { + guid = "", + typeName = "", + uniqueAttributes = new + { + key = new object(), + }, + displayText = "", + entityStatus = "ACTIVE", + relationshipType = "", + relationshipAttributes = new + { + attributes = new + { + key = new object(), + }, + typeName = "", + lastModifiedTS = "", + }, + relationshipGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", + relationshipStatus = "ACTIVE", + } +}); +Response response = client.DeleteTermAssignmentFromEntities("", content); + +Console.WriteLine(response.Status); +]]> + + + +This sample shows how to call GetRelatedTermsAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response>> response = await client.GetRelatedTermsAsync(""); +]]> +This sample shows how to call GetRelatedTermsAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response>> response = await client.GetRelatedTermsAsync("", limit: 1234, offset: 1234, sort: ""); +]]> + + + +This sample shows how to call GetRelatedTerms. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response>> response = client.GetRelatedTerms(""); +]]> +This sample shows how to call GetRelatedTerms with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response>> response = client.GetRelatedTerms("", limit: 1234, offset: 1234, sort: ""); +]]> + + + +This sample shows how to call GetRelatedTermsAsync and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = await client.GetRelatedTermsAsync("", null, null, null, null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("")[0].ToString()); +]]> +This sample shows how to call GetRelatedTermsAsync with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = await client.GetRelatedTermsAsync("", 1234, 1234, "", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("")[0].GetProperty("termGuid").ToString()); +]]> + + + +This sample shows how to call GetRelatedTerms and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = client.GetRelatedTerms("", null, null, null, null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("")[0].ToString()); +]]> +This sample shows how to call GetRelatedTerms with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = client.GetRelatedTerms("", 1234, 1234, "", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("")[0].GetProperty("termGuid").ToString()); +]]> + + + +This sample shows how to call GetGlossaryAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = await client.GetGlossaryAsync(""); +]]> +This sample shows how to call GetGlossaryAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = await client.GetGlossaryAsync(""); +]]> + + + +This sample shows how to call GetGlossary. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = client.GetGlossary(""); +]]> +This sample shows how to call GetGlossary with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = client.GetGlossary(""); +]]> + + + +This sample shows how to call GetGlossaryAsync and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = await client.GetGlossaryAsync("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call GetGlossaryAsync with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = await client.GetGlossaryAsync("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("longDescription").ToString()); +Console.WriteLine(result.GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("qualifiedName").ToString()); +Console.WriteLine(result.GetProperty("shortDescription").ToString()); +Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("categoryGuid").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("parentCategoryGuid").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("language").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("usage").ToString()); +]]> + + + +This sample shows how to call GetGlossary and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = client.GetGlossary("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call GetGlossary with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = client.GetGlossary("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("longDescription").ToString()); +Console.WriteLine(result.GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("qualifiedName").ToString()); +Console.WriteLine(result.GetProperty("shortDescription").ToString()); +Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("categoryGuid").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("parentCategoryGuid").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("language").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("usage").ToString()); +]]> + + + +This sample shows how to call UpdateAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +AtlasGlossary updatedGlossary = new AtlasGlossary(); +Response response = await client.UpdateAsync("", updatedGlossary); +]]> +This sample shows how to call UpdateAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +AtlasGlossary updatedGlossary = new AtlasGlossary +{ + Guid = "", + Classifications = {new AtlasClassification + { + Attributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + TypeName = "", + LastModifiedTS = "", + EntityGuid = "", + EntityStatus = EntityStatus.Active, + RemovePropagationsOnEntityDelete = true, + ValidityPeriods = {new TimeBoundary + { + EndTime = "", + StartTime = "", + TimeZone = "", + }}, + }}, + LongDescription = "", + Name = "", + QualifiedName = "", + ShortDescription = "", + LastModifiedTS = "", + CreateTime = 1234L, + CreatedBy = "", + UpdateTime = 1234L, + UpdatedBy = "", + Categories = {new AtlasRelatedCategoryHeader + { + CategoryGuid = "", + Description = "", + DisplayText = "", + ParentCategoryGuid = "", + RelationGuid = "", + }}, + Language = "", + Terms = {new AtlasRelatedTermHeader + { + Description = "", + DisplayText = "", + Expression = "", + RelationGuid = "", + Status = AtlasTermRelationshipStatus.Draft, + Steward = "", + TermGuid = "", + }}, + Usage = "", +}; +Response response = await client.UpdateAsync("", updatedGlossary, ignoreTermsAndCategories: true); +]]> + + + +This sample shows how to call Update. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +AtlasGlossary updatedGlossary = new AtlasGlossary(); +Response response = client.Update("", updatedGlossary); +]]> +This sample shows how to call Update with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +AtlasGlossary updatedGlossary = new AtlasGlossary +{ + Guid = "", + Classifications = {new AtlasClassification + { + Attributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + TypeName = "", + LastModifiedTS = "", + EntityGuid = "", + EntityStatus = EntityStatus.Active, + RemovePropagationsOnEntityDelete = true, + ValidityPeriods = {new TimeBoundary + { + EndTime = "", + StartTime = "", + TimeZone = "", + }}, + }}, + LongDescription = "", + Name = "", + QualifiedName = "", + ShortDescription = "", + LastModifiedTS = "", + CreateTime = 1234L, + CreatedBy = "", + UpdateTime = 1234L, + UpdatedBy = "", + Categories = {new AtlasRelatedCategoryHeader + { + CategoryGuid = "", + Description = "", + DisplayText = "", + ParentCategoryGuid = "", + RelationGuid = "", + }}, + Language = "", + Terms = {new AtlasRelatedTermHeader + { + Description = "", + DisplayText = "", + Expression = "", + RelationGuid = "", + Status = AtlasTermRelationshipStatus.Draft, + Steward = "", + TermGuid = "", + }}, + Usage = "", +}; +Response response = client.Update("", updatedGlossary, ignoreTermsAndCategories: true); +]]> + + + +This sample shows how to call UpdateAsync and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object()); +Response response = await client.UpdateAsync("", content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call UpdateAsync with all parameters and request content and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new +{ + guid = "", + classifications = new object[] + { + new + { + attributes = new + { + key = new object(), + }, + typeName = "", + lastModifiedTS = "", + entityGuid = "", + entityStatus = "ACTIVE", + removePropagationsOnEntityDelete = true, + validityPeriods = new object[] + { + new + { + endTime = "", + startTime = "", + timeZone = "", + } + }, + } + }, + longDescription = "", + name = "", + qualifiedName = "", + shortDescription = "", + lastModifiedTS = "", + createTime = 1234L, + createdBy = "", + updateTime = 1234L, + updatedBy = "", + categories = new object[] + { + new + { + categoryGuid = "", + description = "", + displayText = "", + parentCategoryGuid = "", + relationGuid = "", + } + }, + language = "", + terms = new object[] + { + new + { + description = "", + displayText = "", + expression = "", + relationGuid = "", + status = "DRAFT", + steward = "", + termGuid = "", + } + }, + usage = "", +}); +Response response = await client.UpdateAsync("", content, ignoreTermsAndCategories: true); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("longDescription").ToString()); +Console.WriteLine(result.GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("qualifiedName").ToString()); +Console.WriteLine(result.GetProperty("shortDescription").ToString()); +Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("categoryGuid").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("parentCategoryGuid").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("language").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("usage").ToString()); +]]> + + + +This sample shows how to call Update and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object()); +Response response = client.Update("", content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call Update with all parameters and request content and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new +{ + guid = "", + classifications = new object[] + { + new + { + attributes = new + { + key = new object(), + }, + typeName = "", + lastModifiedTS = "", + entityGuid = "", + entityStatus = "ACTIVE", + removePropagationsOnEntityDelete = true, + validityPeriods = new object[] + { + new + { + endTime = "", + startTime = "", + timeZone = "", + } + }, + } + }, + longDescription = "", + name = "", + qualifiedName = "", + shortDescription = "", + lastModifiedTS = "", + createTime = 1234L, + createdBy = "", + updateTime = 1234L, + updatedBy = "", + categories = new object[] + { + new + { + categoryGuid = "", + description = "", + displayText = "", + parentCategoryGuid = "", + relationGuid = "", + } + }, + language = "", + terms = new object[] + { + new + { + description = "", + displayText = "", + expression = "", + relationGuid = "", + status = "DRAFT", + steward = "", + termGuid = "", + } + }, + usage = "", +}); +Response response = client.Update("", content, ignoreTermsAndCategories: true); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("longDescription").ToString()); +Console.WriteLine(result.GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("qualifiedName").ToString()); +Console.WriteLine(result.GetProperty("shortDescription").ToString()); +Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("categoryGuid").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("parentCategoryGuid").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("language").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("usage").ToString()); +]]> + + + +This sample shows how to call DeleteAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = await client.DeleteAsync(""); + +Console.WriteLine(response.Status); +]]> +This sample shows how to call DeleteAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = await client.DeleteAsync(""); + +Console.WriteLine(response.Status); +]]> + + + +This sample shows how to call Delete. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = client.Delete(""); + +Console.WriteLine(response.Status); +]]> +This sample shows how to call Delete with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = client.Delete(""); + +Console.WriteLine(response.Status); +]]> + + + +This sample shows how to call GetCategoriesAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response> response = await client.GetCategoriesAsync(""); +]]> +This sample shows how to call GetCategoriesAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response> response = await client.GetCategoriesAsync("", limit: 1234, offset: 1234, sort: ""); +]]> + + + +This sample shows how to call GetCategories. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response> response = client.GetCategories(""); +]]> +This sample shows how to call GetCategories with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response> response = client.GetCategories("", limit: 1234, offset: 1234, sort: ""); +]]> + + + +This sample shows how to call GetCategoriesAsync and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = await client.GetCategoriesAsync("", null, null, null, null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result[0].ToString()); +]]> +This sample shows how to call GetCategoriesAsync with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = await client.GetCategoriesAsync("", 1234, 1234, "", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result[0].GetProperty("guid").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result[0].GetProperty("longDescription").ToString()); +Console.WriteLine(result[0].GetProperty("name").ToString()); +Console.WriteLine(result[0].GetProperty("qualifiedName").ToString()); +Console.WriteLine(result[0].GetProperty("shortDescription").ToString()); +Console.WriteLine(result[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result[0].GetProperty("createTime").ToString()); +Console.WriteLine(result[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result[0].GetProperty("updateTime").ToString()); +Console.WriteLine(result[0].GetProperty("updatedBy").ToString()); +Console.WriteLine(result[0].GetProperty("anchor").GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("anchor").GetProperty("glossaryGuid").ToString()); +Console.WriteLine(result[0].GetProperty("anchor").GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("childrenCategories")[0].GetProperty("categoryGuid").ToString()); +Console.WriteLine(result[0].GetProperty("childrenCategories")[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("childrenCategories")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("childrenCategories")[0].GetProperty("parentCategoryGuid").ToString()); +Console.WriteLine(result[0].GetProperty("childrenCategories")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("parentCategory").GetProperty("categoryGuid").ToString()); +Console.WriteLine(result[0].GetProperty("parentCategory").GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("parentCategory").GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("parentCategory").GetProperty("parentCategoryGuid").ToString()); +Console.WriteLine(result[0].GetProperty("parentCategory").GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("status").ToString()); +Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("termGuid").ToString()); +]]> + + + +This sample shows how to call GetCategories and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = client.GetCategories("", null, null, null, null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result[0].ToString()); +]]> +This sample shows how to call GetCategories with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = client.GetCategories("", 1234, 1234, "", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result[0].GetProperty("guid").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result[0].GetProperty("longDescription").ToString()); +Console.WriteLine(result[0].GetProperty("name").ToString()); +Console.WriteLine(result[0].GetProperty("qualifiedName").ToString()); +Console.WriteLine(result[0].GetProperty("shortDescription").ToString()); +Console.WriteLine(result[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result[0].GetProperty("createTime").ToString()); +Console.WriteLine(result[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result[0].GetProperty("updateTime").ToString()); +Console.WriteLine(result[0].GetProperty("updatedBy").ToString()); +Console.WriteLine(result[0].GetProperty("anchor").GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("anchor").GetProperty("glossaryGuid").ToString()); +Console.WriteLine(result[0].GetProperty("anchor").GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("childrenCategories")[0].GetProperty("categoryGuid").ToString()); +Console.WriteLine(result[0].GetProperty("childrenCategories")[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("childrenCategories")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("childrenCategories")[0].GetProperty("parentCategoryGuid").ToString()); +Console.WriteLine(result[0].GetProperty("childrenCategories")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("parentCategory").GetProperty("categoryGuid").ToString()); +Console.WriteLine(result[0].GetProperty("parentCategory").GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("parentCategory").GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("parentCategory").GetProperty("parentCategoryGuid").ToString()); +Console.WriteLine(result[0].GetProperty("parentCategory").GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("status").ToString()); +Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("termGuid").ToString()); +]]> + + + +This sample shows how to call GetCategoriesHeadersAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response> response = await client.GetCategoriesHeadersAsync(""); +]]> +This sample shows how to call GetCategoriesHeadersAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response> response = await client.GetCategoriesHeadersAsync("", limit: 1234, offset: 1234, sort: ""); +]]> + + + +This sample shows how to call GetCategoriesHeaders. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response> response = client.GetCategoriesHeaders(""); +]]> +This sample shows how to call GetCategoriesHeaders with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response> response = client.GetCategoriesHeaders("", limit: 1234, offset: 1234, sort: ""); +]]> + + + +This sample shows how to call GetCategoriesHeadersAsync and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = await client.GetCategoriesHeadersAsync("", null, null, null, null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result[0].ToString()); +]]> +This sample shows how to call GetCategoriesHeadersAsync with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = await client.GetCategoriesHeadersAsync("", 1234, 1234, "", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result[0].GetProperty("categoryGuid").ToString()); +Console.WriteLine(result[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("parentCategoryGuid").ToString()); +Console.WriteLine(result[0].GetProperty("relationGuid").ToString()); +]]> + + + +This sample shows how to call GetCategoriesHeaders and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = client.GetCategoriesHeaders("", null, null, null, null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result[0].ToString()); +]]> +This sample shows how to call GetCategoriesHeaders with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = client.GetCategoriesHeaders("", 1234, 1234, "", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result[0].GetProperty("categoryGuid").ToString()); +Console.WriteLine(result[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("parentCategoryGuid").ToString()); +Console.WriteLine(result[0].GetProperty("relationGuid").ToString()); +]]> + + + +This sample shows how to call GetDetailedAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = await client.GetDetailedAsync(""); +]]> +This sample shows how to call GetDetailedAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = await client.GetDetailedAsync(""); +]]> + + + +This sample shows how to call GetDetailed. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = client.GetDetailed(""); +]]> +This sample shows how to call GetDetailed with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = client.GetDetailed(""); +]]> + + + +This sample shows how to call GetDetailedAsync and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = await client.GetDetailedAsync("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call GetDetailedAsync with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = await client.GetDetailedAsync("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("longDescription").ToString()); +Console.WriteLine(result.GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("qualifiedName").ToString()); +Console.WriteLine(result.GetProperty("shortDescription").ToString()); +Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("categoryGuid").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("parentCategoryGuid").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("language").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("usage").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("longDescription").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("qualifiedName").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("shortDescription").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("anchor").GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("anchor").GetProperty("glossaryGuid").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("anchor").GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("childrenCategories")[0].GetProperty("categoryGuid").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("childrenCategories")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("childrenCategories")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("childrenCategories")[0].GetProperty("parentCategoryGuid").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("childrenCategories")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("parentCategory").GetProperty("categoryGuid").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("parentCategory").GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("parentCategory").GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("parentCategory").GetProperty("parentCategoryGuid").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("parentCategory").GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("terms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("terms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("terms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("terms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("terms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("terms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("terms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("longDescription").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("qualifiedName").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("shortDescription").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("abbreviation").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("templateName")[0].ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("anchor").GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("anchor").GetProperty("glossaryGuid").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("anchor").GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("antonyms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("antonyms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("antonyms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("antonyms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("antonyms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("antonyms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("antonyms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("nickName").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("hierarchyInfo")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("hierarchyInfo")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("hierarchyInfo")[0].GetProperty("uniqueAttributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("hierarchyInfo")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("hierarchyInfo")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("hierarchyInfo")[0].GetProperty("itemPath").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("hierarchyInfo")[0].GetProperty("resourceId").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("hierarchyInfo")[0].GetProperty("properties").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("resources")[0].GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("resources")[0].GetProperty("url").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("contacts").GetProperty("")[0].GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("contacts").GetProperty("")[0].GetProperty("info").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("attributes").GetProperty("").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("assignedEntities")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("assignedEntities")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("assignedEntities")[0].GetProperty("uniqueAttributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("assignedEntities")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("assignedEntities")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("assignedEntities")[0].GetProperty("relationshipType").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("assignedEntities")[0].GetProperty("relationshipGuid").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("assignedEntities")[0].GetProperty("relationshipStatus").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("categories")[0].GetProperty("categoryGuid").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("categories")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("categories")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("categories")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("categories")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("classifies")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("classifies")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("classifies")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("classifies")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("classifies")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("classifies")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("classifies")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("examples")[0].ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("isA")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("isA")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("isA")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("isA")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("isA")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("isA")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("isA")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("preferredTerms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("preferredTerms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("preferredTerms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("preferredTerms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("preferredTerms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("preferredTerms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("preferredTerms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("preferredToTerms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("preferredToTerms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("preferredToTerms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("preferredToTerms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("preferredToTerms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("preferredToTerms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("preferredToTerms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("replacedBy")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("replacedBy")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("replacedBy")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("replacedBy")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("replacedBy")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("replacedBy")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("replacedBy")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("replacementTerms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("replacementTerms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("replacementTerms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("replacementTerms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("replacementTerms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("replacementTerms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("replacementTerms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("seeAlso")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("seeAlso")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("seeAlso")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("seeAlso")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("seeAlso")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("seeAlso")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("seeAlso")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("synonyms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("synonyms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("synonyms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("synonyms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("synonyms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("synonyms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("synonyms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("translatedTerms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("translatedTerms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("translatedTerms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("translatedTerms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("translatedTerms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("translatedTerms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("translatedTerms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("translationTerms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("translationTerms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("translationTerms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("translationTerms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("translationTerms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("translationTerms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("translationTerms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("usage").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("validValues")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("validValues")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("validValues")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("validValues")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("validValues")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("validValues")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("validValues")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("validValuesFor")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("validValuesFor")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("validValuesFor")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("validValuesFor")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("validValuesFor")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("validValuesFor")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("validValuesFor")[0].GetProperty("termGuid").ToString()); +]]> + + + +This sample shows how to call GetDetailed and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = client.GetDetailed("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call GetDetailed with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = client.GetDetailed("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("longDescription").ToString()); +Console.WriteLine(result.GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("qualifiedName").ToString()); +Console.WriteLine(result.GetProperty("shortDescription").ToString()); +Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("categoryGuid").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("parentCategoryGuid").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("language").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("usage").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("longDescription").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("qualifiedName").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("shortDescription").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("anchor").GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("anchor").GetProperty("glossaryGuid").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("anchor").GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("childrenCategories")[0].GetProperty("categoryGuid").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("childrenCategories")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("childrenCategories")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("childrenCategories")[0].GetProperty("parentCategoryGuid").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("childrenCategories")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("parentCategory").GetProperty("categoryGuid").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("parentCategory").GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("parentCategory").GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("parentCategory").GetProperty("parentCategoryGuid").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("parentCategory").GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("terms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("terms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("terms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("terms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("terms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("terms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("terms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("longDescription").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("qualifiedName").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("shortDescription").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("abbreviation").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("templateName")[0].ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("anchor").GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("anchor").GetProperty("glossaryGuid").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("anchor").GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("antonyms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("antonyms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("antonyms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("antonyms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("antonyms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("antonyms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("antonyms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("nickName").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("hierarchyInfo")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("hierarchyInfo")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("hierarchyInfo")[0].GetProperty("uniqueAttributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("hierarchyInfo")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("hierarchyInfo")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("hierarchyInfo")[0].GetProperty("itemPath").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("hierarchyInfo")[0].GetProperty("resourceId").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("hierarchyInfo")[0].GetProperty("properties").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("resources")[0].GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("resources")[0].GetProperty("url").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("contacts").GetProperty("")[0].GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("contacts").GetProperty("")[0].GetProperty("info").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("attributes").GetProperty("").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("assignedEntities")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("assignedEntities")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("assignedEntities")[0].GetProperty("uniqueAttributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("assignedEntities")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("assignedEntities")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("assignedEntities")[0].GetProperty("relationshipType").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("assignedEntities")[0].GetProperty("relationshipGuid").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("assignedEntities")[0].GetProperty("relationshipStatus").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("categories")[0].GetProperty("categoryGuid").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("categories")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("categories")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("categories")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("categories")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("classifies")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("classifies")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("classifies")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("classifies")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("classifies")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("classifies")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("classifies")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("examples")[0].ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("isA")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("isA")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("isA")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("isA")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("isA")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("isA")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("isA")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("preferredTerms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("preferredTerms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("preferredTerms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("preferredTerms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("preferredTerms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("preferredTerms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("preferredTerms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("preferredToTerms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("preferredToTerms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("preferredToTerms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("preferredToTerms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("preferredToTerms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("preferredToTerms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("preferredToTerms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("replacedBy")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("replacedBy")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("replacedBy")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("replacedBy")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("replacedBy")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("replacedBy")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("replacedBy")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("replacementTerms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("replacementTerms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("replacementTerms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("replacementTerms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("replacementTerms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("replacementTerms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("replacementTerms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("seeAlso")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("seeAlso")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("seeAlso")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("seeAlso")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("seeAlso")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("seeAlso")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("seeAlso")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("synonyms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("synonyms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("synonyms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("synonyms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("synonyms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("synonyms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("synonyms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("translatedTerms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("translatedTerms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("translatedTerms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("translatedTerms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("translatedTerms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("translatedTerms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("translatedTerms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("translationTerms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("translationTerms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("translationTerms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("translationTerms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("translationTerms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("translationTerms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("translationTerms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("usage").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("validValues")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("validValues")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("validValues")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("validValues")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("validValues")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("validValues")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("validValues")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("validValuesFor")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("validValuesFor")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("validValuesFor")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("validValuesFor")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("validValuesFor")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("validValuesFor")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("validValuesFor")[0].GetProperty("termGuid").ToString()); +]]> + + + +This sample shows how to call PartialUpdateAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = await client.PartialUpdateAsync("", BinaryData.FromObjectAsJson(new object())); +]]> +This sample shows how to call PartialUpdateAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = await client.PartialUpdateAsync("", BinaryData.FromObjectAsJson(new object()), ignoreTermsAndCategories: true); +]]> + + + +This sample shows how to call PartialUpdate. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = client.PartialUpdate("", BinaryData.FromObjectAsJson(new object())); +]]> +This sample shows how to call PartialUpdate with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = client.PartialUpdate("", BinaryData.FromObjectAsJson(new object()), ignoreTermsAndCategories: true); +]]> + + + +This sample shows how to call PartialUpdateAsync and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object()); +Response response = await client.PartialUpdateAsync("", content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call PartialUpdateAsync with all parameters and request content and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object()); +Response response = await client.PartialUpdateAsync("", content, ignoreTermsAndCategories: true); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("longDescription").ToString()); +Console.WriteLine(result.GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("qualifiedName").ToString()); +Console.WriteLine(result.GetProperty("shortDescription").ToString()); +Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("categoryGuid").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("parentCategoryGuid").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("language").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("usage").ToString()); +]]> + + + +This sample shows how to call PartialUpdate and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object()); +Response response = client.PartialUpdate("", content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call PartialUpdate with all parameters and request content and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object()); +Response response = client.PartialUpdate("", content, ignoreTermsAndCategories: true); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("longDescription").ToString()); +Console.WriteLine(result.GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("qualifiedName").ToString()); +Console.WriteLine(result.GetProperty("shortDescription").ToString()); +Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("categoryGuid").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("parentCategoryGuid").ToString()); +Console.WriteLine(result.GetProperty("categories")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("language").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("terms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("usage").ToString()); +]]> + + + +This sample shows how to call GetTermsAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response> response = await client.GetTermsAsync(""); +]]> +This sample shows how to call GetTermsAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response> response = await client.GetTermsAsync("", limit: 1234, offset: 1234, sort: ""); +]]> + + + +This sample shows how to call GetTerms. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response> response = client.GetTerms(""); +]]> +This sample shows how to call GetTerms with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response> response = client.GetTerms("", limit: 1234, offset: 1234, sort: ""); +]]> + + + +This sample shows how to call GetTermsAsync and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = await client.GetTermsAsync("", null, null, null, null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result[0].ToString()); +]]> +This sample shows how to call GetTermsAsync with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = await client.GetTermsAsync("", 1234, 1234, "", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result[0].GetProperty("guid").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result[0].GetProperty("longDescription").ToString()); +Console.WriteLine(result[0].GetProperty("name").ToString()); +Console.WriteLine(result[0].GetProperty("qualifiedName").ToString()); +Console.WriteLine(result[0].GetProperty("shortDescription").ToString()); +Console.WriteLine(result[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result[0].GetProperty("createTime").ToString()); +Console.WriteLine(result[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result[0].GetProperty("updateTime").ToString()); +Console.WriteLine(result[0].GetProperty("updatedBy").ToString()); +Console.WriteLine(result[0].GetProperty("abbreviation").ToString()); +Console.WriteLine(result[0].GetProperty("templateName")[0].ToString()); +Console.WriteLine(result[0].GetProperty("anchor").GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("anchor").GetProperty("glossaryGuid").ToString()); +Console.WriteLine(result[0].GetProperty("anchor").GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("antonyms")[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("antonyms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("antonyms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result[0].GetProperty("antonyms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("antonyms")[0].GetProperty("status").ToString()); +Console.WriteLine(result[0].GetProperty("antonyms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result[0].GetProperty("antonyms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result[0].GetProperty("status").ToString()); +Console.WriteLine(result[0].GetProperty("nickName").ToString()); +Console.WriteLine(result[0].GetProperty("hierarchyInfo")[0].GetProperty("guid").ToString()); +Console.WriteLine(result[0].GetProperty("hierarchyInfo")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result[0].GetProperty("hierarchyInfo")[0].GetProperty("uniqueAttributes").GetProperty("").ToString()); +Console.WriteLine(result[0].GetProperty("hierarchyInfo")[0].GetProperty("name").ToString()); +Console.WriteLine(result[0].GetProperty("hierarchyInfo")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("hierarchyInfo")[0].GetProperty("itemPath").ToString()); +Console.WriteLine(result[0].GetProperty("hierarchyInfo")[0].GetProperty("resourceId").ToString()); +Console.WriteLine(result[0].GetProperty("hierarchyInfo")[0].GetProperty("properties").GetProperty("").ToString()); +Console.WriteLine(result[0].GetProperty("resources")[0].GetProperty("displayName").ToString()); +Console.WriteLine(result[0].GetProperty("resources")[0].GetProperty("url").ToString()); +Console.WriteLine(result[0].GetProperty("contacts").GetProperty("")[0].GetProperty("id").ToString()); +Console.WriteLine(result[0].GetProperty("contacts").GetProperty("")[0].GetProperty("info").ToString()); +Console.WriteLine(result[0].GetProperty("attributes").GetProperty("").GetProperty("").ToString()); +Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("guid").ToString()); +Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("uniqueAttributes").GetProperty("").ToString()); +Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("relationshipType").ToString()); +Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("typeName").ToString()); +Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("relationshipGuid").ToString()); +Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("relationshipStatus").ToString()); +Console.WriteLine(result[0].GetProperty("categories")[0].GetProperty("categoryGuid").ToString()); +Console.WriteLine(result[0].GetProperty("categories")[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("categories")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("categories")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("categories")[0].GetProperty("status").ToString()); +Console.WriteLine(result[0].GetProperty("classifies")[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("classifies")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("classifies")[0].GetProperty("expression").ToString()); +Console.WriteLine(result[0].GetProperty("classifies")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("classifies")[0].GetProperty("status").ToString()); +Console.WriteLine(result[0].GetProperty("classifies")[0].GetProperty("steward").ToString()); +Console.WriteLine(result[0].GetProperty("classifies")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result[0].GetProperty("examples")[0].ToString()); +Console.WriteLine(result[0].GetProperty("isA")[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("isA")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("isA")[0].GetProperty("expression").ToString()); +Console.WriteLine(result[0].GetProperty("isA")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("isA")[0].GetProperty("status").ToString()); +Console.WriteLine(result[0].GetProperty("isA")[0].GetProperty("steward").ToString()); +Console.WriteLine(result[0].GetProperty("isA")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result[0].GetProperty("preferredTerms")[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("preferredTerms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("preferredTerms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result[0].GetProperty("preferredTerms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("preferredTerms")[0].GetProperty("status").ToString()); +Console.WriteLine(result[0].GetProperty("preferredTerms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result[0].GetProperty("preferredTerms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result[0].GetProperty("preferredToTerms")[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("preferredToTerms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("preferredToTerms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result[0].GetProperty("preferredToTerms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("preferredToTerms")[0].GetProperty("status").ToString()); +Console.WriteLine(result[0].GetProperty("preferredToTerms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result[0].GetProperty("preferredToTerms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result[0].GetProperty("replacedBy")[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("replacedBy")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("replacedBy")[0].GetProperty("expression").ToString()); +Console.WriteLine(result[0].GetProperty("replacedBy")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("replacedBy")[0].GetProperty("status").ToString()); +Console.WriteLine(result[0].GetProperty("replacedBy")[0].GetProperty("steward").ToString()); +Console.WriteLine(result[0].GetProperty("replacedBy")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result[0].GetProperty("replacementTerms")[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("replacementTerms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("replacementTerms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result[0].GetProperty("replacementTerms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("replacementTerms")[0].GetProperty("status").ToString()); +Console.WriteLine(result[0].GetProperty("replacementTerms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result[0].GetProperty("replacementTerms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result[0].GetProperty("seeAlso")[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("seeAlso")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("seeAlso")[0].GetProperty("expression").ToString()); +Console.WriteLine(result[0].GetProperty("seeAlso")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("seeAlso")[0].GetProperty("status").ToString()); +Console.WriteLine(result[0].GetProperty("seeAlso")[0].GetProperty("steward").ToString()); +Console.WriteLine(result[0].GetProperty("seeAlso")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result[0].GetProperty("synonyms")[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("synonyms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("synonyms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result[0].GetProperty("synonyms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("synonyms")[0].GetProperty("status").ToString()); +Console.WriteLine(result[0].GetProperty("synonyms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result[0].GetProperty("synonyms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result[0].GetProperty("translatedTerms")[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("translatedTerms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("translatedTerms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result[0].GetProperty("translatedTerms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("translatedTerms")[0].GetProperty("status").ToString()); +Console.WriteLine(result[0].GetProperty("translatedTerms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result[0].GetProperty("translatedTerms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result[0].GetProperty("translationTerms")[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("translationTerms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("translationTerms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result[0].GetProperty("translationTerms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("translationTerms")[0].GetProperty("status").ToString()); +Console.WriteLine(result[0].GetProperty("translationTerms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result[0].GetProperty("translationTerms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result[0].GetProperty("usage").ToString()); +Console.WriteLine(result[0].GetProperty("validValues")[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("validValues")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("validValues")[0].GetProperty("expression").ToString()); +Console.WriteLine(result[0].GetProperty("validValues")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("validValues")[0].GetProperty("status").ToString()); +Console.WriteLine(result[0].GetProperty("validValues")[0].GetProperty("steward").ToString()); +Console.WriteLine(result[0].GetProperty("validValues")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result[0].GetProperty("validValuesFor")[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("validValuesFor")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("validValuesFor")[0].GetProperty("expression").ToString()); +Console.WriteLine(result[0].GetProperty("validValuesFor")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("validValuesFor")[0].GetProperty("status").ToString()); +Console.WriteLine(result[0].GetProperty("validValuesFor")[0].GetProperty("steward").ToString()); +Console.WriteLine(result[0].GetProperty("validValuesFor")[0].GetProperty("termGuid").ToString()); +]]> + + + +This sample shows how to call GetTerms and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = client.GetTerms("", null, null, null, null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result[0].ToString()); +]]> +This sample shows how to call GetTerms with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = client.GetTerms("", 1234, 1234, "", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result[0].GetProperty("guid").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result[0].GetProperty("longDescription").ToString()); +Console.WriteLine(result[0].GetProperty("name").ToString()); +Console.WriteLine(result[0].GetProperty("qualifiedName").ToString()); +Console.WriteLine(result[0].GetProperty("shortDescription").ToString()); +Console.WriteLine(result[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result[0].GetProperty("createTime").ToString()); +Console.WriteLine(result[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result[0].GetProperty("updateTime").ToString()); +Console.WriteLine(result[0].GetProperty("updatedBy").ToString()); +Console.WriteLine(result[0].GetProperty("abbreviation").ToString()); +Console.WriteLine(result[0].GetProperty("templateName")[0].ToString()); +Console.WriteLine(result[0].GetProperty("anchor").GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("anchor").GetProperty("glossaryGuid").ToString()); +Console.WriteLine(result[0].GetProperty("anchor").GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("antonyms")[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("antonyms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("antonyms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result[0].GetProperty("antonyms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("antonyms")[0].GetProperty("status").ToString()); +Console.WriteLine(result[0].GetProperty("antonyms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result[0].GetProperty("antonyms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result[0].GetProperty("status").ToString()); +Console.WriteLine(result[0].GetProperty("nickName").ToString()); +Console.WriteLine(result[0].GetProperty("hierarchyInfo")[0].GetProperty("guid").ToString()); +Console.WriteLine(result[0].GetProperty("hierarchyInfo")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result[0].GetProperty("hierarchyInfo")[0].GetProperty("uniqueAttributes").GetProperty("").ToString()); +Console.WriteLine(result[0].GetProperty("hierarchyInfo")[0].GetProperty("name").ToString()); +Console.WriteLine(result[0].GetProperty("hierarchyInfo")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("hierarchyInfo")[0].GetProperty("itemPath").ToString()); +Console.WriteLine(result[0].GetProperty("hierarchyInfo")[0].GetProperty("resourceId").ToString()); +Console.WriteLine(result[0].GetProperty("hierarchyInfo")[0].GetProperty("properties").GetProperty("").ToString()); +Console.WriteLine(result[0].GetProperty("resources")[0].GetProperty("displayName").ToString()); +Console.WriteLine(result[0].GetProperty("resources")[0].GetProperty("url").ToString()); +Console.WriteLine(result[0].GetProperty("contacts").GetProperty("")[0].GetProperty("id").ToString()); +Console.WriteLine(result[0].GetProperty("contacts").GetProperty("")[0].GetProperty("info").ToString()); +Console.WriteLine(result[0].GetProperty("attributes").GetProperty("").GetProperty("").ToString()); +Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("guid").ToString()); +Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("uniqueAttributes").GetProperty("").ToString()); +Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("relationshipType").ToString()); +Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("typeName").ToString()); +Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("relationshipGuid").ToString()); +Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("relationshipStatus").ToString()); +Console.WriteLine(result[0].GetProperty("categories")[0].GetProperty("categoryGuid").ToString()); +Console.WriteLine(result[0].GetProperty("categories")[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("categories")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("categories")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("categories")[0].GetProperty("status").ToString()); +Console.WriteLine(result[0].GetProperty("classifies")[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("classifies")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("classifies")[0].GetProperty("expression").ToString()); +Console.WriteLine(result[0].GetProperty("classifies")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("classifies")[0].GetProperty("status").ToString()); +Console.WriteLine(result[0].GetProperty("classifies")[0].GetProperty("steward").ToString()); +Console.WriteLine(result[0].GetProperty("classifies")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result[0].GetProperty("examples")[0].ToString()); +Console.WriteLine(result[0].GetProperty("isA")[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("isA")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("isA")[0].GetProperty("expression").ToString()); +Console.WriteLine(result[0].GetProperty("isA")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("isA")[0].GetProperty("status").ToString()); +Console.WriteLine(result[0].GetProperty("isA")[0].GetProperty("steward").ToString()); +Console.WriteLine(result[0].GetProperty("isA")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result[0].GetProperty("preferredTerms")[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("preferredTerms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("preferredTerms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result[0].GetProperty("preferredTerms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("preferredTerms")[0].GetProperty("status").ToString()); +Console.WriteLine(result[0].GetProperty("preferredTerms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result[0].GetProperty("preferredTerms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result[0].GetProperty("preferredToTerms")[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("preferredToTerms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("preferredToTerms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result[0].GetProperty("preferredToTerms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("preferredToTerms")[0].GetProperty("status").ToString()); +Console.WriteLine(result[0].GetProperty("preferredToTerms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result[0].GetProperty("preferredToTerms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result[0].GetProperty("replacedBy")[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("replacedBy")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("replacedBy")[0].GetProperty("expression").ToString()); +Console.WriteLine(result[0].GetProperty("replacedBy")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("replacedBy")[0].GetProperty("status").ToString()); +Console.WriteLine(result[0].GetProperty("replacedBy")[0].GetProperty("steward").ToString()); +Console.WriteLine(result[0].GetProperty("replacedBy")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result[0].GetProperty("replacementTerms")[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("replacementTerms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("replacementTerms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result[0].GetProperty("replacementTerms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("replacementTerms")[0].GetProperty("status").ToString()); +Console.WriteLine(result[0].GetProperty("replacementTerms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result[0].GetProperty("replacementTerms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result[0].GetProperty("seeAlso")[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("seeAlso")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("seeAlso")[0].GetProperty("expression").ToString()); +Console.WriteLine(result[0].GetProperty("seeAlso")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("seeAlso")[0].GetProperty("status").ToString()); +Console.WriteLine(result[0].GetProperty("seeAlso")[0].GetProperty("steward").ToString()); +Console.WriteLine(result[0].GetProperty("seeAlso")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result[0].GetProperty("synonyms")[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("synonyms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("synonyms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result[0].GetProperty("synonyms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("synonyms")[0].GetProperty("status").ToString()); +Console.WriteLine(result[0].GetProperty("synonyms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result[0].GetProperty("synonyms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result[0].GetProperty("translatedTerms")[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("translatedTerms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("translatedTerms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result[0].GetProperty("translatedTerms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("translatedTerms")[0].GetProperty("status").ToString()); +Console.WriteLine(result[0].GetProperty("translatedTerms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result[0].GetProperty("translatedTerms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result[0].GetProperty("translationTerms")[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("translationTerms")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("translationTerms")[0].GetProperty("expression").ToString()); +Console.WriteLine(result[0].GetProperty("translationTerms")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("translationTerms")[0].GetProperty("status").ToString()); +Console.WriteLine(result[0].GetProperty("translationTerms")[0].GetProperty("steward").ToString()); +Console.WriteLine(result[0].GetProperty("translationTerms")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result[0].GetProperty("usage").ToString()); +Console.WriteLine(result[0].GetProperty("validValues")[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("validValues")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("validValues")[0].GetProperty("expression").ToString()); +Console.WriteLine(result[0].GetProperty("validValues")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("validValues")[0].GetProperty("status").ToString()); +Console.WriteLine(result[0].GetProperty("validValues")[0].GetProperty("steward").ToString()); +Console.WriteLine(result[0].GetProperty("validValues")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result[0].GetProperty("validValuesFor")[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("validValuesFor")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("validValuesFor")[0].GetProperty("expression").ToString()); +Console.WriteLine(result[0].GetProperty("validValuesFor")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("validValuesFor")[0].GetProperty("status").ToString()); +Console.WriteLine(result[0].GetProperty("validValuesFor")[0].GetProperty("steward").ToString()); +Console.WriteLine(result[0].GetProperty("validValuesFor")[0].GetProperty("termGuid").ToString()); +]]> + + + +This sample shows how to call GetTermHeadersAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response> response = await client.GetTermHeadersAsync(""); +]]> +This sample shows how to call GetTermHeadersAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response> response = await client.GetTermHeadersAsync("", limit: 1234, offset: 1234, sort: ""); +]]> + + + +This sample shows how to call GetTermHeaders. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response> response = client.GetTermHeaders(""); +]]> +This sample shows how to call GetTermHeaders with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response> response = client.GetTermHeaders("", limit: 1234, offset: 1234, sort: ""); +]]> + + + +This sample shows how to call GetTermHeadersAsync and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = await client.GetTermHeadersAsync("", null, null, null, null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result[0].ToString()); +]]> +This sample shows how to call GetTermHeadersAsync with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = await client.GetTermHeadersAsync("", 1234, 1234, "", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("expression").ToString()); +Console.WriteLine(result[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("status").ToString()); +Console.WriteLine(result[0].GetProperty("steward").ToString()); +Console.WriteLine(result[0].GetProperty("termGuid").ToString()); +]]> + + + +This sample shows how to call GetTermHeaders and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = client.GetTermHeaders("", null, null, null, null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result[0].ToString()); +]]> +This sample shows how to call GetTermHeaders with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + +Response response = client.GetTermHeaders("", 1234, 1234, "", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result[0].GetProperty("description").ToString()); +Console.WriteLine(result[0].GetProperty("displayText").ToString()); +Console.WriteLine(result[0].GetProperty("expression").ToString()); +Console.WriteLine(result[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result[0].GetProperty("status").ToString()); +Console.WriteLine(result[0].GetProperty("steward").ToString()); +Console.WriteLine(result[0].GetProperty("termGuid").ToString()); +]]> + + + \ No newline at end of file diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/Docs/Lineage.xml b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/Docs/Lineage.xml new file mode 100644 index 0000000000000..f1c181a3f9b8d --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/Docs/Lineage.xml @@ -0,0 +1,503 @@ + + + + + +This sample shows how to call GetLineageAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Lineage client = new DataMapClient(endpoint, credential).GetLineageClient(apiVersion: "2023-09-01"); + +Response response = await client.GetLineageAsync("", LineageDirection.Input); +]]> +This sample shows how to call GetLineageAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Lineage client = new DataMapClient(endpoint, credential).GetLineageClient(apiVersion: "2023-09-01"); + +Response response = await client.GetLineageAsync("", LineageDirection.Input, depth: 1234); +]]> + + + +This sample shows how to call GetLineage. +"); +TokenCredential credential = new DefaultAzureCredential(); +Lineage client = new DataMapClient(endpoint, credential).GetLineageClient(apiVersion: "2023-09-01"); + +Response response = client.GetLineage("", LineageDirection.Input); +]]> +This sample shows how to call GetLineage with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Lineage client = new DataMapClient(endpoint, credential).GetLineageClient(apiVersion: "2023-09-01"); + +Response response = client.GetLineage("", LineageDirection.Input, depth: 1234); +]]> + + + +This sample shows how to call GetLineageAsync and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Lineage client = new DataMapClient(endpoint, credential).GetLineageClient(apiVersion: "2023-09-01"); + +Response response = await client.GetLineageAsync("", "INPUT"); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call GetLineageAsync with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Lineage client = new DataMapClient(endpoint, credential).GetLineageClient(apiVersion: "2023-09-01"); + +Response response = await client.GetLineageAsync("", "INPUT", depth: 1234); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("baseEntityGuid").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classificationNames")[0].ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("isIncomplete").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("labels")[0].ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meaningNames")[0].ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("confidence").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("widthCounts").GetProperty("").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("lineageDepth").ToString()); +Console.WriteLine(result.GetProperty("lineageWidth").ToString()); +Console.WriteLine(result.GetProperty("childrenCount").ToString()); +Console.WriteLine(result.GetProperty("lineageDirection").ToString()); +Console.WriteLine(result.GetProperty("parentRelations")[0].GetProperty("childEntityId").ToString()); +Console.WriteLine(result.GetProperty("parentRelations")[0].GetProperty("relationshipId").ToString()); +Console.WriteLine(result.GetProperty("parentRelations")[0].GetProperty("parentEntityId").ToString()); +Console.WriteLine(result.GetProperty("relations")[0].GetProperty("fromEntityId").ToString()); +Console.WriteLine(result.GetProperty("relations")[0].GetProperty("relationshipId").ToString()); +Console.WriteLine(result.GetProperty("relations")[0].GetProperty("toEntityId").ToString()); +]]> + + + +This sample shows how to call GetLineage and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Lineage client = new DataMapClient(endpoint, credential).GetLineageClient(apiVersion: "2023-09-01"); + +Response response = client.GetLineage("", "INPUT"); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call GetLineage with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Lineage client = new DataMapClient(endpoint, credential).GetLineageClient(apiVersion: "2023-09-01"); + +Response response = client.GetLineage("", "INPUT", depth: 1234); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("baseEntityGuid").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classificationNames")[0].ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("isIncomplete").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("labels")[0].ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meaningNames")[0].ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("confidence").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("widthCounts").GetProperty("").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("lineageDepth").ToString()); +Console.WriteLine(result.GetProperty("lineageWidth").ToString()); +Console.WriteLine(result.GetProperty("childrenCount").ToString()); +Console.WriteLine(result.GetProperty("lineageDirection").ToString()); +Console.WriteLine(result.GetProperty("parentRelations")[0].GetProperty("childEntityId").ToString()); +Console.WriteLine(result.GetProperty("parentRelations")[0].GetProperty("relationshipId").ToString()); +Console.WriteLine(result.GetProperty("parentRelations")[0].GetProperty("parentEntityId").ToString()); +Console.WriteLine(result.GetProperty("relations")[0].GetProperty("fromEntityId").ToString()); +Console.WriteLine(result.GetProperty("relations")[0].GetProperty("relationshipId").ToString()); +Console.WriteLine(result.GetProperty("relations")[0].GetProperty("toEntityId").ToString()); +]]> + + + +This sample shows how to call GetNextPageAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Lineage client = new DataMapClient(endpoint, credential).GetLineageClient(apiVersion: "2023-09-01"); + +Response response = await client.GetNextPageAsync("", LineageDirection.Input); +]]> +This sample shows how to call GetNextPageAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Lineage client = new DataMapClient(endpoint, credential).GetLineageClient(apiVersion: "2023-09-01"); + +Response response = await client.GetNextPageAsync("", LineageDirection.Input, offset: 1234, limit: 1234); +]]> + + + +This sample shows how to call GetNextPage. +"); +TokenCredential credential = new DefaultAzureCredential(); +Lineage client = new DataMapClient(endpoint, credential).GetLineageClient(apiVersion: "2023-09-01"); + +Response response = client.GetNextPage("", LineageDirection.Input); +]]> +This sample shows how to call GetNextPage with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Lineage client = new DataMapClient(endpoint, credential).GetLineageClient(apiVersion: "2023-09-01"); + +Response response = client.GetNextPage("", LineageDirection.Input, offset: 1234, limit: 1234); +]]> + + + +This sample shows how to call GetNextPageAsync and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Lineage client = new DataMapClient(endpoint, credential).GetLineageClient(apiVersion: "2023-09-01"); + +Response response = await client.GetNextPageAsync("", "INPUT"); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call GetNextPageAsync with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Lineage client = new DataMapClient(endpoint, credential).GetLineageClient(apiVersion: "2023-09-01"); + +Response response = await client.GetNextPageAsync("", "INPUT", offset: 1234, limit: 1234); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("baseEntityGuid").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classificationNames")[0].ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("isIncomplete").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("labels")[0].ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meaningNames")[0].ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("confidence").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("widthCounts").GetProperty("").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("lineageDepth").ToString()); +Console.WriteLine(result.GetProperty("lineageWidth").ToString()); +Console.WriteLine(result.GetProperty("childrenCount").ToString()); +Console.WriteLine(result.GetProperty("lineageDirection").ToString()); +Console.WriteLine(result.GetProperty("parentRelations")[0].GetProperty("childEntityId").ToString()); +Console.WriteLine(result.GetProperty("parentRelations")[0].GetProperty("relationshipId").ToString()); +Console.WriteLine(result.GetProperty("parentRelations")[0].GetProperty("parentEntityId").ToString()); +Console.WriteLine(result.GetProperty("relations")[0].GetProperty("fromEntityId").ToString()); +Console.WriteLine(result.GetProperty("relations")[0].GetProperty("relationshipId").ToString()); +Console.WriteLine(result.GetProperty("relations")[0].GetProperty("toEntityId").ToString()); +]]> + + + +This sample shows how to call GetNextPage and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Lineage client = new DataMapClient(endpoint, credential).GetLineageClient(apiVersion: "2023-09-01"); + +Response response = client.GetNextPage("", "INPUT"); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call GetNextPage with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Lineage client = new DataMapClient(endpoint, credential).GetLineageClient(apiVersion: "2023-09-01"); + +Response response = client.GetNextPage("", "INPUT", offset: 1234, limit: 1234); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("baseEntityGuid").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classificationNames")[0].ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("isIncomplete").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("labels")[0].ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meaningNames")[0].ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("confidence").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("widthCounts").GetProperty("").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("lineageDepth").ToString()); +Console.WriteLine(result.GetProperty("lineageWidth").ToString()); +Console.WriteLine(result.GetProperty("childrenCount").ToString()); +Console.WriteLine(result.GetProperty("lineageDirection").ToString()); +Console.WriteLine(result.GetProperty("parentRelations")[0].GetProperty("childEntityId").ToString()); +Console.WriteLine(result.GetProperty("parentRelations")[0].GetProperty("relationshipId").ToString()); +Console.WriteLine(result.GetProperty("parentRelations")[0].GetProperty("parentEntityId").ToString()); +Console.WriteLine(result.GetProperty("relations")[0].GetProperty("fromEntityId").ToString()); +Console.WriteLine(result.GetProperty("relations")[0].GetProperty("relationshipId").ToString()); +Console.WriteLine(result.GetProperty("relations")[0].GetProperty("toEntityId").ToString()); +]]> + + + +This sample shows how to call GetByUniqueAttributeAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Lineage client = new DataMapClient(endpoint, credential).GetLineageClient(apiVersion: "2023-09-01"); + +Response response = await client.GetByUniqueAttributeAsync("", LineageDirection.Input); +]]> +This sample shows how to call GetByUniqueAttributeAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Lineage client = new DataMapClient(endpoint, credential).GetLineageClient(apiVersion: "2023-09-01"); + +Response response = await client.GetByUniqueAttributeAsync("", LineageDirection.Input, depth: 1234, attr: ""); +]]> + + + +This sample shows how to call GetByUniqueAttribute. +"); +TokenCredential credential = new DefaultAzureCredential(); +Lineage client = new DataMapClient(endpoint, credential).GetLineageClient(apiVersion: "2023-09-01"); + +Response response = client.GetByUniqueAttribute("", LineageDirection.Input); +]]> +This sample shows how to call GetByUniqueAttribute with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Lineage client = new DataMapClient(endpoint, credential).GetLineageClient(apiVersion: "2023-09-01"); + +Response response = client.GetByUniqueAttribute("", LineageDirection.Input, depth: 1234, attr: ""); +]]> + + + +This sample shows how to call GetByUniqueAttributeAsync and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Lineage client = new DataMapClient(endpoint, credential).GetLineageClient(apiVersion: "2023-09-01"); + +Response response = await client.GetByUniqueAttributeAsync("", "INPUT"); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call GetByUniqueAttributeAsync with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Lineage client = new DataMapClient(endpoint, credential).GetLineageClient(apiVersion: "2023-09-01"); + +Response response = await client.GetByUniqueAttributeAsync("", "INPUT", depth: 1234, attr: ""); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("baseEntityGuid").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classificationNames")[0].ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("isIncomplete").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("labels")[0].ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meaningNames")[0].ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("confidence").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("widthCounts").GetProperty("").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("lineageDepth").ToString()); +Console.WriteLine(result.GetProperty("lineageWidth").ToString()); +Console.WriteLine(result.GetProperty("childrenCount").ToString()); +Console.WriteLine(result.GetProperty("lineageDirection").ToString()); +Console.WriteLine(result.GetProperty("parentRelations")[0].GetProperty("childEntityId").ToString()); +Console.WriteLine(result.GetProperty("parentRelations")[0].GetProperty("relationshipId").ToString()); +Console.WriteLine(result.GetProperty("parentRelations")[0].GetProperty("parentEntityId").ToString()); +Console.WriteLine(result.GetProperty("relations")[0].GetProperty("fromEntityId").ToString()); +Console.WriteLine(result.GetProperty("relations")[0].GetProperty("relationshipId").ToString()); +Console.WriteLine(result.GetProperty("relations")[0].GetProperty("toEntityId").ToString()); +]]> + + + +This sample shows how to call GetByUniqueAttribute and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Lineage client = new DataMapClient(endpoint, credential).GetLineageClient(apiVersion: "2023-09-01"); + +Response response = client.GetByUniqueAttribute("", "INPUT"); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call GetByUniqueAttribute with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Lineage client = new DataMapClient(endpoint, credential).GetLineageClient(apiVersion: "2023-09-01"); + +Response response = client.GetByUniqueAttribute("", "INPUT", depth: 1234, attr: ""); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("baseEntityGuid").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classificationNames")[0].ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("isIncomplete").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("labels")[0].ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meaningNames")[0].ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("confidence").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("widthCounts").GetProperty("").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("lineageDepth").ToString()); +Console.WriteLine(result.GetProperty("lineageWidth").ToString()); +Console.WriteLine(result.GetProperty("childrenCount").ToString()); +Console.WriteLine(result.GetProperty("lineageDirection").ToString()); +Console.WriteLine(result.GetProperty("parentRelations")[0].GetProperty("childEntityId").ToString()); +Console.WriteLine(result.GetProperty("parentRelations")[0].GetProperty("relationshipId").ToString()); +Console.WriteLine(result.GetProperty("parentRelations")[0].GetProperty("parentEntityId").ToString()); +Console.WriteLine(result.GetProperty("relations")[0].GetProperty("fromEntityId").ToString()); +Console.WriteLine(result.GetProperty("relations")[0].GetProperty("relationshipId").ToString()); +Console.WriteLine(result.GetProperty("relations")[0].GetProperty("toEntityId").ToString()); +]]> + + + \ No newline at end of file diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/Docs/Relationship.xml b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/Docs/Relationship.xml new file mode 100644 index 0000000000000..4c0d25d47aa64 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/Docs/Relationship.xml @@ -0,0 +1,715 @@ + + + + + +This sample shows how to call CreateAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Relationship client = new DataMapClient(endpoint, credential).GetRelationshipClient(apiVersion: "2023-09-01"); + +AtlasRelationship relationship = new AtlasRelationship(); +Response response = await client.CreateAsync(relationship); +]]> +This sample shows how to call CreateAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Relationship client = new DataMapClient(endpoint, credential).GetRelationshipClient(apiVersion: "2023-09-01"); + +AtlasRelationship relationship = new AtlasRelationship +{ + Attributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + TypeName = "", + LastModifiedTS = "", + CreateTime = 1234L, + CreatedBy = "", + End1 = new AtlasObjectId + { + Guid = "", + TypeName = "", + UniqueAttributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + }, + End2 = default, + Guid = "", + HomeId = "", + Label = " + + + +This sample shows how to call Create. +"); +TokenCredential credential = new DefaultAzureCredential(); +Relationship client = new DataMapClient(endpoint, credential).GetRelationshipClient(apiVersion: "2023-09-01"); + +AtlasRelationship relationship = new AtlasRelationship(); +Response response = client.Create(relationship); +]]> +This sample shows how to call Create with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Relationship client = new DataMapClient(endpoint, credential).GetRelationshipClient(apiVersion: "2023-09-01"); + +AtlasRelationship relationship = new AtlasRelationship +{ + Attributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + TypeName = "", + LastModifiedTS = "", + CreateTime = 1234L, + CreatedBy = "", + End1 = new AtlasObjectId + { + Guid = "", + TypeName = "", + UniqueAttributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + }, + End2 = default, + Guid = "", + HomeId = "", + Label = " + + + +This sample shows how to call CreateAsync and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Relationship client = new DataMapClient(endpoint, credential).GetRelationshipClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object()); +Response response = await client.CreateAsync(content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call CreateAsync with all request content and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Relationship client = new DataMapClient(endpoint, credential).GetRelationshipClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new +{ + attributes = new + { + key = new object(), + }, + typeName = "", + lastModifiedTS = "", + createTime = 1234L, + createdBy = "", + end1 = new + { + guid = "", + typeName = "", + uniqueAttributes = new + { + key = new object(), + }, + }, + guid = "", + homeId = "", + label = " + + + +This sample shows how to call Create and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Relationship client = new DataMapClient(endpoint, credential).GetRelationshipClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object()); +Response response = client.Create(content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call Create with all request content and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Relationship client = new DataMapClient(endpoint, credential).GetRelationshipClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new +{ + attributes = new + { + key = new object(), + }, + typeName = "", + lastModifiedTS = "", + createTime = 1234L, + createdBy = "", + end1 = new + { + guid = "", + typeName = "", + uniqueAttributes = new + { + key = new object(), + }, + }, + guid = "", + homeId = "", + label = " + + + +This sample shows how to call UpdateAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Relationship client = new DataMapClient(endpoint, credential).GetRelationshipClient(apiVersion: "2023-09-01"); + +AtlasRelationship relationship = new AtlasRelationship(); +Response response = await client.UpdateAsync(relationship); +]]> +This sample shows how to call UpdateAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Relationship client = new DataMapClient(endpoint, credential).GetRelationshipClient(apiVersion: "2023-09-01"); + +AtlasRelationship relationship = new AtlasRelationship +{ + Attributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + TypeName = "", + LastModifiedTS = "", + CreateTime = 1234L, + CreatedBy = "", + End1 = new AtlasObjectId + { + Guid = "", + TypeName = "", + UniqueAttributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + }, + End2 = default, + Guid = "", + HomeId = "", + Label = " + + + +This sample shows how to call Update. +"); +TokenCredential credential = new DefaultAzureCredential(); +Relationship client = new DataMapClient(endpoint, credential).GetRelationshipClient(apiVersion: "2023-09-01"); + +AtlasRelationship relationship = new AtlasRelationship(); +Response response = client.Update(relationship); +]]> +This sample shows how to call Update with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Relationship client = new DataMapClient(endpoint, credential).GetRelationshipClient(apiVersion: "2023-09-01"); + +AtlasRelationship relationship = new AtlasRelationship +{ + Attributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + TypeName = "", + LastModifiedTS = "", + CreateTime = 1234L, + CreatedBy = "", + End1 = new AtlasObjectId + { + Guid = "", + TypeName = "", + UniqueAttributes = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + }, + End2 = default, + Guid = "", + HomeId = "", + Label = " + + + +This sample shows how to call UpdateAsync and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Relationship client = new DataMapClient(endpoint, credential).GetRelationshipClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object()); +Response response = await client.UpdateAsync(content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call UpdateAsync with all request content and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Relationship client = new DataMapClient(endpoint, credential).GetRelationshipClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new +{ + attributes = new + { + key = new object(), + }, + typeName = "", + lastModifiedTS = "", + createTime = 1234L, + createdBy = "", + end1 = new + { + guid = "", + typeName = "", + uniqueAttributes = new + { + key = new object(), + }, + }, + guid = "", + homeId = "", + label = " + + + +This sample shows how to call Update and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Relationship client = new DataMapClient(endpoint, credential).GetRelationshipClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object()); +Response response = client.Update(content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call Update with all request content and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Relationship client = new DataMapClient(endpoint, credential).GetRelationshipClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new +{ + attributes = new + { + key = new object(), + }, + typeName = "", + lastModifiedTS = "", + createTime = 1234L, + createdBy = "", + end1 = new + { + guid = "", + typeName = "", + uniqueAttributes = new + { + key = new object(), + }, + }, + guid = "", + homeId = "", + label = " + + + +This sample shows how to call GetRelationshipAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Relationship client = new DataMapClient(endpoint, credential).GetRelationshipClient(apiVersion: "2023-09-01"); + +Response response = await client.GetRelationshipAsync(""); +]]> +This sample shows how to call GetRelationshipAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Relationship client = new DataMapClient(endpoint, credential).GetRelationshipClient(apiVersion: "2023-09-01"); + +Response response = await client.GetRelationshipAsync("", extendedInfo: true); +]]> + + + +This sample shows how to call GetRelationship. +"); +TokenCredential credential = new DefaultAzureCredential(); +Relationship client = new DataMapClient(endpoint, credential).GetRelationshipClient(apiVersion: "2023-09-01"); + +Response response = client.GetRelationship(""); +]]> +This sample shows how to call GetRelationship with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Relationship client = new DataMapClient(endpoint, credential).GetRelationshipClient(apiVersion: "2023-09-01"); + +Response response = client.GetRelationship("", extendedInfo: true); +]]> + + + +This sample shows how to call GetRelationshipAsync and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Relationship client = new DataMapClient(endpoint, credential).GetRelationshipClient(apiVersion: "2023-09-01"); + +Response response = await client.GetRelationshipAsync("", null, null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call GetRelationshipAsync with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Relationship client = new DataMapClient(endpoint, credential).GetRelationshipClient(apiVersion: "2023-09-01"); + +Response response = await client.GetRelationshipAsync("", true, null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classificationNames")[0].ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("isIncomplete").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("labels")[0].ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meaningNames")[0].ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("confidence").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("relationship").GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("relationship").GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("relationship").GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("relationship").GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("relationship").GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("relationship").GetProperty("end1").GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("relationship").GetProperty("end1").GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("relationship").GetProperty("end1").GetProperty("uniqueAttributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("relationship").GetProperty("end2").GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("relationship").GetProperty("end2").GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("relationship").GetProperty("end2").GetProperty("uniqueAttributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("relationship").GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("relationship").GetProperty("homeId").ToString()); +Console.WriteLine(result.GetProperty("relationship").GetProperty("label").ToString()); +Console.WriteLine(result.GetProperty("relationship").GetProperty("provenanceType").ToString()); +Console.WriteLine(result.GetProperty("relationship").GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("relationship").GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("relationship").GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("relationship").GetProperty("version").ToString()); +]]> + + + +This sample shows how to call GetRelationship and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Relationship client = new DataMapClient(endpoint, credential).GetRelationshipClient(apiVersion: "2023-09-01"); + +Response response = client.GetRelationship("", null, null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call GetRelationship with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +Relationship client = new DataMapClient(endpoint, credential).GetRelationshipClient(apiVersion: "2023-09-01"); + +Response response = client.GetRelationship("", true, null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classificationNames")[0].ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("isIncomplete").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("labels")[0].ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meaningNames")[0].ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("confidence").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("displayText").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("expression").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("steward").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("termGuid").ToString()); +Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("relationship").GetProperty("attributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("relationship").GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("relationship").GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("relationship").GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("relationship").GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("relationship").GetProperty("end1").GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("relationship").GetProperty("end1").GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("relationship").GetProperty("end1").GetProperty("uniqueAttributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("relationship").GetProperty("end2").GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("relationship").GetProperty("end2").GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("relationship").GetProperty("end2").GetProperty("uniqueAttributes").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("relationship").GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("relationship").GetProperty("homeId").ToString()); +Console.WriteLine(result.GetProperty("relationship").GetProperty("label").ToString()); +Console.WriteLine(result.GetProperty("relationship").GetProperty("provenanceType").ToString()); +Console.WriteLine(result.GetProperty("relationship").GetProperty("status").ToString()); +Console.WriteLine(result.GetProperty("relationship").GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("relationship").GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("relationship").GetProperty("version").ToString()); +]]> + + + +This sample shows how to call DeleteAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +Relationship client = new DataMapClient(endpoint, credential).GetRelationshipClient(apiVersion: "2023-09-01"); + +Response response = await client.DeleteAsync(""); + +Console.WriteLine(response.Status); +]]> +This sample shows how to call DeleteAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Relationship client = new DataMapClient(endpoint, credential).GetRelationshipClient(apiVersion: "2023-09-01"); + +Response response = await client.DeleteAsync(""); + +Console.WriteLine(response.Status); +]]> + + + +This sample shows how to call Delete. +"); +TokenCredential credential = new DefaultAzureCredential(); +Relationship client = new DataMapClient(endpoint, credential).GetRelationshipClient(apiVersion: "2023-09-01"); + +Response response = client.Delete(""); + +Console.WriteLine(response.Status); +]]> +This sample shows how to call Delete with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +Relationship client = new DataMapClient(endpoint, credential).GetRelationshipClient(apiVersion: "2023-09-01"); + +Response response = client.Delete(""); + +Console.WriteLine(response.Status); +]]> + + + \ No newline at end of file diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/Docs/TypeDefinition.xml b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/Docs/TypeDefinition.xml new file mode 100644 index 0000000000000..1202ea757e5b5 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/Docs/TypeDefinition.xml @@ -0,0 +1,8929 @@ + + + + + +This sample shows how to call GetBusinessMetadataByIdAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = await client.GetBusinessMetadataByIdAsync(""); +]]> +This sample shows how to call GetBusinessMetadataByIdAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = await client.GetBusinessMetadataByIdAsync(""); +]]> + + + +This sample shows how to call GetBusinessMetadataById. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = client.GetBusinessMetadataById(""); +]]> +This sample shows how to call GetBusinessMetadataById with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = client.GetBusinessMetadataById(""); +]]> + + + +This sample shows how to call GetBusinessMetadataByIdAsync and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = await client.GetBusinessMetadataByIdAsync("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call GetBusinessMetadataByIdAsync with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = await client.GetBusinessMetadataByIdAsync("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("valuesMinCount").ToString()); +]]> + + + +This sample shows how to call GetBusinessMetadataById and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = client.GetBusinessMetadataById("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call GetBusinessMetadataById with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = client.GetBusinessMetadataById("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("valuesMinCount").ToString()); +]]> + + + +This sample shows how to call GetBusinessMetadataByNameAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = await client.GetBusinessMetadataByNameAsync(""); +]]> +This sample shows how to call GetBusinessMetadataByNameAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = await client.GetBusinessMetadataByNameAsync(""); +]]> + + + +This sample shows how to call GetBusinessMetadataByName. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = client.GetBusinessMetadataByName(""); +]]> +This sample shows how to call GetBusinessMetadataByName with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = client.GetBusinessMetadataByName(""); +]]> + + + +This sample shows how to call GetBusinessMetadataByNameAsync and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = await client.GetBusinessMetadataByNameAsync("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call GetBusinessMetadataByNameAsync with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = await client.GetBusinessMetadataByNameAsync("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("valuesMinCount").ToString()); +]]> + + + +This sample shows how to call GetBusinessMetadataByName and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = client.GetBusinessMetadataByName("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call GetBusinessMetadataByName with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = client.GetBusinessMetadataByName("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("valuesMinCount").ToString()); +]]> + + + +This sample shows how to call GetClassificationByIdAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = await client.GetClassificationByIdAsync(""); +]]> +This sample shows how to call GetClassificationByIdAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = await client.GetClassificationByIdAsync(""); +]]> + + + +This sample shows how to call GetClassificationById. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = client.GetClassificationById(""); +]]> +This sample shows how to call GetClassificationById with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = client.GetClassificationById(""); +]]> + + + +This sample shows how to call GetClassificationByIdAsync and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = await client.GetClassificationByIdAsync("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call GetClassificationByIdAsync with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = await client.GetClassificationByIdAsync("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("valuesMinCount").ToString()); +Console.WriteLine(result.GetProperty("entityTypes")[0].ToString()); +Console.WriteLine(result.GetProperty("subTypes")[0].ToString()); +Console.WriteLine(result.GetProperty("superTypes")[0].ToString()); +]]> + + + +This sample shows how to call GetClassificationById and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = client.GetClassificationById("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call GetClassificationById with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = client.GetClassificationById("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("valuesMinCount").ToString()); +Console.WriteLine(result.GetProperty("entityTypes")[0].ToString()); +Console.WriteLine(result.GetProperty("subTypes")[0].ToString()); +Console.WriteLine(result.GetProperty("superTypes")[0].ToString()); +]]> + + + +This sample shows how to call GetClassificationByNameAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = await client.GetClassificationByNameAsync(""); +]]> +This sample shows how to call GetClassificationByNameAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = await client.GetClassificationByNameAsync(""); +]]> + + + +This sample shows how to call GetClassificationByName. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = client.GetClassificationByName(""); +]]> +This sample shows how to call GetClassificationByName with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = client.GetClassificationByName(""); +]]> + + + +This sample shows how to call GetClassificationByNameAsync and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = await client.GetClassificationByNameAsync("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call GetClassificationByNameAsync with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = await client.GetClassificationByNameAsync("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("valuesMinCount").ToString()); +Console.WriteLine(result.GetProperty("entityTypes")[0].ToString()); +Console.WriteLine(result.GetProperty("subTypes")[0].ToString()); +Console.WriteLine(result.GetProperty("superTypes")[0].ToString()); +]]> + + + +This sample shows how to call GetClassificationByName and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = client.GetClassificationByName("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call GetClassificationByName with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = client.GetClassificationByName("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("valuesMinCount").ToString()); +Console.WriteLine(result.GetProperty("entityTypes")[0].ToString()); +Console.WriteLine(result.GetProperty("subTypes")[0].ToString()); +Console.WriteLine(result.GetProperty("superTypes")[0].ToString()); +]]> + + + +This sample shows how to call GetEntityByIdAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = await client.GetEntityByIdAsync(""); +]]> +This sample shows how to call GetEntityByIdAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = await client.GetEntityByIdAsync(""); +]]> + + + +This sample shows how to call GetEntityById. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = client.GetEntityById(""); +]]> +This sample shows how to call GetEntityById with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = client.GetEntityById(""); +]]> + + + +This sample shows how to call GetEntityByIdAsync and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = await client.GetEntityByIdAsync("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call GetEntityByIdAsync with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = await client.GetEntityByIdAsync("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("valuesMinCount").ToString()); +Console.WriteLine(result.GetProperty("subTypes")[0].ToString()); +Console.WriteLine(result.GetProperty("superTypes")[0].ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("valuesMinCount").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("isLegacyAttribute").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("relationshipTypeName").ToString()); +]]> + + + +This sample shows how to call GetEntityById and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = client.GetEntityById("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call GetEntityById with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = client.GetEntityById("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("valuesMinCount").ToString()); +Console.WriteLine(result.GetProperty("subTypes")[0].ToString()); +Console.WriteLine(result.GetProperty("superTypes")[0].ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("valuesMinCount").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("isLegacyAttribute").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("relationshipTypeName").ToString()); +]]> + + + +This sample shows how to call GetEntityByNameAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = await client.GetEntityByNameAsync(""); +]]> +This sample shows how to call GetEntityByNameAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = await client.GetEntityByNameAsync(""); +]]> + + + +This sample shows how to call GetEntityByName. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = client.GetEntityByName(""); +]]> +This sample shows how to call GetEntityByName with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = client.GetEntityByName(""); +]]> + + + +This sample shows how to call GetEntityByNameAsync and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = await client.GetEntityByNameAsync("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call GetEntityByNameAsync with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = await client.GetEntityByNameAsync("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("valuesMinCount").ToString()); +Console.WriteLine(result.GetProperty("subTypes")[0].ToString()); +Console.WriteLine(result.GetProperty("superTypes")[0].ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("valuesMinCount").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("isLegacyAttribute").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("relationshipTypeName").ToString()); +]]> + + + +This sample shows how to call GetEntityByName and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = client.GetEntityByName("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call GetEntityByName with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = client.GetEntityByName("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("valuesMinCount").ToString()); +Console.WriteLine(result.GetProperty("subTypes")[0].ToString()); +Console.WriteLine(result.GetProperty("superTypes")[0].ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("valuesMinCount").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("isLegacyAttribute").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("relationshipTypeName").ToString()); +]]> + + + +This sample shows how to call GetEnumByIdAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = await client.GetEnumByIdAsync(""); +]]> +This sample shows how to call GetEnumByIdAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = await client.GetEnumByIdAsync(""); +]]> + + + +This sample shows how to call GetEnumById. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = client.GetEnumById(""); +]]> +This sample shows how to call GetEnumById with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = client.GetEnumById(""); +]]> + + + +This sample shows how to call GetEnumByIdAsync and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = await client.GetEnumByIdAsync("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call GetEnumByIdAsync with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = await client.GetEnumByIdAsync("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("elementDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("elementDefs")[0].GetProperty("ordinal").ToString()); +Console.WriteLine(result.GetProperty("elementDefs")[0].GetProperty("value").ToString()); +]]> + + + +This sample shows how to call GetEnumById and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = client.GetEnumById("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call GetEnumById with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = client.GetEnumById("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("elementDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("elementDefs")[0].GetProperty("ordinal").ToString()); +Console.WriteLine(result.GetProperty("elementDefs")[0].GetProperty("value").ToString()); +]]> + + + +This sample shows how to call GetEnumByNameAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = await client.GetEnumByNameAsync(""); +]]> +This sample shows how to call GetEnumByNameAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = await client.GetEnumByNameAsync(""); +]]> + + + +This sample shows how to call GetEnumByName. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = client.GetEnumByName(""); +]]> +This sample shows how to call GetEnumByName with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = client.GetEnumByName(""); +]]> + + + +This sample shows how to call GetEnumByNameAsync and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = await client.GetEnumByNameAsync("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call GetEnumByNameAsync with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = await client.GetEnumByNameAsync("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("elementDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("elementDefs")[0].GetProperty("ordinal").ToString()); +Console.WriteLine(result.GetProperty("elementDefs")[0].GetProperty("value").ToString()); +]]> + + + +This sample shows how to call GetEnumByName and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = client.GetEnumByName("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call GetEnumByName with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = client.GetEnumByName("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("elementDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("elementDefs")[0].GetProperty("ordinal").ToString()); +Console.WriteLine(result.GetProperty("elementDefs")[0].GetProperty("value").ToString()); +]]> + + + +This sample shows how to call GetRelationshipByIdAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = await client.GetRelationshipByIdAsync(""); +]]> +This sample shows how to call GetRelationshipByIdAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = await client.GetRelationshipByIdAsync(""); +]]> + + + +This sample shows how to call GetRelationshipById. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = client.GetRelationshipById(""); +]]> +This sample shows how to call GetRelationshipById with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = client.GetRelationshipById(""); +]]> + + + +This sample shows how to call GetRelationshipByIdAsync and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = await client.GetRelationshipByIdAsync("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call GetRelationshipByIdAsync with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = await client.GetRelationshipByIdAsync("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("valuesMinCount").ToString()); +Console.WriteLine(result.GetProperty("endDef1").GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("endDef1").GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("endDef1").GetProperty("isContainer").ToString()); +Console.WriteLine(result.GetProperty("endDef1").GetProperty("isLegacyAttribute").ToString()); +Console.WriteLine(result.GetProperty("endDef1").GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("endDef1").GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("endDef2").GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("endDef2").GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("endDef2").GetProperty("isContainer").ToString()); +Console.WriteLine(result.GetProperty("endDef2").GetProperty("isLegacyAttribute").ToString()); +Console.WriteLine(result.GetProperty("endDef2").GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("endDef2").GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("relationshipCategory").ToString()); +Console.WriteLine(result.GetProperty("relationshipLabel").ToString()); +]]> + + + +This sample shows how to call GetRelationshipById and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = client.GetRelationshipById("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call GetRelationshipById with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = client.GetRelationshipById("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("valuesMinCount").ToString()); +Console.WriteLine(result.GetProperty("endDef1").GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("endDef1").GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("endDef1").GetProperty("isContainer").ToString()); +Console.WriteLine(result.GetProperty("endDef1").GetProperty("isLegacyAttribute").ToString()); +Console.WriteLine(result.GetProperty("endDef1").GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("endDef1").GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("endDef2").GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("endDef2").GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("endDef2").GetProperty("isContainer").ToString()); +Console.WriteLine(result.GetProperty("endDef2").GetProperty("isLegacyAttribute").ToString()); +Console.WriteLine(result.GetProperty("endDef2").GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("endDef2").GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("relationshipCategory").ToString()); +Console.WriteLine(result.GetProperty("relationshipLabel").ToString()); +]]> + + + +This sample shows how to call GetRelationshipByNameAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = await client.GetRelationshipByNameAsync(""); +]]> +This sample shows how to call GetRelationshipByNameAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = await client.GetRelationshipByNameAsync(""); +]]> + + + +This sample shows how to call GetRelationshipByName. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = client.GetRelationshipByName(""); +]]> +This sample shows how to call GetRelationshipByName with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = client.GetRelationshipByName(""); +]]> + + + +This sample shows how to call GetRelationshipByNameAsync and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = await client.GetRelationshipByNameAsync("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call GetRelationshipByNameAsync with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = await client.GetRelationshipByNameAsync("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("valuesMinCount").ToString()); +Console.WriteLine(result.GetProperty("endDef1").GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("endDef1").GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("endDef1").GetProperty("isContainer").ToString()); +Console.WriteLine(result.GetProperty("endDef1").GetProperty("isLegacyAttribute").ToString()); +Console.WriteLine(result.GetProperty("endDef1").GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("endDef1").GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("endDef2").GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("endDef2").GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("endDef2").GetProperty("isContainer").ToString()); +Console.WriteLine(result.GetProperty("endDef2").GetProperty("isLegacyAttribute").ToString()); +Console.WriteLine(result.GetProperty("endDef2").GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("endDef2").GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("relationshipCategory").ToString()); +Console.WriteLine(result.GetProperty("relationshipLabel").ToString()); +]]> + + + +This sample shows how to call GetRelationshipByName and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = client.GetRelationshipByName("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call GetRelationshipByName with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = client.GetRelationshipByName("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("valuesMinCount").ToString()); +Console.WriteLine(result.GetProperty("endDef1").GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("endDef1").GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("endDef1").GetProperty("isContainer").ToString()); +Console.WriteLine(result.GetProperty("endDef1").GetProperty("isLegacyAttribute").ToString()); +Console.WriteLine(result.GetProperty("endDef1").GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("endDef1").GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("endDef2").GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("endDef2").GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("endDef2").GetProperty("isContainer").ToString()); +Console.WriteLine(result.GetProperty("endDef2").GetProperty("isLegacyAttribute").ToString()); +Console.WriteLine(result.GetProperty("endDef2").GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("endDef2").GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("relationshipCategory").ToString()); +Console.WriteLine(result.GetProperty("relationshipLabel").ToString()); +]]> + + + +This sample shows how to call GetStructByIdAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = await client.GetStructByIdAsync(""); +]]> +This sample shows how to call GetStructByIdAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = await client.GetStructByIdAsync(""); +]]> + + + +This sample shows how to call GetStructById. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = client.GetStructById(""); +]]> +This sample shows how to call GetStructById with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = client.GetStructById(""); +]]> + + + +This sample shows how to call GetStructByIdAsync and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = await client.GetStructByIdAsync("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call GetStructByIdAsync with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = await client.GetStructByIdAsync("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("valuesMinCount").ToString()); +]]> + + + +This sample shows how to call GetStructById and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = client.GetStructById("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call GetStructById with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = client.GetStructById("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("valuesMinCount").ToString()); +]]> + + + +This sample shows how to call GetStructByNameAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = await client.GetStructByNameAsync(""); +]]> +This sample shows how to call GetStructByNameAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = await client.GetStructByNameAsync(""); +]]> + + + +This sample shows how to call GetStructByName. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = client.GetStructByName(""); +]]> +This sample shows how to call GetStructByName with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = client.GetStructByName(""); +]]> + + + +This sample shows how to call GetStructByNameAsync and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = await client.GetStructByNameAsync("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call GetStructByNameAsync with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = await client.GetStructByNameAsync("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("valuesMinCount").ToString()); +]]> + + + +This sample shows how to call GetStructByName and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = client.GetStructByName("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call GetStructByName with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = client.GetStructByName("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("valuesMinCount").ToString()); +]]> + + + +This sample shows how to call GetByIdAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = await client.GetByIdAsync(""); +]]> +This sample shows how to call GetByIdAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = await client.GetByIdAsync(""); +]]> + + + +This sample shows how to call GetById. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = client.GetById(""); +]]> +This sample shows how to call GetById with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = client.GetById(""); +]]> + + + +This sample shows how to call GetByIdAsync and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = await client.GetByIdAsync("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call GetByIdAsync with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = await client.GetByIdAsync("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("entityTypes")[0].ToString()); +Console.WriteLine(result.GetProperty("subTypes")[0].ToString()); +Console.WriteLine(result.GetProperty("superTypes")[0].ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("valuesMinCount").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("isLegacyAttribute").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("relationshipTypeName").ToString()); +Console.WriteLine(result.GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("elementDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("elementDefs")[0].GetProperty("ordinal").ToString()); +Console.WriteLine(result.GetProperty("elementDefs")[0].GetProperty("value").ToString()); +Console.WriteLine(result.GetProperty("endDef1").GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("endDef1").GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("endDef1").GetProperty("isContainer").ToString()); +Console.WriteLine(result.GetProperty("endDef1").GetProperty("isLegacyAttribute").ToString()); +Console.WriteLine(result.GetProperty("endDef1").GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("endDef1").GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("endDef2").GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("endDef2").GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("endDef2").GetProperty("isContainer").ToString()); +Console.WriteLine(result.GetProperty("endDef2").GetProperty("isLegacyAttribute").ToString()); +Console.WriteLine(result.GetProperty("endDef2").GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("endDef2").GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("relationshipCategory").ToString()); +Console.WriteLine(result.GetProperty("relationshipLabel").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("valuesMinCount").ToString()); +]]> + + + +This sample shows how to call GetById and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = client.GetById("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call GetById with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = client.GetById("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("entityTypes")[0].ToString()); +Console.WriteLine(result.GetProperty("subTypes")[0].ToString()); +Console.WriteLine(result.GetProperty("superTypes")[0].ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("valuesMinCount").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("isLegacyAttribute").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("relationshipTypeName").ToString()); +Console.WriteLine(result.GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("elementDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("elementDefs")[0].GetProperty("ordinal").ToString()); +Console.WriteLine(result.GetProperty("elementDefs")[0].GetProperty("value").ToString()); +Console.WriteLine(result.GetProperty("endDef1").GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("endDef1").GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("endDef1").GetProperty("isContainer").ToString()); +Console.WriteLine(result.GetProperty("endDef1").GetProperty("isLegacyAttribute").ToString()); +Console.WriteLine(result.GetProperty("endDef1").GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("endDef1").GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("endDef2").GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("endDef2").GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("endDef2").GetProperty("isContainer").ToString()); +Console.WriteLine(result.GetProperty("endDef2").GetProperty("isLegacyAttribute").ToString()); +Console.WriteLine(result.GetProperty("endDef2").GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("endDef2").GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("relationshipCategory").ToString()); +Console.WriteLine(result.GetProperty("relationshipLabel").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("valuesMinCount").ToString()); +]]> + + + +This sample shows how to call GetByNameAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = await client.GetByNameAsync(""); +]]> +This sample shows how to call GetByNameAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = await client.GetByNameAsync(""); +]]> + + + +This sample shows how to call GetByName. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = client.GetByName(""); +]]> +This sample shows how to call GetByName with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = client.GetByName(""); +]]> + + + +This sample shows how to call GetByNameAsync and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = await client.GetByNameAsync("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call GetByNameAsync with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = await client.GetByNameAsync("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("entityTypes")[0].ToString()); +Console.WriteLine(result.GetProperty("subTypes")[0].ToString()); +Console.WriteLine(result.GetProperty("superTypes")[0].ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("valuesMinCount").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("isLegacyAttribute").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("relationshipTypeName").ToString()); +Console.WriteLine(result.GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("elementDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("elementDefs")[0].GetProperty("ordinal").ToString()); +Console.WriteLine(result.GetProperty("elementDefs")[0].GetProperty("value").ToString()); +Console.WriteLine(result.GetProperty("endDef1").GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("endDef1").GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("endDef1").GetProperty("isContainer").ToString()); +Console.WriteLine(result.GetProperty("endDef1").GetProperty("isLegacyAttribute").ToString()); +Console.WriteLine(result.GetProperty("endDef1").GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("endDef1").GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("endDef2").GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("endDef2").GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("endDef2").GetProperty("isContainer").ToString()); +Console.WriteLine(result.GetProperty("endDef2").GetProperty("isLegacyAttribute").ToString()); +Console.WriteLine(result.GetProperty("endDef2").GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("endDef2").GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("relationshipCategory").ToString()); +Console.WriteLine(result.GetProperty("relationshipLabel").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("valuesMinCount").ToString()); +]]> + + + +This sample shows how to call GetByName and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = client.GetByName("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call GetByName with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = client.GetByName("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("entityTypes")[0].ToString()); +Console.WriteLine(result.GetProperty("subTypes")[0].ToString()); +Console.WriteLine(result.GetProperty("superTypes")[0].ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("valuesMinCount").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("isLegacyAttribute").ToString()); +Console.WriteLine(result.GetProperty("relationshipAttributeDefs")[0].GetProperty("relationshipTypeName").ToString()); +Console.WriteLine(result.GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("elementDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("elementDefs")[0].GetProperty("ordinal").ToString()); +Console.WriteLine(result.GetProperty("elementDefs")[0].GetProperty("value").ToString()); +Console.WriteLine(result.GetProperty("endDef1").GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("endDef1").GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("endDef1").GetProperty("isContainer").ToString()); +Console.WriteLine(result.GetProperty("endDef1").GetProperty("isLegacyAttribute").ToString()); +Console.WriteLine(result.GetProperty("endDef1").GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("endDef1").GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("endDef2").GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("endDef2").GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("endDef2").GetProperty("isContainer").ToString()); +Console.WriteLine(result.GetProperty("endDef2").GetProperty("isLegacyAttribute").ToString()); +Console.WriteLine(result.GetProperty("endDef2").GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("endDef2").GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("relationshipCategory").ToString()); +Console.WriteLine(result.GetProperty("relationshipLabel").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("valuesMinCount").ToString()); +]]> + + + +This sample shows how to call DeleteAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = await client.DeleteAsync(""); + +Console.WriteLine(response.Status); +]]> +This sample shows how to call DeleteAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = await client.DeleteAsync(""); + +Console.WriteLine(response.Status); +]]> + + + +This sample shows how to call Delete. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = client.Delete(""); + +Console.WriteLine(response.Status); +]]> +This sample shows how to call Delete with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = client.Delete(""); + +Console.WriteLine(response.Status); +]]> + + + +This sample shows how to call GetTypeDefinitionAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = await client.GetTypeDefinitionAsync(); +]]> +This sample shows how to call GetTypeDefinitionAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = await client.GetTypeDefinitionAsync(includeTermTemplate: true, type: TypeDef.Enum); +]]> + + + +This sample shows how to call GetTypeDefinition. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = client.GetTypeDefinition(); +]]> +This sample shows how to call GetTypeDefinition with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = client.GetTypeDefinition(includeTermTemplate: true, type: TypeDef.Enum); +]]> + + + +This sample shows how to call GetTypeDefinitionAsync and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = await client.GetTypeDefinitionAsync(null, null, null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call GetTypeDefinitionAsync with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = await client.GetTypeDefinitionAsync(true, "enum", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("valuesMinCount").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("valuesMinCount").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("entityTypes")[0].ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("subTypes")[0].ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("superTypes")[0].ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("valuesMinCount").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("subTypes")[0].ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("superTypes")[0].ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("valuesMinCount").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("isLegacyAttribute").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("relationshipTypeName").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("elementDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("elementDefs")[0].GetProperty("ordinal").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("elementDefs")[0].GetProperty("value").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("valuesMinCount").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("endDef1").GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("endDef1").GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("endDef1").GetProperty("isContainer").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("endDef1").GetProperty("isLegacyAttribute").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("endDef1").GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("endDef1").GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("endDef2").GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("endDef2").GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("endDef2").GetProperty("isContainer").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("endDef2").GetProperty("isLegacyAttribute").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("endDef2").GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("endDef2").GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("relationshipCategory").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("relationshipLabel").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("valuesMinCount").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("valuesMinCount").ToString()); +]]> + + + +This sample shows how to call GetTypeDefinition and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = client.GetTypeDefinition(null, null, null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call GetTypeDefinition with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = client.GetTypeDefinition(true, "enum", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("valuesMinCount").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("valuesMinCount").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("entityTypes")[0].ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("subTypes")[0].ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("superTypes")[0].ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("valuesMinCount").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("subTypes")[0].ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("superTypes")[0].ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("valuesMinCount").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("isLegacyAttribute").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("relationshipTypeName").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("elementDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("elementDefs")[0].GetProperty("ordinal").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("elementDefs")[0].GetProperty("value").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("valuesMinCount").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("endDef1").GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("endDef1").GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("endDef1").GetProperty("isContainer").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("endDef1").GetProperty("isLegacyAttribute").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("endDef1").GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("endDef1").GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("endDef2").GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("endDef2").GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("endDef2").GetProperty("isContainer").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("endDef2").GetProperty("isLegacyAttribute").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("endDef2").GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("endDef2").GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("relationshipCategory").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("relationshipLabel").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("valuesMinCount").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("valuesMinCount").ToString()); +]]> + + + +This sample shows how to call BatchCreateAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +AtlasTypesDef typesDef = new AtlasTypesDef(); +Response response = await client.BatchCreateAsync(typesDef); +]]> +This sample shows how to call BatchCreateAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +AtlasTypesDef typesDef = new AtlasTypesDef +{ + BusinessMetadataDefs = {new AtlasBusinessMetadataDef + { + Category = TypeCategory.Primitive, + CreateTime = 1234L, + CreatedBy = "", + DateFormatter = new DateFormat + { + AvailableLocales = {""}, + Calendar = 123.45F, + DateInstance = default, + DateTimeInstance = default, + Instance = default, + Lenient = true, + NumberFormat = new NumberFormat + { + AvailableLocales = {""}, + Currency = "", + CurrencyInstance = default, + GroupingUsed = true, + Instance = default, + IntegerInstance = default, + MaximumFractionDigits = 1234, + MaximumIntegerDigits = 1234, + MinimumFractionDigits = 1234, + MinimumIntegerDigits = 1234, + NumberInstance = default, + ParseIntegerOnly = true, + PercentInstance = default, + RoundingMode = RoundingMode.Up, + }, + TimeInstance = default, + TimeZone = new TimeZone + { + DstSavings = 1234, + Id = "", + AvailableIds = {""}, + Default = default, + DisplayName = "", + RawOffset = 1234, + }, + }, + Description = "", + Guid = "", + Name = "", + Options = + { + ["key"] = "" + }, + ServiceType = "", + TypeVersion = "", + UpdateTime = 1234L, + UpdatedBy = "", + Version = 1234L, + LastModifiedTS = "", + AttributeDefs = {new AtlasAttributeDef + { + Cardinality = CardinalityValue.Single, + Constraints = {new AtlasConstraintDef + { + Params = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + Type = "", + }}, + DefaultValue = "", + Description = "", + IncludeInNotification = true, + IsIndexable = true, + IsOptional = true, + IsUnique = true, + Name = "", + Options = + { + ["key"] = "" + }, + TypeName = "", + ValuesMaxCount = 1234, + ValuesMinCount = 1234, + }}, + }}, + ClassificationDefs = {new AtlasClassificationDef + { + Category = TypeCategory.Primitive, + CreateTime = 1234L, + CreatedBy = "", + DateFormatter = default, + Description = "", + Guid = "", + Name = "", + Options = + { + ["key"] = "" + }, + ServiceType = "", + TypeVersion = "", + UpdateTime = 1234L, + UpdatedBy = "", + Version = 1234L, + LastModifiedTS = "", + AttributeDefs = {default}, + EntityTypes = {""}, + SubTypes = {""}, + SuperTypes = {""}, + }}, + EntityDefs = {new AtlasEntityDef + { + Category = TypeCategory.Primitive, + CreateTime = 1234L, + CreatedBy = "", + DateFormatter = default, + Description = "", + Guid = "", + Name = "", + Options = + { + ["key"] = "" + }, + ServiceType = "", + TypeVersion = "", + UpdateTime = 1234L, + UpdatedBy = "", + Version = 1234L, + LastModifiedTS = "", + AttributeDefs = {default}, + SubTypes = {""}, + SuperTypes = {""}, + RelationshipAttributeDefs = {new AtlasRelationshipAttributeDef + { + Cardinality = CardinalityValue.Single, + Constraints = {default}, + DefaultValue = "", + Description = "", + IncludeInNotification = true, + IsIndexable = true, + IsOptional = true, + IsUnique = true, + Name = "", + Options = + { + ["key"] = "" + }, + TypeName = "", + ValuesMaxCount = 1234, + ValuesMinCount = 1234, + IsLegacyAttribute = true, + RelationshipTypeName = "", + }}, + }}, + EnumDefs = {new AtlasEnumDef + { + Category = TypeCategory.Primitive, + CreateTime = 1234L, + CreatedBy = "", + DateFormatter = default, + Description = "", + Guid = "", + Name = "", + Options = + { + ["key"] = "" + }, + ServiceType = "", + TypeVersion = "", + UpdateTime = 1234L, + UpdatedBy = "", + Version = 1234L, + LastModifiedTS = "", + DefaultValue = "", + ElementDefs = {new AtlasEnumElementDef + { + Description = "", + Ordinal = 1234, + Value = "", + }}, + }}, + RelationshipDefs = {new AtlasRelationshipDef + { + Category = TypeCategory.Primitive, + CreateTime = 1234L, + CreatedBy = "", + DateFormatter = default, + Description = "", + Guid = "", + Name = "", + Options = + { + ["key"] = "" + }, + ServiceType = "", + TypeVersion = "", + UpdateTime = 1234L, + UpdatedBy = "", + Version = 1234L, + LastModifiedTS = "", + AttributeDefs = {default}, + EndDef1 = new AtlasRelationshipEndDef + { + Cardinality = CardinalityValue.Single, + Description = "", + IsContainer = true, + IsLegacyAttribute = true, + Name = "", + Type = "", + }, + EndDef2 = default, + RelationshipCategory = RelationshipCategory.Association, + RelationshipLabel = "", + }}, + StructDefs = {new AtlasStructDef + { + Category = TypeCategory.Primitive, + CreateTime = 1234L, + CreatedBy = "", + DateFormatter = default, + Description = "", + Guid = "", + Name = "", + Options = + { + ["key"] = "" + }, + ServiceType = "", + TypeVersion = "", + UpdateTime = 1234L, + UpdatedBy = "", + Version = 1234L, + LastModifiedTS = "", + AttributeDefs = {default}, + }}, + TermTemplateDefs = {new TermTemplateDef + { + Category = TypeCategory.Primitive, + CreateTime = 1234L, + CreatedBy = "", + DateFormatter = default, + Description = "", + Guid = "", + Name = "", + Options = + { + ["key"] = "" + }, + ServiceType = "", + TypeVersion = "", + UpdateTime = 1234L, + UpdatedBy = "", + Version = 1234L, + LastModifiedTS = "", + AttributeDefs = {default}, + }}, +}; +Response response = await client.BatchCreateAsync(typesDef); +]]> + + + +This sample shows how to call BatchCreate. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +AtlasTypesDef typesDef = new AtlasTypesDef(); +Response response = client.BatchCreate(typesDef); +]]> +This sample shows how to call BatchCreate with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +AtlasTypesDef typesDef = new AtlasTypesDef +{ + BusinessMetadataDefs = {new AtlasBusinessMetadataDef + { + Category = TypeCategory.Primitive, + CreateTime = 1234L, + CreatedBy = "", + DateFormatter = new DateFormat + { + AvailableLocales = {""}, + Calendar = 123.45F, + DateInstance = default, + DateTimeInstance = default, + Instance = default, + Lenient = true, + NumberFormat = new NumberFormat + { + AvailableLocales = {""}, + Currency = "", + CurrencyInstance = default, + GroupingUsed = true, + Instance = default, + IntegerInstance = default, + MaximumFractionDigits = 1234, + MaximumIntegerDigits = 1234, + MinimumFractionDigits = 1234, + MinimumIntegerDigits = 1234, + NumberInstance = default, + ParseIntegerOnly = true, + PercentInstance = default, + RoundingMode = RoundingMode.Up, + }, + TimeInstance = default, + TimeZone = new TimeZone + { + DstSavings = 1234, + Id = "", + AvailableIds = {""}, + Default = default, + DisplayName = "", + RawOffset = 1234, + }, + }, + Description = "", + Guid = "", + Name = "", + Options = + { + ["key"] = "" + }, + ServiceType = "", + TypeVersion = "", + UpdateTime = 1234L, + UpdatedBy = "", + Version = 1234L, + LastModifiedTS = "", + AttributeDefs = {new AtlasAttributeDef + { + Cardinality = CardinalityValue.Single, + Constraints = {new AtlasConstraintDef + { + Params = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + Type = "", + }}, + DefaultValue = "", + Description = "", + IncludeInNotification = true, + IsIndexable = true, + IsOptional = true, + IsUnique = true, + Name = "", + Options = + { + ["key"] = "" + }, + TypeName = "", + ValuesMaxCount = 1234, + ValuesMinCount = 1234, + }}, + }}, + ClassificationDefs = {new AtlasClassificationDef + { + Category = TypeCategory.Primitive, + CreateTime = 1234L, + CreatedBy = "", + DateFormatter = default, + Description = "", + Guid = "", + Name = "", + Options = + { + ["key"] = "" + }, + ServiceType = "", + TypeVersion = "", + UpdateTime = 1234L, + UpdatedBy = "", + Version = 1234L, + LastModifiedTS = "", + AttributeDefs = {default}, + EntityTypes = {""}, + SubTypes = {""}, + SuperTypes = {""}, + }}, + EntityDefs = {new AtlasEntityDef + { + Category = TypeCategory.Primitive, + CreateTime = 1234L, + CreatedBy = "", + DateFormatter = default, + Description = "", + Guid = "", + Name = "", + Options = + { + ["key"] = "" + }, + ServiceType = "", + TypeVersion = "", + UpdateTime = 1234L, + UpdatedBy = "", + Version = 1234L, + LastModifiedTS = "", + AttributeDefs = {default}, + SubTypes = {""}, + SuperTypes = {""}, + RelationshipAttributeDefs = {new AtlasRelationshipAttributeDef + { + Cardinality = CardinalityValue.Single, + Constraints = {default}, + DefaultValue = "", + Description = "", + IncludeInNotification = true, + IsIndexable = true, + IsOptional = true, + IsUnique = true, + Name = "", + Options = + { + ["key"] = "" + }, + TypeName = "", + ValuesMaxCount = 1234, + ValuesMinCount = 1234, + IsLegacyAttribute = true, + RelationshipTypeName = "", + }}, + }}, + EnumDefs = {new AtlasEnumDef + { + Category = TypeCategory.Primitive, + CreateTime = 1234L, + CreatedBy = "", + DateFormatter = default, + Description = "", + Guid = "", + Name = "", + Options = + { + ["key"] = "" + }, + ServiceType = "", + TypeVersion = "", + UpdateTime = 1234L, + UpdatedBy = "", + Version = 1234L, + LastModifiedTS = "", + DefaultValue = "", + ElementDefs = {new AtlasEnumElementDef + { + Description = "", + Ordinal = 1234, + Value = "", + }}, + }}, + RelationshipDefs = {new AtlasRelationshipDef + { + Category = TypeCategory.Primitive, + CreateTime = 1234L, + CreatedBy = "", + DateFormatter = default, + Description = "", + Guid = "", + Name = "", + Options = + { + ["key"] = "" + }, + ServiceType = "", + TypeVersion = "", + UpdateTime = 1234L, + UpdatedBy = "", + Version = 1234L, + LastModifiedTS = "", + AttributeDefs = {default}, + EndDef1 = new AtlasRelationshipEndDef + { + Cardinality = CardinalityValue.Single, + Description = "", + IsContainer = true, + IsLegacyAttribute = true, + Name = "", + Type = "", + }, + EndDef2 = default, + RelationshipCategory = RelationshipCategory.Association, + RelationshipLabel = "", + }}, + StructDefs = {new AtlasStructDef + { + Category = TypeCategory.Primitive, + CreateTime = 1234L, + CreatedBy = "", + DateFormatter = default, + Description = "", + Guid = "", + Name = "", + Options = + { + ["key"] = "" + }, + ServiceType = "", + TypeVersion = "", + UpdateTime = 1234L, + UpdatedBy = "", + Version = 1234L, + LastModifiedTS = "", + AttributeDefs = {default}, + }}, + TermTemplateDefs = {new TermTemplateDef + { + Category = TypeCategory.Primitive, + CreateTime = 1234L, + CreatedBy = "", + DateFormatter = default, + Description = "", + Guid = "", + Name = "", + Options = + { + ["key"] = "" + }, + ServiceType = "", + TypeVersion = "", + UpdateTime = 1234L, + UpdatedBy = "", + Version = 1234L, + LastModifiedTS = "", + AttributeDefs = {default}, + }}, +}; +Response response = client.BatchCreate(typesDef); +]]> + + + +This sample shows how to call BatchCreateAsync and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object()); +Response response = await client.BatchCreateAsync(content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call BatchCreateAsync with all request content and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new +{ + businessMetadataDefs = new object[] + { + new + { + category = "PRIMITIVE", + createTime = 1234L, + createdBy = "", + dateFormatter = new + { + availableLocales = new object[] + { + "" + }, + calendar = 123.45F, + lenient = true, + numberFormat = new + { + availableLocales = new object[] + { + "" + }, + currency = "", + groupingUsed = true, + maximumFractionDigits = 1234, + maximumIntegerDigits = 1234, + minimumFractionDigits = 1234, + minimumIntegerDigits = 1234, + parseIntegerOnly = true, + roundingMode = "UP", + }, + timeZone = new Dictionary + { + ["dstSavings"] = 1234, + ["id"] = "", + ["availableIds"] = new object[] + { + "" + }, + ["default"] = null, + ["displayName"] = "", + ["rawOffset"] = 1234 + }, + }, + description = "", + guid = "", + name = "", + options = new + { + key = "", + }, + serviceType = "", + typeVersion = "", + updateTime = 1234L, + updatedBy = "", + version = 1234L, + lastModifiedTS = "", + attributeDefs = new object[] + { + new + { + cardinality = "SINGLE", + constraints = new object[] + { + new Dictionary + { + ["params"] = new + { + key = new object(), + }, + ["type"] = "" + } + }, + defaultValue = "", + description = "", + includeInNotification = true, + isIndexable = true, + isOptional = true, + isUnique = true, + name = "", + options = new + { + key = "", + }, + typeName = "", + valuesMaxCount = 1234, + valuesMinCount = 1234, + } + }, + } + }, + classificationDefs = new object[] + { + new + { + category = "PRIMITIVE", + createTime = 1234L, + createdBy = "", + description = "", + guid = "", + name = "", + options = new + { + key = "", + }, + serviceType = "", + typeVersion = "", + updateTime = 1234L, + updatedBy = "", + version = 1234L, + lastModifiedTS = "", + attributeDefs = new object[] + { + null + }, + entityTypes = new object[] + { + "" + }, + subTypes = new object[] + { + "" + }, + superTypes = new object[] + { + "" + }, + } + }, + entityDefs = new object[] + { + new + { + category = "PRIMITIVE", + createTime = 1234L, + createdBy = "", + description = "", + guid = "", + name = "", + options = new + { + key = "", + }, + serviceType = "", + typeVersion = "", + updateTime = 1234L, + updatedBy = "", + version = 1234L, + lastModifiedTS = "", + attributeDefs = new object[] + { + null + }, + subTypes = new object[] + { + "" + }, + superTypes = new object[] + { + "" + }, + relationshipAttributeDefs = new object[] + { + new + { + cardinality = "SINGLE", + constraints = new object[] + { + null + }, + defaultValue = "", + description = "", + includeInNotification = true, + isIndexable = true, + isOptional = true, + isUnique = true, + name = "", + options = new + { + key = "", + }, + typeName = "", + valuesMaxCount = 1234, + valuesMinCount = 1234, + isLegacyAttribute = true, + relationshipTypeName = "", + } + }, + } + }, + enumDefs = new object[] + { + new + { + category = "PRIMITIVE", + createTime = 1234L, + createdBy = "", + description = "", + guid = "", + name = "", + options = new + { + key = "", + }, + serviceType = "", + typeVersion = "", + updateTime = 1234L, + updatedBy = "", + version = 1234L, + lastModifiedTS = "", + defaultValue = "", + elementDefs = new object[] + { + new + { + description = "", + ordinal = 1234, + value = "", + } + }, + } + }, + relationshipDefs = new object[] + { + new + { + category = "PRIMITIVE", + createTime = 1234L, + createdBy = "", + description = "", + guid = "", + name = "", + options = new + { + key = "", + }, + serviceType = "", + typeVersion = "", + updateTime = 1234L, + updatedBy = "", + version = 1234L, + lastModifiedTS = "", + attributeDefs = new object[] + { + null + }, + endDef1 = new + { + cardinality = "SINGLE", + description = "", + isContainer = true, + isLegacyAttribute = true, + name = "", + type = "", + }, + relationshipCategory = "ASSOCIATION", + relationshipLabel = "", + } + }, + structDefs = new object[] + { + new + { + category = "PRIMITIVE", + createTime = 1234L, + createdBy = "", + description = "", + guid = "", + name = "", + options = new + { + key = "", + }, + serviceType = "", + typeVersion = "", + updateTime = 1234L, + updatedBy = "", + version = 1234L, + lastModifiedTS = "", + attributeDefs = new object[] + { + null + }, + } + }, + termTemplateDefs = new object[] + { + new + { + category = "PRIMITIVE", + createTime = 1234L, + createdBy = "", + description = "", + guid = "", + name = "", + options = new + { + key = "", + }, + serviceType = "", + typeVersion = "", + updateTime = 1234L, + updatedBy = "", + version = 1234L, + lastModifiedTS = "", + attributeDefs = new object[] + { + null + }, + } + }, +}); +Response response = await client.BatchCreateAsync(content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("valuesMinCount").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("valuesMinCount").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("entityTypes")[0].ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("subTypes")[0].ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("superTypes")[0].ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("valuesMinCount").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("subTypes")[0].ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("superTypes")[0].ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("valuesMinCount").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("isLegacyAttribute").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("relationshipTypeName").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("elementDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("elementDefs")[0].GetProperty("ordinal").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("elementDefs")[0].GetProperty("value").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("valuesMinCount").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("endDef1").GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("endDef1").GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("endDef1").GetProperty("isContainer").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("endDef1").GetProperty("isLegacyAttribute").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("endDef1").GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("endDef1").GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("endDef2").GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("endDef2").GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("endDef2").GetProperty("isContainer").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("endDef2").GetProperty("isLegacyAttribute").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("endDef2").GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("endDef2").GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("relationshipCategory").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("relationshipLabel").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("valuesMinCount").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("valuesMinCount").ToString()); +]]> + + + +This sample shows how to call BatchCreate and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object()); +Response response = client.BatchCreate(content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call BatchCreate with all request content and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new +{ + businessMetadataDefs = new object[] + { + new + { + category = "PRIMITIVE", + createTime = 1234L, + createdBy = "", + dateFormatter = new + { + availableLocales = new object[] + { + "" + }, + calendar = 123.45F, + lenient = true, + numberFormat = new + { + availableLocales = new object[] + { + "" + }, + currency = "", + groupingUsed = true, + maximumFractionDigits = 1234, + maximumIntegerDigits = 1234, + minimumFractionDigits = 1234, + minimumIntegerDigits = 1234, + parseIntegerOnly = true, + roundingMode = "UP", + }, + timeZone = new Dictionary + { + ["dstSavings"] = 1234, + ["id"] = "", + ["availableIds"] = new object[] + { + "" + }, + ["default"] = null, + ["displayName"] = "", + ["rawOffset"] = 1234 + }, + }, + description = "", + guid = "", + name = "", + options = new + { + key = "", + }, + serviceType = "", + typeVersion = "", + updateTime = 1234L, + updatedBy = "", + version = 1234L, + lastModifiedTS = "", + attributeDefs = new object[] + { + new + { + cardinality = "SINGLE", + constraints = new object[] + { + new Dictionary + { + ["params"] = new + { + key = new object(), + }, + ["type"] = "" + } + }, + defaultValue = "", + description = "", + includeInNotification = true, + isIndexable = true, + isOptional = true, + isUnique = true, + name = "", + options = new + { + key = "", + }, + typeName = "", + valuesMaxCount = 1234, + valuesMinCount = 1234, + } + }, + } + }, + classificationDefs = new object[] + { + new + { + category = "PRIMITIVE", + createTime = 1234L, + createdBy = "", + description = "", + guid = "", + name = "", + options = new + { + key = "", + }, + serviceType = "", + typeVersion = "", + updateTime = 1234L, + updatedBy = "", + version = 1234L, + lastModifiedTS = "", + attributeDefs = new object[] + { + null + }, + entityTypes = new object[] + { + "" + }, + subTypes = new object[] + { + "" + }, + superTypes = new object[] + { + "" + }, + } + }, + entityDefs = new object[] + { + new + { + category = "PRIMITIVE", + createTime = 1234L, + createdBy = "", + description = "", + guid = "", + name = "", + options = new + { + key = "", + }, + serviceType = "", + typeVersion = "", + updateTime = 1234L, + updatedBy = "", + version = 1234L, + lastModifiedTS = "", + attributeDefs = new object[] + { + null + }, + subTypes = new object[] + { + "" + }, + superTypes = new object[] + { + "" + }, + relationshipAttributeDefs = new object[] + { + new + { + cardinality = "SINGLE", + constraints = new object[] + { + null + }, + defaultValue = "", + description = "", + includeInNotification = true, + isIndexable = true, + isOptional = true, + isUnique = true, + name = "", + options = new + { + key = "", + }, + typeName = "", + valuesMaxCount = 1234, + valuesMinCount = 1234, + isLegacyAttribute = true, + relationshipTypeName = "", + } + }, + } + }, + enumDefs = new object[] + { + new + { + category = "PRIMITIVE", + createTime = 1234L, + createdBy = "", + description = "", + guid = "", + name = "", + options = new + { + key = "", + }, + serviceType = "", + typeVersion = "", + updateTime = 1234L, + updatedBy = "", + version = 1234L, + lastModifiedTS = "", + defaultValue = "", + elementDefs = new object[] + { + new + { + description = "", + ordinal = 1234, + value = "", + } + }, + } + }, + relationshipDefs = new object[] + { + new + { + category = "PRIMITIVE", + createTime = 1234L, + createdBy = "", + description = "", + guid = "", + name = "", + options = new + { + key = "", + }, + serviceType = "", + typeVersion = "", + updateTime = 1234L, + updatedBy = "", + version = 1234L, + lastModifiedTS = "", + attributeDefs = new object[] + { + null + }, + endDef1 = new + { + cardinality = "SINGLE", + description = "", + isContainer = true, + isLegacyAttribute = true, + name = "", + type = "", + }, + relationshipCategory = "ASSOCIATION", + relationshipLabel = "", + } + }, + structDefs = new object[] + { + new + { + category = "PRIMITIVE", + createTime = 1234L, + createdBy = "", + description = "", + guid = "", + name = "", + options = new + { + key = "", + }, + serviceType = "", + typeVersion = "", + updateTime = 1234L, + updatedBy = "", + version = 1234L, + lastModifiedTS = "", + attributeDefs = new object[] + { + null + }, + } + }, + termTemplateDefs = new object[] + { + new + { + category = "PRIMITIVE", + createTime = 1234L, + createdBy = "", + description = "", + guid = "", + name = "", + options = new + { + key = "", + }, + serviceType = "", + typeVersion = "", + updateTime = 1234L, + updatedBy = "", + version = 1234L, + lastModifiedTS = "", + attributeDefs = new object[] + { + null + }, + } + }, +}); +Response response = client.BatchCreate(content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("valuesMinCount").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("valuesMinCount").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("entityTypes")[0].ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("subTypes")[0].ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("superTypes")[0].ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("valuesMinCount").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("subTypes")[0].ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("superTypes")[0].ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("valuesMinCount").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("isLegacyAttribute").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("relationshipTypeName").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("elementDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("elementDefs")[0].GetProperty("ordinal").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("elementDefs")[0].GetProperty("value").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("valuesMinCount").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("endDef1").GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("endDef1").GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("endDef1").GetProperty("isContainer").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("endDef1").GetProperty("isLegacyAttribute").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("endDef1").GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("endDef1").GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("endDef2").GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("endDef2").GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("endDef2").GetProperty("isContainer").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("endDef2").GetProperty("isLegacyAttribute").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("endDef2").GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("endDef2").GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("relationshipCategory").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("relationshipLabel").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("valuesMinCount").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("valuesMinCount").ToString()); +]]> + + + +This sample shows how to call BatchUpdateAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +AtlasTypesDef typesDef = new AtlasTypesDef(); +Response response = await client.BatchUpdateAsync(typesDef); +]]> +This sample shows how to call BatchUpdateAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +AtlasTypesDef typesDef = new AtlasTypesDef +{ + BusinessMetadataDefs = {new AtlasBusinessMetadataDef + { + Category = TypeCategory.Primitive, + CreateTime = 1234L, + CreatedBy = "", + DateFormatter = new DateFormat + { + AvailableLocales = {""}, + Calendar = 123.45F, + DateInstance = default, + DateTimeInstance = default, + Instance = default, + Lenient = true, + NumberFormat = new NumberFormat + { + AvailableLocales = {""}, + Currency = "", + CurrencyInstance = default, + GroupingUsed = true, + Instance = default, + IntegerInstance = default, + MaximumFractionDigits = 1234, + MaximumIntegerDigits = 1234, + MinimumFractionDigits = 1234, + MinimumIntegerDigits = 1234, + NumberInstance = default, + ParseIntegerOnly = true, + PercentInstance = default, + RoundingMode = RoundingMode.Up, + }, + TimeInstance = default, + TimeZone = new TimeZone + { + DstSavings = 1234, + Id = "", + AvailableIds = {""}, + Default = default, + DisplayName = "", + RawOffset = 1234, + }, + }, + Description = "", + Guid = "", + Name = "", + Options = + { + ["key"] = "" + }, + ServiceType = "", + TypeVersion = "", + UpdateTime = 1234L, + UpdatedBy = "", + Version = 1234L, + LastModifiedTS = "", + AttributeDefs = {new AtlasAttributeDef + { + Cardinality = CardinalityValue.Single, + Constraints = {new AtlasConstraintDef + { + Params = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + Type = "", + }}, + DefaultValue = "", + Description = "", + IncludeInNotification = true, + IsIndexable = true, + IsOptional = true, + IsUnique = true, + Name = "", + Options = + { + ["key"] = "" + }, + TypeName = "", + ValuesMaxCount = 1234, + ValuesMinCount = 1234, + }}, + }}, + ClassificationDefs = {new AtlasClassificationDef + { + Category = TypeCategory.Primitive, + CreateTime = 1234L, + CreatedBy = "", + DateFormatter = default, + Description = "", + Guid = "", + Name = "", + Options = + { + ["key"] = "" + }, + ServiceType = "", + TypeVersion = "", + UpdateTime = 1234L, + UpdatedBy = "", + Version = 1234L, + LastModifiedTS = "", + AttributeDefs = {default}, + EntityTypes = {""}, + SubTypes = {""}, + SuperTypes = {""}, + }}, + EntityDefs = {new AtlasEntityDef + { + Category = TypeCategory.Primitive, + CreateTime = 1234L, + CreatedBy = "", + DateFormatter = default, + Description = "", + Guid = "", + Name = "", + Options = + { + ["key"] = "" + }, + ServiceType = "", + TypeVersion = "", + UpdateTime = 1234L, + UpdatedBy = "", + Version = 1234L, + LastModifiedTS = "", + AttributeDefs = {default}, + SubTypes = {""}, + SuperTypes = {""}, + RelationshipAttributeDefs = {new AtlasRelationshipAttributeDef + { + Cardinality = CardinalityValue.Single, + Constraints = {default}, + DefaultValue = "", + Description = "", + IncludeInNotification = true, + IsIndexable = true, + IsOptional = true, + IsUnique = true, + Name = "", + Options = + { + ["key"] = "" + }, + TypeName = "", + ValuesMaxCount = 1234, + ValuesMinCount = 1234, + IsLegacyAttribute = true, + RelationshipTypeName = "", + }}, + }}, + EnumDefs = {new AtlasEnumDef + { + Category = TypeCategory.Primitive, + CreateTime = 1234L, + CreatedBy = "", + DateFormatter = default, + Description = "", + Guid = "", + Name = "", + Options = + { + ["key"] = "" + }, + ServiceType = "", + TypeVersion = "", + UpdateTime = 1234L, + UpdatedBy = "", + Version = 1234L, + LastModifiedTS = "", + DefaultValue = "", + ElementDefs = {new AtlasEnumElementDef + { + Description = "", + Ordinal = 1234, + Value = "", + }}, + }}, + RelationshipDefs = {new AtlasRelationshipDef + { + Category = TypeCategory.Primitive, + CreateTime = 1234L, + CreatedBy = "", + DateFormatter = default, + Description = "", + Guid = "", + Name = "", + Options = + { + ["key"] = "" + }, + ServiceType = "", + TypeVersion = "", + UpdateTime = 1234L, + UpdatedBy = "", + Version = 1234L, + LastModifiedTS = "", + AttributeDefs = {default}, + EndDef1 = new AtlasRelationshipEndDef + { + Cardinality = CardinalityValue.Single, + Description = "", + IsContainer = true, + IsLegacyAttribute = true, + Name = "", + Type = "", + }, + EndDef2 = default, + RelationshipCategory = RelationshipCategory.Association, + RelationshipLabel = "", + }}, + StructDefs = {new AtlasStructDef + { + Category = TypeCategory.Primitive, + CreateTime = 1234L, + CreatedBy = "", + DateFormatter = default, + Description = "", + Guid = "", + Name = "", + Options = + { + ["key"] = "" + }, + ServiceType = "", + TypeVersion = "", + UpdateTime = 1234L, + UpdatedBy = "", + Version = 1234L, + LastModifiedTS = "", + AttributeDefs = {default}, + }}, + TermTemplateDefs = {new TermTemplateDef + { + Category = TypeCategory.Primitive, + CreateTime = 1234L, + CreatedBy = "", + DateFormatter = default, + Description = "", + Guid = "", + Name = "", + Options = + { + ["key"] = "" + }, + ServiceType = "", + TypeVersion = "", + UpdateTime = 1234L, + UpdatedBy = "", + Version = 1234L, + LastModifiedTS = "", + AttributeDefs = {default}, + }}, +}; +Response response = await client.BatchUpdateAsync(typesDef); +]]> + + + +This sample shows how to call BatchUpdate. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +AtlasTypesDef typesDef = new AtlasTypesDef(); +Response response = client.BatchUpdate(typesDef); +]]> +This sample shows how to call BatchUpdate with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +AtlasTypesDef typesDef = new AtlasTypesDef +{ + BusinessMetadataDefs = {new AtlasBusinessMetadataDef + { + Category = TypeCategory.Primitive, + CreateTime = 1234L, + CreatedBy = "", + DateFormatter = new DateFormat + { + AvailableLocales = {""}, + Calendar = 123.45F, + DateInstance = default, + DateTimeInstance = default, + Instance = default, + Lenient = true, + NumberFormat = new NumberFormat + { + AvailableLocales = {""}, + Currency = "", + CurrencyInstance = default, + GroupingUsed = true, + Instance = default, + IntegerInstance = default, + MaximumFractionDigits = 1234, + MaximumIntegerDigits = 1234, + MinimumFractionDigits = 1234, + MinimumIntegerDigits = 1234, + NumberInstance = default, + ParseIntegerOnly = true, + PercentInstance = default, + RoundingMode = RoundingMode.Up, + }, + TimeInstance = default, + TimeZone = new TimeZone + { + DstSavings = 1234, + Id = "", + AvailableIds = {""}, + Default = default, + DisplayName = "", + RawOffset = 1234, + }, + }, + Description = "", + Guid = "", + Name = "", + Options = + { + ["key"] = "" + }, + ServiceType = "", + TypeVersion = "", + UpdateTime = 1234L, + UpdatedBy = "", + Version = 1234L, + LastModifiedTS = "", + AttributeDefs = {new AtlasAttributeDef + { + Cardinality = CardinalityValue.Single, + Constraints = {new AtlasConstraintDef + { + Params = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + Type = "", + }}, + DefaultValue = "", + Description = "", + IncludeInNotification = true, + IsIndexable = true, + IsOptional = true, + IsUnique = true, + Name = "", + Options = + { + ["key"] = "" + }, + TypeName = "", + ValuesMaxCount = 1234, + ValuesMinCount = 1234, + }}, + }}, + ClassificationDefs = {new AtlasClassificationDef + { + Category = TypeCategory.Primitive, + CreateTime = 1234L, + CreatedBy = "", + DateFormatter = default, + Description = "", + Guid = "", + Name = "", + Options = + { + ["key"] = "" + }, + ServiceType = "", + TypeVersion = "", + UpdateTime = 1234L, + UpdatedBy = "", + Version = 1234L, + LastModifiedTS = "", + AttributeDefs = {default}, + EntityTypes = {""}, + SubTypes = {""}, + SuperTypes = {""}, + }}, + EntityDefs = {new AtlasEntityDef + { + Category = TypeCategory.Primitive, + CreateTime = 1234L, + CreatedBy = "", + DateFormatter = default, + Description = "", + Guid = "", + Name = "", + Options = + { + ["key"] = "" + }, + ServiceType = "", + TypeVersion = "", + UpdateTime = 1234L, + UpdatedBy = "", + Version = 1234L, + LastModifiedTS = "", + AttributeDefs = {default}, + SubTypes = {""}, + SuperTypes = {""}, + RelationshipAttributeDefs = {new AtlasRelationshipAttributeDef + { + Cardinality = CardinalityValue.Single, + Constraints = {default}, + DefaultValue = "", + Description = "", + IncludeInNotification = true, + IsIndexable = true, + IsOptional = true, + IsUnique = true, + Name = "", + Options = + { + ["key"] = "" + }, + TypeName = "", + ValuesMaxCount = 1234, + ValuesMinCount = 1234, + IsLegacyAttribute = true, + RelationshipTypeName = "", + }}, + }}, + EnumDefs = {new AtlasEnumDef + { + Category = TypeCategory.Primitive, + CreateTime = 1234L, + CreatedBy = "", + DateFormatter = default, + Description = "", + Guid = "", + Name = "", + Options = + { + ["key"] = "" + }, + ServiceType = "", + TypeVersion = "", + UpdateTime = 1234L, + UpdatedBy = "", + Version = 1234L, + LastModifiedTS = "", + DefaultValue = "", + ElementDefs = {new AtlasEnumElementDef + { + Description = "", + Ordinal = 1234, + Value = "", + }}, + }}, + RelationshipDefs = {new AtlasRelationshipDef + { + Category = TypeCategory.Primitive, + CreateTime = 1234L, + CreatedBy = "", + DateFormatter = default, + Description = "", + Guid = "", + Name = "", + Options = + { + ["key"] = "" + }, + ServiceType = "", + TypeVersion = "", + UpdateTime = 1234L, + UpdatedBy = "", + Version = 1234L, + LastModifiedTS = "", + AttributeDefs = {default}, + EndDef1 = new AtlasRelationshipEndDef + { + Cardinality = CardinalityValue.Single, + Description = "", + IsContainer = true, + IsLegacyAttribute = true, + Name = "", + Type = "", + }, + EndDef2 = default, + RelationshipCategory = RelationshipCategory.Association, + RelationshipLabel = "", + }}, + StructDefs = {new AtlasStructDef + { + Category = TypeCategory.Primitive, + CreateTime = 1234L, + CreatedBy = "", + DateFormatter = default, + Description = "", + Guid = "", + Name = "", + Options = + { + ["key"] = "" + }, + ServiceType = "", + TypeVersion = "", + UpdateTime = 1234L, + UpdatedBy = "", + Version = 1234L, + LastModifiedTS = "", + AttributeDefs = {default}, + }}, + TermTemplateDefs = {new TermTemplateDef + { + Category = TypeCategory.Primitive, + CreateTime = 1234L, + CreatedBy = "", + DateFormatter = default, + Description = "", + Guid = "", + Name = "", + Options = + { + ["key"] = "" + }, + ServiceType = "", + TypeVersion = "", + UpdateTime = 1234L, + UpdatedBy = "", + Version = 1234L, + LastModifiedTS = "", + AttributeDefs = {default}, + }}, +}; +Response response = client.BatchUpdate(typesDef); +]]> + + + +This sample shows how to call BatchUpdateAsync and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object()); +Response response = await client.BatchUpdateAsync(content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call BatchUpdateAsync with all request content and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new +{ + businessMetadataDefs = new object[] + { + new + { + category = "PRIMITIVE", + createTime = 1234L, + createdBy = "", + dateFormatter = new + { + availableLocales = new object[] + { + "" + }, + calendar = 123.45F, + lenient = true, + numberFormat = new + { + availableLocales = new object[] + { + "" + }, + currency = "", + groupingUsed = true, + maximumFractionDigits = 1234, + maximumIntegerDigits = 1234, + minimumFractionDigits = 1234, + minimumIntegerDigits = 1234, + parseIntegerOnly = true, + roundingMode = "UP", + }, + timeZone = new Dictionary + { + ["dstSavings"] = 1234, + ["id"] = "", + ["availableIds"] = new object[] + { + "" + }, + ["default"] = null, + ["displayName"] = "", + ["rawOffset"] = 1234 + }, + }, + description = "", + guid = "", + name = "", + options = new + { + key = "", + }, + serviceType = "", + typeVersion = "", + updateTime = 1234L, + updatedBy = "", + version = 1234L, + lastModifiedTS = "", + attributeDefs = new object[] + { + new + { + cardinality = "SINGLE", + constraints = new object[] + { + new Dictionary + { + ["params"] = new + { + key = new object(), + }, + ["type"] = "" + } + }, + defaultValue = "", + description = "", + includeInNotification = true, + isIndexable = true, + isOptional = true, + isUnique = true, + name = "", + options = new + { + key = "", + }, + typeName = "", + valuesMaxCount = 1234, + valuesMinCount = 1234, + } + }, + } + }, + classificationDefs = new object[] + { + new + { + category = "PRIMITIVE", + createTime = 1234L, + createdBy = "", + description = "", + guid = "", + name = "", + options = new + { + key = "", + }, + serviceType = "", + typeVersion = "", + updateTime = 1234L, + updatedBy = "", + version = 1234L, + lastModifiedTS = "", + attributeDefs = new object[] + { + null + }, + entityTypes = new object[] + { + "" + }, + subTypes = new object[] + { + "" + }, + superTypes = new object[] + { + "" + }, + } + }, + entityDefs = new object[] + { + new + { + category = "PRIMITIVE", + createTime = 1234L, + createdBy = "", + description = "", + guid = "", + name = "", + options = new + { + key = "", + }, + serviceType = "", + typeVersion = "", + updateTime = 1234L, + updatedBy = "", + version = 1234L, + lastModifiedTS = "", + attributeDefs = new object[] + { + null + }, + subTypes = new object[] + { + "" + }, + superTypes = new object[] + { + "" + }, + relationshipAttributeDefs = new object[] + { + new + { + cardinality = "SINGLE", + constraints = new object[] + { + null + }, + defaultValue = "", + description = "", + includeInNotification = true, + isIndexable = true, + isOptional = true, + isUnique = true, + name = "", + options = new + { + key = "", + }, + typeName = "", + valuesMaxCount = 1234, + valuesMinCount = 1234, + isLegacyAttribute = true, + relationshipTypeName = "", + } + }, + } + }, + enumDefs = new object[] + { + new + { + category = "PRIMITIVE", + createTime = 1234L, + createdBy = "", + description = "", + guid = "", + name = "", + options = new + { + key = "", + }, + serviceType = "", + typeVersion = "", + updateTime = 1234L, + updatedBy = "", + version = 1234L, + lastModifiedTS = "", + defaultValue = "", + elementDefs = new object[] + { + new + { + description = "", + ordinal = 1234, + value = "", + } + }, + } + }, + relationshipDefs = new object[] + { + new + { + category = "PRIMITIVE", + createTime = 1234L, + createdBy = "", + description = "", + guid = "", + name = "", + options = new + { + key = "", + }, + serviceType = "", + typeVersion = "", + updateTime = 1234L, + updatedBy = "", + version = 1234L, + lastModifiedTS = "", + attributeDefs = new object[] + { + null + }, + endDef1 = new + { + cardinality = "SINGLE", + description = "", + isContainer = true, + isLegacyAttribute = true, + name = "", + type = "", + }, + relationshipCategory = "ASSOCIATION", + relationshipLabel = "", + } + }, + structDefs = new object[] + { + new + { + category = "PRIMITIVE", + createTime = 1234L, + createdBy = "", + description = "", + guid = "", + name = "", + options = new + { + key = "", + }, + serviceType = "", + typeVersion = "", + updateTime = 1234L, + updatedBy = "", + version = 1234L, + lastModifiedTS = "", + attributeDefs = new object[] + { + null + }, + } + }, + termTemplateDefs = new object[] + { + new + { + category = "PRIMITIVE", + createTime = 1234L, + createdBy = "", + description = "", + guid = "", + name = "", + options = new + { + key = "", + }, + serviceType = "", + typeVersion = "", + updateTime = 1234L, + updatedBy = "", + version = 1234L, + lastModifiedTS = "", + attributeDefs = new object[] + { + null + }, + } + }, +}); +Response response = await client.BatchUpdateAsync(content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("valuesMinCount").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("valuesMinCount").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("entityTypes")[0].ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("subTypes")[0].ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("superTypes")[0].ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("valuesMinCount").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("subTypes")[0].ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("superTypes")[0].ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("valuesMinCount").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("isLegacyAttribute").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("relationshipTypeName").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("elementDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("elementDefs")[0].GetProperty("ordinal").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("elementDefs")[0].GetProperty("value").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("valuesMinCount").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("endDef1").GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("endDef1").GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("endDef1").GetProperty("isContainer").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("endDef1").GetProperty("isLegacyAttribute").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("endDef1").GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("endDef1").GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("endDef2").GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("endDef2").GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("endDef2").GetProperty("isContainer").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("endDef2").GetProperty("isLegacyAttribute").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("endDef2").GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("endDef2").GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("relationshipCategory").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("relationshipLabel").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("valuesMinCount").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("valuesMinCount").ToString()); +]]> + + + +This sample shows how to call BatchUpdate and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object()); +Response response = client.BatchUpdate(content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call BatchUpdate with all request content and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new +{ + businessMetadataDefs = new object[] + { + new + { + category = "PRIMITIVE", + createTime = 1234L, + createdBy = "", + dateFormatter = new + { + availableLocales = new object[] + { + "" + }, + calendar = 123.45F, + lenient = true, + numberFormat = new + { + availableLocales = new object[] + { + "" + }, + currency = "", + groupingUsed = true, + maximumFractionDigits = 1234, + maximumIntegerDigits = 1234, + minimumFractionDigits = 1234, + minimumIntegerDigits = 1234, + parseIntegerOnly = true, + roundingMode = "UP", + }, + timeZone = new Dictionary + { + ["dstSavings"] = 1234, + ["id"] = "", + ["availableIds"] = new object[] + { + "" + }, + ["default"] = null, + ["displayName"] = "", + ["rawOffset"] = 1234 + }, + }, + description = "", + guid = "", + name = "", + options = new + { + key = "", + }, + serviceType = "", + typeVersion = "", + updateTime = 1234L, + updatedBy = "", + version = 1234L, + lastModifiedTS = "", + attributeDefs = new object[] + { + new + { + cardinality = "SINGLE", + constraints = new object[] + { + new Dictionary + { + ["params"] = new + { + key = new object(), + }, + ["type"] = "" + } + }, + defaultValue = "", + description = "", + includeInNotification = true, + isIndexable = true, + isOptional = true, + isUnique = true, + name = "", + options = new + { + key = "", + }, + typeName = "", + valuesMaxCount = 1234, + valuesMinCount = 1234, + } + }, + } + }, + classificationDefs = new object[] + { + new + { + category = "PRIMITIVE", + createTime = 1234L, + createdBy = "", + description = "", + guid = "", + name = "", + options = new + { + key = "", + }, + serviceType = "", + typeVersion = "", + updateTime = 1234L, + updatedBy = "", + version = 1234L, + lastModifiedTS = "", + attributeDefs = new object[] + { + null + }, + entityTypes = new object[] + { + "" + }, + subTypes = new object[] + { + "" + }, + superTypes = new object[] + { + "" + }, + } + }, + entityDefs = new object[] + { + new + { + category = "PRIMITIVE", + createTime = 1234L, + createdBy = "", + description = "", + guid = "", + name = "", + options = new + { + key = "", + }, + serviceType = "", + typeVersion = "", + updateTime = 1234L, + updatedBy = "", + version = 1234L, + lastModifiedTS = "", + attributeDefs = new object[] + { + null + }, + subTypes = new object[] + { + "" + }, + superTypes = new object[] + { + "" + }, + relationshipAttributeDefs = new object[] + { + new + { + cardinality = "SINGLE", + constraints = new object[] + { + null + }, + defaultValue = "", + description = "", + includeInNotification = true, + isIndexable = true, + isOptional = true, + isUnique = true, + name = "", + options = new + { + key = "", + }, + typeName = "", + valuesMaxCount = 1234, + valuesMinCount = 1234, + isLegacyAttribute = true, + relationshipTypeName = "", + } + }, + } + }, + enumDefs = new object[] + { + new + { + category = "PRIMITIVE", + createTime = 1234L, + createdBy = "", + description = "", + guid = "", + name = "", + options = new + { + key = "", + }, + serviceType = "", + typeVersion = "", + updateTime = 1234L, + updatedBy = "", + version = 1234L, + lastModifiedTS = "", + defaultValue = "", + elementDefs = new object[] + { + new + { + description = "", + ordinal = 1234, + value = "", + } + }, + } + }, + relationshipDefs = new object[] + { + new + { + category = "PRIMITIVE", + createTime = 1234L, + createdBy = "", + description = "", + guid = "", + name = "", + options = new + { + key = "", + }, + serviceType = "", + typeVersion = "", + updateTime = 1234L, + updatedBy = "", + version = 1234L, + lastModifiedTS = "", + attributeDefs = new object[] + { + null + }, + endDef1 = new + { + cardinality = "SINGLE", + description = "", + isContainer = true, + isLegacyAttribute = true, + name = "", + type = "", + }, + relationshipCategory = "ASSOCIATION", + relationshipLabel = "", + } + }, + structDefs = new object[] + { + new + { + category = "PRIMITIVE", + createTime = 1234L, + createdBy = "", + description = "", + guid = "", + name = "", + options = new + { + key = "", + }, + serviceType = "", + typeVersion = "", + updateTime = 1234L, + updatedBy = "", + version = 1234L, + lastModifiedTS = "", + attributeDefs = new object[] + { + null + }, + } + }, + termTemplateDefs = new object[] + { + new + { + category = "PRIMITIVE", + createTime = 1234L, + createdBy = "", + description = "", + guid = "", + name = "", + options = new + { + key = "", + }, + serviceType = "", + typeVersion = "", + updateTime = 1234L, + updatedBy = "", + version = 1234L, + lastModifiedTS = "", + attributeDefs = new object[] + { + null + }, + } + }, +}); +Response response = client.BatchUpdate(content); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("businessMetadataDefs")[0].GetProperty("attributeDefs")[0].GetProperty("valuesMinCount").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("attributeDefs")[0].GetProperty("valuesMinCount").ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("entityTypes")[0].ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("subTypes")[0].ToString()); +Console.WriteLine(result.GetProperty("classificationDefs")[0].GetProperty("superTypes")[0].ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("attributeDefs")[0].GetProperty("valuesMinCount").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("subTypes")[0].ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("superTypes")[0].ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("valuesMinCount").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("isLegacyAttribute").ToString()); +Console.WriteLine(result.GetProperty("entityDefs")[0].GetProperty("relationshipAttributeDefs")[0].GetProperty("relationshipTypeName").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("elementDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("elementDefs")[0].GetProperty("ordinal").ToString()); +Console.WriteLine(result.GetProperty("enumDefs")[0].GetProperty("elementDefs")[0].GetProperty("value").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("attributeDefs")[0].GetProperty("valuesMinCount").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("endDef1").GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("endDef1").GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("endDef1").GetProperty("isContainer").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("endDef1").GetProperty("isLegacyAttribute").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("endDef1").GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("endDef1").GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("endDef2").GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("endDef2").GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("endDef2").GetProperty("isContainer").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("endDef2").GetProperty("isLegacyAttribute").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("endDef2").GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("endDef2").GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("relationshipCategory").ToString()); +Console.WriteLine(result.GetProperty("relationshipDefs")[0].GetProperty("relationshipLabel").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("structDefs")[0].GetProperty("attributeDefs")[0].GetProperty("valuesMinCount").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("termTemplateDefs")[0].GetProperty("attributeDefs")[0].GetProperty("valuesMinCount").ToString()); +]]> + + + +This sample shows how to call BatchDeleteAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +AtlasTypesDef typesDef = new AtlasTypesDef(); +Response response = await client.BatchDeleteAsync(typesDef); +]]> +This sample shows how to call BatchDeleteAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +AtlasTypesDef typesDef = new AtlasTypesDef +{ + BusinessMetadataDefs = {new AtlasBusinessMetadataDef + { + Category = TypeCategory.Primitive, + CreateTime = 1234L, + CreatedBy = "", + DateFormatter = new DateFormat + { + AvailableLocales = {""}, + Calendar = 123.45F, + DateInstance = default, + DateTimeInstance = default, + Instance = default, + Lenient = true, + NumberFormat = new NumberFormat + { + AvailableLocales = {""}, + Currency = "", + CurrencyInstance = default, + GroupingUsed = true, + Instance = default, + IntegerInstance = default, + MaximumFractionDigits = 1234, + MaximumIntegerDigits = 1234, + MinimumFractionDigits = 1234, + MinimumIntegerDigits = 1234, + NumberInstance = default, + ParseIntegerOnly = true, + PercentInstance = default, + RoundingMode = RoundingMode.Up, + }, + TimeInstance = default, + TimeZone = new TimeZone + { + DstSavings = 1234, + Id = "", + AvailableIds = {""}, + Default = default, + DisplayName = "", + RawOffset = 1234, + }, + }, + Description = "", + Guid = "", + Name = "", + Options = + { + ["key"] = "" + }, + ServiceType = "", + TypeVersion = "", + UpdateTime = 1234L, + UpdatedBy = "", + Version = 1234L, + LastModifiedTS = "", + AttributeDefs = {new AtlasAttributeDef + { + Cardinality = CardinalityValue.Single, + Constraints = {new AtlasConstraintDef + { + Params = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + Type = "", + }}, + DefaultValue = "", + Description = "", + IncludeInNotification = true, + IsIndexable = true, + IsOptional = true, + IsUnique = true, + Name = "", + Options = + { + ["key"] = "" + }, + TypeName = "", + ValuesMaxCount = 1234, + ValuesMinCount = 1234, + }}, + }}, + ClassificationDefs = {new AtlasClassificationDef + { + Category = TypeCategory.Primitive, + CreateTime = 1234L, + CreatedBy = "", + DateFormatter = default, + Description = "", + Guid = "", + Name = "", + Options = + { + ["key"] = "" + }, + ServiceType = "", + TypeVersion = "", + UpdateTime = 1234L, + UpdatedBy = "", + Version = 1234L, + LastModifiedTS = "", + AttributeDefs = {default}, + EntityTypes = {""}, + SubTypes = {""}, + SuperTypes = {""}, + }}, + EntityDefs = {new AtlasEntityDef + { + Category = TypeCategory.Primitive, + CreateTime = 1234L, + CreatedBy = "", + DateFormatter = default, + Description = "", + Guid = "", + Name = "", + Options = + { + ["key"] = "" + }, + ServiceType = "", + TypeVersion = "", + UpdateTime = 1234L, + UpdatedBy = "", + Version = 1234L, + LastModifiedTS = "", + AttributeDefs = {default}, + SubTypes = {""}, + SuperTypes = {""}, + RelationshipAttributeDefs = {new AtlasRelationshipAttributeDef + { + Cardinality = CardinalityValue.Single, + Constraints = {default}, + DefaultValue = "", + Description = "", + IncludeInNotification = true, + IsIndexable = true, + IsOptional = true, + IsUnique = true, + Name = "", + Options = + { + ["key"] = "" + }, + TypeName = "", + ValuesMaxCount = 1234, + ValuesMinCount = 1234, + IsLegacyAttribute = true, + RelationshipTypeName = "", + }}, + }}, + EnumDefs = {new AtlasEnumDef + { + Category = TypeCategory.Primitive, + CreateTime = 1234L, + CreatedBy = "", + DateFormatter = default, + Description = "", + Guid = "", + Name = "", + Options = + { + ["key"] = "" + }, + ServiceType = "", + TypeVersion = "", + UpdateTime = 1234L, + UpdatedBy = "", + Version = 1234L, + LastModifiedTS = "", + DefaultValue = "", + ElementDefs = {new AtlasEnumElementDef + { + Description = "", + Ordinal = 1234, + Value = "", + }}, + }}, + RelationshipDefs = {new AtlasRelationshipDef + { + Category = TypeCategory.Primitive, + CreateTime = 1234L, + CreatedBy = "", + DateFormatter = default, + Description = "", + Guid = "", + Name = "", + Options = + { + ["key"] = "" + }, + ServiceType = "", + TypeVersion = "", + UpdateTime = 1234L, + UpdatedBy = "", + Version = 1234L, + LastModifiedTS = "", + AttributeDefs = {default}, + EndDef1 = new AtlasRelationshipEndDef + { + Cardinality = CardinalityValue.Single, + Description = "", + IsContainer = true, + IsLegacyAttribute = true, + Name = "", + Type = "", + }, + EndDef2 = default, + RelationshipCategory = RelationshipCategory.Association, + RelationshipLabel = "", + }}, + StructDefs = {new AtlasStructDef + { + Category = TypeCategory.Primitive, + CreateTime = 1234L, + CreatedBy = "", + DateFormatter = default, + Description = "", + Guid = "", + Name = "", + Options = + { + ["key"] = "" + }, + ServiceType = "", + TypeVersion = "", + UpdateTime = 1234L, + UpdatedBy = "", + Version = 1234L, + LastModifiedTS = "", + AttributeDefs = {default}, + }}, + TermTemplateDefs = {new TermTemplateDef + { + Category = TypeCategory.Primitive, + CreateTime = 1234L, + CreatedBy = "", + DateFormatter = default, + Description = "", + Guid = "", + Name = "", + Options = + { + ["key"] = "" + }, + ServiceType = "", + TypeVersion = "", + UpdateTime = 1234L, + UpdatedBy = "", + Version = 1234L, + LastModifiedTS = "", + AttributeDefs = {default}, + }}, +}; +Response response = await client.BatchDeleteAsync(typesDef); +]]> + + + +This sample shows how to call BatchDelete. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +AtlasTypesDef typesDef = new AtlasTypesDef(); +Response response = client.BatchDelete(typesDef); +]]> +This sample shows how to call BatchDelete with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +AtlasTypesDef typesDef = new AtlasTypesDef +{ + BusinessMetadataDefs = {new AtlasBusinessMetadataDef + { + Category = TypeCategory.Primitive, + CreateTime = 1234L, + CreatedBy = "", + DateFormatter = new DateFormat + { + AvailableLocales = {""}, + Calendar = 123.45F, + DateInstance = default, + DateTimeInstance = default, + Instance = default, + Lenient = true, + NumberFormat = new NumberFormat + { + AvailableLocales = {""}, + Currency = "", + CurrencyInstance = default, + GroupingUsed = true, + Instance = default, + IntegerInstance = default, + MaximumFractionDigits = 1234, + MaximumIntegerDigits = 1234, + MinimumFractionDigits = 1234, + MinimumIntegerDigits = 1234, + NumberInstance = default, + ParseIntegerOnly = true, + PercentInstance = default, + RoundingMode = RoundingMode.Up, + }, + TimeInstance = default, + TimeZone = new TimeZone + { + DstSavings = 1234, + Id = "", + AvailableIds = {""}, + Default = default, + DisplayName = "", + RawOffset = 1234, + }, + }, + Description = "", + Guid = "", + Name = "", + Options = + { + ["key"] = "" + }, + ServiceType = "", + TypeVersion = "", + UpdateTime = 1234L, + UpdatedBy = "", + Version = 1234L, + LastModifiedTS = "", + AttributeDefs = {new AtlasAttributeDef + { + Cardinality = CardinalityValue.Single, + Constraints = {new AtlasConstraintDef + { + Params = + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }, + Type = "", + }}, + DefaultValue = "", + Description = "", + IncludeInNotification = true, + IsIndexable = true, + IsOptional = true, + IsUnique = true, + Name = "", + Options = + { + ["key"] = "" + }, + TypeName = "", + ValuesMaxCount = 1234, + ValuesMinCount = 1234, + }}, + }}, + ClassificationDefs = {new AtlasClassificationDef + { + Category = TypeCategory.Primitive, + CreateTime = 1234L, + CreatedBy = "", + DateFormatter = default, + Description = "", + Guid = "", + Name = "", + Options = + { + ["key"] = "" + }, + ServiceType = "", + TypeVersion = "", + UpdateTime = 1234L, + UpdatedBy = "", + Version = 1234L, + LastModifiedTS = "", + AttributeDefs = {default}, + EntityTypes = {""}, + SubTypes = {""}, + SuperTypes = {""}, + }}, + EntityDefs = {new AtlasEntityDef + { + Category = TypeCategory.Primitive, + CreateTime = 1234L, + CreatedBy = "", + DateFormatter = default, + Description = "", + Guid = "", + Name = "", + Options = + { + ["key"] = "" + }, + ServiceType = "", + TypeVersion = "", + UpdateTime = 1234L, + UpdatedBy = "", + Version = 1234L, + LastModifiedTS = "", + AttributeDefs = {default}, + SubTypes = {""}, + SuperTypes = {""}, + RelationshipAttributeDefs = {new AtlasRelationshipAttributeDef + { + Cardinality = CardinalityValue.Single, + Constraints = {default}, + DefaultValue = "", + Description = "", + IncludeInNotification = true, + IsIndexable = true, + IsOptional = true, + IsUnique = true, + Name = "", + Options = + { + ["key"] = "" + }, + TypeName = "", + ValuesMaxCount = 1234, + ValuesMinCount = 1234, + IsLegacyAttribute = true, + RelationshipTypeName = "", + }}, + }}, + EnumDefs = {new AtlasEnumDef + { + Category = TypeCategory.Primitive, + CreateTime = 1234L, + CreatedBy = "", + DateFormatter = default, + Description = "", + Guid = "", + Name = "", + Options = + { + ["key"] = "" + }, + ServiceType = "", + TypeVersion = "", + UpdateTime = 1234L, + UpdatedBy = "", + Version = 1234L, + LastModifiedTS = "", + DefaultValue = "", + ElementDefs = {new AtlasEnumElementDef + { + Description = "", + Ordinal = 1234, + Value = "", + }}, + }}, + RelationshipDefs = {new AtlasRelationshipDef + { + Category = TypeCategory.Primitive, + CreateTime = 1234L, + CreatedBy = "", + DateFormatter = default, + Description = "", + Guid = "", + Name = "", + Options = + { + ["key"] = "" + }, + ServiceType = "", + TypeVersion = "", + UpdateTime = 1234L, + UpdatedBy = "", + Version = 1234L, + LastModifiedTS = "", + AttributeDefs = {default}, + EndDef1 = new AtlasRelationshipEndDef + { + Cardinality = CardinalityValue.Single, + Description = "", + IsContainer = true, + IsLegacyAttribute = true, + Name = "", + Type = "", + }, + EndDef2 = default, + RelationshipCategory = RelationshipCategory.Association, + RelationshipLabel = "", + }}, + StructDefs = {new AtlasStructDef + { + Category = TypeCategory.Primitive, + CreateTime = 1234L, + CreatedBy = "", + DateFormatter = default, + Description = "", + Guid = "", + Name = "", + Options = + { + ["key"] = "" + }, + ServiceType = "", + TypeVersion = "", + UpdateTime = 1234L, + UpdatedBy = "", + Version = 1234L, + LastModifiedTS = "", + AttributeDefs = {default}, + }}, + TermTemplateDefs = {new TermTemplateDef + { + Category = TypeCategory.Primitive, + CreateTime = 1234L, + CreatedBy = "", + DateFormatter = default, + Description = "", + Guid = "", + Name = "", + Options = + { + ["key"] = "" + }, + ServiceType = "", + TypeVersion = "", + UpdateTime = 1234L, + UpdatedBy = "", + Version = 1234L, + LastModifiedTS = "", + AttributeDefs = {default}, + }}, +}; +Response response = client.BatchDelete(typesDef); +]]> + + + +This sample shows how to call BatchDeleteAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object()); +Response response = await client.BatchDeleteAsync(content); + +Console.WriteLine(response.Status); +]]> +This sample shows how to call BatchDeleteAsync with all request content. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new +{ + businessMetadataDefs = new object[] + { + new + { + category = "PRIMITIVE", + createTime = 1234L, + createdBy = "", + dateFormatter = new + { + availableLocales = new object[] + { + "" + }, + calendar = 123.45F, + lenient = true, + numberFormat = new + { + availableLocales = new object[] + { + "" + }, + currency = "", + groupingUsed = true, + maximumFractionDigits = 1234, + maximumIntegerDigits = 1234, + minimumFractionDigits = 1234, + minimumIntegerDigits = 1234, + parseIntegerOnly = true, + roundingMode = "UP", + }, + timeZone = new Dictionary + { + ["dstSavings"] = 1234, + ["id"] = "", + ["availableIds"] = new object[] + { + "" + }, + ["default"] = null, + ["displayName"] = "", + ["rawOffset"] = 1234 + }, + }, + description = "", + guid = "", + name = "", + options = new + { + key = "", + }, + serviceType = "", + typeVersion = "", + updateTime = 1234L, + updatedBy = "", + version = 1234L, + lastModifiedTS = "", + attributeDefs = new object[] + { + new + { + cardinality = "SINGLE", + constraints = new object[] + { + new Dictionary + { + ["params"] = new + { + key = new object(), + }, + ["type"] = "" + } + }, + defaultValue = "", + description = "", + includeInNotification = true, + isIndexable = true, + isOptional = true, + isUnique = true, + name = "", + options = new + { + key = "", + }, + typeName = "", + valuesMaxCount = 1234, + valuesMinCount = 1234, + } + }, + } + }, + classificationDefs = new object[] + { + new + { + category = "PRIMITIVE", + createTime = 1234L, + createdBy = "", + description = "", + guid = "", + name = "", + options = new + { + key = "", + }, + serviceType = "", + typeVersion = "", + updateTime = 1234L, + updatedBy = "", + version = 1234L, + lastModifiedTS = "", + attributeDefs = new object[] + { + null + }, + entityTypes = new object[] + { + "" + }, + subTypes = new object[] + { + "" + }, + superTypes = new object[] + { + "" + }, + } + }, + entityDefs = new object[] + { + new + { + category = "PRIMITIVE", + createTime = 1234L, + createdBy = "", + description = "", + guid = "", + name = "", + options = new + { + key = "", + }, + serviceType = "", + typeVersion = "", + updateTime = 1234L, + updatedBy = "", + version = 1234L, + lastModifiedTS = "", + attributeDefs = new object[] + { + null + }, + subTypes = new object[] + { + "" + }, + superTypes = new object[] + { + "" + }, + relationshipAttributeDefs = new object[] + { + new + { + cardinality = "SINGLE", + constraints = new object[] + { + null + }, + defaultValue = "", + description = "", + includeInNotification = true, + isIndexable = true, + isOptional = true, + isUnique = true, + name = "", + options = new + { + key = "", + }, + typeName = "", + valuesMaxCount = 1234, + valuesMinCount = 1234, + isLegacyAttribute = true, + relationshipTypeName = "", + } + }, + } + }, + enumDefs = new object[] + { + new + { + category = "PRIMITIVE", + createTime = 1234L, + createdBy = "", + description = "", + guid = "", + name = "", + options = new + { + key = "", + }, + serviceType = "", + typeVersion = "", + updateTime = 1234L, + updatedBy = "", + version = 1234L, + lastModifiedTS = "", + defaultValue = "", + elementDefs = new object[] + { + new + { + description = "", + ordinal = 1234, + value = "", + } + }, + } + }, + relationshipDefs = new object[] + { + new + { + category = "PRIMITIVE", + createTime = 1234L, + createdBy = "", + description = "", + guid = "", + name = "", + options = new + { + key = "", + }, + serviceType = "", + typeVersion = "", + updateTime = 1234L, + updatedBy = "", + version = 1234L, + lastModifiedTS = "", + attributeDefs = new object[] + { + null + }, + endDef1 = new + { + cardinality = "SINGLE", + description = "", + isContainer = true, + isLegacyAttribute = true, + name = "", + type = "", + }, + relationshipCategory = "ASSOCIATION", + relationshipLabel = "", + } + }, + structDefs = new object[] + { + new + { + category = "PRIMITIVE", + createTime = 1234L, + createdBy = "", + description = "", + guid = "", + name = "", + options = new + { + key = "", + }, + serviceType = "", + typeVersion = "", + updateTime = 1234L, + updatedBy = "", + version = 1234L, + lastModifiedTS = "", + attributeDefs = new object[] + { + null + }, + } + }, + termTemplateDefs = new object[] + { + new + { + category = "PRIMITIVE", + createTime = 1234L, + createdBy = "", + description = "", + guid = "", + name = "", + options = new + { + key = "", + }, + serviceType = "", + typeVersion = "", + updateTime = 1234L, + updatedBy = "", + version = 1234L, + lastModifiedTS = "", + attributeDefs = new object[] + { + null + }, + } + }, +}); +Response response = await client.BatchDeleteAsync(content); + +Console.WriteLine(response.Status); +]]> + + + +This sample shows how to call BatchDelete. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new object()); +Response response = client.BatchDelete(content); + +Console.WriteLine(response.Status); +]]> +This sample shows how to call BatchDelete with all request content. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +using RequestContent content = RequestContent.Create(new +{ + businessMetadataDefs = new object[] + { + new + { + category = "PRIMITIVE", + createTime = 1234L, + createdBy = "", + dateFormatter = new + { + availableLocales = new object[] + { + "" + }, + calendar = 123.45F, + lenient = true, + numberFormat = new + { + availableLocales = new object[] + { + "" + }, + currency = "", + groupingUsed = true, + maximumFractionDigits = 1234, + maximumIntegerDigits = 1234, + minimumFractionDigits = 1234, + minimumIntegerDigits = 1234, + parseIntegerOnly = true, + roundingMode = "UP", + }, + timeZone = new Dictionary + { + ["dstSavings"] = 1234, + ["id"] = "", + ["availableIds"] = new object[] + { + "" + }, + ["default"] = null, + ["displayName"] = "", + ["rawOffset"] = 1234 + }, + }, + description = "", + guid = "", + name = "", + options = new + { + key = "", + }, + serviceType = "", + typeVersion = "", + updateTime = 1234L, + updatedBy = "", + version = 1234L, + lastModifiedTS = "", + attributeDefs = new object[] + { + new + { + cardinality = "SINGLE", + constraints = new object[] + { + new Dictionary + { + ["params"] = new + { + key = new object(), + }, + ["type"] = "" + } + }, + defaultValue = "", + description = "", + includeInNotification = true, + isIndexable = true, + isOptional = true, + isUnique = true, + name = "", + options = new + { + key = "", + }, + typeName = "", + valuesMaxCount = 1234, + valuesMinCount = 1234, + } + }, + } + }, + classificationDefs = new object[] + { + new + { + category = "PRIMITIVE", + createTime = 1234L, + createdBy = "", + description = "", + guid = "", + name = "", + options = new + { + key = "", + }, + serviceType = "", + typeVersion = "", + updateTime = 1234L, + updatedBy = "", + version = 1234L, + lastModifiedTS = "", + attributeDefs = new object[] + { + null + }, + entityTypes = new object[] + { + "" + }, + subTypes = new object[] + { + "" + }, + superTypes = new object[] + { + "" + }, + } + }, + entityDefs = new object[] + { + new + { + category = "PRIMITIVE", + createTime = 1234L, + createdBy = "", + description = "", + guid = "", + name = "", + options = new + { + key = "", + }, + serviceType = "", + typeVersion = "", + updateTime = 1234L, + updatedBy = "", + version = 1234L, + lastModifiedTS = "", + attributeDefs = new object[] + { + null + }, + subTypes = new object[] + { + "" + }, + superTypes = new object[] + { + "" + }, + relationshipAttributeDefs = new object[] + { + new + { + cardinality = "SINGLE", + constraints = new object[] + { + null + }, + defaultValue = "", + description = "", + includeInNotification = true, + isIndexable = true, + isOptional = true, + isUnique = true, + name = "", + options = new + { + key = "", + }, + typeName = "", + valuesMaxCount = 1234, + valuesMinCount = 1234, + isLegacyAttribute = true, + relationshipTypeName = "", + } + }, + } + }, + enumDefs = new object[] + { + new + { + category = "PRIMITIVE", + createTime = 1234L, + createdBy = "", + description = "", + guid = "", + name = "", + options = new + { + key = "", + }, + serviceType = "", + typeVersion = "", + updateTime = 1234L, + updatedBy = "", + version = 1234L, + lastModifiedTS = "", + defaultValue = "", + elementDefs = new object[] + { + new + { + description = "", + ordinal = 1234, + value = "", + } + }, + } + }, + relationshipDefs = new object[] + { + new + { + category = "PRIMITIVE", + createTime = 1234L, + createdBy = "", + description = "", + guid = "", + name = "", + options = new + { + key = "", + }, + serviceType = "", + typeVersion = "", + updateTime = 1234L, + updatedBy = "", + version = 1234L, + lastModifiedTS = "", + attributeDefs = new object[] + { + null + }, + endDef1 = new + { + cardinality = "SINGLE", + description = "", + isContainer = true, + isLegacyAttribute = true, + name = "", + type = "", + }, + relationshipCategory = "ASSOCIATION", + relationshipLabel = "", + } + }, + structDefs = new object[] + { + new + { + category = "PRIMITIVE", + createTime = 1234L, + createdBy = "", + description = "", + guid = "", + name = "", + options = new + { + key = "", + }, + serviceType = "", + typeVersion = "", + updateTime = 1234L, + updatedBy = "", + version = 1234L, + lastModifiedTS = "", + attributeDefs = new object[] + { + null + }, + } + }, + termTemplateDefs = new object[] + { + new + { + category = "PRIMITIVE", + createTime = 1234L, + createdBy = "", + description = "", + guid = "", + name = "", + options = new + { + key = "", + }, + serviceType = "", + typeVersion = "", + updateTime = 1234L, + updatedBy = "", + version = 1234L, + lastModifiedTS = "", + attributeDefs = new object[] + { + null + }, + } + }, +}); +Response response = client.BatchDelete(content); + +Console.WriteLine(response.Status); +]]> + + + +This sample shows how to call GetHeadersAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response> response = await client.GetHeadersAsync(); +]]> +This sample shows how to call GetHeadersAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response> response = await client.GetHeadersAsync(includeTermTemplate: true, type: TypeDef.Enum); +]]> + + + +This sample shows how to call GetHeaders. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response> response = client.GetHeaders(); +]]> +This sample shows how to call GetHeaders with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response> response = client.GetHeaders(includeTermTemplate: true, type: TypeDef.Enum); +]]> + + + +This sample shows how to call GetHeadersAsync and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = await client.GetHeadersAsync(null, null, null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result[0].ToString()); +]]> +This sample shows how to call GetHeadersAsync with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = await client.GetHeadersAsync(true, "enum", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result[0].GetProperty("category").ToString()); +Console.WriteLine(result[0].GetProperty("guid").ToString()); +Console.WriteLine(result[0].GetProperty("name").ToString()); +]]> + + + +This sample shows how to call GetHeaders and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = client.GetHeaders(null, null, null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result[0].ToString()); +]]> +This sample shows how to call GetHeaders with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = client.GetHeaders(true, "enum", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result[0].GetProperty("category").ToString()); +Console.WriteLine(result[0].GetProperty("guid").ToString()); +Console.WriteLine(result[0].GetProperty("name").ToString()); +]]> + + + +This sample shows how to call GetTermTemplateByIdAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = await client.GetTermTemplateByIdAsync(""); +]]> +This sample shows how to call GetTermTemplateByIdAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = await client.GetTermTemplateByIdAsync(""); +]]> + + + +This sample shows how to call GetTermTemplateById. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = client.GetTermTemplateById(""); +]]> +This sample shows how to call GetTermTemplateById with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = client.GetTermTemplateById(""); +]]> + + + +This sample shows how to call GetTermTemplateByIdAsync and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = await client.GetTermTemplateByIdAsync("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call GetTermTemplateByIdAsync with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = await client.GetTermTemplateByIdAsync("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("valuesMinCount").ToString()); +]]> + + + +This sample shows how to call GetTermTemplateById and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = client.GetTermTemplateById("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call GetTermTemplateById with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = client.GetTermTemplateById("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("valuesMinCount").ToString()); +]]> + + + +This sample shows how to call GetTermTemplateByNameAsync. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = await client.GetTermTemplateByNameAsync(""); +]]> +This sample shows how to call GetTermTemplateByNameAsync with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = await client.GetTermTemplateByNameAsync(""); +]]> + + + +This sample shows how to call GetTermTemplateByName. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = client.GetTermTemplateByName(""); +]]> +This sample shows how to call GetTermTemplateByName with all parameters. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = client.GetTermTemplateByName(""); +]]> + + + +This sample shows how to call GetTermTemplateByNameAsync and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = await client.GetTermTemplateByNameAsync("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call GetTermTemplateByNameAsync with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = await client.GetTermTemplateByNameAsync("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("valuesMinCount").ToString()); +]]> + + + +This sample shows how to call GetTermTemplateByName and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = client.GetTermTemplateByName("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.ToString()); +]]> +This sample shows how to call GetTermTemplateByName with all parameters and parse the result. +"); +TokenCredential credential = new DefaultAzureCredential(); +TypeDefinition client = new DataMapClient(endpoint, credential).GetTypeDefinitionClient(apiVersion: "2023-09-01"); + +Response response = client.GetTermTemplateByName("", null); + +JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; +Console.WriteLine(result.GetProperty("category").ToString()); +Console.WriteLine(result.GetProperty("createTime").ToString()); +Console.WriteLine(result.GetProperty("createdBy").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("calendar").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("lenient").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("availableLocales")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("currency").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("groupingUsed").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("maximumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumFractionDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("minimumIntegerDigits").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("parseIntegerOnly").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("numberFormat").GetProperty("roundingMode").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("dstSavings").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("id").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("availableIds")[0].ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("displayName").ToString()); +Console.WriteLine(result.GetProperty("dateFormatter").GetProperty("timeZone").GetProperty("rawOffset").ToString()); +Console.WriteLine(result.GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("guid").ToString()); +Console.WriteLine(result.GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("serviceType").ToString()); +Console.WriteLine(result.GetProperty("typeVersion").ToString()); +Console.WriteLine(result.GetProperty("updateTime").ToString()); +Console.WriteLine(result.GetProperty("updatedBy").ToString()); +Console.WriteLine(result.GetProperty("version").ToString()); +Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("cardinality").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("params").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("constraints")[0].GetProperty("type").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("defaultValue").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("description").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("includeInNotification").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isIndexable").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isOptional").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("isUnique").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("name").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("options").GetProperty("").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("typeName").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("valuesMaxCount").ToString()); +Console.WriteLine(result.GetProperty("attributeDefs")[0].GetProperty("valuesMinCount").ToString()); +]]> + + + \ No newline at end of file diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/DomainIdFilter.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/DomainIdFilter.Serialization.cs new file mode 100644 index 0000000000000..cbfe1d9638025 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/DomainIdFilter.Serialization.cs @@ -0,0 +1,33 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class DomainIdFilter : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + writer.WritePropertyName("domainId"u8); + writer.WriteStringValue(DomainId); + writer.WritePropertyName("kind"u8); + writer.WriteStringValue(Kind); + writer.WriteEndObject(); + } + + /// Convert into a Utf8JsonRequestContent. + internal override RequestContent ToRequestContent() + { + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(this); + return content; + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/DomainIdFilter.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/DomainIdFilter.cs new file mode 100644 index 0000000000000..78d652fcabc54 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/DomainIdFilter.cs @@ -0,0 +1,38 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + /// Domain id filter for search. + public partial class DomainIdFilter : SearchFilter + { + /// Initializes a new instance of . + /// Domain id. + /// is null. + public DomainIdFilter(string domainId) + { + Argument.AssertNotNull(domainId, nameof(domainId)); + + Kind = "DomainIdFilter"; + DomainId = domainId; + } + + /// Initializes a new instance of . + /// Discriminator. + /// Domain id. + internal DomainIdFilter(string kind, string domainId) : base(kind) + { + DomainId = domainId; + } + + /// Domain id. + public string DomainId { get; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/Entity.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/Entity.cs new file mode 100644 index 0000000000000..8d78573611239 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/Entity.cs @@ -0,0 +1,5526 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Collections.Generic; +using System.Text.Json; +using System.Threading; +using System.Threading.Tasks; +using Azure; +using Azure.Core; +using Azure.Core.Pipeline; + +namespace Azure.Analytics.Purview.DataMap +{ + // Data plane generated sub-client. + /// The Entity sub-client. + public partial class Entity + { + private static readonly string[] AuthorizationScopes = new string[] { "https://purview.azure.net/.default" }; + private readonly TokenCredential _tokenCredential; + private readonly HttpPipeline _pipeline; + private readonly Uri _endpoint; + private readonly string _apiVersion; + + /// The ClientDiagnostics is used to provide tracing support for the client library. + internal ClientDiagnostics ClientDiagnostics { get; } + + /// The HTTP pipeline for sending and receiving REST requests and responses. + public virtual HttpPipeline Pipeline => _pipeline; + + /// Initializes a new instance of Entity for mocking. + protected Entity() + { + } + + /// Initializes a new instance of Entity. + /// The handler for diagnostic messaging in the client. + /// The HTTP pipeline for sending and receiving REST requests and responses. + /// The token credential to copy. + /// The to use. + /// The to use. + internal Entity(ClientDiagnostics clientDiagnostics, HttpPipeline pipeline, TokenCredential tokenCredential, Uri endpoint, string apiVersion) + { + ClientDiagnostics = clientDiagnostics; + _pipeline = pipeline; + _tokenCredential = tokenCredential; + _endpoint = endpoint; + _apiVersion = apiVersion; + } + + /// + /// Create or update an entity. + /// Existing entity is matched using its unique guid if + /// supplied or by its unique attributes eg: qualifiedName. + /// Map and array of + /// collections are not well supported. E.g., array<array<int>>, array<map<string, + /// int>>. + /// For each contact type, the maximum number of contacts is 20. + /// + /// Atlas entity with extended information. + /// + /// Used to define the update behavior for business attributes when updating + /// entities. + /// + /// + /// The collection where entities will be moved to. Only specify a value if you + /// need to move an entity to another collection. + /// + /// The cancellation token to use. + /// is null. + /// + public virtual async Task> CreateOrUpdateAsync(AtlasEntityWithExtInfo entity, BusinessAttributeUpdateBehavior? businessAttributeUpdateBehavior = null, string collectionId = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNull(entity, nameof(entity)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = entity.ToRequestContent(); + Response response = await CreateOrUpdateAsync(content, businessAttributeUpdateBehavior?.ToString(), collectionId, context).ConfigureAwait(false); + return Response.FromValue(EntityMutationResult.FromResponse(response), response); + } + + /// + /// Create or update an entity. + /// Existing entity is matched using its unique guid if + /// supplied or by its unique attributes eg: qualifiedName. + /// Map and array of + /// collections are not well supported. E.g., array<array<int>>, array<map<string, + /// int>>. + /// For each contact type, the maximum number of contacts is 20. + /// + /// Atlas entity with extended information. + /// + /// Used to define the update behavior for business attributes when updating + /// entities. + /// + /// + /// The collection where entities will be moved to. Only specify a value if you + /// need to move an entity to another collection. + /// + /// The cancellation token to use. + /// is null. + /// + public virtual Response CreateOrUpdate(AtlasEntityWithExtInfo entity, BusinessAttributeUpdateBehavior? businessAttributeUpdateBehavior = null, string collectionId = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNull(entity, nameof(entity)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = entity.ToRequestContent(); + Response response = CreateOrUpdate(content, businessAttributeUpdateBehavior?.ToString(), collectionId, context); + return Response.FromValue(EntityMutationResult.FromResponse(response), response); + } + + /// + /// [Protocol Method] Create or update an entity. + /// Existing entity is matched using its unique guid if + /// supplied or by its unique attributes eg: qualifiedName. + /// Map and array of + /// collections are not well supported. E.g., array<array<int>>, array<map<string, + /// int>>. + /// For each contact type, the maximum number of contacts is 20. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The content to send as the body of the request. + /// + /// Used to define the update behavior for business attributes when updating + /// entities. Allowed values: "ignore" | "replace" | "merge" + /// + /// + /// The collection where entities will be moved to. Only specify a value if you + /// need to move an entity to another collection. + /// + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task CreateOrUpdateAsync(RequestContent content, string businessAttributeUpdateBehavior = null, string collectionId = null, RequestContext context = null) + { + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Entity.CreateOrUpdate"); + scope.Start(); + try + { + using HttpMessage message = CreateCreateOrUpdateRequest(content, businessAttributeUpdateBehavior, collectionId, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Create or update an entity. + /// Existing entity is matched using its unique guid if + /// supplied or by its unique attributes eg: qualifiedName. + /// Map and array of + /// collections are not well supported. E.g., array<array<int>>, array<map<string, + /// int>>. + /// For each contact type, the maximum number of contacts is 20. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The content to send as the body of the request. + /// + /// Used to define the update behavior for business attributes when updating + /// entities. Allowed values: "ignore" | "replace" | "merge" + /// + /// + /// The collection where entities will be moved to. Only specify a value if you + /// need to move an entity to another collection. + /// + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response CreateOrUpdate(RequestContent content, string businessAttributeUpdateBehavior = null, string collectionId = null, RequestContext context = null) + { + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Entity.CreateOrUpdate"); + scope.Start(); + try + { + using HttpMessage message = CreateCreateOrUpdateRequest(content, businessAttributeUpdateBehavior, collectionId, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// List entities in bulk identified by its GUIDs. + /// An array of GUIDs of entities to list. + /// Whether to return minimal information for referred entities. + /// Whether to ignore relationship attributes. + /// The cancellation token to use. + /// is null. + /// + public virtual async Task> GetByIdsAsync(IEnumerable guid, bool? minExtInfo = null, bool? ignoreRelationships = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNull(guid, nameof(guid)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = await GetByIdsAsync(guid, minExtInfo, ignoreRelationships, context).ConfigureAwait(false); + return Response.FromValue(AtlasEntitiesWithExtInfo.FromResponse(response), response); + } + + /// List entities in bulk identified by its GUIDs. + /// An array of GUIDs of entities to list. + /// Whether to return minimal information for referred entities. + /// Whether to ignore relationship attributes. + /// The cancellation token to use. + /// is null. + /// + public virtual Response GetByIds(IEnumerable guid, bool? minExtInfo = null, bool? ignoreRelationships = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNull(guid, nameof(guid)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = GetByIds(guid, minExtInfo, ignoreRelationships, context); + return Response.FromValue(AtlasEntitiesWithExtInfo.FromResponse(response), response); + } + + /// + /// [Protocol Method] List entities in bulk identified by its GUIDs. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// An array of GUIDs of entities to list. + /// Whether to return minimal information for referred entities. + /// Whether to ignore relationship attributes. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task GetByIdsAsync(IEnumerable guid, bool? minExtInfo, bool? ignoreRelationships, RequestContext context) + { + Argument.AssertNotNull(guid, nameof(guid)); + + using var scope = ClientDiagnostics.CreateScope("Entity.GetByIds"); + scope.Start(); + try + { + using HttpMessage message = CreateGetByIdsRequest(guid, minExtInfo, ignoreRelationships, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] List entities in bulk identified by its GUIDs. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// An array of GUIDs of entities to list. + /// Whether to return minimal information for referred entities. + /// Whether to ignore relationship attributes. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response GetByIds(IEnumerable guid, bool? minExtInfo, bool? ignoreRelationships, RequestContext context) + { + Argument.AssertNotNull(guid, nameof(guid)); + + using var scope = ClientDiagnostics.CreateScope("Entity.GetByIds"); + scope.Start(); + try + { + using HttpMessage message = CreateGetByIdsRequest(guid, minExtInfo, ignoreRelationships, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// Create or update entities in bulk. + /// Existing entity is matched using its unique + /// guid if supplied or by its unique attributes eg: qualifiedName. + /// Map and array + /// of collections are not well supported. E.g., array<array<int>>, + /// array<map<string, int>>. + /// For each contact type, the maximum number of contacts + /// is 20. + /// + /// An array of entities to create or update. + /// + /// The collection where entities will be moved to. Only specify a value if you + /// need to move an entity to another collection. + /// + /// + /// Used to define the update behavior for business attributes when updating + /// entities. + /// + /// The cancellation token to use. + /// is null. + /// + public virtual async Task> BatchCreateOrUpdateAsync(AtlasEntitiesWithExtInfo entities, string collectionId = null, BusinessAttributeUpdateBehavior? businessAttributeUpdateBehavior = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNull(entities, nameof(entities)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = entities.ToRequestContent(); + Response response = await BatchCreateOrUpdateAsync(content, collectionId, businessAttributeUpdateBehavior?.ToString(), context).ConfigureAwait(false); + return Response.FromValue(EntityMutationResult.FromResponse(response), response); + } + + /// + /// Create or update entities in bulk. + /// Existing entity is matched using its unique + /// guid if supplied or by its unique attributes eg: qualifiedName. + /// Map and array + /// of collections are not well supported. E.g., array<array<int>>, + /// array<map<string, int>>. + /// For each contact type, the maximum number of contacts + /// is 20. + /// + /// An array of entities to create or update. + /// + /// The collection where entities will be moved to. Only specify a value if you + /// need to move an entity to another collection. + /// + /// + /// Used to define the update behavior for business attributes when updating + /// entities. + /// + /// The cancellation token to use. + /// is null. + /// + public virtual Response BatchCreateOrUpdate(AtlasEntitiesWithExtInfo entities, string collectionId = null, BusinessAttributeUpdateBehavior? businessAttributeUpdateBehavior = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNull(entities, nameof(entities)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = entities.ToRequestContent(); + Response response = BatchCreateOrUpdate(content, collectionId, businessAttributeUpdateBehavior?.ToString(), context); + return Response.FromValue(EntityMutationResult.FromResponse(response), response); + } + + /// + /// [Protocol Method] Create or update entities in bulk. + /// Existing entity is matched using its unique + /// guid if supplied or by its unique attributes eg: qualifiedName. + /// Map and array + /// of collections are not well supported. E.g., array<array<int>>, + /// array<map<string, int>>. + /// For each contact type, the maximum number of contacts + /// is 20. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The content to send as the body of the request. + /// + /// The collection where entities will be moved to. Only specify a value if you + /// need to move an entity to another collection. + /// + /// + /// Used to define the update behavior for business attributes when updating + /// entities. Allowed values: "ignore" | "replace" | "merge" + /// + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task BatchCreateOrUpdateAsync(RequestContent content, string collectionId = null, string businessAttributeUpdateBehavior = null, RequestContext context = null) + { + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Entity.BatchCreateOrUpdate"); + scope.Start(); + try + { + using HttpMessage message = CreateBatchCreateOrUpdateRequest(content, collectionId, businessAttributeUpdateBehavior, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Create or update entities in bulk. + /// Existing entity is matched using its unique + /// guid if supplied or by its unique attributes eg: qualifiedName. + /// Map and array + /// of collections are not well supported. E.g., array<array<int>>, + /// array<map<string, int>>. + /// For each contact type, the maximum number of contacts + /// is 20. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The content to send as the body of the request. + /// + /// The collection where entities will be moved to. Only specify a value if you + /// need to move an entity to another collection. + /// + /// + /// Used to define the update behavior for business attributes when updating + /// entities. Allowed values: "ignore" | "replace" | "merge" + /// + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response BatchCreateOrUpdate(RequestContent content, string collectionId = null, string businessAttributeUpdateBehavior = null, RequestContext context = null) + { + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Entity.BatchCreateOrUpdate"); + scope.Start(); + try + { + using HttpMessage message = CreateBatchCreateOrUpdateRequest(content, collectionId, businessAttributeUpdateBehavior, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// Delete a list of entities in bulk identified by their GUIDs or unique + /// attributes. + /// + /// An array of GUIDs of entities to delete. + /// The cancellation token to use. + /// is null. + /// + public virtual async Task> BatchDeleteAsync(IEnumerable guid, CancellationToken cancellationToken = default) + { + Argument.AssertNotNull(guid, nameof(guid)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = await BatchDeleteAsync(guid, context).ConfigureAwait(false); + return Response.FromValue(EntityMutationResult.FromResponse(response), response); + } + + /// + /// Delete a list of entities in bulk identified by their GUIDs or unique + /// attributes. + /// + /// An array of GUIDs of entities to delete. + /// The cancellation token to use. + /// is null. + /// + public virtual Response BatchDelete(IEnumerable guid, CancellationToken cancellationToken = default) + { + Argument.AssertNotNull(guid, nameof(guid)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = BatchDelete(guid, context); + return Response.FromValue(EntityMutationResult.FromResponse(response), response); + } + + /// + /// [Protocol Method] Delete a list of entities in bulk identified by their GUIDs or unique + /// attributes. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// An array of GUIDs of entities to delete. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task BatchDeleteAsync(IEnumerable guid, RequestContext context) + { + Argument.AssertNotNull(guid, nameof(guid)); + + using var scope = ClientDiagnostics.CreateScope("Entity.BatchDelete"); + scope.Start(); + try + { + using HttpMessage message = CreateBatchDeleteRequest(guid, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Delete a list of entities in bulk identified by their GUIDs or unique + /// attributes. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// An array of GUIDs of entities to delete. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response BatchDelete(IEnumerable guid, RequestContext context) + { + Argument.AssertNotNull(guid, nameof(guid)); + + using var scope = ClientDiagnostics.CreateScope("Entity.BatchDelete"); + scope.Start(); + try + { + using HttpMessage message = CreateBatchDeleteRequest(guid, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Associate a classification to multiple entities in bulk. + /// The request to associate a classification to multiple entities. + /// The cancellation token to use. + /// is null. + /// + public virtual async Task AddClassificationAsync(ClassificationAssociateOptions request, CancellationToken cancellationToken = default) + { + Argument.AssertNotNull(request, nameof(request)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = request.ToRequestContent(); + Response response = await AddClassificationAsync(content, context).ConfigureAwait(false); + return response; + } + + /// Associate a classification to multiple entities in bulk. + /// The request to associate a classification to multiple entities. + /// The cancellation token to use. + /// is null. + /// + public virtual Response AddClassification(ClassificationAssociateOptions request, CancellationToken cancellationToken = default) + { + Argument.AssertNotNull(request, nameof(request)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = request.ToRequestContent(); + Response response = AddClassification(content, context); + return response; + } + + /// + /// [Protocol Method] Associate a classification to multiple entities in bulk. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The content to send as the body of the request. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task AddClassificationAsync(RequestContent content, RequestContext context = null) + { + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Entity.AddClassification"); + scope.Start(); + try + { + using HttpMessage message = CreateAddClassificationRequest(content, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Associate a classification to multiple entities in bulk. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The content to send as the body of the request. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response AddClassification(RequestContent content, RequestContext context = null) + { + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Entity.AddClassification"); + scope.Start(); + try + { + using HttpMessage message = CreateAddClassificationRequest(content, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Get complete definition of an entity given its GUID. + /// The globally unique identifier of the entity. + /// Whether to return minimal information for referred entities. + /// Whether to ignore relationship attributes. + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual async Task> GetEntityAsync(string guid, bool? minExtInfo = null, bool? ignoreRelationships = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = await GetEntityAsync(guid, minExtInfo, ignoreRelationships, context).ConfigureAwait(false); + return Response.FromValue(AtlasEntityWithExtInfo.FromResponse(response), response); + } + + /// Get complete definition of an entity given its GUID. + /// The globally unique identifier of the entity. + /// Whether to return minimal information for referred entities. + /// Whether to ignore relationship attributes. + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual Response GetEntity(string guid, bool? minExtInfo = null, bool? ignoreRelationships = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = GetEntity(guid, minExtInfo, ignoreRelationships, context); + return Response.FromValue(AtlasEntityWithExtInfo.FromResponse(response), response); + } + + /// + /// [Protocol Method] Get complete definition of an entity given its GUID. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier of the entity. + /// Whether to return minimal information for referred entities. + /// Whether to ignore relationship attributes. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task GetEntityAsync(string guid, bool? minExtInfo, bool? ignoreRelationships, RequestContext context) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + + using var scope = ClientDiagnostics.CreateScope("Entity.GetEntity"); + scope.Start(); + try + { + using HttpMessage message = CreateGetEntityRequest(guid, minExtInfo, ignoreRelationships, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Get complete definition of an entity given its GUID. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier of the entity. + /// Whether to return minimal information for referred entities. + /// Whether to ignore relationship attributes. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response GetEntity(string guid, bool? minExtInfo, bool? ignoreRelationships, RequestContext context) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + + using var scope = ClientDiagnostics.CreateScope("Entity.GetEntity"); + scope.Start(); + try + { + using HttpMessage message = CreateGetEntityRequest(guid, minExtInfo, ignoreRelationships, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// Update entity partially - create or update entity attribute identified by its + /// GUID. + /// Supports only primitive attribute type and entity references. + /// It does not support updating complex types like arrays, and maps. + /// Null updates are not possible. + /// + /// The globally unique identifier of the entity. + /// The name of the attribute. + /// The value of the attribute. + /// The cancellation token to use. + /// , or is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual async Task> PartialUpdateAttributeByIdAsync(string guid, string name, BinaryData body, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + Argument.AssertNotNull(name, nameof(name)); + Argument.AssertNotNull(body, nameof(body)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = RequestContentHelper.FromObject(body); + Response response = await PartialUpdateAttributeByIdAsync(guid, name, content, context).ConfigureAwait(false); + return Response.FromValue(EntityMutationResult.FromResponse(response), response); + } + + /// + /// Update entity partially - create or update entity attribute identified by its + /// GUID. + /// Supports only primitive attribute type and entity references. + /// It does not support updating complex types like arrays, and maps. + /// Null updates are not possible. + /// + /// The globally unique identifier of the entity. + /// The name of the attribute. + /// The value of the attribute. + /// The cancellation token to use. + /// , or is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual Response PartialUpdateAttributeById(string guid, string name, BinaryData body, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + Argument.AssertNotNull(name, nameof(name)); + Argument.AssertNotNull(body, nameof(body)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = RequestContentHelper.FromObject(body); + Response response = PartialUpdateAttributeById(guid, name, content, context); + return Response.FromValue(EntityMutationResult.FromResponse(response), response); + } + + /// + /// [Protocol Method] Update entity partially - create or update entity attribute identified by its + /// GUID. + /// Supports only primitive attribute type and entity references. + /// It does not support updating complex types like arrays, and maps. + /// Null updates are not possible. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier of the entity. + /// The name of the attribute. + /// The content to send as the body of the request. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// , or is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task PartialUpdateAttributeByIdAsync(string guid, string name, RequestContent content, RequestContext context = null) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + Argument.AssertNotNull(name, nameof(name)); + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Entity.PartialUpdateAttributeById"); + scope.Start(); + try + { + using HttpMessage message = CreatePartialUpdateAttributeByIdRequest(guid, name, content, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Update entity partially - create or update entity attribute identified by its + /// GUID. + /// Supports only primitive attribute type and entity references. + /// It does not support updating complex types like arrays, and maps. + /// Null updates are not possible. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier of the entity. + /// The name of the attribute. + /// The content to send as the body of the request. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// , or is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response PartialUpdateAttributeById(string guid, string name, RequestContent content, RequestContext context = null) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + Argument.AssertNotNull(name, nameof(name)); + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Entity.PartialUpdateAttributeById"); + scope.Start(); + try + { + using HttpMessage message = CreatePartialUpdateAttributeByIdRequest(guid, name, content, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Delete an entity identified by its GUID. + /// The globally unique identifier of the entity. + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual async Task> DeleteAsync(string guid, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = await DeleteAsync(guid, context).ConfigureAwait(false); + return Response.FromValue(EntityMutationResult.FromResponse(response), response); + } + + /// Delete an entity identified by its GUID. + /// The globally unique identifier of the entity. + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual Response Delete(string guid, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = Delete(guid, context); + return Response.FromValue(EntityMutationResult.FromResponse(response), response); + } + + /// + /// [Protocol Method] Delete an entity identified by its GUID. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier of the entity. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task DeleteAsync(string guid, RequestContext context) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + + using var scope = ClientDiagnostics.CreateScope("Entity.Delete"); + scope.Start(); + try + { + using HttpMessage message = CreateDeleteRequest(guid, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Delete an entity identified by its GUID. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier of the entity. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response Delete(string guid, RequestContext context) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + + using var scope = ClientDiagnostics.CreateScope("Entity.Delete"); + scope.Start(); + try + { + using HttpMessage message = CreateDeleteRequest(guid, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Get classification for a given entity represented by a GUID. + /// The globally unique identifier of the entity. + /// The name of the classification. + /// The cancellation token to use. + /// or is null. + /// or is an empty string, and was expected to be non-empty. + /// + public virtual async Task> GetClassificationAsync(string guid, string classificationName, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + Argument.AssertNotNullOrEmpty(classificationName, nameof(classificationName)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = await GetClassificationAsync(guid, classificationName, context).ConfigureAwait(false); + return Response.FromValue(AtlasClassification.FromResponse(response), response); + } + + /// Get classification for a given entity represented by a GUID. + /// The globally unique identifier of the entity. + /// The name of the classification. + /// The cancellation token to use. + /// or is null. + /// or is an empty string, and was expected to be non-empty. + /// + public virtual Response GetClassification(string guid, string classificationName, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + Argument.AssertNotNullOrEmpty(classificationName, nameof(classificationName)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = GetClassification(guid, classificationName, context); + return Response.FromValue(AtlasClassification.FromResponse(response), response); + } + + /// + /// [Protocol Method] Get classification for a given entity represented by a GUID. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier of the entity. + /// The name of the classification. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// or is null. + /// or is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task GetClassificationAsync(string guid, string classificationName, RequestContext context) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + Argument.AssertNotNullOrEmpty(classificationName, nameof(classificationName)); + + using var scope = ClientDiagnostics.CreateScope("Entity.GetClassification"); + scope.Start(); + try + { + using HttpMessage message = CreateGetClassificationRequest(guid, classificationName, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Get classification for a given entity represented by a GUID. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier of the entity. + /// The name of the classification. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// or is null. + /// or is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response GetClassification(string guid, string classificationName, RequestContext context) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + Argument.AssertNotNullOrEmpty(classificationName, nameof(classificationName)); + + using var scope = ClientDiagnostics.CreateScope("Entity.GetClassification"); + scope.Start(); + try + { + using HttpMessage message = CreateGetClassificationRequest(guid, classificationName, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + // The convenience method is omitted here because it has exactly the same parameter list as the corresponding protocol method + /// + /// [Protocol Method] Delete a given classification from an existing entity represented by a GUID. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// The globally unique identifier of the entity. + /// The name of the classification. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// or is null. + /// or is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task RemoveClassificationAsync(string guid, string classificationName, RequestContext context = null) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + Argument.AssertNotNullOrEmpty(classificationName, nameof(classificationName)); + + using var scope = ClientDiagnostics.CreateScope("Entity.RemoveClassification"); + scope.Start(); + try + { + using HttpMessage message = CreateRemoveClassificationRequest(guid, classificationName, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + // The convenience method is omitted here because it has exactly the same parameter list as the corresponding protocol method + /// + /// [Protocol Method] Delete a given classification from an existing entity represented by a GUID. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// The globally unique identifier of the entity. + /// The name of the classification. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// or is null. + /// or is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response RemoveClassification(string guid, string classificationName, RequestContext context = null) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + Argument.AssertNotNullOrEmpty(classificationName, nameof(classificationName)); + + using var scope = ClientDiagnostics.CreateScope("Entity.RemoveClassification"); + scope.Start(); + try + { + using HttpMessage message = CreateRemoveClassificationRequest(guid, classificationName, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// List classifications for a given entity represented by a GUID. + /// The globally unique identifier of the entity. + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual async Task> GetClassificationsAsync(string guid, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = await GetClassificationsAsync(guid, context).ConfigureAwait(false); + return Response.FromValue(AtlasClassifications.FromResponse(response), response); + } + + /// List classifications for a given entity represented by a GUID. + /// The globally unique identifier of the entity. + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual Response GetClassifications(string guid, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = GetClassifications(guid, context); + return Response.FromValue(AtlasClassifications.FromResponse(response), response); + } + + /// + /// [Protocol Method] List classifications for a given entity represented by a GUID. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier of the entity. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task GetClassificationsAsync(string guid, RequestContext context) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + + using var scope = ClientDiagnostics.CreateScope("Entity.GetClassifications"); + scope.Start(); + try + { + using HttpMessage message = CreateGetClassificationsRequest(guid, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] List classifications for a given entity represented by a GUID. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier of the entity. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response GetClassifications(string guid, RequestContext context) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + + using var scope = ClientDiagnostics.CreateScope("Entity.GetClassifications"); + scope.Start(); + try + { + using HttpMessage message = CreateGetClassificationsRequest(guid, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Add classifications to an existing entity represented by a GUID. + /// The globally unique identifier of the entity. + /// An array of classifications to be added. + /// The cancellation token to use. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual async Task AddClassificationsAsync(string guid, IEnumerable classifications, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + Argument.AssertNotNull(classifications, nameof(classifications)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = RequestContentHelper.FromEnumerable(classifications); + Response response = await AddClassificationsAsync(guid, content, context).ConfigureAwait(false); + return response; + } + + /// Add classifications to an existing entity represented by a GUID. + /// The globally unique identifier of the entity. + /// An array of classifications to be added. + /// The cancellation token to use. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual Response AddClassifications(string guid, IEnumerable classifications, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + Argument.AssertNotNull(classifications, nameof(classifications)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = RequestContentHelper.FromEnumerable(classifications); + Response response = AddClassifications(guid, content, context); + return response; + } + + /// + /// [Protocol Method] Add classifications to an existing entity represented by a GUID. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier of the entity. + /// The content to send as the body of the request. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task AddClassificationsAsync(string guid, RequestContent content, RequestContext context = null) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Entity.AddClassifications"); + scope.Start(); + try + { + using HttpMessage message = CreateAddClassificationsRequest(guid, content, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Add classifications to an existing entity represented by a GUID. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier of the entity. + /// The content to send as the body of the request. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response AddClassifications(string guid, RequestContent content, RequestContext context = null) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Entity.AddClassifications"); + scope.Start(); + try + { + using HttpMessage message = CreateAddClassificationsRequest(guid, content, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Update classifications to an existing entity represented by a guid. + /// The globally unique identifier of the entity. + /// An array of classifications to be updated. + /// The cancellation token to use. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual async Task UpdateClassificationsAsync(string guid, IEnumerable classifications, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + Argument.AssertNotNull(classifications, nameof(classifications)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = RequestContentHelper.FromEnumerable(classifications); + Response response = await UpdateClassificationsAsync(guid, content, context).ConfigureAwait(false); + return response; + } + + /// Update classifications to an existing entity represented by a guid. + /// The globally unique identifier of the entity. + /// An array of classifications to be updated. + /// The cancellation token to use. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual Response UpdateClassifications(string guid, IEnumerable classifications, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + Argument.AssertNotNull(classifications, nameof(classifications)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = RequestContentHelper.FromEnumerable(classifications); + Response response = UpdateClassifications(guid, content, context); + return response; + } + + /// + /// [Protocol Method] Update classifications to an existing entity represented by a guid. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier of the entity. + /// The content to send as the body of the request. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task UpdateClassificationsAsync(string guid, RequestContent content, RequestContext context = null) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Entity.UpdateClassifications"); + scope.Start(); + try + { + using HttpMessage message = CreateUpdateClassificationsRequest(guid, content, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Update classifications to an existing entity represented by a guid. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier of the entity. + /// The content to send as the body of the request. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response UpdateClassifications(string guid, RequestContent content, RequestContext context = null) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Entity.UpdateClassifications"); + scope.Start(); + try + { + using HttpMessage message = CreateUpdateClassificationsRequest(guid, content, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// Get complete definition of an entity given its type and unique attribute. + /// + /// In + /// addition to the typeName path parameter, attribute key-value pair(s) can be + /// provided in the following format: + /// attr:\<attrName>=<attrValue>. + /// + /// NOTE: The + /// attrName and attrValue should be unique across entities, eg. + /// qualifiedName. + /// + /// The REST request would look something like this: + /// GET + /// /v2/entity/uniqueAttribute/type/aType?attr:aTypeAttribute=someValue. + /// + /// The name of the type. + /// Whether to return minimal information for referred entities. + /// Whether to ignore relationship attributes. + /// + /// The qualified name of the entity. (This is only an example. qualifiedName can + /// be changed to other unique attributes) + /// + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual async Task> GetByAttributesAsync(string typeName, bool? minExtInfo = null, bool? ignoreRelationships = null, string attr = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(typeName, nameof(typeName)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = await GetByAttributesAsync(typeName, minExtInfo, ignoreRelationships, attr, context).ConfigureAwait(false); + return Response.FromValue(AtlasEntityWithExtInfo.FromResponse(response), response); + } + + /// + /// Get complete definition of an entity given its type and unique attribute. + /// + /// In + /// addition to the typeName path parameter, attribute key-value pair(s) can be + /// provided in the following format: + /// attr:\<attrName>=<attrValue>. + /// + /// NOTE: The + /// attrName and attrValue should be unique across entities, eg. + /// qualifiedName. + /// + /// The REST request would look something like this: + /// GET + /// /v2/entity/uniqueAttribute/type/aType?attr:aTypeAttribute=someValue. + /// + /// The name of the type. + /// Whether to return minimal information for referred entities. + /// Whether to ignore relationship attributes. + /// + /// The qualified name of the entity. (This is only an example. qualifiedName can + /// be changed to other unique attributes) + /// + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual Response GetByAttributes(string typeName, bool? minExtInfo = null, bool? ignoreRelationships = null, string attr = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(typeName, nameof(typeName)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = GetByAttributes(typeName, minExtInfo, ignoreRelationships, attr, context); + return Response.FromValue(AtlasEntityWithExtInfo.FromResponse(response), response); + } + + /// + /// [Protocol Method] Get complete definition of an entity given its type and unique attribute. + /// + /// In + /// addition to the typeName path parameter, attribute key-value pair(s) can be + /// provided in the following format: + /// attr:\<attrName>=<attrValue>. + /// + /// NOTE: The + /// attrName and attrValue should be unique across entities, eg. + /// qualifiedName. + /// + /// The REST request would look something like this: + /// GET + /// /v2/entity/uniqueAttribute/type/aType?attr:aTypeAttribute=someValue. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The name of the type. + /// Whether to return minimal information for referred entities. + /// Whether to ignore relationship attributes. + /// + /// The qualified name of the entity. (This is only an example. qualifiedName can + /// be changed to other unique attributes) + /// + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task GetByAttributesAsync(string typeName, bool? minExtInfo, bool? ignoreRelationships, string attr, RequestContext context) + { + Argument.AssertNotNullOrEmpty(typeName, nameof(typeName)); + + using var scope = ClientDiagnostics.CreateScope("Entity.GetByAttributes"); + scope.Start(); + try + { + using HttpMessage message = CreateGetByAttributesRequest(typeName, minExtInfo, ignoreRelationships, attr, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Get complete definition of an entity given its type and unique attribute. + /// + /// In + /// addition to the typeName path parameter, attribute key-value pair(s) can be + /// provided in the following format: + /// attr:\<attrName>=<attrValue>. + /// + /// NOTE: The + /// attrName and attrValue should be unique across entities, eg. + /// qualifiedName. + /// + /// The REST request would look something like this: + /// GET + /// /v2/entity/uniqueAttribute/type/aType?attr:aTypeAttribute=someValue. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The name of the type. + /// Whether to return minimal information for referred entities. + /// Whether to ignore relationship attributes. + /// + /// The qualified name of the entity. (This is only an example. qualifiedName can + /// be changed to other unique attributes) + /// + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response GetByAttributes(string typeName, bool? minExtInfo, bool? ignoreRelationships, string attr, RequestContext context) + { + Argument.AssertNotNullOrEmpty(typeName, nameof(typeName)); + + using var scope = ClientDiagnostics.CreateScope("Entity.GetByAttributes"); + scope.Start(); + try + { + using HttpMessage message = CreateGetByAttributesRequest(typeName, minExtInfo, ignoreRelationships, attr, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// Update entity partially - Allow a subset of attributes to be updated on an + /// entity which is identified by its type and unique attribute eg: + /// Referenceable.qualifiedName. Null updates are not possible. + /// + /// In addition to the + /// typeName path parameter, attribute key-value pair(s) can be provided in the + /// following format: + /// + /// attr:<attrName>=<attrValue>. + /// NOTE: The attrName and + /// attrValue should be unique across entities, eg. qualifiedName. + /// + /// The REST + /// request would look something like this: + /// PUT + /// /v2/entity/uniqueAttribute/type/aType?attr:aTypeAttribute=someValue. + /// + /// The name of the type. + /// Atlas entity with extended information. + /// + /// The qualified name of the entity. (This is only an example. qualifiedName can + /// be changed to other unique attributes) + /// + /// The cancellation token to use. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual async Task> PartialUpdateByAttributesAsync(string typeName, AtlasEntityWithExtInfo atlasEntityWithExtInfo, string attr = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(typeName, nameof(typeName)); + Argument.AssertNotNull(atlasEntityWithExtInfo, nameof(atlasEntityWithExtInfo)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = atlasEntityWithExtInfo.ToRequestContent(); + Response response = await PartialUpdateByAttributesAsync(typeName, content, attr, context).ConfigureAwait(false); + return Response.FromValue(EntityMutationResult.FromResponse(response), response); + } + + /// + /// Update entity partially - Allow a subset of attributes to be updated on an + /// entity which is identified by its type and unique attribute eg: + /// Referenceable.qualifiedName. Null updates are not possible. + /// + /// In addition to the + /// typeName path parameter, attribute key-value pair(s) can be provided in the + /// following format: + /// + /// attr:<attrName>=<attrValue>. + /// NOTE: The attrName and + /// attrValue should be unique across entities, eg. qualifiedName. + /// + /// The REST + /// request would look something like this: + /// PUT + /// /v2/entity/uniqueAttribute/type/aType?attr:aTypeAttribute=someValue. + /// + /// The name of the type. + /// Atlas entity with extended information. + /// + /// The qualified name of the entity. (This is only an example. qualifiedName can + /// be changed to other unique attributes) + /// + /// The cancellation token to use. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual Response PartialUpdateByAttributes(string typeName, AtlasEntityWithExtInfo atlasEntityWithExtInfo, string attr = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(typeName, nameof(typeName)); + Argument.AssertNotNull(atlasEntityWithExtInfo, nameof(atlasEntityWithExtInfo)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = atlasEntityWithExtInfo.ToRequestContent(); + Response response = PartialUpdateByAttributes(typeName, content, attr, context); + return Response.FromValue(EntityMutationResult.FromResponse(response), response); + } + + /// + /// [Protocol Method] Update entity partially - Allow a subset of attributes to be updated on an + /// entity which is identified by its type and unique attribute eg: + /// Referenceable.qualifiedName. Null updates are not possible. + /// + /// In addition to the + /// typeName path parameter, attribute key-value pair(s) can be provided in the + /// following format: + /// + /// attr:<attrName>=<attrValue>. + /// NOTE: The attrName and + /// attrValue should be unique across entities, eg. qualifiedName. + /// + /// The REST + /// request would look something like this: + /// PUT + /// /v2/entity/uniqueAttribute/type/aType?attr:aTypeAttribute=someValue. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The name of the type. + /// The content to send as the body of the request. + /// + /// The qualified name of the entity. (This is only an example. qualifiedName can + /// be changed to other unique attributes) + /// + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task PartialUpdateByAttributesAsync(string typeName, RequestContent content, string attr = null, RequestContext context = null) + { + Argument.AssertNotNullOrEmpty(typeName, nameof(typeName)); + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Entity.PartialUpdateByAttributes"); + scope.Start(); + try + { + using HttpMessage message = CreatePartialUpdateByAttributesRequest(typeName, content, attr, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Update entity partially - Allow a subset of attributes to be updated on an + /// entity which is identified by its type and unique attribute eg: + /// Referenceable.qualifiedName. Null updates are not possible. + /// + /// In addition to the + /// typeName path parameter, attribute key-value pair(s) can be provided in the + /// following format: + /// + /// attr:<attrName>=<attrValue>. + /// NOTE: The attrName and + /// attrValue should be unique across entities, eg. qualifiedName. + /// + /// The REST + /// request would look something like this: + /// PUT + /// /v2/entity/uniqueAttribute/type/aType?attr:aTypeAttribute=someValue. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The name of the type. + /// The content to send as the body of the request. + /// + /// The qualified name of the entity. (This is only an example. qualifiedName can + /// be changed to other unique attributes) + /// + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response PartialUpdateByAttributes(string typeName, RequestContent content, string attr = null, RequestContext context = null) + { + Argument.AssertNotNullOrEmpty(typeName, nameof(typeName)); + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Entity.PartialUpdateByAttributes"); + scope.Start(); + try + { + using HttpMessage message = CreatePartialUpdateByAttributesRequest(typeName, content, attr, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// Delete an entity identified by its type and unique attributes. + /// In addition to + /// the typeName path parameter, attribute key-value pair(s) can be provided in the + /// following format: + /// attr:\<attrName>=\<attrValue>. + /// NOTE: The attrName and + /// attrValue should be unique across entities, eg. qualifiedName. + /// + /// The REST + /// request would look something like this: + /// DELETE + /// /v2/entity/uniqueAttribute/type/aType?attr:aTypeAttribute=someValue. + /// + /// The name of the type. + /// + /// The qualified name of the entity. (This is only an example. qualifiedName can + /// be changed to other unique attributes) + /// + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual async Task> DeleteByAttributeAsync(string typeName, string attr = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(typeName, nameof(typeName)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = await DeleteByAttributeAsync(typeName, attr, context).ConfigureAwait(false); + return Response.FromValue(EntityMutationResult.FromResponse(response), response); + } + + /// + /// Delete an entity identified by its type and unique attributes. + /// In addition to + /// the typeName path parameter, attribute key-value pair(s) can be provided in the + /// following format: + /// attr:\<attrName>=\<attrValue>. + /// NOTE: The attrName and + /// attrValue should be unique across entities, eg. qualifiedName. + /// + /// The REST + /// request would look something like this: + /// DELETE + /// /v2/entity/uniqueAttribute/type/aType?attr:aTypeAttribute=someValue. + /// + /// The name of the type. + /// + /// The qualified name of the entity. (This is only an example. qualifiedName can + /// be changed to other unique attributes) + /// + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual Response DeleteByAttribute(string typeName, string attr = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(typeName, nameof(typeName)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = DeleteByAttribute(typeName, attr, context); + return Response.FromValue(EntityMutationResult.FromResponse(response), response); + } + + /// + /// [Protocol Method] Delete an entity identified by its type and unique attributes. + /// In addition to + /// the typeName path parameter, attribute key-value pair(s) can be provided in the + /// following format: + /// attr:\<attrName>=\<attrValue>. + /// NOTE: The attrName and + /// attrValue should be unique across entities, eg. qualifiedName. + /// + /// The REST + /// request would look something like this: + /// DELETE + /// /v2/entity/uniqueAttribute/type/aType?attr:aTypeAttribute=someValue. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The name of the type. + /// + /// The qualified name of the entity. (This is only an example. qualifiedName can + /// be changed to other unique attributes) + /// + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task DeleteByAttributeAsync(string typeName, string attr, RequestContext context) + { + Argument.AssertNotNullOrEmpty(typeName, nameof(typeName)); + + using var scope = ClientDiagnostics.CreateScope("Entity.DeleteByAttribute"); + scope.Start(); + try + { + using HttpMessage message = CreateDeleteByAttributeRequest(typeName, attr, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Delete an entity identified by its type and unique attributes. + /// In addition to + /// the typeName path parameter, attribute key-value pair(s) can be provided in the + /// following format: + /// attr:\<attrName>=\<attrValue>. + /// NOTE: The attrName and + /// attrValue should be unique across entities, eg. qualifiedName. + /// + /// The REST + /// request would look something like this: + /// DELETE + /// /v2/entity/uniqueAttribute/type/aType?attr:aTypeAttribute=someValue. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The name of the type. + /// + /// The qualified name of the entity. (This is only an example. qualifiedName can + /// be changed to other unique attributes) + /// + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response DeleteByAttribute(string typeName, string attr, RequestContext context) + { + Argument.AssertNotNullOrEmpty(typeName, nameof(typeName)); + + using var scope = ClientDiagnostics.CreateScope("Entity.DeleteByAttribute"); + scope.Start(); + try + { + using HttpMessage message = CreateDeleteByAttributeRequest(typeName, attr, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + // The convenience method is omitted here because it has exactly the same parameter list as the corresponding protocol method + /// + /// [Protocol Method] Delete a given classification from an entity identified by its type and unique + /// attributes. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// The name of the type. + /// The name of the classification. + /// + /// The qualified name of the entity. (This is only an example. qualifiedName can + /// be changed to other unique attributes) + /// + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// or is null. + /// or is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task RemoveClassificationByAttributeAsync(string typeName, string classificationName, string attr = null, RequestContext context = null) + { + Argument.AssertNotNullOrEmpty(typeName, nameof(typeName)); + Argument.AssertNotNullOrEmpty(classificationName, nameof(classificationName)); + + using var scope = ClientDiagnostics.CreateScope("Entity.RemoveClassificationByAttribute"); + scope.Start(); + try + { + using HttpMessage message = CreateRemoveClassificationByAttributeRequest(typeName, classificationName, attr, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + // The convenience method is omitted here because it has exactly the same parameter list as the corresponding protocol method + /// + /// [Protocol Method] Delete a given classification from an entity identified by its type and unique + /// attributes. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// The name of the type. + /// The name of the classification. + /// + /// The qualified name of the entity. (This is only an example. qualifiedName can + /// be changed to other unique attributes) + /// + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// or is null. + /// or is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response RemoveClassificationByAttribute(string typeName, string classificationName, string attr = null, RequestContext context = null) + { + Argument.AssertNotNullOrEmpty(typeName, nameof(typeName)); + Argument.AssertNotNullOrEmpty(classificationName, nameof(classificationName)); + + using var scope = ClientDiagnostics.CreateScope("Entity.RemoveClassificationByAttribute"); + scope.Start(); + try + { + using HttpMessage message = CreateRemoveClassificationByAttributeRequest(typeName, classificationName, attr, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Add classification to the entity identified by its type and unique attributes. + /// The name of the type. + /// An array of classification to be added. + /// + /// The qualified name of the entity. (This is only an example. qualifiedName can + /// be changed to other unique attributes) + /// + /// The cancellation token to use. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual async Task AddClassificationsByAttributeAsync(string typeName, IEnumerable classifications, string attr = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(typeName, nameof(typeName)); + Argument.AssertNotNull(classifications, nameof(classifications)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = RequestContentHelper.FromEnumerable(classifications); + Response response = await AddClassificationsByAttributeAsync(typeName, content, attr, context).ConfigureAwait(false); + return response; + } + + /// Add classification to the entity identified by its type and unique attributes. + /// The name of the type. + /// An array of classification to be added. + /// + /// The qualified name of the entity. (This is only an example. qualifiedName can + /// be changed to other unique attributes) + /// + /// The cancellation token to use. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual Response AddClassificationsByAttribute(string typeName, IEnumerable classifications, string attr = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(typeName, nameof(typeName)); + Argument.AssertNotNull(classifications, nameof(classifications)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = RequestContentHelper.FromEnumerable(classifications); + Response response = AddClassificationsByAttribute(typeName, content, attr, context); + return response; + } + + /// + /// [Protocol Method] Add classification to the entity identified by its type and unique attributes. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The name of the type. + /// The content to send as the body of the request. + /// + /// The qualified name of the entity. (This is only an example. qualifiedName can + /// be changed to other unique attributes) + /// + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task AddClassificationsByAttributeAsync(string typeName, RequestContent content, string attr = null, RequestContext context = null) + { + Argument.AssertNotNullOrEmpty(typeName, nameof(typeName)); + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Entity.AddClassificationsByAttribute"); + scope.Start(); + try + { + using HttpMessage message = CreateAddClassificationsByAttributeRequest(typeName, content, attr, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Add classification to the entity identified by its type and unique attributes. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The name of the type. + /// The content to send as the body of the request. + /// + /// The qualified name of the entity. (This is only an example. qualifiedName can + /// be changed to other unique attributes) + /// + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response AddClassificationsByAttribute(string typeName, RequestContent content, string attr = null, RequestContext context = null) + { + Argument.AssertNotNullOrEmpty(typeName, nameof(typeName)); + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Entity.AddClassificationsByAttribute"); + scope.Start(); + try + { + using HttpMessage message = CreateAddClassificationsByAttributeRequest(typeName, content, attr, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Update classification on an entity identified by its type and unique attributes. + /// The name of the type. + /// An array of classification to be updated. + /// + /// The qualified name of the entity. (This is only an example. qualifiedName can + /// be changed to other unique attributes) + /// + /// The cancellation token to use. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual async Task UpdateClassificationsByAttributeAsync(string typeName, IEnumerable atlasClassificationArray, string attr = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(typeName, nameof(typeName)); + Argument.AssertNotNull(atlasClassificationArray, nameof(atlasClassificationArray)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = RequestContentHelper.FromEnumerable(atlasClassificationArray); + Response response = await UpdateClassificationsByAttributeAsync(typeName, content, attr, context).ConfigureAwait(false); + return response; + } + + /// Update classification on an entity identified by its type and unique attributes. + /// The name of the type. + /// An array of classification to be updated. + /// + /// The qualified name of the entity. (This is only an example. qualifiedName can + /// be changed to other unique attributes) + /// + /// The cancellation token to use. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual Response UpdateClassificationsByAttribute(string typeName, IEnumerable atlasClassificationArray, string attr = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(typeName, nameof(typeName)); + Argument.AssertNotNull(atlasClassificationArray, nameof(atlasClassificationArray)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = RequestContentHelper.FromEnumerable(atlasClassificationArray); + Response response = UpdateClassificationsByAttribute(typeName, content, attr, context); + return response; + } + + /// + /// [Protocol Method] Update classification on an entity identified by its type and unique attributes. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The name of the type. + /// The content to send as the body of the request. + /// + /// The qualified name of the entity. (This is only an example. qualifiedName can + /// be changed to other unique attributes) + /// + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task UpdateClassificationsByAttributeAsync(string typeName, RequestContent content, string attr = null, RequestContext context = null) + { + Argument.AssertNotNullOrEmpty(typeName, nameof(typeName)); + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Entity.UpdateClassificationsByAttribute"); + scope.Start(); + try + { + using HttpMessage message = CreateUpdateClassificationsByAttributeRequest(typeName, content, attr, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Update classification on an entity identified by its type and unique attributes. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The name of the type. + /// The content to send as the body of the request. + /// + /// The qualified name of the entity. (This is only an example. qualifiedName can + /// be changed to other unique attributes) + /// + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response UpdateClassificationsByAttribute(string typeName, RequestContent content, string attr = null, RequestContext context = null) + { + Argument.AssertNotNullOrEmpty(typeName, nameof(typeName)); + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Entity.UpdateClassificationsByAttribute"); + scope.Start(); + try + { + using HttpMessage message = CreateUpdateClassificationsByAttributeRequest(typeName, content, attr, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Set classifications on entities in bulk. + /// Atlas entity headers. + /// The cancellation token to use. + /// is null. + /// + public virtual async Task>> BatchSetClassificationsAsync(AtlasEntityHeaders entityHeaders, CancellationToken cancellationToken = default) + { + Argument.AssertNotNull(entityHeaders, nameof(entityHeaders)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = entityHeaders.ToRequestContent(); + Response response = await BatchSetClassificationsAsync(content, context).ConfigureAwait(false); + IReadOnlyList value = default; + using var document = await JsonDocument.ParseAsync(response.ContentStream, default, cancellationToken).ConfigureAwait(false); + List array = new List(); + foreach (var item in document.RootElement.EnumerateArray()) + { + array.Add(item.GetString()); + } + value = array; + return Response.FromValue(value, response); + } + + /// Set classifications on entities in bulk. + /// Atlas entity headers. + /// The cancellation token to use. + /// is null. + /// + public virtual Response> BatchSetClassifications(AtlasEntityHeaders entityHeaders, CancellationToken cancellationToken = default) + { + Argument.AssertNotNull(entityHeaders, nameof(entityHeaders)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = entityHeaders.ToRequestContent(); + Response response = BatchSetClassifications(content, context); + IReadOnlyList value = default; + using var document = JsonDocument.Parse(response.ContentStream); + List array = new List(); + foreach (var item in document.RootElement.EnumerateArray()) + { + array.Add(item.GetString()); + } + value = array; + return Response.FromValue(value, response); + } + + /// + /// [Protocol Method] Set classifications on entities in bulk. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The content to send as the body of the request. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task BatchSetClassificationsAsync(RequestContent content, RequestContext context = null) + { + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Entity.BatchSetClassifications"); + scope.Start(); + try + { + using HttpMessage message = CreateBatchSetClassificationsRequest(content, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Set classifications on entities in bulk. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The content to send as the body of the request. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response BatchSetClassifications(RequestContent content, RequestContext context = null) + { + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Entity.BatchSetClassifications"); + scope.Start(); + try + { + using HttpMessage message = CreateBatchSetClassificationsRequest(content, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// Bulk API to retrieve list of entities identified by its unique attributes. + /// In + /// addition to the typeName path parameter, attribute key-value pair(s) can be + /// provided in the following + /// format + /// + /// typeName=\<typeName>&attr_1:\<attrName>=\<attrValue>&attr_2:\<attrName>=\<attrValue>&attr_3:\<attrName>=\<attrValue> + /// + /// NOTE: + /// The attrName should be an unique attribute for the given entity-type. + /// The REST + /// request would look something like this + /// + /// GET + /// /v2/entity/bulk/uniqueAttribute/type/hive_db?attr_1:qualifiedName=db1@cl1&attr_2:qualifiedName=db2@cl1 + /// + /// Note: + /// at least one unique attribute must be provided. + /// + /// The name of the type. + /// Whether to return minimal information for referred entities. + /// Whether to ignore relationship attributes. + /// + /// Qualified name of an entity. E.g. to find 2 entities you can set + /// attrs_1:qualifiedName=db1@cl1&attrs_2:qualifiedName=db2@cl1. (This is only an + /// example. qualifiedName can be changed to other unique attributes) + /// + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual async Task> BatchGetByAttributesAsync(string typeName, bool? minExtInfo = null, bool? ignoreRelationships = null, string attrNQualifiedName = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(typeName, nameof(typeName)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = await BatchGetByAttributesAsync(typeName, minExtInfo, ignoreRelationships, attrNQualifiedName, context).ConfigureAwait(false); + return Response.FromValue(AtlasEntitiesWithExtInfo.FromResponse(response), response); + } + + /// + /// Bulk API to retrieve list of entities identified by its unique attributes. + /// In + /// addition to the typeName path parameter, attribute key-value pair(s) can be + /// provided in the following + /// format + /// + /// typeName=\<typeName>&attr_1:\<attrName>=\<attrValue>&attr_2:\<attrName>=\<attrValue>&attr_3:\<attrName>=\<attrValue> + /// + /// NOTE: + /// The attrName should be an unique attribute for the given entity-type. + /// The REST + /// request would look something like this + /// + /// GET + /// /v2/entity/bulk/uniqueAttribute/type/hive_db?attr_1:qualifiedName=db1@cl1&attr_2:qualifiedName=db2@cl1 + /// + /// Note: + /// at least one unique attribute must be provided. + /// + /// The name of the type. + /// Whether to return minimal information for referred entities. + /// Whether to ignore relationship attributes. + /// + /// Qualified name of an entity. E.g. to find 2 entities you can set + /// attrs_1:qualifiedName=db1@cl1&attrs_2:qualifiedName=db2@cl1. (This is only an + /// example. qualifiedName can be changed to other unique attributes) + /// + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual Response BatchGetByAttributes(string typeName, bool? minExtInfo = null, bool? ignoreRelationships = null, string attrNQualifiedName = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(typeName, nameof(typeName)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = BatchGetByAttributes(typeName, minExtInfo, ignoreRelationships, attrNQualifiedName, context); + return Response.FromValue(AtlasEntitiesWithExtInfo.FromResponse(response), response); + } + + /// + /// [Protocol Method] Bulk API to retrieve list of entities identified by its unique attributes. + /// In + /// addition to the typeName path parameter, attribute key-value pair(s) can be + /// provided in the following + /// format + /// + /// typeName=\<typeName>&attr_1:\<attrName>=\<attrValue>&attr_2:\<attrName>=\<attrValue>&attr_3:\<attrName>=\<attrValue> + /// + /// NOTE: + /// The attrName should be an unique attribute for the given entity-type. + /// The REST + /// request would look something like this + /// + /// GET + /// /v2/entity/bulk/uniqueAttribute/type/hive_db?attr_1:qualifiedName=db1@cl1&attr_2:qualifiedName=db2@cl1 + /// + /// Note: + /// at least one unique attribute must be provided. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The name of the type. + /// Whether to return minimal information for referred entities. + /// Whether to ignore relationship attributes. + /// + /// Qualified name of an entity. E.g. to find 2 entities you can set + /// attrs_1:qualifiedName=db1@cl1&attrs_2:qualifiedName=db2@cl1. (This is only an + /// example. qualifiedName can be changed to other unique attributes) + /// + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task BatchGetByAttributesAsync(string typeName, bool? minExtInfo, bool? ignoreRelationships, string attrNQualifiedName, RequestContext context) + { + Argument.AssertNotNullOrEmpty(typeName, nameof(typeName)); + + using var scope = ClientDiagnostics.CreateScope("Entity.BatchGetByAttributes"); + scope.Start(); + try + { + using HttpMessage message = CreateBatchGetByAttributesRequest(typeName, minExtInfo, ignoreRelationships, attrNQualifiedName, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Bulk API to retrieve list of entities identified by its unique attributes. + /// In + /// addition to the typeName path parameter, attribute key-value pair(s) can be + /// provided in the following + /// format + /// + /// typeName=\<typeName>&attr_1:\<attrName>=\<attrValue>&attr_2:\<attrName>=\<attrValue>&attr_3:\<attrName>=\<attrValue> + /// + /// NOTE: + /// The attrName should be an unique attribute for the given entity-type. + /// The REST + /// request would look something like this + /// + /// GET + /// /v2/entity/bulk/uniqueAttribute/type/hive_db?attr_1:qualifiedName=db1@cl1&attr_2:qualifiedName=db2@cl1 + /// + /// Note: + /// at least one unique attribute must be provided. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The name of the type. + /// Whether to return minimal information for referred entities. + /// Whether to ignore relationship attributes. + /// + /// Qualified name of an entity. E.g. to find 2 entities you can set + /// attrs_1:qualifiedName=db1@cl1&attrs_2:qualifiedName=db2@cl1. (This is only an + /// example. qualifiedName can be changed to other unique attributes) + /// + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response BatchGetByAttributes(string typeName, bool? minExtInfo, bool? ignoreRelationships, string attrNQualifiedName, RequestContext context) + { + Argument.AssertNotNullOrEmpty(typeName, nameof(typeName)); + + using var scope = ClientDiagnostics.CreateScope("Entity.BatchGetByAttributes"); + scope.Start(); + try + { + using HttpMessage message = CreateBatchGetByAttributesRequest(typeName, minExtInfo, ignoreRelationships, attrNQualifiedName, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Get entity header given its GUID. + /// The globally unique identifier of the entity. + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual async Task> GetHeaderAsync(string guid, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = await GetHeaderAsync(guid, context).ConfigureAwait(false); + return Response.FromValue(AtlasEntityHeader.FromResponse(response), response); + } + + /// Get entity header given its GUID. + /// The globally unique identifier of the entity. + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual Response GetHeader(string guid, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = GetHeader(guid, context); + return Response.FromValue(AtlasEntityHeader.FromResponse(response), response); + } + + /// + /// [Protocol Method] Get entity header given its GUID. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier of the entity. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task GetHeaderAsync(string guid, RequestContext context) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + + using var scope = ClientDiagnostics.CreateScope("Entity.GetHeader"); + scope.Start(); + try + { + using HttpMessage message = CreateGetHeaderRequest(guid, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Get entity header given its GUID. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier of the entity. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response GetHeader(string guid, RequestContext context) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + + using var scope = ClientDiagnostics.CreateScope("Entity.GetHeader"); + scope.Start(); + try + { + using HttpMessage message = CreateGetHeaderRequest(guid, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Remove business metadata from an entity. + /// The globally unique identifier of the entity. + /// Business metadata payload. + /// The cancellation token to use. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual async Task RemoveBusinessMetadataAsync(string guid, IDictionary> businessMetadata, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + Argument.AssertNotNull(businessMetadata, nameof(businessMetadata)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = RequestContentHelper.FromDictionary(businessMetadata); + Response response = await RemoveBusinessMetadataAsync(guid, content, context).ConfigureAwait(false); + return response; + } + + /// Remove business metadata from an entity. + /// The globally unique identifier of the entity. + /// Business metadata payload. + /// The cancellation token to use. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual Response RemoveBusinessMetadata(string guid, IDictionary> businessMetadata, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + Argument.AssertNotNull(businessMetadata, nameof(businessMetadata)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = RequestContentHelper.FromDictionary(businessMetadata); + Response response = RemoveBusinessMetadata(guid, content, context); + return response; + } + + /// + /// [Protocol Method] Remove business metadata from an entity. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier of the entity. + /// The content to send as the body of the request. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task RemoveBusinessMetadataAsync(string guid, RequestContent content, RequestContext context = null) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Entity.RemoveBusinessMetadata"); + scope.Start(); + try + { + using HttpMessage message = CreateRemoveBusinessMetadataRequest(guid, content, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Remove business metadata from an entity. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier of the entity. + /// The content to send as the body of the request. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response RemoveBusinessMetadata(string guid, RequestContent content, RequestContext context = null) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Entity.RemoveBusinessMetadata"); + scope.Start(); + try + { + using HttpMessage message = CreateRemoveBusinessMetadataRequest(guid, content, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Add business metadata to an entity. + /// The globally unique identifier of the entity. + /// BusinessMetadata payload. + /// + /// Whether to overwrite the existing business metadata on the entity or not, + /// default is false. + /// + /// The cancellation token to use. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual async Task AddOrUpdateBusinessMetadataAsync(string guid, IDictionary> businessMetadata, bool? isOverwrite = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + Argument.AssertNotNull(businessMetadata, nameof(businessMetadata)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = RequestContentHelper.FromDictionary(businessMetadata); + Response response = await AddOrUpdateBusinessMetadataAsync(guid, content, isOverwrite, context).ConfigureAwait(false); + return response; + } + + /// Add business metadata to an entity. + /// The globally unique identifier of the entity. + /// BusinessMetadata payload. + /// + /// Whether to overwrite the existing business metadata on the entity or not, + /// default is false. + /// + /// The cancellation token to use. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual Response AddOrUpdateBusinessMetadata(string guid, IDictionary> businessMetadata, bool? isOverwrite = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + Argument.AssertNotNull(businessMetadata, nameof(businessMetadata)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = RequestContentHelper.FromDictionary(businessMetadata); + Response response = AddOrUpdateBusinessMetadata(guid, content, isOverwrite, context); + return response; + } + + /// + /// [Protocol Method] Add business metadata to an entity. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier of the entity. + /// The content to send as the body of the request. + /// + /// Whether to overwrite the existing business metadata on the entity or not, + /// default is false. + /// + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task AddOrUpdateBusinessMetadataAsync(string guid, RequestContent content, bool? isOverwrite = null, RequestContext context = null) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Entity.AddOrUpdateBusinessMetadata"); + scope.Start(); + try + { + using HttpMessage message = CreateAddOrUpdateBusinessMetadataRequest(guid, content, isOverwrite, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Add business metadata to an entity. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier of the entity. + /// The content to send as the body of the request. + /// + /// Whether to overwrite the existing business metadata on the entity or not, + /// default is false. + /// + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response AddOrUpdateBusinessMetadata(string guid, RequestContent content, bool? isOverwrite = null, RequestContext context = null) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Entity.AddOrUpdateBusinessMetadata"); + scope.Start(); + try + { + using HttpMessage message = CreateAddOrUpdateBusinessMetadataRequest(guid, content, isOverwrite, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Delete business metadata attributes from an entity. + /// The globally unique identifier of the entity. + /// BusinessMetadata name. + /// Business metadata attribute payload. + /// The cancellation token to use. + /// , or is null. + /// or is an empty string, and was expected to be non-empty. + /// + public virtual async Task RemoveBusinessMetadataAttributesAsync(string guid, string businessMetadataName, IDictionary businessMetadataAttributes, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + Argument.AssertNotNullOrEmpty(businessMetadataName, nameof(businessMetadataName)); + Argument.AssertNotNull(businessMetadataAttributes, nameof(businessMetadataAttributes)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = RequestContentHelper.FromDictionary(businessMetadataAttributes); + Response response = await RemoveBusinessMetadataAttributesAsync(guid, businessMetadataName, content, context).ConfigureAwait(false); + return response; + } + + /// Delete business metadata attributes from an entity. + /// The globally unique identifier of the entity. + /// BusinessMetadata name. + /// Business metadata attribute payload. + /// The cancellation token to use. + /// , or is null. + /// or is an empty string, and was expected to be non-empty. + /// + public virtual Response RemoveBusinessMetadataAttributes(string guid, string businessMetadataName, IDictionary businessMetadataAttributes, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + Argument.AssertNotNullOrEmpty(businessMetadataName, nameof(businessMetadataName)); + Argument.AssertNotNull(businessMetadataAttributes, nameof(businessMetadataAttributes)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = RequestContentHelper.FromDictionary(businessMetadataAttributes); + Response response = RemoveBusinessMetadataAttributes(guid, businessMetadataName, content, context); + return response; + } + + /// + /// [Protocol Method] Delete business metadata attributes from an entity. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier of the entity. + /// BusinessMetadata name. + /// The content to send as the body of the request. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// , or is null. + /// or is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task RemoveBusinessMetadataAttributesAsync(string guid, string businessMetadataName, RequestContent content, RequestContext context = null) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + Argument.AssertNotNullOrEmpty(businessMetadataName, nameof(businessMetadataName)); + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Entity.RemoveBusinessMetadataAttributes"); + scope.Start(); + try + { + using HttpMessage message = CreateRemoveBusinessMetadataAttributesRequest(guid, businessMetadataName, content, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Delete business metadata attributes from an entity. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier of the entity. + /// BusinessMetadata name. + /// The content to send as the body of the request. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// , or is null. + /// or is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response RemoveBusinessMetadataAttributes(string guid, string businessMetadataName, RequestContent content, RequestContext context = null) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + Argument.AssertNotNullOrEmpty(businessMetadataName, nameof(businessMetadataName)); + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Entity.RemoveBusinessMetadataAttributes"); + scope.Start(); + try + { + using HttpMessage message = CreateRemoveBusinessMetadataAttributesRequest(guid, businessMetadataName, content, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Add or update business metadata attributes. + /// The globally unique identifier of the entity. + /// BusinessMetadata name. + /// Business metadata attribute payload. + /// The cancellation token to use. + /// , or is null. + /// or is an empty string, and was expected to be non-empty. + /// + public virtual async Task AddOrUpdateBusinessMetadataAttributesAsync(string guid, string businessMetadataName, IDictionary businessMetadataAttributes, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + Argument.AssertNotNullOrEmpty(businessMetadataName, nameof(businessMetadataName)); + Argument.AssertNotNull(businessMetadataAttributes, nameof(businessMetadataAttributes)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = RequestContentHelper.FromDictionary(businessMetadataAttributes); + Response response = await AddOrUpdateBusinessMetadataAttributesAsync(guid, businessMetadataName, content, context).ConfigureAwait(false); + return response; + } + + /// Add or update business metadata attributes. + /// The globally unique identifier of the entity. + /// BusinessMetadata name. + /// Business metadata attribute payload. + /// The cancellation token to use. + /// , or is null. + /// or is an empty string, and was expected to be non-empty. + /// + public virtual Response AddOrUpdateBusinessMetadataAttributes(string guid, string businessMetadataName, IDictionary businessMetadataAttributes, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + Argument.AssertNotNullOrEmpty(businessMetadataName, nameof(businessMetadataName)); + Argument.AssertNotNull(businessMetadataAttributes, nameof(businessMetadataAttributes)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = RequestContentHelper.FromDictionary(businessMetadataAttributes); + Response response = AddOrUpdateBusinessMetadataAttributes(guid, businessMetadataName, content, context); + return response; + } + + /// + /// [Protocol Method] Add or update business metadata attributes. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier of the entity. + /// BusinessMetadata name. + /// The content to send as the body of the request. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// , or is null. + /// or is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task AddOrUpdateBusinessMetadataAttributesAsync(string guid, string businessMetadataName, RequestContent content, RequestContext context = null) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + Argument.AssertNotNullOrEmpty(businessMetadataName, nameof(businessMetadataName)); + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Entity.AddOrUpdateBusinessMetadataAttributes"); + scope.Start(); + try + { + using HttpMessage message = CreateAddOrUpdateBusinessMetadataAttributesRequest(guid, businessMetadataName, content, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Add or update business metadata attributes. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier of the entity. + /// BusinessMetadata name. + /// The content to send as the body of the request. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// , or is null. + /// or is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response AddOrUpdateBusinessMetadataAttributes(string guid, string businessMetadataName, RequestContent content, RequestContext context = null) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + Argument.AssertNotNullOrEmpty(businessMetadataName, nameof(businessMetadataName)); + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Entity.AddOrUpdateBusinessMetadataAttributes"); + scope.Start(); + try + { + using HttpMessage message = CreateAddOrUpdateBusinessMetadataAttributesRequest(guid, businessMetadataName, content, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Get the sample Template for uploading/creating bulk BusinessMetaData. + /// The cancellation token to use. + /// + public virtual async Task> GetSampleBusinessMetadataTemplateAsync(CancellationToken cancellationToken = default) + { + RequestContext context = FromCancellationToken(cancellationToken); + Response response = await GetSampleBusinessMetadataTemplateAsync(context).ConfigureAwait(false); + return Response.FromValue(response.Content, response); + } + + /// Get the sample Template for uploading/creating bulk BusinessMetaData. + /// The cancellation token to use. + /// + public virtual Response GetSampleBusinessMetadataTemplate(CancellationToken cancellationToken = default) + { + RequestContext context = FromCancellationToken(cancellationToken); + Response response = GetSampleBusinessMetadataTemplate(context); + return Response.FromValue(response.Content, response); + } + + /// + /// [Protocol Method] Get the sample Template for uploading/creating bulk BusinessMetaData + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task GetSampleBusinessMetadataTemplateAsync(RequestContext context) + { + using var scope = ClientDiagnostics.CreateScope("Entity.GetSampleBusinessMetadataTemplate"); + scope.Start(); + try + { + using HttpMessage message = CreateGetSampleBusinessMetadataTemplateRequest(context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Get the sample Template for uploading/creating bulk BusinessMetaData + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response GetSampleBusinessMetadataTemplate(RequestContext context) + { + using var scope = ClientDiagnostics.CreateScope("Entity.GetSampleBusinessMetadataTemplate"); + scope.Start(); + try + { + using HttpMessage message = CreateGetSampleBusinessMetadataTemplateRequest(context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Upload the file for creating Business Metadata in BULK. + /// InputStream of file. + /// The cancellation token to use. + /// is null. + /// + public virtual async Task> ImportBusinessMetadataAsync(BinaryData uploadedInputStream, CancellationToken cancellationToken = default) + { + Argument.AssertNotNull(uploadedInputStream, nameof(uploadedInputStream)); + + RequestContext context = FromCancellationToken(cancellationToken); + ImportBusinessMetadataRequest importBusinessMetadataRequest = new ImportBusinessMetadataRequest(uploadedInputStream); + Response response = await ImportBusinessMetadataAsync(importBusinessMetadataRequest.ToRequestContent(), context).ConfigureAwait(false); + return Response.FromValue(BulkImportResult.FromResponse(response), response); + } + + /// Upload the file for creating Business Metadata in BULK. + /// InputStream of file. + /// The cancellation token to use. + /// is null. + /// + public virtual Response ImportBusinessMetadata(BinaryData uploadedInputStream, CancellationToken cancellationToken = default) + { + Argument.AssertNotNull(uploadedInputStream, nameof(uploadedInputStream)); + + RequestContext context = FromCancellationToken(cancellationToken); + ImportBusinessMetadataRequest importBusinessMetadataRequest = new ImportBusinessMetadataRequest(uploadedInputStream); + Response response = ImportBusinessMetadata(importBusinessMetadataRequest.ToRequestContent(), context); + return Response.FromValue(BulkImportResult.FromResponse(response), response); + } + + /// + /// [Protocol Method] Upload the file for creating Business Metadata in BULK + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The content to send as the body of the request. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task ImportBusinessMetadataAsync(RequestContent content, RequestContext context = null) + { + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Entity.ImportBusinessMetadata"); + scope.Start(); + try + { + using HttpMessage message = CreateImportBusinessMetadataRequest(content, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Upload the file for creating Business Metadata in BULK + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The content to send as the body of the request. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response ImportBusinessMetadata(RequestContent content, RequestContext context = null) + { + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Entity.ImportBusinessMetadata"); + scope.Start(); + try + { + using HttpMessage message = CreateImportBusinessMetadataRequest(content, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Delete given labels to a given entity. + /// The globally unique identifier of the entity. + /// set of labels to be deleted. + /// The cancellation token to use. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual async Task RemoveLabelsAsync(string guid, IEnumerable body, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + Argument.AssertNotNull(body, nameof(body)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = RequestContentHelper.FromEnumerable(body); + Response response = await RemoveLabelsAsync(guid, content, context).ConfigureAwait(false); + return response; + } + + /// Delete given labels to a given entity. + /// The globally unique identifier of the entity. + /// set of labels to be deleted. + /// The cancellation token to use. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual Response RemoveLabels(string guid, IEnumerable body, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + Argument.AssertNotNull(body, nameof(body)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = RequestContentHelper.FromEnumerable(body); + Response response = RemoveLabels(guid, content, context); + return response; + } + + /// + /// [Protocol Method] Delete given labels to a given entity. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier of the entity. + /// The content to send as the body of the request. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task RemoveLabelsAsync(string guid, RequestContent content, RequestContext context = null) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Entity.RemoveLabels"); + scope.Start(); + try + { + using HttpMessage message = CreateRemoveLabelsRequest(guid, content, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Delete given labels to a given entity. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier of the entity. + /// The content to send as the body of the request. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response RemoveLabels(string guid, RequestContent content, RequestContext context = null) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Entity.RemoveLabels"); + scope.Start(); + try + { + using HttpMessage message = CreateRemoveLabelsRequest(guid, content, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Set labels to a given entity. + /// The globally unique identifier of the entity. + /// set of labels to be set to the entity. + /// The cancellation token to use. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual async Task SetLabelsAsync(string guid, IEnumerable body, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + Argument.AssertNotNull(body, nameof(body)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = RequestContentHelper.FromEnumerable(body); + Response response = await SetLabelsAsync(guid, content, context).ConfigureAwait(false); + return response; + } + + /// Set labels to a given entity. + /// The globally unique identifier of the entity. + /// set of labels to be set to the entity. + /// The cancellation token to use. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual Response SetLabels(string guid, IEnumerable body, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + Argument.AssertNotNull(body, nameof(body)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = RequestContentHelper.FromEnumerable(body); + Response response = SetLabels(guid, content, context); + return response; + } + + /// + /// [Protocol Method] Set labels to a given entity. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier of the entity. + /// The content to send as the body of the request. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task SetLabelsAsync(string guid, RequestContent content, RequestContext context = null) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Entity.SetLabels"); + scope.Start(); + try + { + using HttpMessage message = CreateSetLabelsRequest(guid, content, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Set labels to a given entity. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier of the entity. + /// The content to send as the body of the request. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response SetLabels(string guid, RequestContent content, RequestContext context = null) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Entity.SetLabels"); + scope.Start(); + try + { + using HttpMessage message = CreateSetLabelsRequest(guid, content, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Add given labels to a given entity. + /// The globally unique identifier of the entity. + /// set of labels to be added. + /// The cancellation token to use. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual async Task AddLabelAsync(string guid, IEnumerable body, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + Argument.AssertNotNull(body, nameof(body)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = RequestContentHelper.FromEnumerable(body); + Response response = await AddLabelAsync(guid, content, context).ConfigureAwait(false); + return response; + } + + /// Add given labels to a given entity. + /// The globally unique identifier of the entity. + /// set of labels to be added. + /// The cancellation token to use. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual Response AddLabel(string guid, IEnumerable body, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + Argument.AssertNotNull(body, nameof(body)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = RequestContentHelper.FromEnumerable(body); + Response response = AddLabel(guid, content, context); + return response; + } + + /// + /// [Protocol Method] Add given labels to a given entity. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier of the entity. + /// The content to send as the body of the request. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task AddLabelAsync(string guid, RequestContent content, RequestContext context = null) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Entity.AddLabel"); + scope.Start(); + try + { + using HttpMessage message = CreateAddLabelRequest(guid, content, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Add given labels to a given entity. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier of the entity. + /// The content to send as the body of the request. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response AddLabel(string guid, RequestContent content, RequestContext context = null) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Entity.AddLabel"); + scope.Start(); + try + { + using HttpMessage message = CreateAddLabelRequest(guid, content, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// Delete given labels to a given entity identified by its type and unique + /// attribute. + /// + /// If labels is null/empty, no labels will be removed. + /// + /// If any labels + /// in labels set are non-existing labels, they will be ignored, only existing + /// labels will be removed. In addition to the typeName path parameter, attribute + /// key-value pair(s) can be provided in the following format: + /// attr:<attrName>=<attrValue>. NOTE: The attrName and attrValue should be unique + /// across entities, eg. qualifiedName. The REST request would look something like + /// this: DELETE + /// /v2/entity/uniqueAttribute/type/aType?attr:aTypeAttribute=someValue. + /// + /// The name of the type. + /// set of labels to be deleted. + /// + /// The qualified name of the entity. (This is only an example. qualifiedName can + /// be changed to other unique attributes) + /// + /// The cancellation token to use. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual async Task RemoveLabelsByAttributeAsync(string typeName, IEnumerable body, string attr = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(typeName, nameof(typeName)); + Argument.AssertNotNull(body, nameof(body)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = RequestContentHelper.FromEnumerable(body); + Response response = await RemoveLabelsByAttributeAsync(typeName, content, attr, context).ConfigureAwait(false); + return response; + } + + /// + /// Delete given labels to a given entity identified by its type and unique + /// attribute. + /// + /// If labels is null/empty, no labels will be removed. + /// + /// If any labels + /// in labels set are non-existing labels, they will be ignored, only existing + /// labels will be removed. In addition to the typeName path parameter, attribute + /// key-value pair(s) can be provided in the following format: + /// attr:<attrName>=<attrValue>. NOTE: The attrName and attrValue should be unique + /// across entities, eg. qualifiedName. The REST request would look something like + /// this: DELETE + /// /v2/entity/uniqueAttribute/type/aType?attr:aTypeAttribute=someValue. + /// + /// The name of the type. + /// set of labels to be deleted. + /// + /// The qualified name of the entity. (This is only an example. qualifiedName can + /// be changed to other unique attributes) + /// + /// The cancellation token to use. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual Response RemoveLabelsByAttribute(string typeName, IEnumerable body, string attr = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(typeName, nameof(typeName)); + Argument.AssertNotNull(body, nameof(body)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = RequestContentHelper.FromEnumerable(body); + Response response = RemoveLabelsByAttribute(typeName, content, attr, context); + return response; + } + + /// + /// [Protocol Method] Delete given labels to a given entity identified by its type and unique + /// attribute. + /// + /// If labels is null/empty, no labels will be removed. + /// + /// If any labels + /// in labels set are non-existing labels, they will be ignored, only existing + /// labels will be removed. In addition to the typeName path parameter, attribute + /// key-value pair(s) can be provided in the following format: + /// attr:<attrName>=<attrValue>. NOTE: The attrName and attrValue should be unique + /// across entities, eg. qualifiedName. The REST request would look something like + /// this: DELETE + /// /v2/entity/uniqueAttribute/type/aType?attr:aTypeAttribute=someValue. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The name of the type. + /// The content to send as the body of the request. + /// + /// The qualified name of the entity. (This is only an example. qualifiedName can + /// be changed to other unique attributes) + /// + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task RemoveLabelsByAttributeAsync(string typeName, RequestContent content, string attr = null, RequestContext context = null) + { + Argument.AssertNotNullOrEmpty(typeName, nameof(typeName)); + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Entity.RemoveLabelsByAttribute"); + scope.Start(); + try + { + using HttpMessage message = CreateRemoveLabelsByAttributeRequest(typeName, content, attr, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Delete given labels to a given entity identified by its type and unique + /// attribute. + /// + /// If labels is null/empty, no labels will be removed. + /// + /// If any labels + /// in labels set are non-existing labels, they will be ignored, only existing + /// labels will be removed. In addition to the typeName path parameter, attribute + /// key-value pair(s) can be provided in the following format: + /// attr:<attrName>=<attrValue>. NOTE: The attrName and attrValue should be unique + /// across entities, eg. qualifiedName. The REST request would look something like + /// this: DELETE + /// /v2/entity/uniqueAttribute/type/aType?attr:aTypeAttribute=someValue. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The name of the type. + /// The content to send as the body of the request. + /// + /// The qualified name of the entity. (This is only an example. qualifiedName can + /// be changed to other unique attributes) + /// + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response RemoveLabelsByAttribute(string typeName, RequestContent content, string attr = null, RequestContext context = null) + { + Argument.AssertNotNullOrEmpty(typeName, nameof(typeName)); + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Entity.RemoveLabelsByAttribute"); + scope.Start(); + try + { + using HttpMessage message = CreateRemoveLabelsByAttributeRequest(typeName, content, attr, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// Set labels to a given entity identified by its type and unique attributes. + /// + /// If + /// labels is null/empty, existing labels will all be removed. + /// + /// In addition to the + /// typeName path parameter, attribute key-value pair(s) can be provided in the + /// following format: attr:<attrName>=<attrValue>. + /// + /// NOTE: The attrName and + /// attrValue should be unique across entities, eg. qualifiedName. + /// + /// The REST + /// request would look something like this: POST + /// /v2/entity/uniqueAttribute/type/aType?attr:aTypeAttribute=someValue. + /// + /// The name of the type. + /// set of labels to be set. + /// + /// The qualified name of the entity. (This is only an example. qualifiedName can + /// be changed to other unique attributes) + /// + /// The cancellation token to use. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual async Task SetLabelsByAttributeAsync(string typeName, IEnumerable body, string attr = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(typeName, nameof(typeName)); + Argument.AssertNotNull(body, nameof(body)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = RequestContentHelper.FromEnumerable(body); + Response response = await SetLabelsByAttributeAsync(typeName, content, attr, context).ConfigureAwait(false); + return response; + } + + /// + /// Set labels to a given entity identified by its type and unique attributes. + /// + /// If + /// labels is null/empty, existing labels will all be removed. + /// + /// In addition to the + /// typeName path parameter, attribute key-value pair(s) can be provided in the + /// following format: attr:<attrName>=<attrValue>. + /// + /// NOTE: The attrName and + /// attrValue should be unique across entities, eg. qualifiedName. + /// + /// The REST + /// request would look something like this: POST + /// /v2/entity/uniqueAttribute/type/aType?attr:aTypeAttribute=someValue. + /// + /// The name of the type. + /// set of labels to be set. + /// + /// The qualified name of the entity. (This is only an example. qualifiedName can + /// be changed to other unique attributes) + /// + /// The cancellation token to use. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual Response SetLabelsByAttribute(string typeName, IEnumerable body, string attr = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(typeName, nameof(typeName)); + Argument.AssertNotNull(body, nameof(body)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = RequestContentHelper.FromEnumerable(body); + Response response = SetLabelsByAttribute(typeName, content, attr, context); + return response; + } + + /// + /// [Protocol Method] Set labels to a given entity identified by its type and unique attributes. + /// + /// If + /// labels is null/empty, existing labels will all be removed. + /// + /// In addition to the + /// typeName path parameter, attribute key-value pair(s) can be provided in the + /// following format: attr:<attrName>=<attrValue>. + /// + /// NOTE: The attrName and + /// attrValue should be unique across entities, eg. qualifiedName. + /// + /// The REST + /// request would look something like this: POST + /// /v2/entity/uniqueAttribute/type/aType?attr:aTypeAttribute=someValue. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The name of the type. + /// The content to send as the body of the request. + /// + /// The qualified name of the entity. (This is only an example. qualifiedName can + /// be changed to other unique attributes) + /// + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task SetLabelsByAttributeAsync(string typeName, RequestContent content, string attr = null, RequestContext context = null) + { + Argument.AssertNotNullOrEmpty(typeName, nameof(typeName)); + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Entity.SetLabelsByAttribute"); + scope.Start(); + try + { + using HttpMessage message = CreateSetLabelsByAttributeRequest(typeName, content, attr, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Set labels to a given entity identified by its type and unique attributes. + /// + /// If + /// labels is null/empty, existing labels will all be removed. + /// + /// In addition to the + /// typeName path parameter, attribute key-value pair(s) can be provided in the + /// following format: attr:<attrName>=<attrValue>. + /// + /// NOTE: The attrName and + /// attrValue should be unique across entities, eg. qualifiedName. + /// + /// The REST + /// request would look something like this: POST + /// /v2/entity/uniqueAttribute/type/aType?attr:aTypeAttribute=someValue. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The name of the type. + /// The content to send as the body of the request. + /// + /// The qualified name of the entity. (This is only an example. qualifiedName can + /// be changed to other unique attributes) + /// + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response SetLabelsByAttribute(string typeName, RequestContent content, string attr = null, RequestContext context = null) + { + Argument.AssertNotNullOrEmpty(typeName, nameof(typeName)); + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Entity.SetLabelsByAttribute"); + scope.Start(); + try + { + using HttpMessage message = CreateSetLabelsByAttributeRequest(typeName, content, attr, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// Add given labels to a given entity identified by its type and unique + /// attributes. + /// + /// If labels is null/empty, no labels will be added. + /// + /// In addition to + /// the typeName path parameter, attribute key-value pair(s) can be provided in the + /// following format: attr:<attrName>=<attrValue>. + /// + /// NOTE: The attrName and + /// attrValue should be unique across entities, eg. qualifiedName. + /// + /// The REST + /// request would look something like this: PUT + /// /v2/entity/uniqueAttribute/type/aType?attr:aTypeAttribute=someValue. + /// + /// The name of the type. + /// set of labels to be added. + /// + /// The qualified name of the entity. (This is only an example. qualifiedName can + /// be changed to other unique attributes) + /// + /// The cancellation token to use. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual async Task AddLabelsByAttributeAsync(string typeName, IEnumerable labels, string attr = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(typeName, nameof(typeName)); + Argument.AssertNotNull(labels, nameof(labels)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = RequestContentHelper.FromEnumerable(labels); + Response response = await AddLabelsByAttributeAsync(typeName, content, attr, context).ConfigureAwait(false); + return response; + } + + /// + /// Add given labels to a given entity identified by its type and unique + /// attributes. + /// + /// If labels is null/empty, no labels will be added. + /// + /// In addition to + /// the typeName path parameter, attribute key-value pair(s) can be provided in the + /// following format: attr:<attrName>=<attrValue>. + /// + /// NOTE: The attrName and + /// attrValue should be unique across entities, eg. qualifiedName. + /// + /// The REST + /// request would look something like this: PUT + /// /v2/entity/uniqueAttribute/type/aType?attr:aTypeAttribute=someValue. + /// + /// The name of the type. + /// set of labels to be added. + /// + /// The qualified name of the entity. (This is only an example. qualifiedName can + /// be changed to other unique attributes) + /// + /// The cancellation token to use. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual Response AddLabelsByAttribute(string typeName, IEnumerable labels, string attr = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(typeName, nameof(typeName)); + Argument.AssertNotNull(labels, nameof(labels)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = RequestContentHelper.FromEnumerable(labels); + Response response = AddLabelsByAttribute(typeName, content, attr, context); + return response; + } + + /// + /// [Protocol Method] Add given labels to a given entity identified by its type and unique + /// attributes. + /// + /// If labels is null/empty, no labels will be added. + /// + /// In addition to + /// the typeName path parameter, attribute key-value pair(s) can be provided in the + /// following format: attr:<attrName>=<attrValue>. + /// + /// NOTE: The attrName and + /// attrValue should be unique across entities, eg. qualifiedName. + /// + /// The REST + /// request would look something like this: PUT + /// /v2/entity/uniqueAttribute/type/aType?attr:aTypeAttribute=someValue. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The name of the type. + /// The content to send as the body of the request. + /// + /// The qualified name of the entity. (This is only an example. qualifiedName can + /// be changed to other unique attributes) + /// + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task AddLabelsByAttributeAsync(string typeName, RequestContent content, string attr = null, RequestContext context = null) + { + Argument.AssertNotNullOrEmpty(typeName, nameof(typeName)); + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Entity.AddLabelsByAttribute"); + scope.Start(); + try + { + using HttpMessage message = CreateAddLabelsByAttributeRequest(typeName, content, attr, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Add given labels to a given entity identified by its type and unique + /// attributes. + /// + /// If labels is null/empty, no labels will be added. + /// + /// In addition to + /// the typeName path parameter, attribute key-value pair(s) can be provided in the + /// following format: attr:<attrName>=<attrValue>. + /// + /// NOTE: The attrName and + /// attrValue should be unique across entities, eg. qualifiedName. + /// + /// The REST + /// request would look something like this: PUT + /// /v2/entity/uniqueAttribute/type/aType?attr:aTypeAttribute=someValue. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The name of the type. + /// The content to send as the body of the request. + /// + /// The qualified name of the entity. (This is only an example. qualifiedName can + /// be changed to other unique attributes) + /// + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response AddLabelsByAttribute(string typeName, RequestContent content, string attr = null, RequestContext context = null) + { + Argument.AssertNotNullOrEmpty(typeName, nameof(typeName)); + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Entity.AddLabelsByAttribute"); + scope.Start(); + try + { + using HttpMessage message = CreateAddLabelsByAttributeRequest(typeName, content, attr, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Move existing entities to the target collection. + /// The collection where entities will be moved to. + /// Entity guids to be moved to target collection. + /// The cancellation token to use. + /// or is null. + /// + public virtual async Task> MoveEntitiesToCollectionAsync(string collectionId, MoveEntitiesOptions moveEntitiesRequest, CancellationToken cancellationToken = default) + { + Argument.AssertNotNull(collectionId, nameof(collectionId)); + Argument.AssertNotNull(moveEntitiesRequest, nameof(moveEntitiesRequest)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = moveEntitiesRequest.ToRequestContent(); + Response response = await MoveEntitiesToCollectionAsync(collectionId, content, context).ConfigureAwait(false); + return Response.FromValue(EntityMutationResult.FromResponse(response), response); + } + + /// Move existing entities to the target collection. + /// The collection where entities will be moved to. + /// Entity guids to be moved to target collection. + /// The cancellation token to use. + /// or is null. + /// + public virtual Response MoveEntitiesToCollection(string collectionId, MoveEntitiesOptions moveEntitiesRequest, CancellationToken cancellationToken = default) + { + Argument.AssertNotNull(collectionId, nameof(collectionId)); + Argument.AssertNotNull(moveEntitiesRequest, nameof(moveEntitiesRequest)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = moveEntitiesRequest.ToRequestContent(); + Response response = MoveEntitiesToCollection(collectionId, content, context); + return Response.FromValue(EntityMutationResult.FromResponse(response), response); + } + + /// + /// [Protocol Method] Move existing entities to the target collection. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The collection where entities will be moved to. + /// The content to send as the body of the request. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// or is null. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task MoveEntitiesToCollectionAsync(string collectionId, RequestContent content, RequestContext context = null) + { + Argument.AssertNotNull(collectionId, nameof(collectionId)); + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Entity.MoveEntitiesToCollection"); + scope.Start(); + try + { + using HttpMessage message = CreateMoveEntitiesToCollectionRequest(collectionId, content, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Move existing entities to the target collection. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The collection where entities will be moved to. + /// The content to send as the body of the request. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// or is null. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response MoveEntitiesToCollection(string collectionId, RequestContent content, RequestContext context = null) + { + Argument.AssertNotNull(collectionId, nameof(collectionId)); + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Entity.MoveEntitiesToCollection"); + scope.Start(); + try + { + using HttpMessage message = CreateMoveEntitiesToCollectionRequest(collectionId, content, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + internal HttpMessage CreateCreateOrUpdateRequest(RequestContent content, string businessAttributeUpdateBehavior, string collectionId, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier200); + var request = message.Request; + request.Method = RequestMethod.Post; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/entity", false); + uri.AppendQuery("api-version", _apiVersion, true); + if (businessAttributeUpdateBehavior != null) + { + uri.AppendQuery("businessAttributeUpdateBehavior", businessAttributeUpdateBehavior, true); + } + if (collectionId != null) + { + uri.AppendQuery("collectionId", collectionId, true); + } + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + request.Headers.Add("Content-Type", "application/json"); + request.Content = content; + return message; + } + + internal HttpMessage CreateGetByIdsRequest(IEnumerable guid, bool? minExtInfo, bool? ignoreRelationships, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier200); + var request = message.Request; + request.Method = RequestMethod.Get; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/entity/bulk", false); + if (guid != null && Optional.IsCollectionDefined(guid)) + { + foreach (var param in guid) + { + uri.AppendQuery("guid", param, true); + } + } + uri.AppendQuery("api-version", _apiVersion, true); + if (minExtInfo != null) + { + uri.AppendQuery("minExtInfo", minExtInfo.Value, true); + } + if (ignoreRelationships != null) + { + uri.AppendQuery("ignoreRelationships", ignoreRelationships.Value, true); + } + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + return message; + } + + internal HttpMessage CreateBatchCreateOrUpdateRequest(RequestContent content, string collectionId, string businessAttributeUpdateBehavior, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier200); + var request = message.Request; + request.Method = RequestMethod.Post; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/entity/bulk", false); + uri.AppendQuery("api-version", _apiVersion, true); + if (collectionId != null) + { + uri.AppendQuery("collectionId", collectionId, true); + } + if (businessAttributeUpdateBehavior != null) + { + uri.AppendQuery("businessAttributeUpdateBehavior", businessAttributeUpdateBehavior, true); + } + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + request.Headers.Add("Content-Type", "application/json"); + request.Content = content; + return message; + } + + internal HttpMessage CreateBatchDeleteRequest(IEnumerable guid, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier200); + var request = message.Request; + request.Method = RequestMethod.Delete; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/entity/bulk", false); + if (guid != null && Optional.IsCollectionDefined(guid)) + { + foreach (var param in guid) + { + uri.AppendQuery("guid", param, true); + } + } + uri.AppendQuery("api-version", _apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + return message; + } + + internal HttpMessage CreateAddClassificationRequest(RequestContent content, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier204); + var request = message.Request; + request.Method = RequestMethod.Post; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/entity/bulk/classification", false); + uri.AppendQuery("api-version", _apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + request.Headers.Add("Content-Type", "application/json"); + request.Content = content; + return message; + } + + internal HttpMessage CreateGetEntityRequest(string guid, bool? minExtInfo, bool? ignoreRelationships, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier200); + var request = message.Request; + request.Method = RequestMethod.Get; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/entity/guid/", false); + uri.AppendPath(guid, true); + uri.AppendQuery("api-version", _apiVersion, true); + if (minExtInfo != null) + { + uri.AppendQuery("minExtInfo", minExtInfo.Value, true); + } + if (ignoreRelationships != null) + { + uri.AppendQuery("ignoreRelationships", ignoreRelationships.Value, true); + } + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + return message; + } + + internal HttpMessage CreatePartialUpdateAttributeByIdRequest(string guid, string name, RequestContent content, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier200); + var request = message.Request; + request.Method = RequestMethod.Put; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/entity/guid/", false); + uri.AppendPath(guid, true); + uri.AppendQuery("name", name, true); + uri.AppendQuery("api-version", _apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + request.Headers.Add("Content-Type", "application/json"); + request.Content = content; + return message; + } + + internal HttpMessage CreateDeleteRequest(string guid, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier200); + var request = message.Request; + request.Method = RequestMethod.Delete; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/entity/guid/", false); + uri.AppendPath(guid, true); + uri.AppendQuery("api-version", _apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + return message; + } + + internal HttpMessage CreateGetClassificationRequest(string guid, string classificationName, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier200); + var request = message.Request; + request.Method = RequestMethod.Get; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/entity/guid/", false); + uri.AppendPath(guid, true); + uri.AppendPath("/classification/", false); + uri.AppendPath(classificationName, true); + uri.AppendQuery("api-version", _apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + return message; + } + + internal HttpMessage CreateRemoveClassificationRequest(string guid, string classificationName, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier204); + var request = message.Request; + request.Method = RequestMethod.Delete; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/entity/guid/", false); + uri.AppendPath(guid, true); + uri.AppendPath("/classification/", false); + uri.AppendPath(classificationName, true); + uri.AppendQuery("api-version", _apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + return message; + } + + internal HttpMessage CreateGetClassificationsRequest(string guid, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier200); + var request = message.Request; + request.Method = RequestMethod.Get; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/entity/guid/", false); + uri.AppendPath(guid, true); + uri.AppendPath("/classifications", false); + uri.AppendQuery("api-version", _apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + return message; + } + + internal HttpMessage CreateAddClassificationsRequest(string guid, RequestContent content, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier204); + var request = message.Request; + request.Method = RequestMethod.Post; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/entity/guid/", false); + uri.AppendPath(guid, true); + uri.AppendPath("/classifications", false); + uri.AppendQuery("api-version", _apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + request.Headers.Add("Content-Type", "application/json"); + request.Content = content; + return message; + } + + internal HttpMessage CreateUpdateClassificationsRequest(string guid, RequestContent content, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier204); + var request = message.Request; + request.Method = RequestMethod.Put; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/entity/guid/", false); + uri.AppendPath(guid, true); + uri.AppendPath("/classifications", false); + uri.AppendQuery("api-version", _apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + request.Headers.Add("Content-Type", "application/json"); + request.Content = content; + return message; + } + + internal HttpMessage CreateGetByAttributesRequest(string typeName, bool? minExtInfo, bool? ignoreRelationships, string attr, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier200); + var request = message.Request; + request.Method = RequestMethod.Get; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/entity/uniqueAttribute/type/", false); + uri.AppendPath(typeName, true); + uri.AppendQuery("api-version", _apiVersion, true); + if (minExtInfo != null) + { + uri.AppendQuery("minExtInfo", minExtInfo.Value, true); + } + if (ignoreRelationships != null) + { + uri.AppendQuery("ignoreRelationships", ignoreRelationships.Value, true); + } + if (attr != null) + { + uri.AppendQuery("attr:qualifiedName", attr, true); + } + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + return message; + } + + internal HttpMessage CreatePartialUpdateByAttributesRequest(string typeName, RequestContent content, string attr, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier200); + var request = message.Request; + request.Method = RequestMethod.Put; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/entity/uniqueAttribute/type/", false); + uri.AppendPath(typeName, true); + uri.AppendQuery("api-version", _apiVersion, true); + if (attr != null) + { + uri.AppendQuery("attr:qualifiedName", attr, true); + } + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + request.Headers.Add("Content-Type", "application/json"); + request.Content = content; + return message; + } + + internal HttpMessage CreateDeleteByAttributeRequest(string typeName, string attr, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier200); + var request = message.Request; + request.Method = RequestMethod.Delete; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/entity/uniqueAttribute/type/", false); + uri.AppendPath(typeName, true); + uri.AppendQuery("api-version", _apiVersion, true); + if (attr != null) + { + uri.AppendQuery("attr:qualifiedName", attr, true); + } + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + return message; + } + + internal HttpMessage CreateRemoveClassificationByAttributeRequest(string typeName, string classificationName, string attr, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier204); + var request = message.Request; + request.Method = RequestMethod.Delete; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/entity/uniqueAttribute/type/", false); + uri.AppendPath(typeName, true); + uri.AppendPath("/classification/", false); + uri.AppendPath(classificationName, true); + uri.AppendQuery("api-version", _apiVersion, true); + if (attr != null) + { + uri.AppendQuery("attr:qualifiedName", attr, true); + } + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + return message; + } + + internal HttpMessage CreateAddClassificationsByAttributeRequest(string typeName, RequestContent content, string attr, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier204); + var request = message.Request; + request.Method = RequestMethod.Post; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/entity/uniqueAttribute/type/", false); + uri.AppendPath(typeName, true); + uri.AppendPath("/classifications", false); + uri.AppendQuery("api-version", _apiVersion, true); + if (attr != null) + { + uri.AppendQuery("attr:qualifiedName", attr, true); + } + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + request.Headers.Add("Content-Type", "application/json"); + request.Content = content; + return message; + } + + internal HttpMessage CreateUpdateClassificationsByAttributeRequest(string typeName, RequestContent content, string attr, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier204); + var request = message.Request; + request.Method = RequestMethod.Put; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/entity/uniqueAttribute/type/", false); + uri.AppendPath(typeName, true); + uri.AppendPath("/classifications", false); + uri.AppendQuery("api-version", _apiVersion, true); + if (attr != null) + { + uri.AppendQuery("attr:qualifiedName", attr, true); + } + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + request.Headers.Add("Content-Type", "application/json"); + request.Content = content; + return message; + } + + internal HttpMessage CreateBatchSetClassificationsRequest(RequestContent content, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier200); + var request = message.Request; + request.Method = RequestMethod.Post; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/entity/bulk/setClassifications", false); + uri.AppendQuery("api-version", _apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + request.Headers.Add("Content-Type", "application/json"); + request.Content = content; + return message; + } + + internal HttpMessage CreateBatchGetByAttributesRequest(string typeName, bool? minExtInfo, bool? ignoreRelationships, string attrNQualifiedName, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier200); + var request = message.Request; + request.Method = RequestMethod.Get; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/entity/bulk/uniqueAttribute/type/", false); + uri.AppendPath(typeName, true); + uri.AppendQuery("api-version", _apiVersion, true); + if (minExtInfo != null) + { + uri.AppendQuery("minExtInfo", minExtInfo.Value, true); + } + if (ignoreRelationships != null) + { + uri.AppendQuery("ignoreRelationships", ignoreRelationships.Value, true); + } + if (attrNQualifiedName != null) + { + uri.AppendQuery("attr_N:qualifiedName", attrNQualifiedName, true); + } + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + return message; + } + + internal HttpMessage CreateGetHeaderRequest(string guid, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier200); + var request = message.Request; + request.Method = RequestMethod.Get; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/entity/guid/", false); + uri.AppendPath(guid, true); + uri.AppendPath("/header", false); + uri.AppendQuery("api-version", _apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + return message; + } + + internal HttpMessage CreateRemoveBusinessMetadataRequest(string guid, RequestContent content, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier204); + var request = message.Request; + request.Method = RequestMethod.Delete; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/entity/guid/", false); + uri.AppendPath(guid, true); + uri.AppendPath("/businessmetadata", false); + uri.AppendQuery("api-version", _apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + request.Headers.Add("Content-Type", "application/json"); + request.Content = content; + return message; + } + + internal HttpMessage CreateAddOrUpdateBusinessMetadataRequest(string guid, RequestContent content, bool? isOverwrite, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier204); + var request = message.Request; + request.Method = RequestMethod.Post; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/entity/guid/", false); + uri.AppendPath(guid, true); + uri.AppendPath("/businessmetadata", false); + uri.AppendQuery("api-version", _apiVersion, true); + if (isOverwrite != null) + { + uri.AppendQuery("isOverwrite", isOverwrite.Value, true); + } + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + request.Headers.Add("Content-Type", "application/json"); + request.Content = content; + return message; + } + + internal HttpMessage CreateRemoveBusinessMetadataAttributesRequest(string guid, string businessMetadataName, RequestContent content, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier204); + var request = message.Request; + request.Method = RequestMethod.Delete; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/entity/guid/", false); + uri.AppendPath(guid, true); + uri.AppendPath("/businessmetadata/", false); + uri.AppendPath(businessMetadataName, true); + uri.AppendQuery("api-version", _apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + request.Headers.Add("Content-Type", "application/json"); + request.Content = content; + return message; + } + + internal HttpMessage CreateAddOrUpdateBusinessMetadataAttributesRequest(string guid, string businessMetadataName, RequestContent content, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier204); + var request = message.Request; + request.Method = RequestMethod.Post; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/entity/guid/", false); + uri.AppendPath(guid, true); + uri.AppendPath("/businessmetadata/", false); + uri.AppendPath(businessMetadataName, true); + uri.AppendQuery("api-version", _apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + request.Headers.Add("Content-Type", "application/json"); + request.Content = content; + return message; + } + + internal HttpMessage CreateGetSampleBusinessMetadataTemplateRequest(RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier200); + var request = message.Request; + request.Method = RequestMethod.Get; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/entity/businessmetadata/import/template", false); + uri.AppendQuery("api-version", _apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + return message; + } + + internal HttpMessage CreateImportBusinessMetadataRequest(RequestContent content, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier200); + var request = message.Request; + request.Method = RequestMethod.Post; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/entity/businessmetadata/import", false); + uri.AppendQuery("api-version", _apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + request.Headers.Add("content-type", "multipart/form-data"); + request.Content = content; + return message; + } + + internal HttpMessage CreateRemoveLabelsRequest(string guid, RequestContent content, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier204); + var request = message.Request; + request.Method = RequestMethod.Delete; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/entity/guid/", false); + uri.AppendPath(guid, true); + uri.AppendPath("/labels", false); + uri.AppendQuery("api-version", _apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + request.Headers.Add("Content-Type", "application/json"); + request.Content = content; + return message; + } + + internal HttpMessage CreateSetLabelsRequest(string guid, RequestContent content, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier204); + var request = message.Request; + request.Method = RequestMethod.Post; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/entity/guid/", false); + uri.AppendPath(guid, true); + uri.AppendPath("/labels", false); + uri.AppendQuery("api-version", _apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + request.Headers.Add("Content-Type", "application/json"); + request.Content = content; + return message; + } + + internal HttpMessage CreateAddLabelRequest(string guid, RequestContent content, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier204); + var request = message.Request; + request.Method = RequestMethod.Put; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/entity/guid/", false); + uri.AppendPath(guid, true); + uri.AppendPath("/labels", false); + uri.AppendQuery("api-version", _apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + request.Headers.Add("Content-Type", "application/json"); + request.Content = content; + return message; + } + + internal HttpMessage CreateRemoveLabelsByAttributeRequest(string typeName, RequestContent content, string attr, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier204); + var request = message.Request; + request.Method = RequestMethod.Delete; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/entity/uniqueAttribute/type/", false); + uri.AppendPath(typeName, true); + uri.AppendPath("/labels", false); + uri.AppendQuery("api-version", _apiVersion, true); + if (attr != null) + { + uri.AppendQuery("attr:qualifiedName", attr, true); + } + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + request.Headers.Add("Content-Type", "application/json"); + request.Content = content; + return message; + } + + internal HttpMessage CreateSetLabelsByAttributeRequest(string typeName, RequestContent content, string attr, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier204); + var request = message.Request; + request.Method = RequestMethod.Post; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/entity/uniqueAttribute/type/", false); + uri.AppendPath(typeName, true); + uri.AppendPath("/labels", false); + uri.AppendQuery("api-version", _apiVersion, true); + if (attr != null) + { + uri.AppendQuery("attr:qualifiedName", attr, true); + } + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + request.Headers.Add("Content-Type", "application/json"); + request.Content = content; + return message; + } + + internal HttpMessage CreateAddLabelsByAttributeRequest(string typeName, RequestContent content, string attr, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier204); + var request = message.Request; + request.Method = RequestMethod.Put; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/entity/uniqueAttribute/type/", false); + uri.AppendPath(typeName, true); + uri.AppendPath("/labels", false); + uri.AppendQuery("api-version", _apiVersion, true); + if (attr != null) + { + uri.AppendQuery("attr:qualifiedName", attr, true); + } + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + request.Headers.Add("Content-Type", "application/json"); + request.Content = content; + return message; + } + + internal HttpMessage CreateMoveEntitiesToCollectionRequest(string collectionId, RequestContent content, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier200); + var request = message.Request; + request.Method = RequestMethod.Post; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/entity/moveTo", false); + uri.AppendQuery("collectionId", collectionId, true); + uri.AppendQuery("api-version", _apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + request.Headers.Add("Content-Type", "application/json"); + request.Content = content; + return message; + } + + private static RequestContext DefaultRequestContext = new RequestContext(); + internal static RequestContext FromCancellationToken(CancellationToken cancellationToken = default) + { + if (!cancellationToken.CanBeCanceled) + { + return DefaultRequestContext; + } + + return new RequestContext() { CancellationToken = cancellationToken }; + } + + private static ResponseClassifier _responseClassifier200; + private static ResponseClassifier ResponseClassifier200 => _responseClassifier200 ??= new StatusCodeClassifier(stackalloc ushort[] { 200 }); + private static ResponseClassifier _responseClassifier204; + private static ResponseClassifier ResponseClassifier204 => _responseClassifier204 ??= new StatusCodeClassifier(stackalloc ushort[] { 204 }); + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/EntityMutationResult.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/EntityMutationResult.Serialization.cs new file mode 100644 index 0000000000000..843ab90b42157 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/EntityMutationResult.Serialization.cs @@ -0,0 +1,94 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using System.Text.Json; +using Azure; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class EntityMutationResult + { + internal static EntityMutationResult DeserializeEntityMutationResult(JsonElement element) + { + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + Optional> guidAssignments = default; + Optional>> mutatedEntities = default; + Optional> partialUpdatedEntities = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("guidAssignments"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + Dictionary dictionary = new Dictionary(); + foreach (var property0 in property.Value.EnumerateObject()) + { + dictionary.Add(property0.Name, property0.Value.GetString()); + } + guidAssignments = dictionary; + continue; + } + if (property.NameEquals("mutatedEntities"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + Dictionary> dictionary = new Dictionary>(); + foreach (var property0 in property.Value.EnumerateObject()) + { + if (property0.Value.ValueKind == JsonValueKind.Null) + { + dictionary.Add(property0.Name, null); + } + else + { + List array = new List(); + foreach (var item in property0.Value.EnumerateArray()) + { + array.Add(AtlasEntityHeader.DeserializeAtlasEntityHeader(item)); + } + dictionary.Add(property0.Name, array); + } + } + mutatedEntities = dictionary; + continue; + } + if (property.NameEquals("partialUpdatedEntities"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(AtlasEntityHeader.DeserializeAtlasEntityHeader(item)); + } + partialUpdatedEntities = array; + continue; + } + } + return new EntityMutationResult(Optional.ToDictionary(guidAssignments), Optional.ToDictionary(mutatedEntities), Optional.ToList(partialUpdatedEntities)); + } + + /// Deserializes the model from a raw response. + /// The response to deserialize the model from. + internal static EntityMutationResult FromResponse(Response response) + { + using var document = JsonDocument.Parse(response.Content); + return DeserializeEntityMutationResult(document.RootElement); + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/EntityMutationResult.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/EntityMutationResult.cs new file mode 100644 index 0000000000000..f75fab5e7bb83 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/EntityMutationResult.cs @@ -0,0 +1,42 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + /// The mutation response result of entity. + public partial class EntityMutationResult + { + /// Initializes a new instance of . + internal EntityMutationResult() + { + GuidAssignments = new ChangeTrackingDictionary(); + MutatedEntities = new ChangeTrackingDictionary>(); + PartialUpdatedEntities = new ChangeTrackingList(); + } + + /// Initializes a new instance of . + /// A map of GUID assignments with entities. + /// The entity headers of mutated entities. + /// An array of entity headers that partially updated. + internal EntityMutationResult(IReadOnlyDictionary guidAssignments, IReadOnlyDictionary> mutatedEntities, IReadOnlyList partialUpdatedEntities) + { + GuidAssignments = guidAssignments; + MutatedEntities = mutatedEntities; + PartialUpdatedEntities = partialUpdatedEntities; + } + + /// A map of GUID assignments with entities. + public IReadOnlyDictionary GuidAssignments { get; } + /// The entity headers of mutated entities. + public IReadOnlyDictionary> MutatedEntities { get; } + /// An array of entity headers that partially updated. + public IReadOnlyList PartialUpdatedEntities { get; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/EntityStatus.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/EntityStatus.cs new file mode 100644 index 0000000000000..7521a9c79c319 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/EntityStatus.cs @@ -0,0 +1,51 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.ComponentModel; + +namespace Azure.Analytics.Purview.DataMap +{ + /// Status - can be active or deleted. + public readonly partial struct EntityStatus : IEquatable + { + private readonly string _value; + + /// Initializes a new instance of . + /// is null. + public EntityStatus(string value) + { + _value = value ?? throw new ArgumentNullException(nameof(value)); + } + + private const string ActiveValue = "ACTIVE"; + private const string DeletedValue = "DELETED"; + + /// The status is active. + public static EntityStatus Active { get; } = new EntityStatus(ActiveValue); + /// The status is deleted. + public static EntityStatus Deleted { get; } = new EntityStatus(DeletedValue); + /// Determines if two values are the same. + public static bool operator ==(EntityStatus left, EntityStatus right) => left.Equals(right); + /// Determines if two values are not the same. + public static bool operator !=(EntityStatus left, EntityStatus right) => !left.Equals(right); + /// Converts a string to a . + public static implicit operator EntityStatus(string value) => new EntityStatus(value); + + /// + [EditorBrowsable(EditorBrowsableState.Never)] + public override bool Equals(object obj) => obj is EntityStatus other && Equals(other); + /// + public bool Equals(EntityStatus other) => string.Equals(_value, other._value, StringComparison.InvariantCultureIgnoreCase); + + /// + [EditorBrowsable(EditorBrowsableState.Never)] + public override int GetHashCode() => _value?.GetHashCode() ?? 0; + /// + public override string ToString() => _value; + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/EntityTypeFilter.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/EntityTypeFilter.Serialization.cs new file mode 100644 index 0000000000000..0dfc73fe046d2 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/EntityTypeFilter.Serialization.cs @@ -0,0 +1,38 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class EntityTypeFilter : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + writer.WritePropertyName("entityType"u8); + writer.WriteStringValue(EntityType); + if (Optional.IsDefined(IncludeSubTypes)) + { + writer.WritePropertyName("includeSubTypes"u8); + writer.WriteBooleanValue(IncludeSubTypes.Value); + } + writer.WritePropertyName("kind"u8); + writer.WriteStringValue(Kind); + writer.WriteEndObject(); + } + + /// Convert into a Utf8JsonRequestContent. + internal override RequestContent ToRequestContent() + { + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(this); + return content; + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/EntityTypeFilter.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/EntityTypeFilter.cs new file mode 100644 index 0000000000000..b9fcaee48fa92 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/EntityTypeFilter.cs @@ -0,0 +1,42 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + /// Entity type filter for search. + public partial class EntityTypeFilter : SearchFilter + { + /// Initializes a new instance of . + /// Type name. + /// is null. + public EntityTypeFilter(string entityType) + { + Argument.AssertNotNull(entityType, nameof(entityType)); + + Kind = "EntityTypeFilter"; + EntityType = entityType; + } + + /// Initializes a new instance of . + /// Discriminator. + /// Type name. + /// Whether to include sub types. + internal EntityTypeFilter(string kind, string entityType, bool? includeSubTypes) : base(kind) + { + EntityType = entityType; + IncludeSubTypes = includeSubTypes; + } + + /// Type name. + public string EntityType { get; } + /// Whether to include sub types. + public bool? IncludeSubTypes { get; set; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ExistsFilter.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ExistsFilter.Serialization.cs new file mode 100644 index 0000000000000..569bb01fb6ac9 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ExistsFilter.Serialization.cs @@ -0,0 +1,33 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class ExistsFilter : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + writer.WritePropertyName("exists"u8); + writer.WriteStringValue(Field); + writer.WritePropertyName("kind"u8); + writer.WriteStringValue(Kind); + writer.WriteEndObject(); + } + + /// Convert into a Utf8JsonRequestContent. + internal override RequestContent ToRequestContent() + { + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(this); + return content; + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ExistsFilter.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ExistsFilter.cs new file mode 100644 index 0000000000000..7ce3a4f66134a --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ExistsFilter.cs @@ -0,0 +1,38 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + /// Exists filter for search. + public partial class ExistsFilter : SearchFilter + { + /// Initializes a new instance of . + /// Field. + /// is null. + public ExistsFilter(string field) + { + Argument.AssertNotNull(field, nameof(field)); + + Kind = "ExistsFilter"; + Field = field; + } + + /// Initializes a new instance of . + /// Discriminator. + /// Field. + internal ExistsFilter(string kind, string field) : base(kind) + { + Field = field; + } + + /// Field. + public string Field { get; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/FileExtensionFilter.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/FileExtensionFilter.Serialization.cs new file mode 100644 index 0000000000000..197eb7da53955 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/FileExtensionFilter.Serialization.cs @@ -0,0 +1,33 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class FileExtensionFilter : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + writer.WritePropertyName("fileExtension"u8); + writer.WriteStringValue(FileExtension); + writer.WritePropertyName("kind"u8); + writer.WriteStringValue(Kind); + writer.WriteEndObject(); + } + + /// Convert into a Utf8JsonRequestContent. + internal override RequestContent ToRequestContent() + { + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(this); + return content; + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/FileExtensionFilter.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/FileExtensionFilter.cs new file mode 100644 index 0000000000000..66755cdb8b076 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/FileExtensionFilter.cs @@ -0,0 +1,38 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + /// File extension filter for search. + public partial class FileExtensionFilter : SearchFilter + { + /// Initializes a new instance of . + /// File extension. + /// is null. + public FileExtensionFilter(string fileExtension) + { + Argument.AssertNotNull(fileExtension, nameof(fileExtension)); + + Kind = "FileExtensionFilter"; + FileExtension = fileExtension; + } + + /// Initializes a new instance of . + /// Discriminator. + /// File extension. + internal FileExtensionFilter(string kind, string fileExtension) : base(kind) + { + FileExtension = fileExtension; + } + + /// File extension. + public string FileExtension { get; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/FilterOperator.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/FilterOperator.cs new file mode 100644 index 0000000000000..3c8f7546f5d13 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/FilterOperator.cs @@ -0,0 +1,78 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.ComponentModel; + +namespace Azure.Analytics.Purview.DataMap +{ + /// Search Filter Operator. + public readonly partial struct FilterOperator : IEquatable + { + private readonly string _value; + + /// Initializes a new instance of . + /// is null. + public FilterOperator(string value) + { + _value = value ?? throw new ArgumentNullException(nameof(value)); + } + + private const string EqValue = "eq"; + private const string NeValue = "ne"; + private const string GtValue = "gt"; + private const string LtValue = "lt"; + private const string GeValue = "ge"; + private const string LeValue = "le"; + private const string ContainsValue = "contains"; + private const string StartswithValue = "startswith"; + private const string PrefixValue = "prefix"; + private const string TimerangeValue = "timerange"; + private const string ExistsValue = "exists"; + + /// equal. + public static FilterOperator Eq { get; } = new FilterOperator(EqValue); + /// not equal. + public static FilterOperator Ne { get; } = new FilterOperator(NeValue); + /// greater than. + public static FilterOperator Gt { get; } = new FilterOperator(GtValue); + /// less than. + public static FilterOperator Lt { get; } = new FilterOperator(LtValue); + /// greater than or equal to. + public static FilterOperator Ge { get; } = new FilterOperator(GeValue); + /// less than or equal to. + public static FilterOperator Le { get; } = new FilterOperator(LeValue); + /// contains. + public static FilterOperator Contains { get; } = new FilterOperator(ContainsValue); + /// start with. + public static FilterOperator Startswith { get; } = new FilterOperator(StartswithValue); + /// prefix. + public static FilterOperator Prefix { get; } = new FilterOperator(PrefixValue); + /// time range. + public static FilterOperator Timerange { get; } = new FilterOperator(TimerangeValue); + /// exists. + public static FilterOperator Exists { get; } = new FilterOperator(ExistsValue); + /// Determines if two values are the same. + public static bool operator ==(FilterOperator left, FilterOperator right) => left.Equals(right); + /// Determines if two values are not the same. + public static bool operator !=(FilterOperator left, FilterOperator right) => !left.Equals(right); + /// Converts a string to a . + public static implicit operator FilterOperator(string value) => new FilterOperator(value); + + /// + [EditorBrowsable(EditorBrowsableState.Never)] + public override bool Equals(object obj) => obj is FilterOperator other && Equals(other); + /// + public bool Equals(FilterOperator other) => string.Equals(_value, other._value, StringComparison.InvariantCultureIgnoreCase); + + /// + [EditorBrowsable(EditorBrowsableState.Never)] + public override int GetHashCode() => _value?.GetHashCode() ?? 0; + /// + public override string ToString() => _value; + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/Glossary.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/Glossary.cs new file mode 100644 index 0000000000000..c7acf506ed7d9 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/Glossary.cs @@ -0,0 +1,4429 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Collections.Generic; +using System.Text.Json; +using System.Threading; +using System.Threading.Tasks; +using Azure; +using Azure.Core; +using Azure.Core.Pipeline; + +namespace Azure.Analytics.Purview.DataMap +{ + // Data plane generated sub-client. + /// The Glossary sub-client. + public partial class Glossary + { + private static readonly string[] AuthorizationScopes = new string[] { "https://purview.azure.net/.default" }; + private readonly TokenCredential _tokenCredential; + private readonly HttpPipeline _pipeline; + private readonly Uri _endpoint; + private readonly string _apiVersion; + + /// The ClientDiagnostics is used to provide tracing support for the client library. + internal ClientDiagnostics ClientDiagnostics { get; } + + /// The HTTP pipeline for sending and receiving REST requests and responses. + public virtual HttpPipeline Pipeline => _pipeline; + + /// Initializes a new instance of Glossary for mocking. + protected Glossary() + { + } + + /// Initializes a new instance of Glossary. + /// The handler for diagnostic messaging in the client. + /// The HTTP pipeline for sending and receiving REST requests and responses. + /// The token credential to copy. + /// The to use. + /// The to use. + internal Glossary(ClientDiagnostics clientDiagnostics, HttpPipeline pipeline, TokenCredential tokenCredential, Uri endpoint, string apiVersion) + { + ClientDiagnostics = clientDiagnostics; + _pipeline = pipeline; + _tokenCredential = tokenCredential; + _endpoint = endpoint; + _apiVersion = apiVersion; + } + + /// + /// Get all glossaries. Recommend using limit/offset to get pagination result. + /// Recommend using 'ignoreTermsAndCategories=true' and fetch terms/categories + /// separately using + /// + /// 'GET /datamap/api/atlas/v2/glossary/{glossaryId}/terms' + /// and + /// + /// 'GET '/datamap/api/atlas/v2/glossary/{glossaryId}/categories'. + /// + /// The page size - by default there is no paging. + /// The offset for pagination purpose. + /// The sort order, ASC (default) or DESC. + /// Whether ignore terms and categories. + /// The cancellation token to use. + /// + public virtual async Task>> BatchGetAsync(int? limit = null, int? offset = null, string sort = null, bool? ignoreTermsAndCategories = null, CancellationToken cancellationToken = default) + { + RequestContext context = FromCancellationToken(cancellationToken); + Response response = await BatchGetAsync(limit, offset, sort, ignoreTermsAndCategories, context).ConfigureAwait(false); + IReadOnlyList value = default; + using var document = await JsonDocument.ParseAsync(response.ContentStream, default, cancellationToken).ConfigureAwait(false); + List array = new List(); + foreach (var item in document.RootElement.EnumerateArray()) + { + array.Add(AtlasGlossary.DeserializeAtlasGlossary(item)); + } + value = array; + return Response.FromValue(value, response); + } + + /// + /// Get all glossaries. Recommend using limit/offset to get pagination result. + /// Recommend using 'ignoreTermsAndCategories=true' and fetch terms/categories + /// separately using + /// + /// 'GET /datamap/api/atlas/v2/glossary/{glossaryId}/terms' + /// and + /// + /// 'GET '/datamap/api/atlas/v2/glossary/{glossaryId}/categories'. + /// + /// The page size - by default there is no paging. + /// The offset for pagination purpose. + /// The sort order, ASC (default) or DESC. + /// Whether ignore terms and categories. + /// The cancellation token to use. + /// + public virtual Response> BatchGet(int? limit = null, int? offset = null, string sort = null, bool? ignoreTermsAndCategories = null, CancellationToken cancellationToken = default) + { + RequestContext context = FromCancellationToken(cancellationToken); + Response response = BatchGet(limit, offset, sort, ignoreTermsAndCategories, context); + IReadOnlyList value = default; + using var document = JsonDocument.Parse(response.ContentStream); + List array = new List(); + foreach (var item in document.RootElement.EnumerateArray()) + { + array.Add(AtlasGlossary.DeserializeAtlasGlossary(item)); + } + value = array; + return Response.FromValue(value, response); + } + + /// + /// [Protocol Method] Get all glossaries. Recommend using limit/offset to get pagination result. + /// Recommend using 'ignoreTermsAndCategories=true' and fetch terms/categories + /// separately using + /// + /// 'GET /datamap/api/atlas/v2/glossary/{glossaryId}/terms' + /// and + /// + /// 'GET '/datamap/api/atlas/v2/glossary/{glossaryId}/categories'. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The page size - by default there is no paging. + /// The offset for pagination purpose. + /// The sort order, ASC (default) or DESC. + /// Whether ignore terms and categories. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task BatchGetAsync(int? limit, int? offset, string sort, bool? ignoreTermsAndCategories, RequestContext context) + { + using var scope = ClientDiagnostics.CreateScope("Glossary.BatchGet"); + scope.Start(); + try + { + using HttpMessage message = CreateBatchGetRequest(limit, offset, sort, ignoreTermsAndCategories, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Get all glossaries. Recommend using limit/offset to get pagination result. + /// Recommend using 'ignoreTermsAndCategories=true' and fetch terms/categories + /// separately using + /// + /// 'GET /datamap/api/atlas/v2/glossary/{glossaryId}/terms' + /// and + /// + /// 'GET '/datamap/api/atlas/v2/glossary/{glossaryId}/categories'. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The page size - by default there is no paging. + /// The offset for pagination purpose. + /// The sort order, ASC (default) or DESC. + /// Whether ignore terms and categories. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response BatchGet(int? limit, int? offset, string sort, bool? ignoreTermsAndCategories, RequestContext context) + { + using var scope = ClientDiagnostics.CreateScope("Glossary.BatchGet"); + scope.Start(); + try + { + using HttpMessage message = CreateBatchGetRequest(limit, offset, sort, ignoreTermsAndCategories, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Create a glossary. + /// + /// Glossary definition, terms & categories can be anchored to a glossary. + /// Using + /// the anchor attribute when creating the Term/Category. + /// + /// The cancellation token to use. + /// is null. + /// + public virtual async Task> CreateAsync(AtlasGlossary atlasGlossary, CancellationToken cancellationToken = default) + { + Argument.AssertNotNull(atlasGlossary, nameof(atlasGlossary)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = atlasGlossary.ToRequestContent(); + Response response = await CreateAsync(content, context).ConfigureAwait(false); + return Response.FromValue(AtlasGlossary.FromResponse(response), response); + } + + /// Create a glossary. + /// + /// Glossary definition, terms & categories can be anchored to a glossary. + /// Using + /// the anchor attribute when creating the Term/Category. + /// + /// The cancellation token to use. + /// is null. + /// + public virtual Response Create(AtlasGlossary atlasGlossary, CancellationToken cancellationToken = default) + { + Argument.AssertNotNull(atlasGlossary, nameof(atlasGlossary)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = atlasGlossary.ToRequestContent(); + Response response = Create(content, context); + return Response.FromValue(AtlasGlossary.FromResponse(response), response); + } + + /// + /// [Protocol Method] Create a glossary. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The content to send as the body of the request. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task CreateAsync(RequestContent content, RequestContext context = null) + { + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Glossary.Create"); + scope.Start(); + try + { + using HttpMessage message = CreateCreateRequest(content, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Create a glossary. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The content to send as the body of the request. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response Create(RequestContent content, RequestContext context = null) + { + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Glossary.Create"); + scope.Start(); + try + { + using HttpMessage message = CreateCreateRequest(content, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Create glossary category in bulk. + /// An array of glossary category definitions to be created. + /// The cancellation token to use. + /// is null. + /// + public virtual async Task>> CreateCategoriesAsync(IEnumerable glossaryCategory, CancellationToken cancellationToken = default) + { + Argument.AssertNotNull(glossaryCategory, nameof(glossaryCategory)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = RequestContentHelper.FromEnumerable(glossaryCategory); + Response response = await CreateCategoriesAsync(content, context).ConfigureAwait(false); + IReadOnlyList value = default; + using var document = await JsonDocument.ParseAsync(response.ContentStream, default, cancellationToken).ConfigureAwait(false); + List array = new List(); + foreach (var item in document.RootElement.EnumerateArray()) + { + array.Add(AtlasGlossaryCategory.DeserializeAtlasGlossaryCategory(item)); + } + value = array; + return Response.FromValue(value, response); + } + + /// Create glossary category in bulk. + /// An array of glossary category definitions to be created. + /// The cancellation token to use. + /// is null. + /// + public virtual Response> CreateCategories(IEnumerable glossaryCategory, CancellationToken cancellationToken = default) + { + Argument.AssertNotNull(glossaryCategory, nameof(glossaryCategory)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = RequestContentHelper.FromEnumerable(glossaryCategory); + Response response = CreateCategories(content, context); + IReadOnlyList value = default; + using var document = JsonDocument.Parse(response.ContentStream); + List array = new List(); + foreach (var item in document.RootElement.EnumerateArray()) + { + array.Add(AtlasGlossaryCategory.DeserializeAtlasGlossaryCategory(item)); + } + value = array; + return Response.FromValue(value, response); + } + + /// + /// [Protocol Method] Create glossary category in bulk. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The content to send as the body of the request. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task CreateCategoriesAsync(RequestContent content, RequestContext context = null) + { + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Glossary.CreateCategories"); + scope.Start(); + try + { + using HttpMessage message = CreateCreateCategoriesRequest(content, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Create glossary category in bulk. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The content to send as the body of the request. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response CreateCategories(RequestContent content, RequestContext context = null) + { + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Glossary.CreateCategories"); + scope.Start(); + try + { + using HttpMessage message = CreateCreateCategoriesRequest(content, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Create a glossary category. + /// + /// The glossary category definition. A category must be anchored to a Glossary + /// when creating. + /// Optionally, terms belonging to the category and the hierarchy + /// can also be defined during creation. + /// + /// The cancellation token to use. + /// is null. + /// + public virtual async Task> CreateCategoryAsync(AtlasGlossaryCategory glossaryCategory, CancellationToken cancellationToken = default) + { + Argument.AssertNotNull(glossaryCategory, nameof(glossaryCategory)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = glossaryCategory.ToRequestContent(); + Response response = await CreateCategoryAsync(content, context).ConfigureAwait(false); + return Response.FromValue(AtlasGlossaryCategory.FromResponse(response), response); + } + + /// Create a glossary category. + /// + /// The glossary category definition. A category must be anchored to a Glossary + /// when creating. + /// Optionally, terms belonging to the category and the hierarchy + /// can also be defined during creation. + /// + /// The cancellation token to use. + /// is null. + /// + public virtual Response CreateCategory(AtlasGlossaryCategory glossaryCategory, CancellationToken cancellationToken = default) + { + Argument.AssertNotNull(glossaryCategory, nameof(glossaryCategory)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = glossaryCategory.ToRequestContent(); + Response response = CreateCategory(content, context); + return Response.FromValue(AtlasGlossaryCategory.FromResponse(response), response); + } + + /// + /// [Protocol Method] Create a glossary category. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The content to send as the body of the request. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task CreateCategoryAsync(RequestContent content, RequestContext context = null) + { + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Glossary.CreateCategory"); + scope.Start(); + try + { + using HttpMessage message = CreateCreateCategoryRequest(content, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Create a glossary category. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The content to send as the body of the request. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response CreateCategory(RequestContent content, RequestContext context = null) + { + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Glossary.CreateCategory"); + scope.Start(); + try + { + using HttpMessage message = CreateCreateCategoryRequest(content, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Get specific glossary category by its GUID. + /// The globally unique identifier of the category. + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual async Task> GetCategoryAsync(string categoryId, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(categoryId, nameof(categoryId)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = await GetCategoryAsync(categoryId, context).ConfigureAwait(false); + return Response.FromValue(AtlasGlossaryCategory.FromResponse(response), response); + } + + /// Get specific glossary category by its GUID. + /// The globally unique identifier of the category. + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual Response GetCategory(string categoryId, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(categoryId, nameof(categoryId)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = GetCategory(categoryId, context); + return Response.FromValue(AtlasGlossaryCategory.FromResponse(response), response); + } + + /// + /// [Protocol Method] Get specific glossary category by its GUID. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier of the category. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task GetCategoryAsync(string categoryId, RequestContext context) + { + Argument.AssertNotNullOrEmpty(categoryId, nameof(categoryId)); + + using var scope = ClientDiagnostics.CreateScope("Glossary.GetCategory"); + scope.Start(); + try + { + using HttpMessage message = CreateGetCategoryRequest(categoryId, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Get specific glossary category by its GUID. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier of the category. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response GetCategory(string categoryId, RequestContext context) + { + Argument.AssertNotNullOrEmpty(categoryId, nameof(categoryId)); + + using var scope = ClientDiagnostics.CreateScope("Glossary.GetCategory"); + scope.Start(); + try + { + using HttpMessage message = CreateGetCategoryRequest(categoryId, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Update the given glossary category by its GUID. + /// The globally unique identifier of the category. + /// The glossary category to be updated. + /// The cancellation token to use. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual async Task> UpdateCategoryAsync(string categoryId, AtlasGlossaryCategory glossaryCategory, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(categoryId, nameof(categoryId)); + Argument.AssertNotNull(glossaryCategory, nameof(glossaryCategory)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = glossaryCategory.ToRequestContent(); + Response response = await UpdateCategoryAsync(categoryId, content, context).ConfigureAwait(false); + return Response.FromValue(AtlasGlossaryCategory.FromResponse(response), response); + } + + /// Update the given glossary category by its GUID. + /// The globally unique identifier of the category. + /// The glossary category to be updated. + /// The cancellation token to use. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual Response UpdateCategory(string categoryId, AtlasGlossaryCategory glossaryCategory, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(categoryId, nameof(categoryId)); + Argument.AssertNotNull(glossaryCategory, nameof(glossaryCategory)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = glossaryCategory.ToRequestContent(); + Response response = UpdateCategory(categoryId, content, context); + return Response.FromValue(AtlasGlossaryCategory.FromResponse(response), response); + } + + /// + /// [Protocol Method] Update the given glossary category by its GUID. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier of the category. + /// The content to send as the body of the request. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task UpdateCategoryAsync(string categoryId, RequestContent content, RequestContext context = null) + { + Argument.AssertNotNullOrEmpty(categoryId, nameof(categoryId)); + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Glossary.UpdateCategory"); + scope.Start(); + try + { + using HttpMessage message = CreateUpdateCategoryRequest(categoryId, content, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Update the given glossary category by its GUID. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier of the category. + /// The content to send as the body of the request. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response UpdateCategory(string categoryId, RequestContent content, RequestContext context = null) + { + Argument.AssertNotNullOrEmpty(categoryId, nameof(categoryId)); + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Glossary.UpdateCategory"); + scope.Start(); + try + { + using HttpMessage message = CreateUpdateCategoryRequest(categoryId, content, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + // The convenience method is omitted here because it has exactly the same parameter list as the corresponding protocol method + /// + /// [Protocol Method] Delete a glossary category. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// The globally unique identifier of the category. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task DeleteCategoryAsync(string categoryId, RequestContext context = null) + { + Argument.AssertNotNullOrEmpty(categoryId, nameof(categoryId)); + + using var scope = ClientDiagnostics.CreateScope("Glossary.DeleteCategory"); + scope.Start(); + try + { + using HttpMessage message = CreateDeleteCategoryRequest(categoryId, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + // The convenience method is omitted here because it has exactly the same parameter list as the corresponding protocol method + /// + /// [Protocol Method] Delete a glossary category. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// The globally unique identifier of the category. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response DeleteCategory(string categoryId, RequestContext context = null) + { + Argument.AssertNotNullOrEmpty(categoryId, nameof(categoryId)); + + using var scope = ClientDiagnostics.CreateScope("Glossary.DeleteCategory"); + scope.Start(); + try + { + using HttpMessage message = CreateDeleteCategoryRequest(categoryId, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// Update the glossary category partially. So far we only supports partial + /// updating shortDescription and longDescription for category. + /// + /// The globally unique identifier of the category. + /// + /// A map containing keys as attribute names and values as corresponding attribute + /// values for partial update. + /// + /// The cancellation token to use. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual async Task> PartialUpdateCategoryAsync(string categoryId, BinaryData partialUpdates, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(categoryId, nameof(categoryId)); + Argument.AssertNotNull(partialUpdates, nameof(partialUpdates)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = RequestContentHelper.FromObject(partialUpdates); + Response response = await PartialUpdateCategoryAsync(categoryId, content, context).ConfigureAwait(false); + return Response.FromValue(AtlasGlossaryCategory.FromResponse(response), response); + } + + /// + /// Update the glossary category partially. So far we only supports partial + /// updating shortDescription and longDescription for category. + /// + /// The globally unique identifier of the category. + /// + /// A map containing keys as attribute names and values as corresponding attribute + /// values for partial update. + /// + /// The cancellation token to use. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual Response PartialUpdateCategory(string categoryId, BinaryData partialUpdates, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(categoryId, nameof(categoryId)); + Argument.AssertNotNull(partialUpdates, nameof(partialUpdates)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = RequestContentHelper.FromObject(partialUpdates); + Response response = PartialUpdateCategory(categoryId, content, context); + return Response.FromValue(AtlasGlossaryCategory.FromResponse(response), response); + } + + /// + /// [Protocol Method] Update the glossary category partially. So far we only supports partial + /// updating shortDescription and longDescription for category. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier of the category. + /// The content to send as the body of the request. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task PartialUpdateCategoryAsync(string categoryId, RequestContent content, RequestContext context = null) + { + Argument.AssertNotNullOrEmpty(categoryId, nameof(categoryId)); + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Glossary.PartialUpdateCategory"); + scope.Start(); + try + { + using HttpMessage message = CreatePartialUpdateCategoryRequest(categoryId, content, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Update the glossary category partially. So far we only supports partial + /// updating shortDescription and longDescription for category. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier of the category. + /// The content to send as the body of the request. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response PartialUpdateCategory(string categoryId, RequestContent content, RequestContext context = null) + { + Argument.AssertNotNullOrEmpty(categoryId, nameof(categoryId)); + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Glossary.PartialUpdateCategory"); + scope.Start(); + try + { + using HttpMessage message = CreatePartialUpdateCategoryRequest(categoryId, content, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// Get all related categories (parent and children). Limit, offset, and sort + /// parameters are currently not being enabled and won't work even they are passed. + /// + /// The globally unique identifier of the category. + /// The page size - by default there is no paging. + /// The offset for pagination purpose. + /// The sort order, ASC (default) or DESC. + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual async Task>>> GetRelatedCategoriesAsync(string categoryId, int? limit = null, int? offset = null, string sort = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(categoryId, nameof(categoryId)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = await GetRelatedCategoriesAsync(categoryId, limit, offset, sort, context).ConfigureAwait(false); + IReadOnlyDictionary> value = default; + using var document = await JsonDocument.ParseAsync(response.ContentStream, default, cancellationToken).ConfigureAwait(false); + Dictionary> dictionary = new Dictionary>(); + foreach (var property in document.RootElement.EnumerateObject()) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + dictionary.Add(property.Name, null); + } + else + { + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(AtlasRelatedCategoryHeader.DeserializeAtlasRelatedCategoryHeader(item)); + } + dictionary.Add(property.Name, array); + } + } + value = dictionary; + return Response.FromValue(value, response); + } + + /// + /// Get all related categories (parent and children). Limit, offset, and sort + /// parameters are currently not being enabled and won't work even they are passed. + /// + /// The globally unique identifier of the category. + /// The page size - by default there is no paging. + /// The offset for pagination purpose. + /// The sort order, ASC (default) or DESC. + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual Response>> GetRelatedCategories(string categoryId, int? limit = null, int? offset = null, string sort = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(categoryId, nameof(categoryId)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = GetRelatedCategories(categoryId, limit, offset, sort, context); + IReadOnlyDictionary> value = default; + using var document = JsonDocument.Parse(response.ContentStream); + Dictionary> dictionary = new Dictionary>(); + foreach (var property in document.RootElement.EnumerateObject()) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + dictionary.Add(property.Name, null); + } + else + { + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(AtlasRelatedCategoryHeader.DeserializeAtlasRelatedCategoryHeader(item)); + } + dictionary.Add(property.Name, array); + } + } + value = dictionary; + return Response.FromValue(value, response); + } + + /// + /// [Protocol Method] Get all related categories (parent and children). Limit, offset, and sort + /// parameters are currently not being enabled and won't work even they are passed. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier of the category. + /// The page size - by default there is no paging. + /// The offset for pagination purpose. + /// The sort order, ASC (default) or DESC. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task GetRelatedCategoriesAsync(string categoryId, int? limit, int? offset, string sort, RequestContext context) + { + Argument.AssertNotNullOrEmpty(categoryId, nameof(categoryId)); + + using var scope = ClientDiagnostics.CreateScope("Glossary.GetRelatedCategories"); + scope.Start(); + try + { + using HttpMessage message = CreateGetRelatedCategoriesRequest(categoryId, limit, offset, sort, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Get all related categories (parent and children). Limit, offset, and sort + /// parameters are currently not being enabled and won't work even they are passed. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier of the category. + /// The page size - by default there is no paging. + /// The offset for pagination purpose. + /// The sort order, ASC (default) or DESC. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response GetRelatedCategories(string categoryId, int? limit, int? offset, string sort, RequestContext context) + { + Argument.AssertNotNullOrEmpty(categoryId, nameof(categoryId)); + + using var scope = ClientDiagnostics.CreateScope("Glossary.GetRelatedCategories"); + scope.Start(); + try + { + using HttpMessage message = CreateGetRelatedCategoriesRequest(categoryId, limit, offset, sort, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Get all terms associated with the specific category. + /// The globally unique identifier of the category. + /// The page size - by default there is no paging. + /// The offset for pagination purpose. + /// The sort order, ASC (default) or DESC. + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual async Task>> GetCategoryTermsAsync(string categoryId, int? limit = null, int? offset = null, string sort = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(categoryId, nameof(categoryId)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = await GetCategoryTermsAsync(categoryId, limit, offset, sort, context).ConfigureAwait(false); + IReadOnlyList value = default; + using var document = await JsonDocument.ParseAsync(response.ContentStream, default, cancellationToken).ConfigureAwait(false); + List array = new List(); + foreach (var item in document.RootElement.EnumerateArray()) + { + array.Add(AtlasRelatedTermHeader.DeserializeAtlasRelatedTermHeader(item)); + } + value = array; + return Response.FromValue(value, response); + } + + /// Get all terms associated with the specific category. + /// The globally unique identifier of the category. + /// The page size - by default there is no paging. + /// The offset for pagination purpose. + /// The sort order, ASC (default) or DESC. + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual Response> GetCategoryTerms(string categoryId, int? limit = null, int? offset = null, string sort = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(categoryId, nameof(categoryId)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = GetCategoryTerms(categoryId, limit, offset, sort, context); + IReadOnlyList value = default; + using var document = JsonDocument.Parse(response.ContentStream); + List array = new List(); + foreach (var item in document.RootElement.EnumerateArray()) + { + array.Add(AtlasRelatedTermHeader.DeserializeAtlasRelatedTermHeader(item)); + } + value = array; + return Response.FromValue(value, response); + } + + /// + /// [Protocol Method] Get all terms associated with the specific category. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier of the category. + /// The page size - by default there is no paging. + /// The offset for pagination purpose. + /// The sort order, ASC (default) or DESC. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task GetCategoryTermsAsync(string categoryId, int? limit, int? offset, string sort, RequestContext context) + { + Argument.AssertNotNullOrEmpty(categoryId, nameof(categoryId)); + + using var scope = ClientDiagnostics.CreateScope("Glossary.GetCategoryTerms"); + scope.Start(); + try + { + using HttpMessage message = CreateGetCategoryTermsRequest(categoryId, limit, offset, sort, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Get all terms associated with the specific category. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier of the category. + /// The page size - by default there is no paging. + /// The offset for pagination purpose. + /// The sort order, ASC (default) or DESC. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response GetCategoryTerms(string categoryId, int? limit, int? offset, string sort, RequestContext context) + { + Argument.AssertNotNullOrEmpty(categoryId, nameof(categoryId)); + + using var scope = ClientDiagnostics.CreateScope("Glossary.GetCategoryTerms"); + scope.Start(); + try + { + using HttpMessage message = CreateGetCategoryTermsRequest(categoryId, limit, offset, sort, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Create a glossary term. + /// + /// The glossary term definition. A term must be anchored to a Glossary at the time + /// of creation. + /// Optionally it can be categorized as well. + /// + /// Whether include term hierarchy. + /// The cancellation token to use. + /// is null. + /// + public virtual async Task> CreateTermAsync(AtlasGlossaryTerm glossaryTerm, bool? includeTermHierarchy = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNull(glossaryTerm, nameof(glossaryTerm)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = glossaryTerm.ToRequestContent(); + Response response = await CreateTermAsync(content, includeTermHierarchy, context).ConfigureAwait(false); + return Response.FromValue(AtlasGlossaryTerm.FromResponse(response), response); + } + + /// Create a glossary term. + /// + /// The glossary term definition. A term must be anchored to a Glossary at the time + /// of creation. + /// Optionally it can be categorized as well. + /// + /// Whether include term hierarchy. + /// The cancellation token to use. + /// is null. + /// + public virtual Response CreateTerm(AtlasGlossaryTerm glossaryTerm, bool? includeTermHierarchy = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNull(glossaryTerm, nameof(glossaryTerm)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = glossaryTerm.ToRequestContent(); + Response response = CreateTerm(content, includeTermHierarchy, context); + return Response.FromValue(AtlasGlossaryTerm.FromResponse(response), response); + } + + /// + /// [Protocol Method] Create a glossary term. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The content to send as the body of the request. + /// Whether include term hierarchy. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task CreateTermAsync(RequestContent content, bool? includeTermHierarchy = null, RequestContext context = null) + { + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Glossary.CreateTerm"); + scope.Start(); + try + { + using HttpMessage message = CreateCreateTermRequest(content, includeTermHierarchy, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Create a glossary term. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The content to send as the body of the request. + /// Whether include term hierarchy. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response CreateTerm(RequestContent content, bool? includeTermHierarchy = null, RequestContext context = null) + { + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Glossary.CreateTerm"); + scope.Start(); + try + { + using HttpMessage message = CreateCreateTermRequest(content, includeTermHierarchy, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Get a specific glossary term by its GUID. + /// The globally unique identifier for glossary term. + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual async Task> GetTermAsync(string termId, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(termId, nameof(termId)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = await GetTermAsync(termId, context).ConfigureAwait(false); + return Response.FromValue(AtlasGlossaryTerm.FromResponse(response), response); + } + + /// Get a specific glossary term by its GUID. + /// The globally unique identifier for glossary term. + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual Response GetTerm(string termId, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(termId, nameof(termId)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = GetTerm(termId, context); + return Response.FromValue(AtlasGlossaryTerm.FromResponse(response), response); + } + + /// + /// [Protocol Method] Get a specific glossary term by its GUID. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier for glossary term. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task GetTermAsync(string termId, RequestContext context) + { + Argument.AssertNotNullOrEmpty(termId, nameof(termId)); + + using var scope = ClientDiagnostics.CreateScope("Glossary.GetTerm"); + scope.Start(); + try + { + using HttpMessage message = CreateGetTermRequest(termId, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Get a specific glossary term by its GUID. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier for glossary term. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response GetTerm(string termId, RequestContext context) + { + Argument.AssertNotNullOrEmpty(termId, nameof(termId)); + + using var scope = ClientDiagnostics.CreateScope("Glossary.GetTerm"); + scope.Start(); + try + { + using HttpMessage message = CreateGetTermRequest(termId, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Update the given glossary term by its GUID. + /// The globally unique identifier for glossary term. + /// The glossary term to be updated. + /// Whether include term hierarchy. + /// The cancellation token to use. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual async Task> UpdateTermAsync(string termId, AtlasGlossaryTerm glossaryTerm, bool? includeTermHierarchy = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(termId, nameof(termId)); + Argument.AssertNotNull(glossaryTerm, nameof(glossaryTerm)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = glossaryTerm.ToRequestContent(); + Response response = await UpdateTermAsync(termId, content, includeTermHierarchy, context).ConfigureAwait(false); + return Response.FromValue(AtlasGlossaryTerm.FromResponse(response), response); + } + + /// Update the given glossary term by its GUID. + /// The globally unique identifier for glossary term. + /// The glossary term to be updated. + /// Whether include term hierarchy. + /// The cancellation token to use. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual Response UpdateTerm(string termId, AtlasGlossaryTerm glossaryTerm, bool? includeTermHierarchy = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(termId, nameof(termId)); + Argument.AssertNotNull(glossaryTerm, nameof(glossaryTerm)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = glossaryTerm.ToRequestContent(); + Response response = UpdateTerm(termId, content, includeTermHierarchy, context); + return Response.FromValue(AtlasGlossaryTerm.FromResponse(response), response); + } + + /// + /// [Protocol Method] Update the given glossary term by its GUID. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier for glossary term. + /// The content to send as the body of the request. + /// Whether include term hierarchy. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task UpdateTermAsync(string termId, RequestContent content, bool? includeTermHierarchy = null, RequestContext context = null) + { + Argument.AssertNotNullOrEmpty(termId, nameof(termId)); + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Glossary.UpdateTerm"); + scope.Start(); + try + { + using HttpMessage message = CreateUpdateTermRequest(termId, content, includeTermHierarchy, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Update the given glossary term by its GUID. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier for glossary term. + /// The content to send as the body of the request. + /// Whether include term hierarchy. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response UpdateTerm(string termId, RequestContent content, bool? includeTermHierarchy = null, RequestContext context = null) + { + Argument.AssertNotNullOrEmpty(termId, nameof(termId)); + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Glossary.UpdateTerm"); + scope.Start(); + try + { + using HttpMessage message = CreateUpdateTermRequest(termId, content, includeTermHierarchy, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + // The convenience method is omitted here because it has exactly the same parameter list as the corresponding protocol method + /// + /// [Protocol Method] Delete a glossary term. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// The globally unique identifier for glossary term. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task DeleteTermAsync(string termId, RequestContext context = null) + { + Argument.AssertNotNullOrEmpty(termId, nameof(termId)); + + using var scope = ClientDiagnostics.CreateScope("Glossary.DeleteTerm"); + scope.Start(); + try + { + using HttpMessage message = CreateDeleteTermRequest(termId, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + // The convenience method is omitted here because it has exactly the same parameter list as the corresponding protocol method + /// + /// [Protocol Method] Delete a glossary term. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// The globally unique identifier for glossary term. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response DeleteTerm(string termId, RequestContext context = null) + { + Argument.AssertNotNullOrEmpty(termId, nameof(termId)); + + using var scope = ClientDiagnostics.CreateScope("Glossary.DeleteTerm"); + scope.Start(); + try + { + using HttpMessage message = CreateDeleteTermRequest(termId, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// Update the glossary term partially. So far we only supports partial updating + /// shortDescription, longDescription, abbreviation, usage and status for term. + /// + /// The globally unique identifier for glossary term. + /// + /// A map containing keys as attribute names and values as corresponding attribute + /// values to be updated. + /// + /// Whether include term hierarchy. + /// The cancellation token to use. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual async Task> PartialUpdateTermAsync(string termId, BinaryData partialUpdates, bool? includeTermHierarchy = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(termId, nameof(termId)); + Argument.AssertNotNull(partialUpdates, nameof(partialUpdates)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = RequestContentHelper.FromObject(partialUpdates); + Response response = await PartialUpdateTermAsync(termId, content, includeTermHierarchy, context).ConfigureAwait(false); + return Response.FromValue(AtlasGlossaryTerm.FromResponse(response), response); + } + + /// + /// Update the glossary term partially. So far we only supports partial updating + /// shortDescription, longDescription, abbreviation, usage and status for term. + /// + /// The globally unique identifier for glossary term. + /// + /// A map containing keys as attribute names and values as corresponding attribute + /// values to be updated. + /// + /// Whether include term hierarchy. + /// The cancellation token to use. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual Response PartialUpdateTerm(string termId, BinaryData partialUpdates, bool? includeTermHierarchy = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(termId, nameof(termId)); + Argument.AssertNotNull(partialUpdates, nameof(partialUpdates)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = RequestContentHelper.FromObject(partialUpdates); + Response response = PartialUpdateTerm(termId, content, includeTermHierarchy, context); + return Response.FromValue(AtlasGlossaryTerm.FromResponse(response), response); + } + + /// + /// [Protocol Method] Update the glossary term partially. So far we only supports partial updating + /// shortDescription, longDescription, abbreviation, usage and status for term. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier for glossary term. + /// The content to send as the body of the request. + /// Whether include term hierarchy. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task PartialUpdateTermAsync(string termId, RequestContent content, bool? includeTermHierarchy = null, RequestContext context = null) + { + Argument.AssertNotNullOrEmpty(termId, nameof(termId)); + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Glossary.PartialUpdateTerm"); + scope.Start(); + try + { + using HttpMessage message = CreatePartialUpdateTermRequest(termId, content, includeTermHierarchy, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Update the glossary term partially. So far we only supports partial updating + /// shortDescription, longDescription, abbreviation, usage and status for term. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier for glossary term. + /// The content to send as the body of the request. + /// Whether include term hierarchy. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response PartialUpdateTerm(string termId, RequestContent content, bool? includeTermHierarchy = null, RequestContext context = null) + { + Argument.AssertNotNullOrEmpty(termId, nameof(termId)); + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Glossary.PartialUpdateTerm"); + scope.Start(); + try + { + using HttpMessage message = CreatePartialUpdateTermRequest(termId, content, includeTermHierarchy, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Create glossary terms in bulk. + /// An array of glossary term definitions to be created in bulk. + /// Whether include term hierarchy. + /// The cancellation token to use. + /// is null. + /// + public virtual async Task>> CreateTermsAsync(IEnumerable glossaryTerm, bool? includeTermHierarchy = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNull(glossaryTerm, nameof(glossaryTerm)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = RequestContentHelper.FromEnumerable(glossaryTerm); + Response response = await CreateTermsAsync(content, includeTermHierarchy, context).ConfigureAwait(false); + IReadOnlyList value = default; + using var document = await JsonDocument.ParseAsync(response.ContentStream, default, cancellationToken).ConfigureAwait(false); + List array = new List(); + foreach (var item in document.RootElement.EnumerateArray()) + { + array.Add(AtlasGlossaryTerm.DeserializeAtlasGlossaryTerm(item)); + } + value = array; + return Response.FromValue(value, response); + } + + /// Create glossary terms in bulk. + /// An array of glossary term definitions to be created in bulk. + /// Whether include term hierarchy. + /// The cancellation token to use. + /// is null. + /// + public virtual Response> CreateTerms(IEnumerable glossaryTerm, bool? includeTermHierarchy = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNull(glossaryTerm, nameof(glossaryTerm)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = RequestContentHelper.FromEnumerable(glossaryTerm); + Response response = CreateTerms(content, includeTermHierarchy, context); + IReadOnlyList value = default; + using var document = JsonDocument.Parse(response.ContentStream); + List array = new List(); + foreach (var item in document.RootElement.EnumerateArray()) + { + array.Add(AtlasGlossaryTerm.DeserializeAtlasGlossaryTerm(item)); + } + value = array; + return Response.FromValue(value, response); + } + + /// + /// [Protocol Method] Create glossary terms in bulk. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The content to send as the body of the request. + /// Whether include term hierarchy. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task CreateTermsAsync(RequestContent content, bool? includeTermHierarchy = null, RequestContext context = null) + { + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Glossary.CreateTerms"); + scope.Start(); + try + { + using HttpMessage message = CreateCreateTermsRequest(content, includeTermHierarchy, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Create glossary terms in bulk. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The content to send as the body of the request. + /// Whether include term hierarchy. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response CreateTerms(RequestContent content, bool? includeTermHierarchy = null, RequestContext context = null) + { + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Glossary.CreateTerms"); + scope.Start(); + try + { + using HttpMessage message = CreateCreateTermsRequest(content, includeTermHierarchy, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// List all related objects assigned with the specified term. Recommend using + /// limit/offset to get pagination result. + /// + /// The globally unique identifier for glossary term. + /// The page size - by default there is no paging. + /// The offset for pagination purpose. + /// The sort order, ASC (default) or DESC. + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual async Task>> GetEntitiesAssignedWithTermAsync(string termId, int? limit = null, int? offset = null, string sort = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(termId, nameof(termId)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = await GetEntitiesAssignedWithTermAsync(termId, limit, offset, sort, context).ConfigureAwait(false); + IReadOnlyList value = default; + using var document = await JsonDocument.ParseAsync(response.ContentStream, default, cancellationToken).ConfigureAwait(false); + List array = new List(); + foreach (var item in document.RootElement.EnumerateArray()) + { + array.Add(AtlasRelatedObjectId.DeserializeAtlasRelatedObjectId(item)); + } + value = array; + return Response.FromValue(value, response); + } + + /// + /// List all related objects assigned with the specified term. Recommend using + /// limit/offset to get pagination result. + /// + /// The globally unique identifier for glossary term. + /// The page size - by default there is no paging. + /// The offset for pagination purpose. + /// The sort order, ASC (default) or DESC. + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual Response> GetEntitiesAssignedWithTerm(string termId, int? limit = null, int? offset = null, string sort = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(termId, nameof(termId)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = GetEntitiesAssignedWithTerm(termId, limit, offset, sort, context); + IReadOnlyList value = default; + using var document = JsonDocument.Parse(response.ContentStream); + List array = new List(); + foreach (var item in document.RootElement.EnumerateArray()) + { + array.Add(AtlasRelatedObjectId.DeserializeAtlasRelatedObjectId(item)); + } + value = array; + return Response.FromValue(value, response); + } + + /// + /// [Protocol Method] List all related objects assigned with the specified term. Recommend using + /// limit/offset to get pagination result. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier for glossary term. + /// The page size - by default there is no paging. + /// The offset for pagination purpose. + /// The sort order, ASC (default) or DESC. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task GetEntitiesAssignedWithTermAsync(string termId, int? limit, int? offset, string sort, RequestContext context) + { + Argument.AssertNotNullOrEmpty(termId, nameof(termId)); + + using var scope = ClientDiagnostics.CreateScope("Glossary.GetEntitiesAssignedWithTerm"); + scope.Start(); + try + { + using HttpMessage message = CreateGetEntitiesAssignedWithTermRequest(termId, limit, offset, sort, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] List all related objects assigned with the specified term. Recommend using + /// limit/offset to get pagination result. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier for glossary term. + /// The page size - by default there is no paging. + /// The offset for pagination purpose. + /// The sort order, ASC (default) or DESC. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response GetEntitiesAssignedWithTerm(string termId, int? limit, int? offset, string sort, RequestContext context) + { + Argument.AssertNotNullOrEmpty(termId, nameof(termId)); + + using var scope = ClientDiagnostics.CreateScope("Glossary.GetEntitiesAssignedWithTerm"); + scope.Start(); + try + { + using HttpMessage message = CreateGetEntitiesAssignedWithTermRequest(termId, limit, offset, sort, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// Assign the given term to the provided list of related objects. Recommend using + /// small batches with multiple API calls. + /// + /// [Entities Create Or Update + /// operation](https://learn.microsoft.com/en-us/rest/api/purview/datamapdataplane/entity/bulk-create-or-update?tabs=HTTP) + /// is an alternative to assign a term to multiple entities. + /// + /// The globally unique identifier for glossary term. + /// An array of related object IDs to which the term has to be associated. + /// The cancellation token to use. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual async Task AssignTermToEntitiesAsync(string termId, IEnumerable relatedObjectIds, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(termId, nameof(termId)); + Argument.AssertNotNull(relatedObjectIds, nameof(relatedObjectIds)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = RequestContentHelper.FromEnumerable(relatedObjectIds); + Response response = await AssignTermToEntitiesAsync(termId, content, context).ConfigureAwait(false); + return response; + } + + /// + /// Assign the given term to the provided list of related objects. Recommend using + /// small batches with multiple API calls. + /// + /// [Entities Create Or Update + /// operation](https://learn.microsoft.com/en-us/rest/api/purview/datamapdataplane/entity/bulk-create-or-update?tabs=HTTP) + /// is an alternative to assign a term to multiple entities. + /// + /// The globally unique identifier for glossary term. + /// An array of related object IDs to which the term has to be associated. + /// The cancellation token to use. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual Response AssignTermToEntities(string termId, IEnumerable relatedObjectIds, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(termId, nameof(termId)); + Argument.AssertNotNull(relatedObjectIds, nameof(relatedObjectIds)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = RequestContentHelper.FromEnumerable(relatedObjectIds); + Response response = AssignTermToEntities(termId, content, context); + return response; + } + + /// + /// [Protocol Method] Assign the given term to the provided list of related objects. Recommend using + /// small batches with multiple API calls. + /// + /// [Entities Create Or Update + /// operation](https://learn.microsoft.com/en-us/rest/api/purview/datamapdataplane/entity/bulk-create-or-update?tabs=HTTP) + /// is an alternative to assign a term to multiple entities. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier for glossary term. + /// The content to send as the body of the request. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task AssignTermToEntitiesAsync(string termId, RequestContent content, RequestContext context = null) + { + Argument.AssertNotNullOrEmpty(termId, nameof(termId)); + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Glossary.AssignTermToEntities"); + scope.Start(); + try + { + using HttpMessage message = CreateAssignTermToEntitiesRequest(termId, content, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Assign the given term to the provided list of related objects. Recommend using + /// small batches with multiple API calls. + /// + /// [Entities Create Or Update + /// operation](https://learn.microsoft.com/en-us/rest/api/purview/datamapdataplane/entity/bulk-create-or-update?tabs=HTTP) + /// is an alternative to assign a term to multiple entities. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier for glossary term. + /// The content to send as the body of the request. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response AssignTermToEntities(string termId, RequestContent content, RequestContext context = null) + { + Argument.AssertNotNullOrEmpty(termId, nameof(termId)); + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Glossary.AssignTermToEntities"); + scope.Start(); + try + { + using HttpMessage message = CreateAssignTermToEntitiesRequest(termId, content, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Delete the term assignment for the given list of related objects. + /// The globally unique identifier for glossary term. + /// An array of related object IDs from which the term has to be dissociated. + /// The cancellation token to use. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual async Task DeleteTermAssignmentFromEntitiesAsync(string termId, IEnumerable relatedObjectIds, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(termId, nameof(termId)); + Argument.AssertNotNull(relatedObjectIds, nameof(relatedObjectIds)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = RequestContentHelper.FromEnumerable(relatedObjectIds); + Response response = await DeleteTermAssignmentFromEntitiesAsync(termId, content, context).ConfigureAwait(false); + return response; + } + + /// Delete the term assignment for the given list of related objects. + /// The globally unique identifier for glossary term. + /// An array of related object IDs from which the term has to be dissociated. + /// The cancellation token to use. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual Response DeleteTermAssignmentFromEntities(string termId, IEnumerable relatedObjectIds, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(termId, nameof(termId)); + Argument.AssertNotNull(relatedObjectIds, nameof(relatedObjectIds)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = RequestContentHelper.FromEnumerable(relatedObjectIds); + Response response = DeleteTermAssignmentFromEntities(termId, content, context); + return response; + } + + /// + /// [Protocol Method] Delete the term assignment for the given list of related objects. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier for glossary term. + /// The content to send as the body of the request. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task DeleteTermAssignmentFromEntitiesAsync(string termId, RequestContent content, RequestContext context = null) + { + Argument.AssertNotNullOrEmpty(termId, nameof(termId)); + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Glossary.DeleteTermAssignmentFromEntities"); + scope.Start(); + try + { + using HttpMessage message = CreateDeleteTermAssignmentFromEntitiesRequest(termId, content, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Delete the term assignment for the given list of related objects. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier for glossary term. + /// The content to send as the body of the request. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response DeleteTermAssignmentFromEntities(string termId, RequestContent content, RequestContext context = null) + { + Argument.AssertNotNullOrEmpty(termId, nameof(termId)); + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Glossary.DeleteTermAssignmentFromEntities"); + scope.Start(); + try + { + using HttpMessage message = CreateDeleteTermAssignmentFromEntitiesRequest(termId, content, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// Get all related terms for a specific term by its GUID. Limit, offset, and sort + /// parameters are currently not being enabled and won't work even they are passed. + /// + /// The globally unique identifier for glossary term. + /// The page size - by default there is no paging. + /// The offset for pagination purpose. + /// The sort order, ASC (default) or DESC. + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual async Task>>> GetRelatedTermsAsync(string termId, int? limit = null, int? offset = null, string sort = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(termId, nameof(termId)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = await GetRelatedTermsAsync(termId, limit, offset, sort, context).ConfigureAwait(false); + IReadOnlyDictionary> value = default; + using var document = await JsonDocument.ParseAsync(response.ContentStream, default, cancellationToken).ConfigureAwait(false); + Dictionary> dictionary = new Dictionary>(); + foreach (var property in document.RootElement.EnumerateObject()) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + dictionary.Add(property.Name, null); + } + else + { + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(AtlasRelatedTermHeader.DeserializeAtlasRelatedTermHeader(item)); + } + dictionary.Add(property.Name, array); + } + } + value = dictionary; + return Response.FromValue(value, response); + } + + /// + /// Get all related terms for a specific term by its GUID. Limit, offset, and sort + /// parameters are currently not being enabled and won't work even they are passed. + /// + /// The globally unique identifier for glossary term. + /// The page size - by default there is no paging. + /// The offset for pagination purpose. + /// The sort order, ASC (default) or DESC. + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual Response>> GetRelatedTerms(string termId, int? limit = null, int? offset = null, string sort = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(termId, nameof(termId)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = GetRelatedTerms(termId, limit, offset, sort, context); + IReadOnlyDictionary> value = default; + using var document = JsonDocument.Parse(response.ContentStream); + Dictionary> dictionary = new Dictionary>(); + foreach (var property in document.RootElement.EnumerateObject()) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + dictionary.Add(property.Name, null); + } + else + { + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(AtlasRelatedTermHeader.DeserializeAtlasRelatedTermHeader(item)); + } + dictionary.Add(property.Name, array); + } + } + value = dictionary; + return Response.FromValue(value, response); + } + + /// + /// [Protocol Method] Get all related terms for a specific term by its GUID. Limit, offset, and sort + /// parameters are currently not being enabled and won't work even they are passed. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier for glossary term. + /// The page size - by default there is no paging. + /// The offset for pagination purpose. + /// The sort order, ASC (default) or DESC. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task GetRelatedTermsAsync(string termId, int? limit, int? offset, string sort, RequestContext context) + { + Argument.AssertNotNullOrEmpty(termId, nameof(termId)); + + using var scope = ClientDiagnostics.CreateScope("Glossary.GetRelatedTerms"); + scope.Start(); + try + { + using HttpMessage message = CreateGetRelatedTermsRequest(termId, limit, offset, sort, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Get all related terms for a specific term by its GUID. Limit, offset, and sort + /// parameters are currently not being enabled and won't work even they are passed. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier for glossary term. + /// The page size - by default there is no paging. + /// The offset for pagination purpose. + /// The sort order, ASC (default) or DESC. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response GetRelatedTerms(string termId, int? limit, int? offset, string sort, RequestContext context) + { + Argument.AssertNotNullOrEmpty(termId, nameof(termId)); + + using var scope = ClientDiagnostics.CreateScope("Glossary.GetRelatedTerms"); + scope.Start(); + try + { + using HttpMessage message = CreateGetRelatedTermsRequest(termId, limit, offset, sort, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Get a specific Glossary by its GUID. + /// The globally unique identifier for glossary. + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual async Task> GetGlossaryAsync(string glossaryId, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(glossaryId, nameof(glossaryId)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = await GetGlossaryAsync(glossaryId, context).ConfigureAwait(false); + return Response.FromValue(AtlasGlossary.FromResponse(response), response); + } + + /// Get a specific Glossary by its GUID. + /// The globally unique identifier for glossary. + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual Response GetGlossary(string glossaryId, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(glossaryId, nameof(glossaryId)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = GetGlossary(glossaryId, context); + return Response.FromValue(AtlasGlossary.FromResponse(response), response); + } + + /// + /// [Protocol Method] Get a specific Glossary by its GUID. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier for glossary. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task GetGlossaryAsync(string glossaryId, RequestContext context) + { + Argument.AssertNotNullOrEmpty(glossaryId, nameof(glossaryId)); + + using var scope = ClientDiagnostics.CreateScope("Glossary.GetGlossary"); + scope.Start(); + try + { + using HttpMessage message = CreateGetGlossaryRequest(glossaryId, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Get a specific Glossary by its GUID. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier for glossary. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response GetGlossary(string glossaryId, RequestContext context) + { + Argument.AssertNotNullOrEmpty(glossaryId, nameof(glossaryId)); + + using var scope = ClientDiagnostics.CreateScope("Glossary.GetGlossary"); + scope.Start(); + try + { + using HttpMessage message = CreateGetGlossaryRequest(glossaryId, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Update the given glossary. + /// The globally unique identifier for glossary. + /// The glossary definition to be updated. + /// Whether ignore terms and categories. + /// The cancellation token to use. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual async Task> UpdateAsync(string glossaryId, AtlasGlossary updatedGlossary, bool? ignoreTermsAndCategories = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(glossaryId, nameof(glossaryId)); + Argument.AssertNotNull(updatedGlossary, nameof(updatedGlossary)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = updatedGlossary.ToRequestContent(); + Response response = await UpdateAsync(glossaryId, content, ignoreTermsAndCategories, context).ConfigureAwait(false); + return Response.FromValue(AtlasGlossary.FromResponse(response), response); + } + + /// Update the given glossary. + /// The globally unique identifier for glossary. + /// The glossary definition to be updated. + /// Whether ignore terms and categories. + /// The cancellation token to use. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual Response Update(string glossaryId, AtlasGlossary updatedGlossary, bool? ignoreTermsAndCategories = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(glossaryId, nameof(glossaryId)); + Argument.AssertNotNull(updatedGlossary, nameof(updatedGlossary)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = updatedGlossary.ToRequestContent(); + Response response = Update(glossaryId, content, ignoreTermsAndCategories, context); + return Response.FromValue(AtlasGlossary.FromResponse(response), response); + } + + /// + /// [Protocol Method] Update the given glossary. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier for glossary. + /// The content to send as the body of the request. + /// Whether ignore terms and categories. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task UpdateAsync(string glossaryId, RequestContent content, bool? ignoreTermsAndCategories = null, RequestContext context = null) + { + Argument.AssertNotNullOrEmpty(glossaryId, nameof(glossaryId)); + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Glossary.Update"); + scope.Start(); + try + { + using HttpMessage message = CreateUpdateRequest(glossaryId, content, ignoreTermsAndCategories, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Update the given glossary. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier for glossary. + /// The content to send as the body of the request. + /// Whether ignore terms and categories. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response Update(string glossaryId, RequestContent content, bool? ignoreTermsAndCategories = null, RequestContext context = null) + { + Argument.AssertNotNullOrEmpty(glossaryId, nameof(glossaryId)); + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Glossary.Update"); + scope.Start(); + try + { + using HttpMessage message = CreateUpdateRequest(glossaryId, content, ignoreTermsAndCategories, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + // The convenience method is omitted here because it has exactly the same parameter list as the corresponding protocol method + /// + /// [Protocol Method] Delete a glossary. Will delete underlying terms/categories together. Recommend + /// separate delete terms and categories. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// The globally unique identifier for glossary. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task DeleteAsync(string glossaryId, RequestContext context = null) + { + Argument.AssertNotNullOrEmpty(glossaryId, nameof(glossaryId)); + + using var scope = ClientDiagnostics.CreateScope("Glossary.Delete"); + scope.Start(); + try + { + using HttpMessage message = CreateDeleteRequest(glossaryId, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + // The convenience method is omitted here because it has exactly the same parameter list as the corresponding protocol method + /// + /// [Protocol Method] Delete a glossary. Will delete underlying terms/categories together. Recommend + /// separate delete terms and categories. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// The globally unique identifier for glossary. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response Delete(string glossaryId, RequestContext context = null) + { + Argument.AssertNotNullOrEmpty(glossaryId, nameof(glossaryId)); + + using var scope = ClientDiagnostics.CreateScope("Glossary.Delete"); + scope.Start(); + try + { + using HttpMessage message = CreateDeleteRequest(glossaryId, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// Get the categories belonging to a specific glossary. Recommend using + /// limit/offset to get pagination result. + /// + /// The globally unique identifier for glossary. + /// The page size - by default there is no paging. + /// The offset for pagination purpose. + /// The sort order, ASC (default) or DESC. + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual async Task>> GetCategoriesAsync(string glossaryId, int? limit = null, int? offset = null, string sort = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(glossaryId, nameof(glossaryId)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = await GetCategoriesAsync(glossaryId, limit, offset, sort, context).ConfigureAwait(false); + IReadOnlyList value = default; + using var document = await JsonDocument.ParseAsync(response.ContentStream, default, cancellationToken).ConfigureAwait(false); + List array = new List(); + foreach (var item in document.RootElement.EnumerateArray()) + { + array.Add(AtlasGlossaryCategory.DeserializeAtlasGlossaryCategory(item)); + } + value = array; + return Response.FromValue(value, response); + } + + /// + /// Get the categories belonging to a specific glossary. Recommend using + /// limit/offset to get pagination result. + /// + /// The globally unique identifier for glossary. + /// The page size - by default there is no paging. + /// The offset for pagination purpose. + /// The sort order, ASC (default) or DESC. + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual Response> GetCategories(string glossaryId, int? limit = null, int? offset = null, string sort = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(glossaryId, nameof(glossaryId)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = GetCategories(glossaryId, limit, offset, sort, context); + IReadOnlyList value = default; + using var document = JsonDocument.Parse(response.ContentStream); + List array = new List(); + foreach (var item in document.RootElement.EnumerateArray()) + { + array.Add(AtlasGlossaryCategory.DeserializeAtlasGlossaryCategory(item)); + } + value = array; + return Response.FromValue(value, response); + } + + /// + /// [Protocol Method] Get the categories belonging to a specific glossary. Recommend using + /// limit/offset to get pagination result. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier for glossary. + /// The page size - by default there is no paging. + /// The offset for pagination purpose. + /// The sort order, ASC (default) or DESC. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task GetCategoriesAsync(string glossaryId, int? limit, int? offset, string sort, RequestContext context) + { + Argument.AssertNotNullOrEmpty(glossaryId, nameof(glossaryId)); + + using var scope = ClientDiagnostics.CreateScope("Glossary.GetCategories"); + scope.Start(); + try + { + using HttpMessage message = CreateGetCategoriesRequest(glossaryId, limit, offset, sort, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Get the categories belonging to a specific glossary. Recommend using + /// limit/offset to get pagination result. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier for glossary. + /// The page size - by default there is no paging. + /// The offset for pagination purpose. + /// The sort order, ASC (default) or DESC. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response GetCategories(string glossaryId, int? limit, int? offset, string sort, RequestContext context) + { + Argument.AssertNotNullOrEmpty(glossaryId, nameof(glossaryId)); + + using var scope = ClientDiagnostics.CreateScope("Glossary.GetCategories"); + scope.Start(); + try + { + using HttpMessage message = CreateGetCategoriesRequest(glossaryId, limit, offset, sort, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// Get the category headers belonging to a specific glossary. Recommend using + /// limit/offset to get pagination result. + /// + /// The globally unique identifier for glossary. + /// The page size - by default there is no paging. + /// The offset for pagination purpose. + /// The sort order, ASC (default) or DESC. + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual async Task>> GetCategoriesHeadersAsync(string glossaryId, int? limit = null, int? offset = null, string sort = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(glossaryId, nameof(glossaryId)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = await GetCategoriesHeadersAsync(glossaryId, limit, offset, sort, context).ConfigureAwait(false); + IReadOnlyList value = default; + using var document = await JsonDocument.ParseAsync(response.ContentStream, default, cancellationToken).ConfigureAwait(false); + List array = new List(); + foreach (var item in document.RootElement.EnumerateArray()) + { + array.Add(AtlasRelatedCategoryHeader.DeserializeAtlasRelatedCategoryHeader(item)); + } + value = array; + return Response.FromValue(value, response); + } + + /// + /// Get the category headers belonging to a specific glossary. Recommend using + /// limit/offset to get pagination result. + /// + /// The globally unique identifier for glossary. + /// The page size - by default there is no paging. + /// The offset for pagination purpose. + /// The sort order, ASC (default) or DESC. + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual Response> GetCategoriesHeaders(string glossaryId, int? limit = null, int? offset = null, string sort = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(glossaryId, nameof(glossaryId)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = GetCategoriesHeaders(glossaryId, limit, offset, sort, context); + IReadOnlyList value = default; + using var document = JsonDocument.Parse(response.ContentStream); + List array = new List(); + foreach (var item in document.RootElement.EnumerateArray()) + { + array.Add(AtlasRelatedCategoryHeader.DeserializeAtlasRelatedCategoryHeader(item)); + } + value = array; + return Response.FromValue(value, response); + } + + /// + /// [Protocol Method] Get the category headers belonging to a specific glossary. Recommend using + /// limit/offset to get pagination result. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier for glossary. + /// The page size - by default there is no paging. + /// The offset for pagination purpose. + /// The sort order, ASC (default) or DESC. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task GetCategoriesHeadersAsync(string glossaryId, int? limit, int? offset, string sort, RequestContext context) + { + Argument.AssertNotNullOrEmpty(glossaryId, nameof(glossaryId)); + + using var scope = ClientDiagnostics.CreateScope("Glossary.GetCategoriesHeaders"); + scope.Start(); + try + { + using HttpMessage message = CreateGetCategoriesHeadersRequest(glossaryId, limit, offset, sort, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Get the category headers belonging to a specific glossary. Recommend using + /// limit/offset to get pagination result. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier for glossary. + /// The page size - by default there is no paging. + /// The offset for pagination purpose. + /// The sort order, ASC (default) or DESC. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response GetCategoriesHeaders(string glossaryId, int? limit, int? offset, string sort, RequestContext context) + { + Argument.AssertNotNullOrEmpty(glossaryId, nameof(glossaryId)); + + using var scope = ClientDiagnostics.CreateScope("Glossary.GetCategoriesHeaders"); + scope.Start(); + try + { + using HttpMessage message = CreateGetCategoriesHeadersRequest(glossaryId, limit, offset, sort, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// Get a specific glossary with detailed information. This API is not + /// recommend. + /// + /// Recommend to fetch terms/categories details separately using + /// + /// GET /datamap/api/atlas/v2/glossary/{glossaryId}/terms and + /// + /// GET /datamap/api/atlas/v2/glossary/{glossaryId}/categories. + /// + /// The globally unique identifier for glossary. + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual async Task> GetDetailedAsync(string glossaryId, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(glossaryId, nameof(glossaryId)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = await GetDetailedAsync(glossaryId, context).ConfigureAwait(false); + return Response.FromValue(AtlasGlossaryExtInfo.FromResponse(response), response); + } + + /// + /// Get a specific glossary with detailed information. This API is not + /// recommend. + /// + /// Recommend to fetch terms/categories details separately using + /// + /// GET /datamap/api/atlas/v2/glossary/{glossaryId}/terms and + /// + /// GET /datamap/api/atlas/v2/glossary/{glossaryId}/categories. + /// + /// The globally unique identifier for glossary. + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual Response GetDetailed(string glossaryId, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(glossaryId, nameof(glossaryId)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = GetDetailed(glossaryId, context); + return Response.FromValue(AtlasGlossaryExtInfo.FromResponse(response), response); + } + + /// + /// [Protocol Method] Get a specific glossary with detailed information. This API is not + /// recommend. + /// + /// Recommend to fetch terms/categories details separately using + /// + /// GET /datamap/api/atlas/v2/glossary/{glossaryId}/terms and + /// + /// GET /datamap/api/atlas/v2/glossary/{glossaryId}/categories. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier for glossary. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task GetDetailedAsync(string glossaryId, RequestContext context) + { + Argument.AssertNotNullOrEmpty(glossaryId, nameof(glossaryId)); + + using var scope = ClientDiagnostics.CreateScope("Glossary.GetDetailed"); + scope.Start(); + try + { + using HttpMessage message = CreateGetDetailedRequest(glossaryId, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Get a specific glossary with detailed information. This API is not + /// recommend. + /// + /// Recommend to fetch terms/categories details separately using + /// + /// GET /datamap/api/atlas/v2/glossary/{glossaryId}/terms and + /// + /// GET /datamap/api/atlas/v2/glossary/{glossaryId}/categories. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier for glossary. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response GetDetailed(string glossaryId, RequestContext context) + { + Argument.AssertNotNullOrEmpty(glossaryId, nameof(glossaryId)); + + using var scope = ClientDiagnostics.CreateScope("Glossary.GetDetailed"); + scope.Start(); + try + { + using HttpMessage message = CreateGetDetailedRequest(glossaryId, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// Update the glossary partially. Some properties such as qualifiedName are not + /// allowed to be updated. + /// + /// So far we only supports partial updating + /// shortDescription, longDescription, language and usage for glossary. + /// + /// Recommend + /// using 'ignoreTermsAndCategories=true' to reduce response body size. + /// + /// The globally unique identifier for glossary. + /// + /// A map containing keys as attribute names and values as corresponding attribute + /// values. + /// + /// Whether ignore terms and categories. + /// The cancellation token to use. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual async Task> PartialUpdateAsync(string glossaryId, BinaryData partialUpdates, bool? ignoreTermsAndCategories = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(glossaryId, nameof(glossaryId)); + Argument.AssertNotNull(partialUpdates, nameof(partialUpdates)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = RequestContentHelper.FromObject(partialUpdates); + Response response = await PartialUpdateAsync(glossaryId, content, ignoreTermsAndCategories, context).ConfigureAwait(false); + return Response.FromValue(AtlasGlossary.FromResponse(response), response); + } + + /// + /// Update the glossary partially. Some properties such as qualifiedName are not + /// allowed to be updated. + /// + /// So far we only supports partial updating + /// shortDescription, longDescription, language and usage for glossary. + /// + /// Recommend + /// using 'ignoreTermsAndCategories=true' to reduce response body size. + /// + /// The globally unique identifier for glossary. + /// + /// A map containing keys as attribute names and values as corresponding attribute + /// values. + /// + /// Whether ignore terms and categories. + /// The cancellation token to use. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual Response PartialUpdate(string glossaryId, BinaryData partialUpdates, bool? ignoreTermsAndCategories = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(glossaryId, nameof(glossaryId)); + Argument.AssertNotNull(partialUpdates, nameof(partialUpdates)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = RequestContentHelper.FromObject(partialUpdates); + Response response = PartialUpdate(glossaryId, content, ignoreTermsAndCategories, context); + return Response.FromValue(AtlasGlossary.FromResponse(response), response); + } + + /// + /// [Protocol Method] Update the glossary partially. Some properties such as qualifiedName are not + /// allowed to be updated. + /// + /// So far we only supports partial updating + /// shortDescription, longDescription, language and usage for glossary. + /// + /// Recommend + /// using 'ignoreTermsAndCategories=true' to reduce response body size. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier for glossary. + /// The content to send as the body of the request. + /// Whether ignore terms and categories. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task PartialUpdateAsync(string glossaryId, RequestContent content, bool? ignoreTermsAndCategories = null, RequestContext context = null) + { + Argument.AssertNotNullOrEmpty(glossaryId, nameof(glossaryId)); + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Glossary.PartialUpdate"); + scope.Start(); + try + { + using HttpMessage message = CreatePartialUpdateRequest(glossaryId, content, ignoreTermsAndCategories, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Update the glossary partially. Some properties such as qualifiedName are not + /// allowed to be updated. + /// + /// So far we only supports partial updating + /// shortDescription, longDescription, language and usage for glossary. + /// + /// Recommend + /// using 'ignoreTermsAndCategories=true' to reduce response body size. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier for glossary. + /// The content to send as the body of the request. + /// Whether ignore terms and categories. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response PartialUpdate(string glossaryId, RequestContent content, bool? ignoreTermsAndCategories = null, RequestContext context = null) + { + Argument.AssertNotNullOrEmpty(glossaryId, nameof(glossaryId)); + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Glossary.PartialUpdate"); + scope.Start(); + try + { + using HttpMessage message = CreatePartialUpdateRequest(glossaryId, content, ignoreTermsAndCategories, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// Get terms belonging to a specific glossary. Recommend using limit/offset to get + /// pagination result. + /// + /// The globally unique identifier for glossary. + /// The page size - by default there is no paging. + /// The offset for pagination purpose. + /// The sort order, ASC (default) or DESC. + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual async Task>> GetTermsAsync(string glossaryId, int? limit = null, int? offset = null, string sort = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(glossaryId, nameof(glossaryId)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = await GetTermsAsync(glossaryId, limit, offset, sort, context).ConfigureAwait(false); + IReadOnlyList value = default; + using var document = await JsonDocument.ParseAsync(response.ContentStream, default, cancellationToken).ConfigureAwait(false); + List array = new List(); + foreach (var item in document.RootElement.EnumerateArray()) + { + array.Add(AtlasGlossaryTerm.DeserializeAtlasGlossaryTerm(item)); + } + value = array; + return Response.FromValue(value, response); + } + + /// + /// Get terms belonging to a specific glossary. Recommend using limit/offset to get + /// pagination result. + /// + /// The globally unique identifier for glossary. + /// The page size - by default there is no paging. + /// The offset for pagination purpose. + /// The sort order, ASC (default) or DESC. + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual Response> GetTerms(string glossaryId, int? limit = null, int? offset = null, string sort = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(glossaryId, nameof(glossaryId)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = GetTerms(glossaryId, limit, offset, sort, context); + IReadOnlyList value = default; + using var document = JsonDocument.Parse(response.ContentStream); + List array = new List(); + foreach (var item in document.RootElement.EnumerateArray()) + { + array.Add(AtlasGlossaryTerm.DeserializeAtlasGlossaryTerm(item)); + } + value = array; + return Response.FromValue(value, response); + } + + /// + /// [Protocol Method] Get terms belonging to a specific glossary. Recommend using limit/offset to get + /// pagination result. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier for glossary. + /// The page size - by default there is no paging. + /// The offset for pagination purpose. + /// The sort order, ASC (default) or DESC. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task GetTermsAsync(string glossaryId, int? limit, int? offset, string sort, RequestContext context) + { + Argument.AssertNotNullOrEmpty(glossaryId, nameof(glossaryId)); + + using var scope = ClientDiagnostics.CreateScope("Glossary.GetTerms"); + scope.Start(); + try + { + using HttpMessage message = CreateGetTermsRequest(glossaryId, limit, offset, sort, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Get terms belonging to a specific glossary. Recommend using limit/offset to get + /// pagination result. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier for glossary. + /// The page size - by default there is no paging. + /// The offset for pagination purpose. + /// The sort order, ASC (default) or DESC. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response GetTerms(string glossaryId, int? limit, int? offset, string sort, RequestContext context) + { + Argument.AssertNotNullOrEmpty(glossaryId, nameof(glossaryId)); + + using var scope = ClientDiagnostics.CreateScope("Glossary.GetTerms"); + scope.Start(); + try + { + using HttpMessage message = CreateGetTermsRequest(glossaryId, limit, offset, sort, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// Get term headers belonging to a specific glossary. Recommend using limit/offset + /// to get pagination result. + /// + /// The globally unique identifier for glossary. + /// The page size - by default there is no paging. + /// The offset for pagination purpose. + /// The sort order, ASC (default) or DESC. + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual async Task>> GetTermHeadersAsync(string glossaryId, int? limit = null, int? offset = null, string sort = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(glossaryId, nameof(glossaryId)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = await GetTermHeadersAsync(glossaryId, limit, offset, sort, context).ConfigureAwait(false); + IReadOnlyList value = default; + using var document = await JsonDocument.ParseAsync(response.ContentStream, default, cancellationToken).ConfigureAwait(false); + List array = new List(); + foreach (var item in document.RootElement.EnumerateArray()) + { + array.Add(AtlasRelatedTermHeader.DeserializeAtlasRelatedTermHeader(item)); + } + value = array; + return Response.FromValue(value, response); + } + + /// + /// Get term headers belonging to a specific glossary. Recommend using limit/offset + /// to get pagination result. + /// + /// The globally unique identifier for glossary. + /// The page size - by default there is no paging. + /// The offset for pagination purpose. + /// The sort order, ASC (default) or DESC. + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual Response> GetTermHeaders(string glossaryId, int? limit = null, int? offset = null, string sort = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(glossaryId, nameof(glossaryId)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = GetTermHeaders(glossaryId, limit, offset, sort, context); + IReadOnlyList value = default; + using var document = JsonDocument.Parse(response.ContentStream); + List array = new List(); + foreach (var item in document.RootElement.EnumerateArray()) + { + array.Add(AtlasRelatedTermHeader.DeserializeAtlasRelatedTermHeader(item)); + } + value = array; + return Response.FromValue(value, response); + } + + /// + /// [Protocol Method] Get term headers belonging to a specific glossary. Recommend using limit/offset + /// to get pagination result. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier for glossary. + /// The page size - by default there is no paging. + /// The offset for pagination purpose. + /// The sort order, ASC (default) or DESC. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task GetTermHeadersAsync(string glossaryId, int? limit, int? offset, string sort, RequestContext context) + { + Argument.AssertNotNullOrEmpty(glossaryId, nameof(glossaryId)); + + using var scope = ClientDiagnostics.CreateScope("Glossary.GetTermHeaders"); + scope.Start(); + try + { + using HttpMessage message = CreateGetTermHeadersRequest(glossaryId, limit, offset, sort, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Get term headers belonging to a specific glossary. Recommend using limit/offset + /// to get pagination result. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier for glossary. + /// The page size - by default there is no paging. + /// The offset for pagination purpose. + /// The sort order, ASC (default) or DESC. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response GetTermHeaders(string glossaryId, int? limit, int? offset, string sort, RequestContext context) + { + Argument.AssertNotNullOrEmpty(glossaryId, nameof(glossaryId)); + + using var scope = ClientDiagnostics.CreateScope("Glossary.GetTermHeaders"); + scope.Start(); + try + { + using HttpMessage message = CreateGetTermHeadersRequest(glossaryId, limit, offset, sort, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + internal HttpMessage CreateBatchGetRequest(int? limit, int? offset, string sort, bool? ignoreTermsAndCategories, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier200); + var request = message.Request; + request.Method = RequestMethod.Get; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/glossary", false); + uri.AppendQuery("api-version", _apiVersion, true); + if (limit != null) + { + uri.AppendQuery("limit", limit.Value, true); + } + if (offset != null) + { + uri.AppendQuery("offset", offset.Value, true); + } + if (sort != null) + { + uri.AppendQuery("sort", sort, true); + } + if (ignoreTermsAndCategories != null) + { + uri.AppendQuery("ignoreTermsAndCategories", ignoreTermsAndCategories.Value, true); + } + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + return message; + } + + internal HttpMessage CreateCreateRequest(RequestContent content, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier200); + var request = message.Request; + request.Method = RequestMethod.Post; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/glossary", false); + uri.AppendQuery("api-version", _apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + request.Headers.Add("Content-Type", "application/json"); + request.Content = content; + return message; + } + + internal HttpMessage CreateCreateCategoriesRequest(RequestContent content, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier200); + var request = message.Request; + request.Method = RequestMethod.Post; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/glossary/categories", false); + uri.AppendQuery("api-version", _apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + request.Headers.Add("Content-Type", "application/json"); + request.Content = content; + return message; + } + + internal HttpMessage CreateCreateCategoryRequest(RequestContent content, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier200); + var request = message.Request; + request.Method = RequestMethod.Post; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/glossary/category", false); + uri.AppendQuery("api-version", _apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + request.Headers.Add("Content-Type", "application/json"); + request.Content = content; + return message; + } + + internal HttpMessage CreateGetCategoryRequest(string categoryId, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier200); + var request = message.Request; + request.Method = RequestMethod.Get; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/glossary/category/", false); + uri.AppendPath(categoryId, true); + uri.AppendQuery("api-version", _apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + return message; + } + + internal HttpMessage CreateUpdateCategoryRequest(string categoryId, RequestContent content, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier200); + var request = message.Request; + request.Method = RequestMethod.Put; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/glossary/category/", false); + uri.AppendPath(categoryId, true); + uri.AppendQuery("api-version", _apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + request.Headers.Add("Content-Type", "application/json"); + request.Content = content; + return message; + } + + internal HttpMessage CreateDeleteCategoryRequest(string categoryId, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier204); + var request = message.Request; + request.Method = RequestMethod.Delete; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/glossary/category/", false); + uri.AppendPath(categoryId, true); + uri.AppendQuery("api-version", _apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + return message; + } + + internal HttpMessage CreatePartialUpdateCategoryRequest(string categoryId, RequestContent content, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier200); + var request = message.Request; + request.Method = RequestMethod.Put; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/glossary/category/", false); + uri.AppendPath(categoryId, true); + uri.AppendPath("/partial", false); + uri.AppendQuery("api-version", _apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + request.Headers.Add("Content-Type", "application/json"); + request.Content = content; + return message; + } + + internal HttpMessage CreateGetRelatedCategoriesRequest(string categoryId, int? limit, int? offset, string sort, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier200); + var request = message.Request; + request.Method = RequestMethod.Get; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/glossary/category/", false); + uri.AppendPath(categoryId, true); + uri.AppendPath("/related", false); + uri.AppendQuery("api-version", _apiVersion, true); + if (limit != null) + { + uri.AppendQuery("limit", limit.Value, true); + } + if (offset != null) + { + uri.AppendQuery("offset", offset.Value, true); + } + if (sort != null) + { + uri.AppendQuery("sort", sort, true); + } + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + return message; + } + + internal HttpMessage CreateGetCategoryTermsRequest(string categoryId, int? limit, int? offset, string sort, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier200); + var request = message.Request; + request.Method = RequestMethod.Get; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/glossary/category/", false); + uri.AppendPath(categoryId, true); + uri.AppendPath("/terms", false); + uri.AppendQuery("api-version", _apiVersion, true); + if (limit != null) + { + uri.AppendQuery("limit", limit.Value, true); + } + if (offset != null) + { + uri.AppendQuery("offset", offset.Value, true); + } + if (sort != null) + { + uri.AppendQuery("sort", sort, true); + } + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + return message; + } + + internal HttpMessage CreateCreateTermRequest(RequestContent content, bool? includeTermHierarchy, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier200); + var request = message.Request; + request.Method = RequestMethod.Post; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/glossary/term", false); + uri.AppendQuery("api-version", _apiVersion, true); + if (includeTermHierarchy != null) + { + uri.AppendQuery("includeTermHierarchy", includeTermHierarchy.Value, true); + } + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + request.Headers.Add("Content-Type", "application/json"); + request.Content = content; + return message; + } + + internal HttpMessage CreateGetTermRequest(string termId, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier200); + var request = message.Request; + request.Method = RequestMethod.Get; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/glossary/term/", false); + uri.AppendPath(termId, true); + uri.AppendQuery("api-version", _apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + return message; + } + + internal HttpMessage CreateUpdateTermRequest(string termId, RequestContent content, bool? includeTermHierarchy, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier200); + var request = message.Request; + request.Method = RequestMethod.Put; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/glossary/term/", false); + uri.AppendPath(termId, true); + uri.AppendQuery("api-version", _apiVersion, true); + if (includeTermHierarchy != null) + { + uri.AppendQuery("includeTermHierarchy", includeTermHierarchy.Value, true); + } + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + request.Headers.Add("Content-Type", "application/json"); + request.Content = content; + return message; + } + + internal HttpMessage CreateDeleteTermRequest(string termId, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier204); + var request = message.Request; + request.Method = RequestMethod.Delete; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/glossary/term/", false); + uri.AppendPath(termId, true); + uri.AppendQuery("api-version", _apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + return message; + } + + internal HttpMessage CreatePartialUpdateTermRequest(string termId, RequestContent content, bool? includeTermHierarchy, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier200); + var request = message.Request; + request.Method = RequestMethod.Put; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/glossary/term/", false); + uri.AppendPath(termId, true); + uri.AppendPath("/partial", false); + uri.AppendQuery("api-version", _apiVersion, true); + if (includeTermHierarchy != null) + { + uri.AppendQuery("includeTermHierarchy", includeTermHierarchy.Value, true); + } + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + request.Headers.Add("Content-Type", "application/json"); + request.Content = content; + return message; + } + + internal HttpMessage CreateCreateTermsRequest(RequestContent content, bool? includeTermHierarchy, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier200); + var request = message.Request; + request.Method = RequestMethod.Post; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/glossary/terms", false); + uri.AppendQuery("api-version", _apiVersion, true); + if (includeTermHierarchy != null) + { + uri.AppendQuery("includeTermHierarchy", includeTermHierarchy.Value, true); + } + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + request.Headers.Add("Content-Type", "application/json"); + request.Content = content; + return message; + } + + internal HttpMessage CreateGetEntitiesAssignedWithTermRequest(string termId, int? limit, int? offset, string sort, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier200); + var request = message.Request; + request.Method = RequestMethod.Get; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/glossary/terms/", false); + uri.AppendPath(termId, true); + uri.AppendPath("/assignedEntities", false); + uri.AppendQuery("api-version", _apiVersion, true); + if (limit != null) + { + uri.AppendQuery("limit", limit.Value, true); + } + if (offset != null) + { + uri.AppendQuery("offset", offset.Value, true); + } + if (sort != null) + { + uri.AppendQuery("sort", sort, true); + } + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + return message; + } + + internal HttpMessage CreateAssignTermToEntitiesRequest(string termId, RequestContent content, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier204); + var request = message.Request; + request.Method = RequestMethod.Post; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/glossary/terms/", false); + uri.AppendPath(termId, true); + uri.AppendPath("/assignedEntities", false); + uri.AppendQuery("api-version", _apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + request.Headers.Add("Content-Type", "application/json"); + request.Content = content; + return message; + } + + internal HttpMessage CreateDeleteTermAssignmentFromEntitiesRequest(string termId, RequestContent content, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier204); + var request = message.Request; + request.Method = RequestMethod.Delete; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/glossary/terms/", false); + uri.AppendPath(termId, true); + uri.AppendPath("/assignedEntities", false); + uri.AppendQuery("api-version", _apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + request.Headers.Add("Content-Type", "application/json"); + request.Content = content; + return message; + } + + internal HttpMessage CreateGetRelatedTermsRequest(string termId, int? limit, int? offset, string sort, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier200); + var request = message.Request; + request.Method = RequestMethod.Get; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/glossary/terms/", false); + uri.AppendPath(termId, true); + uri.AppendPath("/related", false); + uri.AppendQuery("api-version", _apiVersion, true); + if (limit != null) + { + uri.AppendQuery("limit", limit.Value, true); + } + if (offset != null) + { + uri.AppendQuery("offset", offset.Value, true); + } + if (sort != null) + { + uri.AppendQuery("sort", sort, true); + } + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + return message; + } + + internal HttpMessage CreateGetGlossaryRequest(string glossaryId, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier200); + var request = message.Request; + request.Method = RequestMethod.Get; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/glossary/", false); + uri.AppendPath(glossaryId, true); + uri.AppendQuery("api-version", _apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + return message; + } + + internal HttpMessage CreateUpdateRequest(string glossaryId, RequestContent content, bool? ignoreTermsAndCategories, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier200); + var request = message.Request; + request.Method = RequestMethod.Put; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/glossary/", false); + uri.AppendPath(glossaryId, true); + uri.AppendQuery("api-version", _apiVersion, true); + if (ignoreTermsAndCategories != null) + { + uri.AppendQuery("ignoreTermsAndCategories", ignoreTermsAndCategories.Value, true); + } + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + request.Headers.Add("Content-Type", "application/json"); + request.Content = content; + return message; + } + + internal HttpMessage CreateDeleteRequest(string glossaryId, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier204); + var request = message.Request; + request.Method = RequestMethod.Delete; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/glossary/", false); + uri.AppendPath(glossaryId, true); + uri.AppendQuery("api-version", _apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + return message; + } + + internal HttpMessage CreateGetCategoriesRequest(string glossaryId, int? limit, int? offset, string sort, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier200); + var request = message.Request; + request.Method = RequestMethod.Get; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/glossary/", false); + uri.AppendPath(glossaryId, true); + uri.AppendPath("/categories", false); + uri.AppendQuery("api-version", _apiVersion, true); + if (limit != null) + { + uri.AppendQuery("limit", limit.Value, true); + } + if (offset != null) + { + uri.AppendQuery("offset", offset.Value, true); + } + if (sort != null) + { + uri.AppendQuery("sort", sort, true); + } + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + return message; + } + + internal HttpMessage CreateGetCategoriesHeadersRequest(string glossaryId, int? limit, int? offset, string sort, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier200); + var request = message.Request; + request.Method = RequestMethod.Get; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/glossary/", false); + uri.AppendPath(glossaryId, true); + uri.AppendPath("/categories/headers", false); + uri.AppendQuery("api-version", _apiVersion, true); + if (limit != null) + { + uri.AppendQuery("limit", limit.Value, true); + } + if (offset != null) + { + uri.AppendQuery("offset", offset.Value, true); + } + if (sort != null) + { + uri.AppendQuery("sort", sort, true); + } + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + return message; + } + + internal HttpMessage CreateGetDetailedRequest(string glossaryId, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier200); + var request = message.Request; + request.Method = RequestMethod.Get; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/glossary/", false); + uri.AppendPath(glossaryId, true); + uri.AppendPath("/detailed", false); + uri.AppendQuery("api-version", _apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + return message; + } + + internal HttpMessage CreatePartialUpdateRequest(string glossaryId, RequestContent content, bool? ignoreTermsAndCategories, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier200); + var request = message.Request; + request.Method = RequestMethod.Put; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/glossary/", false); + uri.AppendPath(glossaryId, true); + uri.AppendPath("/partial", false); + uri.AppendQuery("api-version", _apiVersion, true); + if (ignoreTermsAndCategories != null) + { + uri.AppendQuery("ignoreTermsAndCategories", ignoreTermsAndCategories.Value, true); + } + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + request.Headers.Add("Content-Type", "application/json"); + request.Content = content; + return message; + } + + internal HttpMessage CreateGetTermsRequest(string glossaryId, int? limit, int? offset, string sort, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier200); + var request = message.Request; + request.Method = RequestMethod.Get; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/glossary/", false); + uri.AppendPath(glossaryId, true); + uri.AppendPath("/terms", false); + uri.AppendQuery("api-version", _apiVersion, true); + if (limit != null) + { + uri.AppendQuery("limit", limit.Value, true); + } + if (offset != null) + { + uri.AppendQuery("offset", offset.Value, true); + } + if (sort != null) + { + uri.AppendQuery("sort", sort, true); + } + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + return message; + } + + internal HttpMessage CreateGetTermHeadersRequest(string glossaryId, int? limit, int? offset, string sort, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier200); + var request = message.Request; + request.Method = RequestMethod.Get; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/glossary/", false); + uri.AppendPath(glossaryId, true); + uri.AppendPath("/terms/headers", false); + uri.AppendQuery("api-version", _apiVersion, true); + if (limit != null) + { + uri.AppendQuery("limit", limit.Value, true); + } + if (offset != null) + { + uri.AppendQuery("offset", offset.Value, true); + } + if (sort != null) + { + uri.AppendQuery("sort", sort, true); + } + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + return message; + } + + private static RequestContext DefaultRequestContext = new RequestContext(); + internal static RequestContext FromCancellationToken(CancellationToken cancellationToken = default) + { + if (!cancellationToken.CanBeCanceled) + { + return DefaultRequestContext; + } + + return new RequestContext() { CancellationToken = cancellationToken }; + } + + private static ResponseClassifier _responseClassifier200; + private static ResponseClassifier ResponseClassifier200 => _responseClassifier200 ??= new StatusCodeClassifier(stackalloc ushort[] { 200 }); + private static ResponseClassifier _responseClassifier204; + private static ResponseClassifier ResponseClassifier204 => _responseClassifier204 ??= new StatusCodeClassifier(stackalloc ushort[] { 204 }); + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/GlossaryFilter.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/GlossaryFilter.Serialization.cs new file mode 100644 index 0000000000000..bfd549a839640 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/GlossaryFilter.Serialization.cs @@ -0,0 +1,33 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class GlossaryFilter : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + writer.WritePropertyName("glossaryType"u8); + writer.WriteStringValue(GlossaryType); + writer.WritePropertyName("kind"u8); + writer.WriteStringValue(Kind); + writer.WriteEndObject(); + } + + /// Convert into a Utf8JsonRequestContent. + internal override RequestContent ToRequestContent() + { + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(this); + return content; + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/GlossaryFilter.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/GlossaryFilter.cs new file mode 100644 index 0000000000000..a0f2be7c282e9 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/GlossaryFilter.cs @@ -0,0 +1,38 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + /// Glossary filter for search. + public partial class GlossaryFilter : SearchFilter + { + /// Initializes a new instance of . + /// Glossary type. Either AtlasGlossary or AtlasGlossaryType. + /// is null. + public GlossaryFilter(string glossaryType) + { + Argument.AssertNotNull(glossaryType, nameof(glossaryType)); + + Kind = "GlossaryFilter"; + GlossaryType = glossaryType; + } + + /// Initializes a new instance of . + /// Discriminator. + /// Glossary type. Either AtlasGlossary or AtlasGlossaryType. + internal GlossaryFilter(string kind, string glossaryType) : base(kind) + { + GlossaryType = glossaryType; + } + + /// Glossary type. Either AtlasGlossary or AtlasGlossaryType. + public string GlossaryType { get; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/IdFilter.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/IdFilter.Serialization.cs new file mode 100644 index 0000000000000..caf13d2b09f4b --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/IdFilter.Serialization.cs @@ -0,0 +1,33 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class IdFilter : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + writer.WritePropertyName("id"u8); + writer.WriteStringValue(Id); + writer.WritePropertyName("kind"u8); + writer.WriteStringValue(Kind); + writer.WriteEndObject(); + } + + /// Convert into a Utf8JsonRequestContent. + internal override RequestContent ToRequestContent() + { + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(this); + return content; + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/IdFilter.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/IdFilter.cs new file mode 100644 index 0000000000000..1ed0b8a4c721b --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/IdFilter.cs @@ -0,0 +1,38 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + /// Id filter for search. + public partial class IdFilter : SearchFilter + { + /// Initializes a new instance of . + /// Id value. + /// is null. + public IdFilter(string id) + { + Argument.AssertNotNull(id, nameof(id)); + + Kind = "IdFilter"; + Id = id; + } + + /// Initializes a new instance of . + /// Discriminator. + /// Id value. + internal IdFilter(string kind, string id) : base(kind) + { + Id = id; + } + + /// Id value. + public string Id { get; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ImportBusinessMetadataRequest.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ImportBusinessMetadataRequest.Serialization.cs new file mode 100644 index 0000000000000..8041344ef99ad --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ImportBusinessMetadataRequest.Serialization.cs @@ -0,0 +1,31 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + internal partial class ImportBusinessMetadataRequest : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + writer.WritePropertyName("uploadedInputStream"u8); + writer.WriteBase64StringValue(UploadedInputStream.ToArray(), "D"); + writer.WriteEndObject(); + } + + /// Convert into a Utf8JsonRequestContent. + internal virtual RequestContent ToRequestContent() + { + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(this); + return content; + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ImportBusinessMetadataRequest.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ImportBusinessMetadataRequest.cs new file mode 100644 index 0000000000000..1506f37ec5409 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ImportBusinessMetadataRequest.cs @@ -0,0 +1,44 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + /// The ImportBusinessMetadataRequest. + internal partial class ImportBusinessMetadataRequest + { + /// Initializes a new instance of . + /// InputStream of file. + /// is null. + public ImportBusinessMetadataRequest(BinaryData uploadedInputStream) + { + Argument.AssertNotNull(uploadedInputStream, nameof(uploadedInputStream)); + + UploadedInputStream = uploadedInputStream; + } + + /// + /// InputStream of file + /// + /// To assign a byte[] to this property use . + /// The byte[] will be serialized to a Base64 encoded string. + /// + /// + /// Examples: + /// + /// + /// BinaryData.FromBytes(new byte[] { 1, 2, 3 }) + /// Creates a payload of "AQID". + /// + /// + /// + /// + public BinaryData UploadedInputStream { get; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ImportInfo.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ImportInfo.Serialization.cs new file mode 100644 index 0000000000000..d297f461ded9a --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ImportInfo.Serialization.cs @@ -0,0 +1,64 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class ImportInfo + { + internal static ImportInfo DeserializeImportInfo(JsonElement element) + { + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + Optional childObjectName = default; + Optional importStatus = default; + Optional parentObjectName = default; + Optional remarks = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("childObjectName"u8)) + { + childObjectName = property.Value.GetString(); + continue; + } + if (property.NameEquals("importStatus"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + importStatus = new ImportStatus(property.Value.GetString()); + continue; + } + if (property.NameEquals("parentObjectName"u8)) + { + parentObjectName = property.Value.GetString(); + continue; + } + if (property.NameEquals("remarks"u8)) + { + remarks = property.Value.GetString(); + continue; + } + } + return new ImportInfo(childObjectName.Value, Optional.ToNullable(importStatus), parentObjectName.Value, remarks.Value); + } + + /// Deserializes the model from a raw response. + /// The response to deserialize the model from. + internal static ImportInfo FromResponse(Response response) + { + using var document = JsonDocument.Parse(response.Content); + return DeserializeImportInfo(document.RootElement); + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ImportInfo.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ImportInfo.cs new file mode 100644 index 0000000000000..fdd8523ae2e45 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ImportInfo.cs @@ -0,0 +1,40 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +namespace Azure.Analytics.Purview.DataMap +{ + /// ImportInfo. + public partial class ImportInfo + { + /// Initializes a new instance of . + internal ImportInfo() + { + } + + /// Initializes a new instance of . + /// childObjectName. + /// importStatus. + /// parentObjectName. + /// remarks. + internal ImportInfo(string childObjectName, ImportStatus? importStatus, string parentObjectName, string remarks) + { + ChildObjectName = childObjectName; + ImportStatus = importStatus; + ParentObjectName = parentObjectName; + Remarks = remarks; + } + + /// childObjectName. + public string ChildObjectName { get; } + /// importStatus. + public ImportStatus? ImportStatus { get; } + /// parentObjectName. + public string ParentObjectName { get; } + /// remarks. + public string Remarks { get; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ImportStatus.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ImportStatus.cs new file mode 100644 index 0000000000000..92997bc1c4f38 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ImportStatus.cs @@ -0,0 +1,51 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.ComponentModel; + +namespace Azure.Analytics.Purview.DataMap +{ + /// Status for import. + public readonly partial struct ImportStatus : IEquatable + { + private readonly string _value; + + /// Initializes a new instance of . + /// is null. + public ImportStatus(string value) + { + _value = value ?? throw new ArgumentNullException(nameof(value)); + } + + private const string SuccessValue = "SUCCESS"; + private const string FailedValue = "FAILED"; + + /// Success. + public static ImportStatus Success { get; } = new ImportStatus(SuccessValue); + /// Failed. + public static ImportStatus Failed { get; } = new ImportStatus(FailedValue); + /// Determines if two values are the same. + public static bool operator ==(ImportStatus left, ImportStatus right) => left.Equals(right); + /// Determines if two values are not the same. + public static bool operator !=(ImportStatus left, ImportStatus right) => !left.Equals(right); + /// Converts a string to a . + public static implicit operator ImportStatus(string value) => new ImportStatus(value); + + /// + [EditorBrowsable(EditorBrowsableState.Never)] + public override bool Equals(object obj) => obj is ImportStatus other && Equals(other); + /// + public bool Equals(ImportStatus other) => string.Equals(_value, other._value, StringComparison.InvariantCultureIgnoreCase); + + /// + [EditorBrowsable(EditorBrowsableState.Never)] + public override int GetHashCode() => _value?.GetHashCode() ?? 0; + /// + public override string ToString() => _value; + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/LabelFilter.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/LabelFilter.Serialization.cs new file mode 100644 index 0000000000000..6b410582391b8 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/LabelFilter.Serialization.cs @@ -0,0 +1,38 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class LabelFilter : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + writer.WritePropertyName("label"u8); + writer.WriteStringValue(Label); + if (Optional.IsDefined(IncludeSubLabels)) + { + writer.WritePropertyName("includeSubLabels"u8); + writer.WriteBooleanValue(IncludeSubLabels.Value); + } + writer.WritePropertyName("kind"u8); + writer.WriteStringValue(Kind); + writer.WriteEndObject(); + } + + /// Convert into a Utf8JsonRequestContent. + internal override RequestContent ToRequestContent() + { + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(this); + return content; + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/LabelFilter.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/LabelFilter.cs new file mode 100644 index 0000000000000..2916afde5609d --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/LabelFilter.cs @@ -0,0 +1,42 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + /// Label filter for search. + public partial class LabelFilter : SearchFilter + { + /// Initializes a new instance of . + /// Label. + /// is null. + public LabelFilter(string label) + { + Argument.AssertNotNull(label, nameof(label)); + + Kind = "LabelFilter"; + Label = label; + } + + /// Initializes a new instance of . + /// Discriminator. + /// Label. + /// Whether to include sub labels. + internal LabelFilter(string kind, string label, bool? includeSubLabels) : base(kind) + { + Label = label; + IncludeSubLabels = includeSubLabels; + } + + /// Label. + public string Label { get; } + /// Whether to include sub labels. + public bool? IncludeSubLabels { get; set; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/Lineage.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/Lineage.cs new file mode 100644 index 0000000000000..0db88b6e723cf --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/Lineage.cs @@ -0,0 +1,583 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Threading; +using System.Threading.Tasks; +using Azure; +using Azure.Core; +using Azure.Core.Pipeline; + +namespace Azure.Analytics.Purview.DataMap +{ + // Data plane generated sub-client. + /// The Lineage sub-client. + public partial class Lineage + { + private static readonly string[] AuthorizationScopes = new string[] { "https://purview.azure.net/.default" }; + private readonly TokenCredential _tokenCredential; + private readonly HttpPipeline _pipeline; + private readonly Uri _endpoint; + private readonly string _apiVersion; + + /// The ClientDiagnostics is used to provide tracing support for the client library. + internal ClientDiagnostics ClientDiagnostics { get; } + + /// The HTTP pipeline for sending and receiving REST requests and responses. + public virtual HttpPipeline Pipeline => _pipeline; + + /// Initializes a new instance of Lineage for mocking. + protected Lineage() + { + } + + /// Initializes a new instance of Lineage. + /// The handler for diagnostic messaging in the client. + /// The HTTP pipeline for sending and receiving REST requests and responses. + /// The token credential to copy. + /// The to use. + /// The to use. + internal Lineage(ClientDiagnostics clientDiagnostics, HttpPipeline pipeline, TokenCredential tokenCredential, Uri endpoint, string apiVersion) + { + ClientDiagnostics = clientDiagnostics; + _pipeline = pipeline; + _tokenCredential = tokenCredential; + _endpoint = endpoint; + _apiVersion = apiVersion; + } + + /// Get lineage info of the entity specified by GUID. + /// The globally unique identifier of the entity. + /// The direction of the lineage, which could be INPUT, OUTPUT or BOTH. + /// The number of hops for lineage. + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual async Task> GetLineageAsync(string guid, LineageDirection direction, int? depth = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = await GetLineageAsync(guid, direction.ToString(), depth, context).ConfigureAwait(false); + return Response.FromValue(AtlasLineageInfo.FromResponse(response), response); + } + + /// Get lineage info of the entity specified by GUID. + /// The globally unique identifier of the entity. + /// The direction of the lineage, which could be INPUT, OUTPUT or BOTH. + /// The number of hops for lineage. + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual Response GetLineage(string guid, LineageDirection direction, int? depth = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = GetLineage(guid, direction.ToString(), depth, context); + return Response.FromValue(AtlasLineageInfo.FromResponse(response), response); + } + + /// + /// [Protocol Method] Get lineage info of the entity specified by GUID. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier of the entity. + /// The direction of the lineage, which could be INPUT, OUTPUT or BOTH. Allowed values: "INPUT" | "OUTPUT" | "BOTH". + /// The number of hops for lineage. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task GetLineageAsync(string guid, string direction, int? depth = null, RequestContext context = null) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + Argument.AssertNotNull(direction, nameof(direction)); + + using var scope = ClientDiagnostics.CreateScope("Lineage.GetLineage"); + scope.Start(); + try + { + using HttpMessage message = CreateGetLineageRequest(guid, direction, depth, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Get lineage info of the entity specified by GUID. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier of the entity. + /// The direction of the lineage, which could be INPUT, OUTPUT or BOTH. Allowed values: "INPUT" | "OUTPUT" | "BOTH". + /// The number of hops for lineage. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response GetLineage(string guid, string direction, int? depth = null, RequestContext context = null) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + Argument.AssertNotNull(direction, nameof(direction)); + + using var scope = ClientDiagnostics.CreateScope("Lineage.GetLineage"); + scope.Start(); + try + { + using HttpMessage message = CreateGetLineageRequest(guid, direction, depth, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Return immediate next page lineage info about entity with pagination. + /// The globally unique identifier of the entity. + /// The direction of the lineage, which could be INPUT, OUTPUT or BOTH. + /// The offset for pagination purpose. + /// The page size - by default there is no paging. + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual async Task> GetNextPageAsync(string guid, LineageDirection direction, int? offset = null, int? limit = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = await GetNextPageAsync(guid, direction.ToString(), offset, limit, context).ConfigureAwait(false); + return Response.FromValue(AtlasLineageInfo.FromResponse(response), response); + } + + /// Return immediate next page lineage info about entity with pagination. + /// The globally unique identifier of the entity. + /// The direction of the lineage, which could be INPUT, OUTPUT or BOTH. + /// The offset for pagination purpose. + /// The page size - by default there is no paging. + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual Response GetNextPage(string guid, LineageDirection direction, int? offset = null, int? limit = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = GetNextPage(guid, direction.ToString(), offset, limit, context); + return Response.FromValue(AtlasLineageInfo.FromResponse(response), response); + } + + /// + /// [Protocol Method] Return immediate next page lineage info about entity with pagination + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier of the entity. + /// The direction of the lineage, which could be INPUT, OUTPUT or BOTH. Allowed values: "INPUT" | "OUTPUT" | "BOTH". + /// The offset for pagination purpose. + /// The page size - by default there is no paging. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task GetNextPageAsync(string guid, string direction, int? offset = null, int? limit = null, RequestContext context = null) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + Argument.AssertNotNull(direction, nameof(direction)); + + using var scope = ClientDiagnostics.CreateScope("Lineage.GetNextPage"); + scope.Start(); + try + { + using HttpMessage message = CreateGetNextPageRequest(guid, direction, offset, limit, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Return immediate next page lineage info about entity with pagination + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier of the entity. + /// The direction of the lineage, which could be INPUT, OUTPUT or BOTH. Allowed values: "INPUT" | "OUTPUT" | "BOTH". + /// The offset for pagination purpose. + /// The page size - by default there is no paging. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response GetNextPage(string guid, string direction, int? offset = null, int? limit = null, RequestContext context = null) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + Argument.AssertNotNull(direction, nameof(direction)); + + using var scope = ClientDiagnostics.CreateScope("Lineage.GetNextPage"); + scope.Start(); + try + { + using HttpMessage message = CreateGetNextPageRequest(guid, direction, offset, limit, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// Return lineage info about entity. + /// + /// In addition to the typeName path parameter, + /// attribute key-value pair(s) can be provided in the following + /// format + /// + /// attr:[attrName]=[attrValue] + /// + /// NOTE: The attrName and attrValue should be + /// unique across entities, eg. qualifiedName. + /// + /// The REST request would look + /// something like this: + /// + /// GET + /// /v2/lineage/uniqueAttribute/type/aType?attr:aTypeAttribute=someValue. + /// + /// The name of the type. + /// The direction of the lineage, which could be INPUT, OUTPUT or BOTH. + /// The number of hops for lineage. + /// + /// The qualified name of the entity. (This is only an example. qualifiedName can + /// be changed to other unique attributes) + /// + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual async Task> GetByUniqueAttributeAsync(string typeName, LineageDirection direction, int? depth = null, string attr = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(typeName, nameof(typeName)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = await GetByUniqueAttributeAsync(typeName, direction.ToString(), depth, attr, context).ConfigureAwait(false); + return Response.FromValue(AtlasLineageInfo.FromResponse(response), response); + } + + /// + /// Return lineage info about entity. + /// + /// In addition to the typeName path parameter, + /// attribute key-value pair(s) can be provided in the following + /// format + /// + /// attr:[attrName]=[attrValue] + /// + /// NOTE: The attrName and attrValue should be + /// unique across entities, eg. qualifiedName. + /// + /// The REST request would look + /// something like this: + /// + /// GET + /// /v2/lineage/uniqueAttribute/type/aType?attr:aTypeAttribute=someValue. + /// + /// The name of the type. + /// The direction of the lineage, which could be INPUT, OUTPUT or BOTH. + /// The number of hops for lineage. + /// + /// The qualified name of the entity. (This is only an example. qualifiedName can + /// be changed to other unique attributes) + /// + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual Response GetByUniqueAttribute(string typeName, LineageDirection direction, int? depth = null, string attr = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(typeName, nameof(typeName)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = GetByUniqueAttribute(typeName, direction.ToString(), depth, attr, context); + return Response.FromValue(AtlasLineageInfo.FromResponse(response), response); + } + + /// + /// [Protocol Method] Return lineage info about entity. + /// + /// In addition to the typeName path parameter, + /// attribute key-value pair(s) can be provided in the following + /// format + /// + /// attr:[attrName]=[attrValue] + /// + /// NOTE: The attrName and attrValue should be + /// unique across entities, eg. qualifiedName. + /// + /// The REST request would look + /// something like this: + /// + /// GET + /// /v2/lineage/uniqueAttribute/type/aType?attr:aTypeAttribute=someValue. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The name of the type. + /// The direction of the lineage, which could be INPUT, OUTPUT or BOTH. Allowed values: "INPUT" | "OUTPUT" | "BOTH". + /// The number of hops for lineage. + /// + /// The qualified name of the entity. (This is only an example. qualifiedName can + /// be changed to other unique attributes) + /// + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task GetByUniqueAttributeAsync(string typeName, string direction, int? depth = null, string attr = null, RequestContext context = null) + { + Argument.AssertNotNullOrEmpty(typeName, nameof(typeName)); + Argument.AssertNotNull(direction, nameof(direction)); + + using var scope = ClientDiagnostics.CreateScope("Lineage.GetByUniqueAttribute"); + scope.Start(); + try + { + using HttpMessage message = CreateGetByUniqueAttributeRequest(typeName, direction, depth, attr, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Return lineage info about entity. + /// + /// In addition to the typeName path parameter, + /// attribute key-value pair(s) can be provided in the following + /// format + /// + /// attr:[attrName]=[attrValue] + /// + /// NOTE: The attrName and attrValue should be + /// unique across entities, eg. qualifiedName. + /// + /// The REST request would look + /// something like this: + /// + /// GET + /// /v2/lineage/uniqueAttribute/type/aType?attr:aTypeAttribute=someValue. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The name of the type. + /// The direction of the lineage, which could be INPUT, OUTPUT or BOTH. Allowed values: "INPUT" | "OUTPUT" | "BOTH". + /// The number of hops for lineage. + /// + /// The qualified name of the entity. (This is only an example. qualifiedName can + /// be changed to other unique attributes) + /// + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// or is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response GetByUniqueAttribute(string typeName, string direction, int? depth = null, string attr = null, RequestContext context = null) + { + Argument.AssertNotNullOrEmpty(typeName, nameof(typeName)); + Argument.AssertNotNull(direction, nameof(direction)); + + using var scope = ClientDiagnostics.CreateScope("Lineage.GetByUniqueAttribute"); + scope.Start(); + try + { + using HttpMessage message = CreateGetByUniqueAttributeRequest(typeName, direction, depth, attr, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + internal HttpMessage CreateGetLineageRequest(string guid, string direction, int? depth, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier200); + var request = message.Request; + request.Method = RequestMethod.Get; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/lineage/", false); + uri.AppendPath(guid, true); + uri.AppendQuery("direction", direction, true); + uri.AppendQuery("api-version", _apiVersion, true); + if (depth != null) + { + uri.AppendQuery("depth", depth.Value, true); + } + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + return message; + } + + internal HttpMessage CreateGetNextPageRequest(string guid, string direction, int? offset, int? limit, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier200); + var request = message.Request; + request.Method = RequestMethod.Get; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/lineage/", false); + uri.AppendPath(guid, true); + uri.AppendPath("/next", false); + uri.AppendQuery("direction", direction, true); + uri.AppendQuery("api-version", _apiVersion, true); + if (offset != null) + { + uri.AppendQuery("offset", offset.Value, true); + } + if (limit != null) + { + uri.AppendQuery("limit", limit.Value, true); + } + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + return message; + } + + internal HttpMessage CreateGetByUniqueAttributeRequest(string typeName, string direction, int? depth, string attr, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier200); + var request = message.Request; + request.Method = RequestMethod.Get; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/lineage/uniqueAttribute/type/", false); + uri.AppendPath(typeName, true); + uri.AppendQuery("direction", direction, true); + uri.AppendQuery("api-version", _apiVersion, true); + if (depth != null) + { + uri.AppendQuery("depth", depth.Value, true); + } + if (attr != null) + { + uri.AppendQuery("attr:qualifiedName", attr, true); + } + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + return message; + } + + private static RequestContext DefaultRequestContext = new RequestContext(); + internal static RequestContext FromCancellationToken(CancellationToken cancellationToken = default) + { + if (!cancellationToken.CanBeCanceled) + { + return DefaultRequestContext; + } + + return new RequestContext() { CancellationToken = cancellationToken }; + } + + private static ResponseClassifier _responseClassifier200; + private static ResponseClassifier ResponseClassifier200 => _responseClassifier200 ??= new StatusCodeClassifier(stackalloc ushort[] { 200 }); + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/LineageDirection.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/LineageDirection.cs new file mode 100644 index 0000000000000..4fedf8acaf217 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/LineageDirection.cs @@ -0,0 +1,54 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.ComponentModel; + +namespace Azure.Analytics.Purview.DataMap +{ + /// Lineage direction. + public readonly partial struct LineageDirection : IEquatable + { + private readonly string _value; + + /// Initializes a new instance of . + /// is null. + public LineageDirection(string value) + { + _value = value ?? throw new ArgumentNullException(nameof(value)); + } + + private const string InputValue = "INPUT"; + private const string OutputValue = "OUTPUT"; + private const string BothValue = "BOTH"; + + /// input. + public static LineageDirection Input { get; } = new LineageDirection(InputValue); + /// output. + public static LineageDirection Output { get; } = new LineageDirection(OutputValue); + /// both. + public static LineageDirection Both { get; } = new LineageDirection(BothValue); + /// Determines if two values are the same. + public static bool operator ==(LineageDirection left, LineageDirection right) => left.Equals(right); + /// Determines if two values are not the same. + public static bool operator !=(LineageDirection left, LineageDirection right) => !left.Equals(right); + /// Converts a string to a . + public static implicit operator LineageDirection(string value) => new LineageDirection(value); + + /// + [EditorBrowsable(EditorBrowsableState.Never)] + public override bool Equals(object obj) => obj is LineageDirection other && Equals(other); + /// + public bool Equals(LineageDirection other) => string.Equals(_value, other._value, StringComparison.InvariantCultureIgnoreCase); + + /// + [EditorBrowsable(EditorBrowsableState.Never)] + public override int GetHashCode() => _value?.GetHashCode() ?? 0; + /// + public override string ToString() => _value; + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/LineageRelation.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/LineageRelation.Serialization.cs new file mode 100644 index 0000000000000..51d0721229e62 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/LineageRelation.Serialization.cs @@ -0,0 +1,54 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class LineageRelation + { + internal static LineageRelation DeserializeLineageRelation(JsonElement element) + { + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + Optional fromEntityId = default; + Optional relationshipId = default; + Optional toEntityId = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("fromEntityId"u8)) + { + fromEntityId = property.Value.GetString(); + continue; + } + if (property.NameEquals("relationshipId"u8)) + { + relationshipId = property.Value.GetString(); + continue; + } + if (property.NameEquals("toEntityId"u8)) + { + toEntityId = property.Value.GetString(); + continue; + } + } + return new LineageRelation(fromEntityId.Value, relationshipId.Value, toEntityId.Value); + } + + /// Deserializes the model from a raw response. + /// The response to deserialize the model from. + internal static LineageRelation FromResponse(Response response) + { + using var document = JsonDocument.Parse(response.Content); + return DeserializeLineageRelation(document.RootElement); + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/LineageRelation.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/LineageRelation.cs new file mode 100644 index 0000000000000..2396c8242c8e5 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/LineageRelation.cs @@ -0,0 +1,36 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +namespace Azure.Analytics.Purview.DataMap +{ + /// The lineage relation with GUID of the from and to entity. + public partial class LineageRelation + { + /// Initializes a new instance of . + internal LineageRelation() + { + } + + /// Initializes a new instance of . + /// The GUID of from-entity. + /// The GUID of relationship. + /// The GUID of to-entity. + internal LineageRelation(string fromEntityId, string relationshipId, string toEntityId) + { + FromEntityId = fromEntityId; + RelationshipId = relationshipId; + ToEntityId = toEntityId; + } + + /// The GUID of from-entity. + public string FromEntityId { get; } + /// The GUID of relationship. + public string RelationshipId { get; } + /// The GUID of to-entity. + public string ToEntityId { get; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/MoveEntitiesOptions.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/MoveEntitiesOptions.Serialization.cs new file mode 100644 index 0000000000000..5f94229cbb89d --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/MoveEntitiesOptions.Serialization.cs @@ -0,0 +1,39 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class MoveEntitiesOptions : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + if (Optional.IsCollectionDefined(EntityGuids)) + { + writer.WritePropertyName("entityGuids"u8); + writer.WriteStartArray(); + foreach (var item in EntityGuids) + { + writer.WriteStringValue(item); + } + writer.WriteEndArray(); + } + writer.WriteEndObject(); + } + + /// Convert into a Utf8JsonRequestContent. + internal virtual RequestContent ToRequestContent() + { + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(this); + return content; + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/MoveEntitiesOptions.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/MoveEntitiesOptions.cs new file mode 100644 index 0000000000000..6ada68fa6cb54 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/MoveEntitiesOptions.cs @@ -0,0 +1,32 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + /// MoveEntitiesContent. + public partial class MoveEntitiesOptions + { + /// Initializes a new instance of . + public MoveEntitiesOptions() + { + EntityGuids = new ChangeTrackingList(); + } + + /// Initializes a new instance of . + /// An array of entity guids to be moved to target collection. + internal MoveEntitiesOptions(IList entityGuids) + { + EntityGuids = entityGuids; + } + + /// An array of entity guids to be moved to target collection. + public IList EntityGuids { get; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/NotFilter.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/NotFilter.Serialization.cs new file mode 100644 index 0000000000000..6f686e370049e --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/NotFilter.Serialization.cs @@ -0,0 +1,33 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class NotFilter : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + writer.WritePropertyName("not"u8); + writer.WriteObjectValue(NotFilters); + writer.WritePropertyName("kind"u8); + writer.WriteStringValue(Kind); + writer.WriteEndObject(); + } + + /// Convert into a Utf8JsonRequestContent. + internal override RequestContent ToRequestContent() + { + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(this); + return content; + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/NotFilter.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/NotFilter.cs new file mode 100644 index 0000000000000..e2bd19e3229eb --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/NotFilter.cs @@ -0,0 +1,42 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + /// Not filter for search. + public partial class NotFilter : SearchFilter + { + /// Initializes a new instance of . + /// Not filter. + /// is null. + public NotFilter(SearchFilter notFilters) + { + Argument.AssertNotNull(notFilters, nameof(notFilters)); + + Kind = "NotFilter"; + NotFilters = notFilters; + } + + /// Initializes a new instance of . + /// Discriminator. + /// Not filter. + internal NotFilter(string kind, SearchFilter notFilters) : base(kind) + { + NotFilters = notFilters; + } + + /// + /// Not filter + /// Please note is the base class. According to the scenario, a derived class of the base class might need to be assigned here, or this property needs to be casted to one of the possible derived classes. + /// The available derived classes include , , , , , , , , , , , , , , , , , , , , and . + /// + public SearchFilter NotFilters { get; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/NumberFormat.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/NumberFormat.Serialization.cs new file mode 100644 index 0000000000000..f32e43f5a3405 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/NumberFormat.Serialization.cs @@ -0,0 +1,267 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using System.Text.Json; +using Azure; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class NumberFormat : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + if (Optional.IsCollectionDefined(AvailableLocales)) + { + writer.WritePropertyName("availableLocales"u8); + writer.WriteStartArray(); + foreach (var item in AvailableLocales) + { + writer.WriteStringValue(item); + } + writer.WriteEndArray(); + } + if (Optional.IsDefined(Currency)) + { + writer.WritePropertyName("currency"u8); + writer.WriteStringValue(Currency); + } + if (Optional.IsDefined(CurrencyInstance)) + { + writer.WritePropertyName("currencyInstance"u8); + writer.WriteObjectValue(CurrencyInstance); + } + if (Optional.IsDefined(GroupingUsed)) + { + writer.WritePropertyName("groupingUsed"u8); + writer.WriteBooleanValue(GroupingUsed.Value); + } + if (Optional.IsDefined(Instance)) + { + writer.WritePropertyName("instance"u8); + writer.WriteObjectValue(Instance); + } + if (Optional.IsDefined(IntegerInstance)) + { + writer.WritePropertyName("integerInstance"u8); + writer.WriteObjectValue(IntegerInstance); + } + if (Optional.IsDefined(MaximumFractionDigits)) + { + writer.WritePropertyName("maximumFractionDigits"u8); + writer.WriteNumberValue(MaximumFractionDigits.Value); + } + if (Optional.IsDefined(MaximumIntegerDigits)) + { + writer.WritePropertyName("maximumIntegerDigits"u8); + writer.WriteNumberValue(MaximumIntegerDigits.Value); + } + if (Optional.IsDefined(MinimumFractionDigits)) + { + writer.WritePropertyName("minimumFractionDigits"u8); + writer.WriteNumberValue(MinimumFractionDigits.Value); + } + if (Optional.IsDefined(MinimumIntegerDigits)) + { + writer.WritePropertyName("minimumIntegerDigits"u8); + writer.WriteNumberValue(MinimumIntegerDigits.Value); + } + if (Optional.IsDefined(NumberInstance)) + { + writer.WritePropertyName("numberInstance"u8); + writer.WriteObjectValue(NumberInstance); + } + if (Optional.IsDefined(ParseIntegerOnly)) + { + writer.WritePropertyName("parseIntegerOnly"u8); + writer.WriteBooleanValue(ParseIntegerOnly.Value); + } + if (Optional.IsDefined(PercentInstance)) + { + writer.WritePropertyName("percentInstance"u8); + writer.WriteObjectValue(PercentInstance); + } + if (Optional.IsDefined(RoundingMode)) + { + writer.WritePropertyName("roundingMode"u8); + writer.WriteStringValue(RoundingMode.Value.ToString()); + } + writer.WriteEndObject(); + } + + internal static NumberFormat DeserializeNumberFormat(JsonElement element) + { + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + Optional> availableLocales = default; + Optional currency = default; + Optional currencyInstance = default; + Optional groupingUsed = default; + Optional instance = default; + Optional integerInstance = default; + Optional maximumFractionDigits = default; + Optional maximumIntegerDigits = default; + Optional minimumFractionDigits = default; + Optional minimumIntegerDigits = default; + Optional numberInstance = default; + Optional parseIntegerOnly = default; + Optional percentInstance = default; + Optional roundingMode = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("availableLocales"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(item.GetString()); + } + availableLocales = array; + continue; + } + if (property.NameEquals("currency"u8)) + { + currency = property.Value.GetString(); + continue; + } + if (property.NameEquals("currencyInstance"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + currencyInstance = DeserializeNumberFormat(property.Value); + continue; + } + if (property.NameEquals("groupingUsed"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + groupingUsed = property.Value.GetBoolean(); + continue; + } + if (property.NameEquals("instance"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + instance = DeserializeNumberFormat(property.Value); + continue; + } + if (property.NameEquals("integerInstance"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + integerInstance = DeserializeNumberFormat(property.Value); + continue; + } + if (property.NameEquals("maximumFractionDigits"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + maximumFractionDigits = property.Value.GetInt32(); + continue; + } + if (property.NameEquals("maximumIntegerDigits"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + maximumIntegerDigits = property.Value.GetInt32(); + continue; + } + if (property.NameEquals("minimumFractionDigits"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + minimumFractionDigits = property.Value.GetInt32(); + continue; + } + if (property.NameEquals("minimumIntegerDigits"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + minimumIntegerDigits = property.Value.GetInt32(); + continue; + } + if (property.NameEquals("numberInstance"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + numberInstance = DeserializeNumberFormat(property.Value); + continue; + } + if (property.NameEquals("parseIntegerOnly"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + parseIntegerOnly = property.Value.GetBoolean(); + continue; + } + if (property.NameEquals("percentInstance"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + percentInstance = DeserializeNumberFormat(property.Value); + continue; + } + if (property.NameEquals("roundingMode"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + roundingMode = new RoundingMode(property.Value.GetString()); + continue; + } + } + return new NumberFormat(Optional.ToList(availableLocales), currency.Value, currencyInstance.Value, Optional.ToNullable(groupingUsed), instance.Value, integerInstance.Value, Optional.ToNullable(maximumFractionDigits), Optional.ToNullable(maximumIntegerDigits), Optional.ToNullable(minimumFractionDigits), Optional.ToNullable(minimumIntegerDigits), numberInstance.Value, Optional.ToNullable(parseIntegerOnly), percentInstance.Value, Optional.ToNullable(roundingMode)); + } + + /// Deserializes the model from a raw response. + /// The response to deserialize the model from. + internal static NumberFormat FromResponse(Response response) + { + using var document = JsonDocument.Parse(response.Content); + return DeserializeNumberFormat(document.RootElement); + } + + /// Convert into a Utf8JsonRequestContent. + internal virtual RequestContent ToRequestContent() + { + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(this); + return content; + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/NumberFormat.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/NumberFormat.cs new file mode 100644 index 0000000000000..264c8375b29f4 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/NumberFormat.cs @@ -0,0 +1,84 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + /// The number format. + public partial class NumberFormat + { + /// Initializes a new instance of . + public NumberFormat() + { + AvailableLocales = new ChangeTrackingList(); + } + + /// Initializes a new instance of . + /// The number format. + /// The currency. + /// The number format. + /// Determines if grouping is used. + /// The number format. + /// The number format. + /// The maximum of fraction digits. + /// The maximum of integer digits. + /// The minimum of fraction digits. + /// The minimum of integer digits. + /// The number format. + /// Determines if only integer is parsed. + /// The number format. + /// The enum of rounding mode. + internal NumberFormat(IList availableLocales, string currency, NumberFormat currencyInstance, bool? groupingUsed, NumberFormat instance, NumberFormat integerInstance, int? maximumFractionDigits, int? maximumIntegerDigits, int? minimumFractionDigits, int? minimumIntegerDigits, NumberFormat numberInstance, bool? parseIntegerOnly, NumberFormat percentInstance, RoundingMode? roundingMode) + { + AvailableLocales = availableLocales; + Currency = currency; + CurrencyInstance = currencyInstance; + GroupingUsed = groupingUsed; + Instance = instance; + IntegerInstance = integerInstance; + MaximumFractionDigits = maximumFractionDigits; + MaximumIntegerDigits = maximumIntegerDigits; + MinimumFractionDigits = minimumFractionDigits; + MinimumIntegerDigits = minimumIntegerDigits; + NumberInstance = numberInstance; + ParseIntegerOnly = parseIntegerOnly; + PercentInstance = percentInstance; + RoundingMode = roundingMode; + } + + /// The number format. + public IList AvailableLocales { get; } + /// The currency. + public string Currency { get; set; } + /// The number format. + public NumberFormat CurrencyInstance { get; set; } + /// Determines if grouping is used. + public bool? GroupingUsed { get; set; } + /// The number format. + public NumberFormat Instance { get; set; } + /// The number format. + public NumberFormat IntegerInstance { get; set; } + /// The maximum of fraction digits. + public int? MaximumFractionDigits { get; set; } + /// The maximum of integer digits. + public int? MaximumIntegerDigits { get; set; } + /// The minimum of fraction digits. + public int? MinimumFractionDigits { get; set; } + /// The minimum of integer digits. + public int? MinimumIntegerDigits { get; set; } + /// The number format. + public NumberFormat NumberInstance { get; set; } + /// Determines if only integer is parsed. + public bool? ParseIntegerOnly { get; set; } + /// The number format. + public NumberFormat PercentInstance { get; set; } + /// The enum of rounding mode. + public RoundingMode? RoundingMode { get; set; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ObjectTypeFilter.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ObjectTypeFilter.Serialization.cs new file mode 100644 index 0000000000000..dace5911c8b55 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ObjectTypeFilter.Serialization.cs @@ -0,0 +1,33 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class ObjectTypeFilter : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + writer.WritePropertyName("objectType"u8); + writer.WriteStringValue(ObjectType); + writer.WritePropertyName("kind"u8); + writer.WriteStringValue(Kind); + writer.WriteEndObject(); + } + + /// Convert into a Utf8JsonRequestContent. + internal override RequestContent ToRequestContent() + { + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(this); + return content; + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ObjectTypeFilter.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ObjectTypeFilter.cs new file mode 100644 index 0000000000000..d4d4221efd913 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ObjectTypeFilter.cs @@ -0,0 +1,38 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + /// Label filter for search. + public partial class ObjectTypeFilter : SearchFilter + { + /// Initializes a new instance of . + /// Object type. + /// is null. + public ObjectTypeFilter(string objectType) + { + Argument.AssertNotNull(objectType, nameof(objectType)); + + Kind = "ObjectTypeFilter"; + ObjectType = objectType; + } + + /// Initializes a new instance of . + /// Discriminator. + /// Object type. + internal ObjectTypeFilter(string kind, string objectType) : base(kind) + { + ObjectType = objectType; + } + + /// Object type. + public string ObjectType { get; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/OrFilter.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/OrFilter.Serialization.cs new file mode 100644 index 0000000000000..6705e11566c31 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/OrFilter.Serialization.cs @@ -0,0 +1,38 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class OrFilter : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + writer.WritePropertyName("or"u8); + writer.WriteStartArray(); + foreach (var item in OrFilters) + { + writer.WriteObjectValue(item); + } + writer.WriteEndArray(); + writer.WritePropertyName("kind"u8); + writer.WriteStringValue(Kind); + writer.WriteEndObject(); + } + + /// Convert into a Utf8JsonRequestContent. + internal override RequestContent ToRequestContent() + { + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(this); + return content; + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/OrFilter.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/OrFilter.cs new file mode 100644 index 0000000000000..d4aa9734d4c68 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/OrFilter.cs @@ -0,0 +1,44 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Collections.Generic; +using System.Linq; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + /// Or filter for search. + public partial class OrFilter : SearchFilter + { + /// Initializes a new instance of . + /// List of filters. + /// is null. + public OrFilter(IEnumerable orFilters) + { + Argument.AssertNotNull(orFilters, nameof(orFilters)); + + Kind = "OrFilter"; + OrFilters = orFilters.ToList(); + } + + /// Initializes a new instance of . + /// Discriminator. + /// List of filters. + internal OrFilter(string kind, IList orFilters) : base(kind) + { + OrFilters = orFilters; + } + + /// + /// List of filters + /// Please note is the base class. According to the scenario, a derived class of the base class might need to be assigned here, or this property needs to be casted to one of the possible derived classes. + /// The available derived classes include , , , , , , , , , , , , , , , , , , , , and . + /// + public IList OrFilters { get; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ParentRelation.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ParentRelation.Serialization.cs new file mode 100644 index 0000000000000..06d0f1f279904 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ParentRelation.Serialization.cs @@ -0,0 +1,54 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class ParentRelation + { + internal static ParentRelation DeserializeParentRelation(JsonElement element) + { + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + Optional childEntityId = default; + Optional relationshipId = default; + Optional parentEntityId = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("childEntityId"u8)) + { + childEntityId = property.Value.GetString(); + continue; + } + if (property.NameEquals("relationshipId"u8)) + { + relationshipId = property.Value.GetString(); + continue; + } + if (property.NameEquals("parentEntityId"u8)) + { + parentEntityId = property.Value.GetString(); + continue; + } + } + return new ParentRelation(childEntityId.Value, relationshipId.Value, parentEntityId.Value); + } + + /// Deserializes the model from a raw response. + /// The response to deserialize the model from. + internal static ParentRelation FromResponse(Response response) + { + using var document = JsonDocument.Parse(response.Content); + return DeserializeParentRelation(document.RootElement); + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ParentRelation.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ParentRelation.cs new file mode 100644 index 0000000000000..08efd1ed698ad --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ParentRelation.cs @@ -0,0 +1,36 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +namespace Azure.Analytics.Purview.DataMap +{ + /// The lineage parents relation with GUID of the parent entity and to child entity. + public partial class ParentRelation + { + /// Initializes a new instance of . + internal ParentRelation() + { + } + + /// Initializes a new instance of . + /// The GUID of child entity. + /// The GUID of relationship. + /// The GUID of parent entity. + internal ParentRelation(string childEntityId, string relationshipId, string parentEntityId) + { + ChildEntityId = childEntityId; + RelationshipId = relationshipId; + ParentEntityId = parentEntityId; + } + + /// The GUID of child entity. + public string ChildEntityId { get; } + /// The GUID of relationship. + public string RelationshipId { get; } + /// The GUID of parent entity. + public string ParentEntityId { get; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/PathFilter.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/PathFilter.Serialization.cs new file mode 100644 index 0000000000000..a5dbee7889d9a --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/PathFilter.Serialization.cs @@ -0,0 +1,38 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class PathFilter : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + writer.WritePropertyName("path"u8); + writer.WriteStringValue(Path); + if (Optional.IsDefined(IsParent)) + { + writer.WritePropertyName("isParent"u8); + writer.WriteBooleanValue(IsParent.Value); + } + writer.WritePropertyName("kind"u8); + writer.WriteStringValue(Kind); + writer.WriteEndObject(); + } + + /// Convert into a Utf8JsonRequestContent. + internal override RequestContent ToRequestContent() + { + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(this); + return content; + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/PathFilter.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/PathFilter.cs new file mode 100644 index 0000000000000..09d7f5a6aa940 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/PathFilter.cs @@ -0,0 +1,42 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + /// Path filter for search. + public partial class PathFilter : SearchFilter + { + /// Initializes a new instance of . + /// Path. + /// is null. + public PathFilter(string path) + { + Argument.AssertNotNull(path, nameof(path)); + + Kind = "PathFilter"; + Path = path; + } + + /// Initializes a new instance of . + /// Discriminator. + /// Path. + /// Whether the path is parent path. + internal PathFilter(string kind, string path, bool? isParent) : base(kind) + { + Path = path; + IsParent = isParent; + } + + /// Path. + public string Path { get; } + /// Whether the path is parent path. + public bool? IsParent { get; set; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/PurviewObjectId.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/PurviewObjectId.Serialization.cs new file mode 100644 index 0000000000000..43a4231f9f9df --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/PurviewObjectId.Serialization.cs @@ -0,0 +1,208 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Collections.Generic; +using System.Text.Json; +using Azure; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class PurviewObjectId : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + if (Optional.IsDefined(Guid)) + { + writer.WritePropertyName("guid"u8); + writer.WriteStringValue(Guid); + } + if (Optional.IsDefined(TypeName)) + { + writer.WritePropertyName("typeName"u8); + writer.WriteStringValue(TypeName); + } + if (Optional.IsCollectionDefined(UniqueAttributes)) + { + writer.WritePropertyName("uniqueAttributes"u8); + writer.WriteStartObject(); + foreach (var item in UniqueAttributes) + { + writer.WritePropertyName(item.Key); + if (item.Value == null) + { + writer.WriteNullValue(); + continue; + } +#if NET6_0_OR_GREATER + writer.WriteRawValue(item.Value); +#else + using (JsonDocument document = JsonDocument.Parse(item.Value)) + { + JsonSerializer.Serialize(writer, document.RootElement); + } +#endif + } + writer.WriteEndObject(); + } + if (Optional.IsDefined(Name)) + { + writer.WritePropertyName("name"u8); + writer.WriteStringValue(Name); + } + if (Optional.IsDefined(DisplayText)) + { + writer.WritePropertyName("displayText"u8); + writer.WriteStringValue(DisplayText); + } + if (Optional.IsDefined(ItemPath)) + { + writer.WritePropertyName("itemPath"u8); + writer.WriteStringValue(ItemPath); + } + if (Optional.IsDefined(ResourceId)) + { + writer.WritePropertyName("resourceId"u8); + writer.WriteStringValue(ResourceId); + } + if (Optional.IsCollectionDefined(Properties)) + { + writer.WritePropertyName("properties"u8); + writer.WriteStartObject(); + foreach (var item in Properties) + { + writer.WritePropertyName(item.Key); + if (item.Value == null) + { + writer.WriteNullValue(); + continue; + } +#if NET6_0_OR_GREATER + writer.WriteRawValue(item.Value); +#else + using (JsonDocument document = JsonDocument.Parse(item.Value)) + { + JsonSerializer.Serialize(writer, document.RootElement); + } +#endif + } + writer.WriteEndObject(); + } + writer.WriteEndObject(); + } + + internal static PurviewObjectId DeserializePurviewObjectId(JsonElement element) + { + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + Optional guid = default; + Optional typeName = default; + Optional> uniqueAttributes = default; + Optional name = default; + Optional displayText = default; + Optional itemPath = default; + Optional resourceId = default; + Optional> properties = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("guid"u8)) + { + guid = property.Value.GetString(); + continue; + } + if (property.NameEquals("typeName"u8)) + { + typeName = property.Value.GetString(); + continue; + } + if (property.NameEquals("uniqueAttributes"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + Dictionary dictionary = new Dictionary(); + foreach (var property0 in property.Value.EnumerateObject()) + { + if (property0.Value.ValueKind == JsonValueKind.Null) + { + dictionary.Add(property0.Name, null); + } + else + { + dictionary.Add(property0.Name, BinaryData.FromString(property0.Value.GetRawText())); + } + } + uniqueAttributes = dictionary; + continue; + } + if (property.NameEquals("name"u8)) + { + name = property.Value.GetString(); + continue; + } + if (property.NameEquals("displayText"u8)) + { + displayText = property.Value.GetString(); + continue; + } + if (property.NameEquals("itemPath"u8)) + { + itemPath = property.Value.GetString(); + continue; + } + if (property.NameEquals("resourceId"u8)) + { + resourceId = property.Value.GetString(); + continue; + } + if (property.NameEquals("properties"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + Dictionary dictionary = new Dictionary(); + foreach (var property0 in property.Value.EnumerateObject()) + { + if (property0.Value.ValueKind == JsonValueKind.Null) + { + dictionary.Add(property0.Name, null); + } + else + { + dictionary.Add(property0.Name, BinaryData.FromString(property0.Value.GetRawText())); + } + } + properties = dictionary; + continue; + } + } + return new PurviewObjectId(guid.Value, typeName.Value, Optional.ToDictionary(uniqueAttributes), name.Value, displayText.Value, itemPath.Value, resourceId.Value, Optional.ToDictionary(properties)); + } + + /// Deserializes the model from a raw response. + /// The response to deserialize the model from. + internal static PurviewObjectId FromResponse(Response response) + { + using var document = JsonDocument.Parse(response.Content); + return DeserializePurviewObjectId(document.RootElement); + } + + /// Convert into a Utf8JsonRequestContent. + internal virtual RequestContent ToRequestContent() + { + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(this); + return content; + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/PurviewObjectId.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/PurviewObjectId.cs new file mode 100644 index 0000000000000..fba96a2220189 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/PurviewObjectId.cs @@ -0,0 +1,120 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Collections.Generic; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + /// PurviewObjectId. + public partial class PurviewObjectId + { + /// Initializes a new instance of . + public PurviewObjectId() + { + UniqueAttributes = new ChangeTrackingDictionary(); + Properties = new ChangeTrackingDictionary(); + } + + /// Initializes a new instance of . + /// The GUID of the object. + /// The name of the type. + /// The unique attributes of the object. + /// Name. + /// Display text. + /// Item path. + /// Resource Id. + /// Dictionary of <any>. + internal PurviewObjectId(string guid, string typeName, IDictionary uniqueAttributes, string name, string displayText, string itemPath, string resourceId, IDictionary properties) + { + Guid = guid; + TypeName = typeName; + UniqueAttributes = uniqueAttributes; + Name = name; + DisplayText = displayText; + ItemPath = itemPath; + ResourceId = resourceId; + Properties = properties; + } + + /// The GUID of the object. + public string Guid { get; set; } + /// The name of the type. + public string TypeName { get; set; } + /// + /// The unique attributes of the object. + /// + /// To assign an object to the value of this property use . + /// + /// + /// To assign an already formatted json string to this property use . + /// + /// + /// Examples: + /// + /// + /// BinaryData.FromObjectAsJson("foo") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromString("\"foo\"") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromObjectAsJson(new { key = "value" }) + /// Creates a payload of { "key": "value" }. + /// + /// + /// BinaryData.FromString("{\"key\": \"value\"}") + /// Creates a payload of { "key": "value" }. + /// + /// + /// + /// + public IDictionary UniqueAttributes { get; } + /// Name. + public string Name { get; set; } + /// Display text. + public string DisplayText { get; set; } + /// Item path. + public string ItemPath { get; set; } + /// Resource Id. + public string ResourceId { get; set; } + /// + /// Dictionary of <any> + /// + /// To assign an object to the value of this property use . + /// + /// + /// To assign an already formatted json string to this property use . + /// + /// + /// Examples: + /// + /// + /// BinaryData.FromObjectAsJson("foo") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromString("\"foo\"") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromObjectAsJson(new { key = "value" }) + /// Creates a payload of { "key": "value" }. + /// + /// + /// BinaryData.FromString("{\"key\": \"value\"}") + /// Creates a payload of { "key": "value" }. + /// + /// + /// + /// + public IDictionary Properties { get; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/Relationship.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/Relationship.cs new file mode 100644 index 0000000000000..f309d5c91ded2 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/Relationship.cs @@ -0,0 +1,553 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Threading; +using System.Threading.Tasks; +using Azure; +using Azure.Core; +using Azure.Core.Pipeline; + +namespace Azure.Analytics.Purview.DataMap +{ + // Data plane generated sub-client. + /// The Relationship sub-client. + public partial class Relationship + { + private static readonly string[] AuthorizationScopes = new string[] { "https://purview.azure.net/.default" }; + private readonly TokenCredential _tokenCredential; + private readonly HttpPipeline _pipeline; + private readonly Uri _endpoint; + private readonly string _apiVersion; + + /// The ClientDiagnostics is used to provide tracing support for the client library. + internal ClientDiagnostics ClientDiagnostics { get; } + + /// The HTTP pipeline for sending and receiving REST requests and responses. + public virtual HttpPipeline Pipeline => _pipeline; + + /// Initializes a new instance of Relationship for mocking. + protected Relationship() + { + } + + /// Initializes a new instance of Relationship. + /// The handler for diagnostic messaging in the client. + /// The HTTP pipeline for sending and receiving REST requests and responses. + /// The token credential to copy. + /// The to use. + /// The to use. + internal Relationship(ClientDiagnostics clientDiagnostics, HttpPipeline pipeline, TokenCredential tokenCredential, Uri endpoint, string apiVersion) + { + ClientDiagnostics = clientDiagnostics; + _pipeline = pipeline; + _tokenCredential = tokenCredential; + _endpoint = endpoint; + _apiVersion = apiVersion; + } + + /// Create a new relationship between entities. + /// + /// The AtlasRelationship object containing the information for the relationship to + /// be created. + /// + /// The cancellation token to use. + /// is null. + /// + public virtual async Task> CreateAsync(AtlasRelationship relationship, CancellationToken cancellationToken = default) + { + Argument.AssertNotNull(relationship, nameof(relationship)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = relationship.ToRequestContent(); + Response response = await CreateAsync(content, context).ConfigureAwait(false); + return Response.FromValue(AtlasRelationship.FromResponse(response), response); + } + + /// Create a new relationship between entities. + /// + /// The AtlasRelationship object containing the information for the relationship to + /// be created. + /// + /// The cancellation token to use. + /// is null. + /// + public virtual Response Create(AtlasRelationship relationship, CancellationToken cancellationToken = default) + { + Argument.AssertNotNull(relationship, nameof(relationship)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = relationship.ToRequestContent(); + Response response = Create(content, context); + return Response.FromValue(AtlasRelationship.FromResponse(response), response); + } + + /// + /// [Protocol Method] Create a new relationship between entities. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The content to send as the body of the request. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task CreateAsync(RequestContent content, RequestContext context = null) + { + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Relationship.Create"); + scope.Start(); + try + { + using HttpMessage message = CreateCreateRequest(content, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Create a new relationship between entities. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The content to send as the body of the request. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response Create(RequestContent content, RequestContext context = null) + { + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Relationship.Create"); + scope.Start(); + try + { + using HttpMessage message = CreateCreateRequest(content, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Update an existing relationship between entities. + /// + /// The AtlasRelationship object containing the information for the relationship to + /// be created. + /// + /// The cancellation token to use. + /// is null. + /// + public virtual async Task> UpdateAsync(AtlasRelationship relationship, CancellationToken cancellationToken = default) + { + Argument.AssertNotNull(relationship, nameof(relationship)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = relationship.ToRequestContent(); + Response response = await UpdateAsync(content, context).ConfigureAwait(false); + return Response.FromValue(AtlasRelationship.FromResponse(response), response); + } + + /// Update an existing relationship between entities. + /// + /// The AtlasRelationship object containing the information for the relationship to + /// be created. + /// + /// The cancellation token to use. + /// is null. + /// + public virtual Response Update(AtlasRelationship relationship, CancellationToken cancellationToken = default) + { + Argument.AssertNotNull(relationship, nameof(relationship)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = relationship.ToRequestContent(); + Response response = Update(content, context); + return Response.FromValue(AtlasRelationship.FromResponse(response), response); + } + + /// + /// [Protocol Method] Update an existing relationship between entities. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The content to send as the body of the request. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task UpdateAsync(RequestContent content, RequestContext context = null) + { + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Relationship.Update"); + scope.Start(); + try + { + using HttpMessage message = CreateUpdateRequest(content, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Update an existing relationship between entities. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The content to send as the body of the request. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response Update(RequestContent content, RequestContext context = null) + { + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("Relationship.Update"); + scope.Start(); + try + { + using HttpMessage message = CreateUpdateRequest(content, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Get relationship information between entities by its GUID. + /// The globally unique identifier of the relationship. + /// Limits whether includes extended information. + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual async Task> GetRelationshipAsync(string guid, bool? extendedInfo = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = await GetRelationshipAsync(guid, extendedInfo, context).ConfigureAwait(false); + return Response.FromValue(AtlasRelationshipWithExtInfo.FromResponse(response), response); + } + + /// Get relationship information between entities by its GUID. + /// The globally unique identifier of the relationship. + /// Limits whether includes extended information. + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual Response GetRelationship(string guid, bool? extendedInfo = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = GetRelationship(guid, extendedInfo, context); + return Response.FromValue(AtlasRelationshipWithExtInfo.FromResponse(response), response); + } + + /// + /// [Protocol Method] Get relationship information between entities by its GUID. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier of the relationship. + /// Limits whether includes extended information. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task GetRelationshipAsync(string guid, bool? extendedInfo, RequestContext context) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + + using var scope = ClientDiagnostics.CreateScope("Relationship.GetRelationship"); + scope.Start(); + try + { + using HttpMessage message = CreateGetRelationshipRequest(guid, extendedInfo, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Get relationship information between entities by its GUID. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier of the relationship. + /// Limits whether includes extended information. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response GetRelationship(string guid, bool? extendedInfo, RequestContext context) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + + using var scope = ClientDiagnostics.CreateScope("Relationship.GetRelationship"); + scope.Start(); + try + { + using HttpMessage message = CreateGetRelationshipRequest(guid, extendedInfo, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + // The convenience method is omitted here because it has exactly the same parameter list as the corresponding protocol method + /// + /// [Protocol Method] Delete a relationship between entities by its GUID. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// The globally unique identifier of the relationship. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task DeleteAsync(string guid, RequestContext context = null) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + + using var scope = ClientDiagnostics.CreateScope("Relationship.Delete"); + scope.Start(); + try + { + using HttpMessage message = CreateDeleteRequest(guid, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + // The convenience method is omitted here because it has exactly the same parameter list as the corresponding protocol method + /// + /// [Protocol Method] Delete a relationship between entities by its GUID. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// The globally unique identifier of the relationship. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response Delete(string guid, RequestContext context = null) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + + using var scope = ClientDiagnostics.CreateScope("Relationship.Delete"); + scope.Start(); + try + { + using HttpMessage message = CreateDeleteRequest(guid, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + internal HttpMessage CreateCreateRequest(RequestContent content, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier200); + var request = message.Request; + request.Method = RequestMethod.Post; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/relationship", false); + uri.AppendQuery("api-version", _apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + request.Headers.Add("Content-Type", "application/json"); + request.Content = content; + return message; + } + + internal HttpMessage CreateUpdateRequest(RequestContent content, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier200); + var request = message.Request; + request.Method = RequestMethod.Put; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/relationship", false); + uri.AppendQuery("api-version", _apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + request.Headers.Add("Content-Type", "application/json"); + request.Content = content; + return message; + } + + internal HttpMessage CreateGetRelationshipRequest(string guid, bool? extendedInfo, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier200); + var request = message.Request; + request.Method = RequestMethod.Get; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/relationship/guid/", false); + uri.AppendPath(guid, true); + uri.AppendQuery("api-version", _apiVersion, true); + if (extendedInfo != null) + { + uri.AppendQuery("extendedInfo", extendedInfo.Value, true); + } + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + return message; + } + + internal HttpMessage CreateDeleteRequest(string guid, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier204); + var request = message.Request; + request.Method = RequestMethod.Delete; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/relationship/guid/", false); + uri.AppendPath(guid, true); + uri.AppendQuery("api-version", _apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + return message; + } + + private static RequestContext DefaultRequestContext = new RequestContext(); + internal static RequestContext FromCancellationToken(CancellationToken cancellationToken = default) + { + if (!cancellationToken.CanBeCanceled) + { + return DefaultRequestContext; + } + + return new RequestContext() { CancellationToken = cancellationToken }; + } + + private static ResponseClassifier _responseClassifier200; + private static ResponseClassifier ResponseClassifier200 => _responseClassifier200 ??= new StatusCodeClassifier(stackalloc ushort[] { 200 }); + private static ResponseClassifier _responseClassifier204; + private static ResponseClassifier ResponseClassifier204 => _responseClassifier204 ??= new StatusCodeClassifier(stackalloc ushort[] { 204 }); + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/RelationshipCategory.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/RelationshipCategory.cs new file mode 100644 index 0000000000000..5d1c2f363679a --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/RelationshipCategory.cs @@ -0,0 +1,54 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.ComponentModel; + +namespace Azure.Analytics.Purview.DataMap +{ + /// Relationship Category. + public readonly partial struct RelationshipCategory : IEquatable + { + private readonly string _value; + + /// Initializes a new instance of . + /// is null. + public RelationshipCategory(string value) + { + _value = value ?? throw new ArgumentNullException(nameof(value)); + } + + private const string AssociationValue = "ASSOCIATION"; + private const string AggregationValue = "AGGREGATION"; + private const string CompositionValue = "COMPOSITION"; + + /// association. + public static RelationshipCategory Association { get; } = new RelationshipCategory(AssociationValue); + /// aggregation. + public static RelationshipCategory Aggregation { get; } = new RelationshipCategory(AggregationValue); + /// composition. + public static RelationshipCategory Composition { get; } = new RelationshipCategory(CompositionValue); + /// Determines if two values are the same. + public static bool operator ==(RelationshipCategory left, RelationshipCategory right) => left.Equals(right); + /// Determines if two values are not the same. + public static bool operator !=(RelationshipCategory left, RelationshipCategory right) => !left.Equals(right); + /// Converts a string to a . + public static implicit operator RelationshipCategory(string value) => new RelationshipCategory(value); + + /// + [EditorBrowsable(EditorBrowsableState.Never)] + public override bool Equals(object obj) => obj is RelationshipCategory other && Equals(other); + /// + public bool Equals(RelationshipCategory other) => string.Equals(_value, other._value, StringComparison.InvariantCultureIgnoreCase); + + /// + [EditorBrowsable(EditorBrowsableState.Never)] + public override int GetHashCode() => _value?.GetHashCode() ?? 0; + /// + public override string ToString() => _value; + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ResourceLink.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ResourceLink.Serialization.cs new file mode 100644 index 0000000000000..7890b0aa4be70 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ResourceLink.Serialization.cs @@ -0,0 +1,72 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class ResourceLink : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + if (Optional.IsDefined(DisplayName)) + { + writer.WritePropertyName("displayName"u8); + writer.WriteStringValue(DisplayName); + } + if (Optional.IsDefined(Url)) + { + writer.WritePropertyName("url"u8); + writer.WriteStringValue(Url); + } + writer.WriteEndObject(); + } + + internal static ResourceLink DeserializeResourceLink(JsonElement element) + { + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + Optional displayName = default; + Optional url = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("displayName"u8)) + { + displayName = property.Value.GetString(); + continue; + } + if (property.NameEquals("url"u8)) + { + url = property.Value.GetString(); + continue; + } + } + return new ResourceLink(displayName.Value, url.Value); + } + + /// Deserializes the model from a raw response. + /// The response to deserialize the model from. + internal static ResourceLink FromResponse(Response response) + { + using var document = JsonDocument.Parse(response.Content); + return DeserializeResourceLink(document.RootElement); + } + + /// Convert into a Utf8JsonRequestContent. + internal virtual RequestContent ToRequestContent() + { + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(this); + return content; + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ResourceLink.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ResourceLink.cs new file mode 100644 index 0000000000000..2541a706a0baf --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ResourceLink.cs @@ -0,0 +1,32 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +namespace Azure.Analytics.Purview.DataMap +{ + /// ResourceLink. + public partial class ResourceLink + { + /// Initializes a new instance of . + public ResourceLink() + { + } + + /// Initializes a new instance of . + /// Display name for url. + /// web url. http or https. + internal ResourceLink(string displayName, string url) + { + DisplayName = displayName; + Url = url; + } + + /// Display name for url. + public string DisplayName { get; set; } + /// web url. http or https. + public string Url { get; set; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/RoundingMode.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/RoundingMode.cs new file mode 100644 index 0000000000000..e5e7ca207e40d --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/RoundingMode.cs @@ -0,0 +1,69 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.ComponentModel; + +namespace Azure.Analytics.Purview.DataMap +{ + /// Rounding Mode. + public readonly partial struct RoundingMode : IEquatable + { + private readonly string _value; + + /// Initializes a new instance of . + /// is null. + public RoundingMode(string value) + { + _value = value ?? throw new ArgumentNullException(nameof(value)); + } + + private const string UpValue = "UP"; + private const string DownValue = "DOWN"; + private const string CeilingValue = "CEILING"; + private const string FloorValue = "FLOOR"; + private const string HalfUpValue = "HALF_UP"; + private const string HalfDownValue = "HALF_DOWN"; + private const string HalfEvenValue = "HALF_EVEN"; + private const string UnnecessaryValue = "UNNECESSARY"; + + /// up. + public static RoundingMode Up { get; } = new RoundingMode(UpValue); + /// down. + public static RoundingMode Down { get; } = new RoundingMode(DownValue); + /// ceiling. + public static RoundingMode Ceiling { get; } = new RoundingMode(CeilingValue); + /// floor. + public static RoundingMode Floor { get; } = new RoundingMode(FloorValue); + /// half up. + public static RoundingMode HalfUp { get; } = new RoundingMode(HalfUpValue); + /// half down. + public static RoundingMode HalfDown { get; } = new RoundingMode(HalfDownValue); + /// half even. + public static RoundingMode HalfEven { get; } = new RoundingMode(HalfEvenValue); + /// unnecessary. + public static RoundingMode Unnecessary { get; } = new RoundingMode(UnnecessaryValue); + /// Determines if two values are the same. + public static bool operator ==(RoundingMode left, RoundingMode right) => left.Equals(right); + /// Determines if two values are not the same. + public static bool operator !=(RoundingMode left, RoundingMode right) => !left.Equals(right); + /// Converts a string to a . + public static implicit operator RoundingMode(string value) => new RoundingMode(value); + + /// + [EditorBrowsable(EditorBrowsableState.Never)] + public override bool Equals(object obj) => obj is RoundingMode other && Equals(other); + /// + public bool Equals(RoundingMode other) => string.Equals(_value, other._value, StringComparison.InvariantCultureIgnoreCase); + + /// + [EditorBrowsable(EditorBrowsableState.Never)] + public override int GetHashCode() => _value?.GetHashCode() ?? 0; + /// + public override string ToString() => _value; + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ScanInfoFilter.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ScanInfoFilter.Serialization.cs new file mode 100644 index 0000000000000..be10e1e8ecc60 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ScanInfoFilter.Serialization.cs @@ -0,0 +1,41 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class ScanInfoFilter : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + if (Optional.IsDefined(DataSourceName)) + { + writer.WritePropertyName("dataSourceName"u8); + writer.WriteStringValue(DataSourceName); + } + if (Optional.IsDefined(ScanName)) + { + writer.WritePropertyName("scanName"u8); + writer.WriteStringValue(ScanName); + } + writer.WritePropertyName("kind"u8); + writer.WriteStringValue(Kind); + writer.WriteEndObject(); + } + + /// Convert into a Utf8JsonRequestContent. + internal override RequestContent ToRequestContent() + { + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(this); + return content; + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ScanInfoFilter.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ScanInfoFilter.cs new file mode 100644 index 0000000000000..0fa0f2fbdefe7 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/ScanInfoFilter.cs @@ -0,0 +1,34 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +namespace Azure.Analytics.Purview.DataMap +{ + /// Scan info filter for search. + public partial class ScanInfoFilter : SearchFilter + { + /// Initializes a new instance of . + public ScanInfoFilter() + { + Kind = "ScanInfoFilter"; + } + + /// Initializes a new instance of . + /// Discriminator. + /// Data source name. + /// Scan name. + internal ScanInfoFilter(string kind, string dataSourceName, string scanName) : base(kind) + { + DataSourceName = dataSourceName; + ScanName = scanName; + } + + /// Data source name. + public string DataSourceName { get; set; } + /// Scan name. + public string ScanName { get; set; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SearchFacetItem.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SearchFacetItem.Serialization.cs new file mode 100644 index 0000000000000..f52c464e5045b --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SearchFacetItem.Serialization.cs @@ -0,0 +1,44 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class SearchFacetItem : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + if (Optional.IsDefined(Count)) + { + writer.WritePropertyName("count"u8); + writer.WriteNumberValue(Count.Value); + } + if (Optional.IsDefined(Facet)) + { + writer.WritePropertyName("facet"u8); + writer.WriteStringValue(Facet); + } + if (Optional.IsDefined(Sort)) + { + writer.WritePropertyName("sort"u8); + writer.WriteObjectValue(Sort); + } + writer.WriteEndObject(); + } + + /// Convert into a Utf8JsonRequestContent. + internal virtual RequestContent ToRequestContent() + { + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(this); + return content; + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SearchFacetItem.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SearchFacetItem.cs new file mode 100644 index 0000000000000..8eb0fd41e3127 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SearchFacetItem.cs @@ -0,0 +1,36 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +namespace Azure.Analytics.Purview.DataMap +{ + /// The content of a search facet result item. + public partial class SearchFacetItem + { + /// Initializes a new instance of . + public SearchFacetItem() + { + } + + /// Initializes a new instance of . + /// The count of the facet item. + /// The name of the facet item. + /// Define the sorting criteria for items. + internal SearchFacetItem(int? count, string facet, SearchFacetSort sort) + { + Count = count; + Facet = facet; + Sort = sort; + } + + /// The count of the facet item. + public int? Count { get; set; } + /// The name of the facet item. + public string Facet { get; set; } + /// Define the sorting criteria for items. + public SearchFacetSort Sort { get; set; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SearchFacetItemValue.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SearchFacetItemValue.Serialization.cs new file mode 100644 index 0000000000000..e8675431df721 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SearchFacetItemValue.Serialization.cs @@ -0,0 +1,52 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class SearchFacetItemValue + { + internal static SearchFacetItemValue DeserializeSearchFacetItemValue(JsonElement element) + { + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + Optional count = default; + Optional value = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("count"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + count = property.Value.GetInt32(); + continue; + } + if (property.NameEquals("value"u8)) + { + value = property.Value.GetString(); + continue; + } + } + return new SearchFacetItemValue(Optional.ToNullable(count), value.Value); + } + + /// Deserializes the model from a raw response. + /// The response to deserialize the model from. + internal static SearchFacetItemValue FromResponse(Response response) + { + using var document = JsonDocument.Parse(response.Content); + return DeserializeSearchFacetItemValue(document.RootElement); + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SearchFacetItemValue.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SearchFacetItemValue.cs new file mode 100644 index 0000000000000..6e61620840445 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SearchFacetItemValue.cs @@ -0,0 +1,32 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +namespace Azure.Analytics.Purview.DataMap +{ + /// The content of a search facet result item. + public partial class SearchFacetItemValue + { + /// Initializes a new instance of . + internal SearchFacetItemValue() + { + } + + /// Initializes a new instance of . + /// The count of the facet item. + /// The name of the facet item. + internal SearchFacetItemValue(int? count, string value) + { + Count = count; + Value = value; + } + + /// The count of the facet item. + public int? Count { get; } + /// The name of the facet item. + public string Value { get; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SearchFacetResultValue.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SearchFacetResultValue.Serialization.cs new file mode 100644 index 0000000000000..edfb7da17a746 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SearchFacetResultValue.Serialization.cs @@ -0,0 +1,187 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using System.Text.Json; +using Azure; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class SearchFacetResultValue + { + internal static SearchFacetResultValue DeserializeSearchFacetResultValue(JsonElement element) + { + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + Optional> entityType = default; + Optional> assetType = default; + Optional> classification = default; + Optional> term = default; + Optional> contactId = default; + Optional> contactType = default; + Optional> label = default; + Optional> glossaryType = default; + Optional> termStatus = default; + Optional> termTemplate = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("entityType"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(SearchFacetItemValue.DeserializeSearchFacetItemValue(item)); + } + entityType = array; + continue; + } + if (property.NameEquals("assetType"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(SearchFacetItemValue.DeserializeSearchFacetItemValue(item)); + } + assetType = array; + continue; + } + if (property.NameEquals("classification"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(SearchFacetItemValue.DeserializeSearchFacetItemValue(item)); + } + classification = array; + continue; + } + if (property.NameEquals("term"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(SearchFacetItemValue.DeserializeSearchFacetItemValue(item)); + } + term = array; + continue; + } + if (property.NameEquals("contactId"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(SearchFacetItemValue.DeserializeSearchFacetItemValue(item)); + } + contactId = array; + continue; + } + if (property.NameEquals("contactType"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(SearchFacetItemValue.DeserializeSearchFacetItemValue(item)); + } + contactType = array; + continue; + } + if (property.NameEquals("label"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(SearchFacetItemValue.DeserializeSearchFacetItemValue(item)); + } + label = array; + continue; + } + if (property.NameEquals("glossaryType"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(SearchFacetItemValue.DeserializeSearchFacetItemValue(item)); + } + glossaryType = array; + continue; + } + if (property.NameEquals("termStatus"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(SearchFacetItemValue.DeserializeSearchFacetItemValue(item)); + } + termStatus = array; + continue; + } + if (property.NameEquals("termTemplate"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(SearchFacetItemValue.DeserializeSearchFacetItemValue(item)); + } + termTemplate = array; + continue; + } + } + return new SearchFacetResultValue(Optional.ToList(entityType), Optional.ToList(assetType), Optional.ToList(classification), Optional.ToList(term), Optional.ToList(contactId), Optional.ToList(contactType), Optional.ToList(label), Optional.ToList(glossaryType), Optional.ToList(termStatus), Optional.ToList(termTemplate)); + } + + /// Deserializes the model from a raw response. + /// The response to deserialize the model from. + internal static SearchFacetResultValue FromResponse(Response response) + { + using var document = JsonDocument.Parse(response.Content); + return DeserializeSearchFacetResultValue(document.RootElement); + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SearchFacetResultValue.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SearchFacetResultValue.cs new file mode 100644 index 0000000000000..17e00e54d13a2 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SearchFacetResultValue.cs @@ -0,0 +1,81 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + /// + /// A facet list that consists of index fields assetType ,classification, + /// contactId, and label. When the facet is specified in the request, the value of + /// the facet is returned as an element of @search.facets. + /// + public partial class SearchFacetResultValue + { + /// Initializes a new instance of . + internal SearchFacetResultValue() + { + EntityType = new ChangeTrackingList(); + AssetType = new ChangeTrackingList(); + Classification = new ChangeTrackingList(); + Term = new ChangeTrackingList(); + ContactId = new ChangeTrackingList(); + ContactType = new ChangeTrackingList(); + Label = new ChangeTrackingList(); + GlossaryType = new ChangeTrackingList(); + TermStatus = new ChangeTrackingList(); + TermTemplate = new ChangeTrackingList(); + } + + /// Initializes a new instance of . + /// Entity type. + /// Asset type. + /// Classification. + /// Term. + /// Contact id. + /// Contact type. + /// Label. + /// Glossary type. + /// Term status. + /// Term template. + internal SearchFacetResultValue(IReadOnlyList entityType, IReadOnlyList assetType, IReadOnlyList classification, IReadOnlyList term, IReadOnlyList contactId, IReadOnlyList contactType, IReadOnlyList label, IReadOnlyList glossaryType, IReadOnlyList termStatus, IReadOnlyList termTemplate) + { + EntityType = entityType; + AssetType = assetType; + Classification = classification; + Term = term; + ContactId = contactId; + ContactType = contactType; + Label = label; + GlossaryType = glossaryType; + TermStatus = termStatus; + TermTemplate = termTemplate; + } + + /// Entity type. + public IReadOnlyList EntityType { get; } + /// Asset type. + public IReadOnlyList AssetType { get; } + /// Classification. + public IReadOnlyList Classification { get; } + /// Term. + public IReadOnlyList Term { get; } + /// Contact id. + public IReadOnlyList ContactId { get; } + /// Contact type. + public IReadOnlyList ContactType { get; } + /// Label. + public IReadOnlyList Label { get; } + /// Glossary type. + public IReadOnlyList GlossaryType { get; } + /// Term status. + public IReadOnlyList TermStatus { get; } + /// Term template. + public IReadOnlyList TermTemplate { get; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SearchFacetSort.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SearchFacetSort.Serialization.cs new file mode 100644 index 0000000000000..c68d95b5dcb87 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SearchFacetSort.Serialization.cs @@ -0,0 +1,39 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class SearchFacetSort : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + if (Optional.IsDefined(Count)) + { + writer.WritePropertyName("count"u8); + writer.WriteStringValue(Count.Value.ToString()); + } + if (Optional.IsDefined(Value)) + { + writer.WritePropertyName("value"u8); + writer.WriteStringValue(Value.Value.ToString()); + } + writer.WriteEndObject(); + } + + /// Convert into a Utf8JsonRequestContent. + internal virtual RequestContent ToRequestContent() + { + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(this); + return content; + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SearchFacetSort.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SearchFacetSort.cs new file mode 100644 index 0000000000000..3274aff22cce1 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SearchFacetSort.cs @@ -0,0 +1,32 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +namespace Azure.Analytics.Purview.DataMap +{ + /// The sorting criteria. + public partial class SearchFacetSort + { + /// Initializes a new instance of . + public SearchFacetSort() + { + } + + /// Initializes a new instance of . + /// Order by count. + /// Order by value. + internal SearchFacetSort(SearchSortOrder? count, SearchSortOrder? value) + { + Count = count; + Value = value; + } + + /// Order by count. + public SearchSortOrder? Count { get; set; } + /// Order by value. + public SearchSortOrder? Value { get; set; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SearchFilter.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SearchFilter.Serialization.cs new file mode 100644 index 0000000000000..d7828c80fe415 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SearchFilter.Serialization.cs @@ -0,0 +1,31 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class SearchFilter : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + writer.WritePropertyName("kind"u8); + writer.WriteStringValue(Kind); + writer.WriteEndObject(); + } + + /// Convert into a Utf8JsonRequestContent. + internal virtual RequestContent ToRequestContent() + { + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(this); + return content; + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SearchFilter.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SearchFilter.cs new file mode 100644 index 0000000000000..44a67a23d188d --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SearchFilter.cs @@ -0,0 +1,32 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +namespace Azure.Analytics.Purview.DataMap +{ + /// + /// Base model for search filter + /// Please note is the base class. According to the scenario, a derived class of the base class might need to be assigned here, or this property needs to be casted to one of the possible derived classes. + /// The available derived classes include , , , , , , , , , , , , , , , , , , , , and . + /// + public abstract partial class SearchFilter + { + /// Initializes a new instance of . + protected SearchFilter() + { + } + + /// Initializes a new instance of . + /// Discriminator. + internal SearchFilter(string kind) + { + Kind = kind; + } + + /// Discriminator. + internal string Kind { get; set; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SearchHighlights.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SearchHighlights.Serialization.cs new file mode 100644 index 0000000000000..27439f347016b --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SearchHighlights.Serialization.cs @@ -0,0 +1,112 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using System.Text.Json; +using Azure; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class SearchHighlights + { + internal static SearchHighlights DeserializeSearchHighlights(JsonElement element) + { + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + Optional> id = default; + Optional> qualifiedName = default; + Optional> name = default; + Optional> description = default; + Optional> entityType = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("id"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(item.GetString()); + } + id = array; + continue; + } + if (property.NameEquals("qualifiedName"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(item.GetString()); + } + qualifiedName = array; + continue; + } + if (property.NameEquals("name"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(item.GetString()); + } + name = array; + continue; + } + if (property.NameEquals("description"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(item.GetString()); + } + description = array; + continue; + } + if (property.NameEquals("entityType"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(item.GetString()); + } + entityType = array; + continue; + } + } + return new SearchHighlights(Optional.ToList(id), Optional.ToList(qualifiedName), Optional.ToList(name), Optional.ToList(description), Optional.ToList(entityType)); + } + + /// Deserializes the model from a raw response. + /// The response to deserialize the model from. + internal static SearchHighlights FromResponse(Response response) + { + using var document = JsonDocument.Parse(response.Content); + return DeserializeSearchHighlights(document.RootElement); + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SearchHighlights.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SearchHighlights.cs new file mode 100644 index 0000000000000..567c6000f4444 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SearchHighlights.cs @@ -0,0 +1,57 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + /// + /// A highlight list that consists of index fields id ,qualifiedName, name, + /// description, entityType. When the keyword appears in those fields, the value of + /// the field, attached with emphasis mark, is returned as an element of + /// @search.highlights. + /// + public partial class SearchHighlights + { + /// Initializes a new instance of . + internal SearchHighlights() + { + Id = new ChangeTrackingList(); + QualifiedName = new ChangeTrackingList(); + Name = new ChangeTrackingList(); + Description = new ChangeTrackingList(); + EntityType = new ChangeTrackingList(); + } + + /// Initializes a new instance of . + /// Id. + /// Qualified name. + /// Name. + /// Description. + /// Entity type. + internal SearchHighlights(IReadOnlyList id, IReadOnlyList qualifiedName, IReadOnlyList name, IReadOnlyList description, IReadOnlyList entityType) + { + Id = id; + QualifiedName = qualifiedName; + Name = name; + Description = description; + EntityType = entityType; + } + + /// Id. + public IReadOnlyList Id { get; } + /// Qualified name. + public IReadOnlyList QualifiedName { get; } + /// Name. + public IReadOnlyList Name { get; } + /// Description. + public IReadOnlyList Description { get; } + /// Entity type. + public IReadOnlyList EntityType { get; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SearchOptions.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SearchOptions.Serialization.cs new file mode 100644 index 0000000000000..90c937c779fce --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SearchOptions.Serialization.cs @@ -0,0 +1,93 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class SearchOptions : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + if (Optional.IsDefined(Keywords)) + { + writer.WritePropertyName("keywords"u8); + writer.WriteStringValue(Keywords); + } + if (Optional.IsDefined(Limit)) + { + writer.WritePropertyName("limit"u8); + writer.WriteNumberValue(Limit.Value); + } + if (Optional.IsDefined(ContinuationToken)) + { + writer.WritePropertyName("continuationToken"u8); + writer.WriteStringValue(ContinuationToken); + } + if (Optional.IsCollectionDefined(Orderby)) + { + writer.WritePropertyName("orderby"u8); + writer.WriteStartArray(); + foreach (var item in Orderby) + { + if (item == null) + { + writer.WriteNullValue(); + continue; + } +#if NET6_0_OR_GREATER + writer.WriteRawValue(item); +#else + using (JsonDocument document = JsonDocument.Parse(item)) + { + JsonSerializer.Serialize(writer, document.RootElement); + } +#endif + } + writer.WriteEndArray(); + } + if (Optional.IsDefined(Filter)) + { + writer.WritePropertyName("filter"u8); +#if NET6_0_OR_GREATER + writer.WriteRawValue(Filter); +#else + using (JsonDocument document = JsonDocument.Parse(Filter)) + { + JsonSerializer.Serialize(writer, document.RootElement); + } +#endif + } + if (Optional.IsCollectionDefined(Facets)) + { + writer.WritePropertyName("facets"u8); + writer.WriteStartArray(); + foreach (var item in Facets) + { + writer.WriteObjectValue(item); + } + writer.WriteEndArray(); + } + if (Optional.IsDefined(TaxonomySetting)) + { + writer.WritePropertyName("taxonomySetting"u8); + writer.WriteObjectValue(TaxonomySetting); + } + writer.WriteEndObject(); + } + + /// Convert into a Utf8JsonRequestContent. + internal virtual RequestContent ToRequestContent() + { + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(this); + return content; + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SearchOptions.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SearchOptions.cs new file mode 100644 index 0000000000000..03d87a8b12f2c --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SearchOptions.cs @@ -0,0 +1,128 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Collections.Generic; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + /// The search query of advanced search request. + public partial class SearchOptions + { + /// Initializes a new instance of . + public SearchOptions() + { + Orderby = new ChangeTrackingList(); + Facets = new ChangeTrackingList(); + } + + /// Initializes a new instance of . + /// The keywords applied to all searchable fields. + /// + /// The limit of the number of the search result. default value is 50; maximum + /// value is 1000. + /// + /// + /// The token used to get next batch of data. Default 'Null' to get the first + /// batch, and will return new token in each response unless there's no more data. + /// + /// The sort order of search results, can specify multiple fields. + /// The filter for the search. See examples for the usage of supported filters. + /// The facets for search. See examples for the usage of supported facets. + /// The taxonomy setting for search. + internal SearchOptions(string keywords, int? limit, string continuationToken, IList orderby, BinaryData filter, IList facets, SearchTaxonomySetting taxonomySetting) + { + Keywords = keywords; + Limit = limit; + ContinuationToken = continuationToken; + Orderby = orderby; + Filter = filter; + Facets = facets; + TaxonomySetting = taxonomySetting; + } + + /// The keywords applied to all searchable fields. + public string Keywords { get; set; } + /// + /// The limit of the number of the search result. default value is 50; maximum + /// value is 1000. + /// + public int? Limit { get; set; } + /// + /// The token used to get next batch of data. Default 'Null' to get the first + /// batch, and will return new token in each response unless there's no more data. + /// + public string ContinuationToken { get; set; } + /// + /// The sort order of search results, can specify multiple fields. + /// + /// To assign an object to the element of this property use . + /// + /// + /// To assign an already formatted json string to this property use . + /// + /// + /// Examples: + /// + /// + /// BinaryData.FromObjectAsJson("foo") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromString("\"foo\"") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromObjectAsJson(new { key = "value" }) + /// Creates a payload of { "key": "value" }. + /// + /// + /// BinaryData.FromString("{\"key\": \"value\"}") + /// Creates a payload of { "key": "value" }. + /// + /// + /// + /// + public IList Orderby { get; } + /// + /// The filter for the search. See examples for the usage of supported filters. + /// + /// To assign an object to this property use . + /// + /// + /// To assign an already formatted json string to this property use . + /// + /// + /// Examples: + /// + /// + /// BinaryData.FromObjectAsJson("foo") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromString("\"foo\"") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromObjectAsJson(new { key = "value" }) + /// Creates a payload of { "key": "value" }. + /// + /// + /// BinaryData.FromString("{\"key\": \"value\"}") + /// Creates a payload of { "key": "value" }. + /// + /// + /// + /// + public BinaryData Filter { get; set; } + /// The facets for search. See examples for the usage of supported facets. + public IList Facets { get; } + /// The taxonomy setting for search. + public SearchTaxonomySetting TaxonomySetting { get; set; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SearchResult.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SearchResult.Serialization.cs new file mode 100644 index 0000000000000..a3b2ebecc870a --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SearchResult.Serialization.cs @@ -0,0 +1,88 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using System.Text.Json; +using Azure; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class SearchResult + { + internal static SearchResult DeserializeSearchResult(JsonElement element) + { + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + Optional searchCount = default; + Optional searchCountApproximate = default; + Optional continuationToken = default; + Optional searchFacets = default; + Optional> value = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("@search.count"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + searchCount = property.Value.GetInt32(); + continue; + } + if (property.NameEquals("@search.count.approximate"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + searchCountApproximate = property.Value.GetBoolean(); + continue; + } + if (property.NameEquals("continuationToken"u8)) + { + continuationToken = property.Value.GetString(); + continue; + } + if (property.NameEquals("@search.facets"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + searchFacets = SearchFacetResultValue.DeserializeSearchFacetResultValue(property.Value); + continue; + } + if (property.NameEquals("value"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(SearchResultValue.DeserializeSearchResultValue(item)); + } + value = array; + continue; + } + } + return new SearchResult(Optional.ToNullable(searchCount), Optional.ToNullable(searchCountApproximate), continuationToken.Value, searchFacets.Value, Optional.ToList(value)); + } + + /// Deserializes the model from a raw response. + /// The response to deserialize the model from. + internal static SearchResult FromResponse(Response response) + { + using var document = JsonDocument.Parse(response.Content); + return DeserializeSearchResult(document.RootElement); + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SearchResult.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SearchResult.cs new file mode 100644 index 0000000000000..6477ea9b0b3f2 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SearchResult.cs @@ -0,0 +1,62 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + /// The result of the search result. + public partial class SearchResult + { + /// Initializes a new instance of . + internal SearchResult() + { + Value = new ChangeTrackingList(); + } + + /// Initializes a new instance of . + /// + /// The total number of search results (not the number of documents in a single + /// page). + /// + /// 'True' if the '@search.count' is an approximate value and vise versa. + /// The token used to get next batch of data. Absent if there's no more data. + /// + /// A facet list that consists of index fields assetType ,classification, + /// contactId, and label. When the facet is specified in the request, the value of + /// the facet is returned as an element of @search.facets. + /// + /// Search result value. + internal SearchResult(int? searchCount, bool? searchCountApproximate, string continuationToken, SearchFacetResultValue searchFacets, IReadOnlyList value) + { + SearchCount = searchCount; + SearchCountApproximate = searchCountApproximate; + ContinuationToken = continuationToken; + SearchFacets = searchFacets; + Value = value; + } + + /// + /// The total number of search results (not the number of documents in a single + /// page). + /// + public int? SearchCount { get; } + /// 'True' if the '@search.count' is an approximate value and vise versa. + public bool? SearchCountApproximate { get; } + /// The token used to get next batch of data. Absent if there's no more data. + public string ContinuationToken { get; } + /// + /// A facet list that consists of index fields assetType ,classification, + /// contactId, and label. When the facet is specified in the request, the value of + /// the facet is returned as an element of @search.facets. + /// + public SearchFacetResultValue SearchFacets { get; } + /// Search result value. + public IReadOnlyList Value { get; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SearchResultValue.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SearchResultValue.Serialization.cs new file mode 100644 index 0000000000000..55a06dd14478a --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SearchResultValue.Serialization.cs @@ -0,0 +1,239 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using System.Text.Json; +using Azure; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class SearchResultValue + { + internal static SearchResultValue DeserializeSearchResultValue(JsonElement element) + { + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + Optional searchScore = default; + Optional searchHighlights = default; + Optional objectType = default; + Optional createTime = default; + Optional updateTime = default; + Optional id = default; + Optional name = default; + Optional qualifiedName = default; + Optional entityType = default; + Optional description = default; + Optional endorsement = default; + Optional owner = default; + Optional> classification = default; + Optional> label = default; + Optional> term = default; + Optional> contact = default; + Optional> assetType = default; + Optional glossaryType = default; + Optional glossary = default; + Optional termStatus = default; + Optional> termTemplate = default; + Optional longDescription = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("@search.score"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + searchScore = property.Value.GetSingle(); + continue; + } + if (property.NameEquals("@search.highlights"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + searchHighlights = SearchHighlights.DeserializeSearchHighlights(property.Value); + continue; + } + if (property.NameEquals("objectType"u8)) + { + objectType = property.Value.GetString(); + continue; + } + if (property.NameEquals("createTime"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + createTime = property.Value.GetInt64(); + continue; + } + if (property.NameEquals("updateTime"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + updateTime = property.Value.GetInt64(); + continue; + } + if (property.NameEquals("id"u8)) + { + id = property.Value.GetString(); + continue; + } + if (property.NameEquals("name"u8)) + { + name = property.Value.GetString(); + continue; + } + if (property.NameEquals("qualifiedName"u8)) + { + qualifiedName = property.Value.GetString(); + continue; + } + if (property.NameEquals("entityType"u8)) + { + entityType = property.Value.GetString(); + continue; + } + if (property.NameEquals("description"u8)) + { + description = property.Value.GetString(); + continue; + } + if (property.NameEquals("endorsement"u8)) + { + endorsement = property.Value.GetString(); + continue; + } + if (property.NameEquals("owner"u8)) + { + owner = property.Value.GetString(); + continue; + } + if (property.NameEquals("classification"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(item.GetString()); + } + classification = array; + continue; + } + if (property.NameEquals("label"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(item.GetString()); + } + label = array; + continue; + } + if (property.NameEquals("term"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(TermSearchResultValue.DeserializeTermSearchResultValue(item)); + } + term = array; + continue; + } + if (property.NameEquals("contact"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(ContactSearchResultValue.DeserializeContactSearchResultValue(item)); + } + contact = array; + continue; + } + if (property.NameEquals("assetType"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(item.GetString()); + } + assetType = array; + continue; + } + if (property.NameEquals("glossaryType"u8)) + { + glossaryType = property.Value.GetString(); + continue; + } + if (property.NameEquals("glossary"u8)) + { + glossary = property.Value.GetString(); + continue; + } + if (property.NameEquals("termStatus"u8)) + { + termStatus = property.Value.GetString(); + continue; + } + if (property.NameEquals("termTemplate"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(item.GetString()); + } + termTemplate = array; + continue; + } + if (property.NameEquals("longDescription"u8)) + { + longDescription = property.Value.GetString(); + continue; + } + } + return new SearchResultValue(Optional.ToNullable(searchScore), searchHighlights.Value, objectType.Value, Optional.ToNullable(createTime), Optional.ToNullable(updateTime), id.Value, name.Value, qualifiedName.Value, entityType.Value, description.Value, endorsement.Value, owner.Value, Optional.ToList(classification), Optional.ToList(label), Optional.ToList(term), Optional.ToList(contact), Optional.ToList(assetType), glossaryType.Value, glossary.Value, termStatus.Value, Optional.ToList(termTemplate), longDescription.Value); + } + + /// Deserializes the model from a raw response. + /// The response to deserialize the model from. + internal static SearchResultValue FromResponse(Response response) + { + using var document = JsonDocument.Parse(response.Content); + return DeserializeSearchResultValue(document.RootElement); + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SearchResultValue.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SearchResultValue.cs new file mode 100644 index 0000000000000..e89a64e678724 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SearchResultValue.cs @@ -0,0 +1,149 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + /// The value item of the search result. + public partial class SearchResultValue + { + /// Initializes a new instance of . + internal SearchResultValue() + { + Classification = new ChangeTrackingList(); + Label = new ChangeTrackingList(); + Term = new ChangeTrackingList(); + Contact = new ChangeTrackingList(); + AssetType = new ChangeTrackingList(); + TermTemplate = new ChangeTrackingList(); + } + + /// Initializes a new instance of . + /// + /// The search score calculated by the search engine. The results are ordered by + /// search score by default. + /// + /// + /// A highlight list that consists of index fields id ,qualifiedName, name, + /// description, entityType. When the keyword appears in those fields, the value of + /// the field, attached with emphasis mark, is returned as an element of + /// @search.highlights. + /// + /// + /// The object type of the record. Object type is the top-level property to + /// distinguish whether a record is an asset or a term. + /// + /// The create time of the record. The Unix epoch format. + /// The last update time of the record. The Unix epoch format. + /// The GUID of the record. + /// The name of the record. + /// The qualified name of the record. + /// The type name of the asset. + /// The description of the asset. + /// The endorsement of the asset. + /// The owner of the record. + /// The classifications of the record. + /// The labels of the asset. + /// The terms assigned to the asset. + /// The contacts of the asset. + /// The asset types of the asset. + /// + /// The type name of the term. Could be AtlasGlossary, AtlasGlossaryTerm or + /// AtlasGlossaryCategory. + /// + /// The glossary name of the term. + /// The status of the term. + /// The term template names used by the term. + /// The definition of the term. + internal SearchResultValue(float? searchScore, SearchHighlights searchHighlights, string objectType, long? createTime, long? updateTime, string id, string name, string qualifiedName, string entityType, string description, string endorsement, string owner, IReadOnlyList classification, IReadOnlyList label, IReadOnlyList term, IReadOnlyList contact, IReadOnlyList assetType, string glossaryType, string glossary, string termStatus, IReadOnlyList termTemplate, string longDescription) + { + SearchScore = searchScore; + SearchHighlights = searchHighlights; + ObjectType = objectType; + CreateTime = createTime; + UpdateTime = updateTime; + Id = id; + Name = name; + QualifiedName = qualifiedName; + EntityType = entityType; + Description = description; + Endorsement = endorsement; + Owner = owner; + Classification = classification; + Label = label; + Term = term; + Contact = contact; + AssetType = assetType; + GlossaryType = glossaryType; + Glossary = glossary; + TermStatus = termStatus; + TermTemplate = termTemplate; + LongDescription = longDescription; + } + + /// + /// The search score calculated by the search engine. The results are ordered by + /// search score by default. + /// + public float? SearchScore { get; } + /// + /// A highlight list that consists of index fields id ,qualifiedName, name, + /// description, entityType. When the keyword appears in those fields, the value of + /// the field, attached with emphasis mark, is returned as an element of + /// @search.highlights. + /// + public SearchHighlights SearchHighlights { get; } + /// + /// The object type of the record. Object type is the top-level property to + /// distinguish whether a record is an asset or a term. + /// + public string ObjectType { get; } + /// The create time of the record. The Unix epoch format. + public long? CreateTime { get; } + /// The last update time of the record. The Unix epoch format. + public long? UpdateTime { get; } + /// The GUID of the record. + public string Id { get; } + /// The name of the record. + public string Name { get; } + /// The qualified name of the record. + public string QualifiedName { get; } + /// The type name of the asset. + public string EntityType { get; } + /// The description of the asset. + public string Description { get; } + /// The endorsement of the asset. + public string Endorsement { get; } + /// The owner of the record. + public string Owner { get; } + /// The classifications of the record. + public IReadOnlyList Classification { get; } + /// The labels of the asset. + public IReadOnlyList Label { get; } + /// The terms assigned to the asset. + public IReadOnlyList Term { get; } + /// The contacts of the asset. + public IReadOnlyList Contact { get; } + /// The asset types of the asset. + public IReadOnlyList AssetType { get; } + /// + /// The type name of the term. Could be AtlasGlossary, AtlasGlossaryTerm or + /// AtlasGlossaryCategory. + /// + public string GlossaryType { get; } + /// The glossary name of the term. + public string Glossary { get; } + /// The status of the term. + public string TermStatus { get; } + /// The term template names used by the term. + public IReadOnlyList TermTemplate { get; } + /// The definition of the term. + public string LongDescription { get; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SearchSortOrder.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SearchSortOrder.cs new file mode 100644 index 0000000000000..40f55c2030e9b --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SearchSortOrder.cs @@ -0,0 +1,51 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.ComponentModel; + +namespace Azure.Analytics.Purview.DataMap +{ + /// Search sort order. + public readonly partial struct SearchSortOrder : IEquatable + { + private readonly string _value; + + /// Initializes a new instance of . + /// is null. + public SearchSortOrder(string value) + { + _value = value ?? throw new ArgumentNullException(nameof(value)); + } + + private const string AscendValue = "asc"; + private const string DescendValue = "desc"; + + /// Use ascending order for sorting. + public static SearchSortOrder Ascend { get; } = new SearchSortOrder(AscendValue); + /// Use descending order for sorting. + public static SearchSortOrder Descend { get; } = new SearchSortOrder(DescendValue); + /// Determines if two values are the same. + public static bool operator ==(SearchSortOrder left, SearchSortOrder right) => left.Equals(right); + /// Determines if two values are not the same. + public static bool operator !=(SearchSortOrder left, SearchSortOrder right) => !left.Equals(right); + /// Converts a string to a . + public static implicit operator SearchSortOrder(string value) => new SearchSortOrder(value); + + /// + [EditorBrowsable(EditorBrowsableState.Never)] + public override bool Equals(object obj) => obj is SearchSortOrder other && Equals(other); + /// + public bool Equals(SearchSortOrder other) => string.Equals(_value, other._value, StringComparison.InvariantCultureIgnoreCase); + + /// + [EditorBrowsable(EditorBrowsableState.Never)] + public override int GetHashCode() => _value?.GetHashCode() ?? 0; + /// + public override string ToString() => _value; + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SearchTaxonomySetting.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SearchTaxonomySetting.Serialization.cs new file mode 100644 index 0000000000000..77a1c7412bba6 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SearchTaxonomySetting.Serialization.cs @@ -0,0 +1,44 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class SearchTaxonomySetting : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + if (Optional.IsCollectionDefined(AssetTypes)) + { + writer.WritePropertyName("assetTypes"u8); + writer.WriteStartArray(); + foreach (var item in AssetTypes) + { + writer.WriteStringValue(item); + } + writer.WriteEndArray(); + } + if (Optional.IsDefined(Facet)) + { + writer.WritePropertyName("facet"u8); + writer.WriteObjectValue(Facet); + } + writer.WriteEndObject(); + } + + /// Convert into a Utf8JsonRequestContent. + internal virtual RequestContent ToRequestContent() + { + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(this); + return content; + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SearchTaxonomySetting.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SearchTaxonomySetting.cs new file mode 100644 index 0000000000000..176c660e75514 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SearchTaxonomySetting.cs @@ -0,0 +1,36 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + /// Taxonomy setting for search request. + public partial class SearchTaxonomySetting + { + /// Initializes a new instance of . + public SearchTaxonomySetting() + { + AssetTypes = new ChangeTrackingList(); + } + + /// Initializes a new instance of . + /// Asset types. + /// The content of a search facet result item. + internal SearchTaxonomySetting(IList assetTypes, SearchFacetItem facet) + { + AssetTypes = assetTypes; + Facet = facet; + } + + /// Asset types. + public IList AssetTypes { get; } + /// The content of a search facet result item. + public SearchFacetItem Facet { get; set; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SortType.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SortType.cs new file mode 100644 index 0000000000000..3fbfc82d381e2 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SortType.cs @@ -0,0 +1,54 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.ComponentModel; + +namespace Azure.Analytics.Purview.DataMap +{ + /// Type for sorting. + public readonly partial struct SortType : IEquatable + { + private readonly string _value; + + /// Initializes a new instance of . + /// is null. + public SortType(string value) + { + _value = value ?? throw new ArgumentNullException(nameof(value)); + } + + private const string NoneValue = "NONE"; + private const string AscendValue = "ASC"; + private const string DescendValue = "DESC"; + + /// No sorting order. + public static SortType None { get; } = new SortType(NoneValue); + /// Use ascending order for sorting. + public static SortType Ascend { get; } = new SortType(AscendValue); + /// Use descending order for sorting. + public static SortType Descend { get; } = new SortType(DescendValue); + /// Determines if two values are the same. + public static bool operator ==(SortType left, SortType right) => left.Equals(right); + /// Determines if two values are not the same. + public static bool operator !=(SortType left, SortType right) => !left.Equals(right); + /// Converts a string to a . + public static implicit operator SortType(string value) => new SortType(value); + + /// + [EditorBrowsable(EditorBrowsableState.Never)] + public override bool Equals(object obj) => obj is SortType other && Equals(other); + /// + public bool Equals(SortType other) => string.Equals(_value, other._value, StringComparison.InvariantCultureIgnoreCase); + + /// + [EditorBrowsable(EditorBrowsableState.Never)] + public override int GetHashCode() => _value?.GetHashCode() ?? 0; + /// + public override string ToString() => _value; + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/StatusAtlasRelationship.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/StatusAtlasRelationship.cs new file mode 100644 index 0000000000000..48e238befa2f3 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/StatusAtlasRelationship.cs @@ -0,0 +1,51 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.ComponentModel; + +namespace Azure.Analytics.Purview.DataMap +{ + /// Status for atlas relationship. + public readonly partial struct StatusAtlasRelationship : IEquatable + { + private readonly string _value; + + /// Initializes a new instance of . + /// is null. + public StatusAtlasRelationship(string value) + { + _value = value ?? throw new ArgumentNullException(nameof(value)); + } + + private const string ActiveValue = "ACTIVE"; + private const string DeletedValue = "DELETED"; + + /// active. + public static StatusAtlasRelationship Active { get; } = new StatusAtlasRelationship(ActiveValue); + /// deleted. + public static StatusAtlasRelationship Deleted { get; } = new StatusAtlasRelationship(DeletedValue); + /// Determines if two values are the same. + public static bool operator ==(StatusAtlasRelationship left, StatusAtlasRelationship right) => left.Equals(right); + /// Determines if two values are not the same. + public static bool operator !=(StatusAtlasRelationship left, StatusAtlasRelationship right) => !left.Equals(right); + /// Converts a string to a . + public static implicit operator StatusAtlasRelationship(string value) => new StatusAtlasRelationship(value); + + /// + [EditorBrowsable(EditorBrowsableState.Never)] + public override bool Equals(object obj) => obj is StatusAtlasRelationship other && Equals(other); + /// + public bool Equals(StatusAtlasRelationship other) => string.Equals(_value, other._value, StringComparison.InvariantCultureIgnoreCase); + + /// + [EditorBrowsable(EditorBrowsableState.Never)] + public override int GetHashCode() => _value?.GetHashCode() ?? 0; + /// + public override string ToString() => _value; + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SuggestOptions.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SuggestOptions.Serialization.cs new file mode 100644 index 0000000000000..43211c9fb16ac --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SuggestOptions.Serialization.cs @@ -0,0 +1,44 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class SuggestOptions : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + if (Optional.IsDefined(Keywords)) + { + writer.WritePropertyName("keywords"u8); + writer.WriteStringValue(Keywords); + } + if (Optional.IsDefined(Limit)) + { + writer.WritePropertyName("limit"u8); + writer.WriteNumberValue(Limit.Value); + } + if (Optional.IsDefined(Filter)) + { + writer.WritePropertyName("filter"u8); + writer.WriteObjectValue(Filter); + } + writer.WriteEndObject(); + } + + /// Convert into a Utf8JsonRequestContent. + internal virtual RequestContent ToRequestContent() + { + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(this); + return content; + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SuggestOptions.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SuggestOptions.cs new file mode 100644 index 0000000000000..2ee2b0559435f --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SuggestOptions.cs @@ -0,0 +1,56 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +namespace Azure.Analytics.Purview.DataMap +{ + /// The query of suggest request. + public partial class SuggestOptions + { + /// Initializes a new instance of . + public SuggestOptions() + { + } + + /// Initializes a new instance of . + /// + /// The keywords applied to all fields that support suggest operation. It must be + /// at least 1 character, and no more than 100 characters. In the index schema we + /// defined a default suggester which lists all the supported fields and specifies + /// a search mode. + /// + /// + /// The number of suggestions we hope to return. The default value is 5. The value + /// must be a number between 1 and 100. + /// + /// The filter for the search. + internal SuggestOptions(string keywords, int? limit, SearchFilter filter) + { + Keywords = keywords; + Limit = limit; + Filter = filter; + } + + /// + /// The keywords applied to all fields that support suggest operation. It must be + /// at least 1 character, and no more than 100 characters. In the index schema we + /// defined a default suggester which lists all the supported fields and specifies + /// a search mode. + /// + public string Keywords { get; set; } + /// + /// The number of suggestions we hope to return. The default value is 5. The value + /// must be a number between 1 and 100. + /// + public int? Limit { get; set; } + /// + /// The filter for the search. + /// Please note is the base class. According to the scenario, a derived class of the base class might need to be assigned here, or this property needs to be casted to one of the possible derived classes. + /// The available derived classes include , , , , , , , , , , , , , , , , , , , , and . + /// + public SearchFilter Filter { get; set; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SuggestResult.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SuggestResult.Serialization.cs new file mode 100644 index 0000000000000..f02c51317e85f --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SuggestResult.Serialization.cs @@ -0,0 +1,52 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using System.Text.Json; +using Azure; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class SuggestResult + { + internal static SuggestResult DeserializeSuggestResult(JsonElement element) + { + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + Optional> value = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("value"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(SuggestResultValue.DeserializeSuggestResultValue(item)); + } + value = array; + continue; + } + } + return new SuggestResult(Optional.ToList(value)); + } + + /// Deserializes the model from a raw response. + /// The response to deserialize the model from. + internal static SuggestResult FromResponse(Response response) + { + using var document = JsonDocument.Parse(response.Content); + return DeserializeSuggestResult(document.RootElement); + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SuggestResult.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SuggestResult.cs new file mode 100644 index 0000000000000..6c84f80c1b704 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SuggestResult.cs @@ -0,0 +1,32 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + /// The result item of the search suggest. + public partial class SuggestResult + { + /// Initializes a new instance of . + internal SuggestResult() + { + Value = new ChangeTrackingList(); + } + + /// Initializes a new instance of . + /// The result value. + internal SuggestResult(IReadOnlyList value) + { + Value = value; + } + + /// The result value. + public IReadOnlyList Value { get; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SuggestResultValue.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SuggestResultValue.Serialization.cs new file mode 100644 index 0000000000000..7100df46ddad7 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SuggestResultValue.Serialization.cs @@ -0,0 +1,235 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using System.Text.Json; +using Azure; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class SuggestResultValue + { + internal static SuggestResultValue DeserializeSuggestResultValue(JsonElement element) + { + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + Optional searchScore = default; + Optional searchText = default; + Optional objectType = default; + Optional createTime = default; + Optional updateTime = default; + Optional id = default; + Optional name = default; + Optional qualifiedName = default; + Optional entityType = default; + Optional description = default; + Optional endorsement = default; + Optional owner = default; + Optional> classification = default; + Optional> label = default; + Optional> term = default; + Optional> contact = default; + Optional> assetType = default; + Optional glossaryType = default; + Optional glossary = default; + Optional termStatus = default; + Optional> termTemplate = default; + Optional longDescription = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("@search.score"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + searchScore = property.Value.GetSingle(); + continue; + } + if (property.NameEquals("@search.text"u8)) + { + searchText = property.Value.GetString(); + continue; + } + if (property.NameEquals("objectType"u8)) + { + objectType = property.Value.GetString(); + continue; + } + if (property.NameEquals("createTime"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + createTime = property.Value.GetInt64(); + continue; + } + if (property.NameEquals("updateTime"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + updateTime = property.Value.GetInt64(); + continue; + } + if (property.NameEquals("id"u8)) + { + id = property.Value.GetString(); + continue; + } + if (property.NameEquals("name"u8)) + { + name = property.Value.GetString(); + continue; + } + if (property.NameEquals("qualifiedName"u8)) + { + qualifiedName = property.Value.GetString(); + continue; + } + if (property.NameEquals("entityType"u8)) + { + entityType = property.Value.GetString(); + continue; + } + if (property.NameEquals("description"u8)) + { + description = property.Value.GetString(); + continue; + } + if (property.NameEquals("endorsement"u8)) + { + endorsement = property.Value.GetString(); + continue; + } + if (property.NameEquals("owner"u8)) + { + owner = property.Value.GetString(); + continue; + } + if (property.NameEquals("classification"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(item.GetString()); + } + classification = array; + continue; + } + if (property.NameEquals("label"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(item.GetString()); + } + label = array; + continue; + } + if (property.NameEquals("term"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(TermSearchResultValue.DeserializeTermSearchResultValue(item)); + } + term = array; + continue; + } + if (property.NameEquals("contact"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(ContactSearchResultValue.DeserializeContactSearchResultValue(item)); + } + contact = array; + continue; + } + if (property.NameEquals("assetType"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(item.GetString()); + } + assetType = array; + continue; + } + if (property.NameEquals("glossaryType"u8)) + { + glossaryType = property.Value.GetString(); + continue; + } + if (property.NameEquals("glossary"u8)) + { + glossary = property.Value.GetString(); + continue; + } + if (property.NameEquals("termStatus"u8)) + { + termStatus = property.Value.GetString(); + continue; + } + if (property.NameEquals("termTemplate"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(item.GetString()); + } + termTemplate = array; + continue; + } + if (property.NameEquals("longDescription"u8)) + { + longDescription = property.Value.GetString(); + continue; + } + } + return new SuggestResultValue(Optional.ToNullable(searchScore), searchText.Value, objectType.Value, Optional.ToNullable(createTime), Optional.ToNullable(updateTime), id.Value, name.Value, qualifiedName.Value, entityType.Value, description.Value, endorsement.Value, owner.Value, Optional.ToList(classification), Optional.ToList(label), Optional.ToList(term), Optional.ToList(contact), Optional.ToList(assetType), glossaryType.Value, glossary.Value, termStatus.Value, Optional.ToList(termTemplate), longDescription.Value); + } + + /// Deserializes the model from a raw response. + /// The response to deserialize the model from. + internal static SuggestResultValue FromResponse(Response response) + { + using var document = JsonDocument.Parse(response.Content); + return DeserializeSuggestResultValue(document.RootElement); + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SuggestResultValue.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SuggestResultValue.cs new file mode 100644 index 0000000000000..7be9ed8076a49 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/SuggestResultValue.cs @@ -0,0 +1,145 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + /// The value item of the search suggest. + public partial class SuggestResultValue + { + /// Initializes a new instance of . + internal SuggestResultValue() + { + Classification = new ChangeTrackingList(); + Label = new ChangeTrackingList(); + Term = new ChangeTrackingList(); + Contact = new ChangeTrackingList(); + AssetType = new ChangeTrackingList(); + TermTemplate = new ChangeTrackingList(); + } + + /// Initializes a new instance of . + /// + /// The search score calculated by the search engine. The results are ordered by + /// search score by default. + /// + /// + /// The target text that contains the keyword as prefix. The keyword is wrapped + /// with emphasis mark. + /// + /// + /// The object type of the record. Object type is the top-level property to + /// distinguish whether a record is an asset or a term. + /// + /// The create time of the record. The Unix epoch format. + /// The last update time of the record. The Unix epoch format. + /// The GUID of the record. + /// The name of the record. + /// The qualified name of the record. + /// The type name of the asset. + /// The description of the asset. + /// The endorsement of the asset. + /// The owner of the record. + /// The classifications of the record. + /// The labels of the asset. + /// The terms assigned to the asset. + /// The contacts of the asset. + /// The asset types of the asset. + /// + /// The type name of the term. Could be AtlasGlossary, AtlasGlossaryTerm or + /// AtlasGlossaryCategory. + /// + /// The glossary name of the term. + /// The status of the term. + /// The term template names used by the term. + /// The definition of the term. + internal SuggestResultValue(float? searchScore, string searchText, string objectType, long? createTime, long? updateTime, string id, string name, string qualifiedName, string entityType, string description, string endorsement, string owner, IReadOnlyList classification, IReadOnlyList label, IReadOnlyList term, IReadOnlyList contact, IReadOnlyList assetType, string glossaryType, string glossary, string termStatus, IReadOnlyList termTemplate, string longDescription) + { + SearchScore = searchScore; + SearchText = searchText; + ObjectType = objectType; + CreateTime = createTime; + UpdateTime = updateTime; + Id = id; + Name = name; + QualifiedName = qualifiedName; + EntityType = entityType; + Description = description; + Endorsement = endorsement; + Owner = owner; + Classification = classification; + Label = label; + Term = term; + Contact = contact; + AssetType = assetType; + GlossaryType = glossaryType; + Glossary = glossary; + TermStatus = termStatus; + TermTemplate = termTemplate; + LongDescription = longDescription; + } + + /// + /// The search score calculated by the search engine. The results are ordered by + /// search score by default. + /// + public float? SearchScore { get; } + /// + /// The target text that contains the keyword as prefix. The keyword is wrapped + /// with emphasis mark. + /// + public string SearchText { get; } + /// + /// The object type of the record. Object type is the top-level property to + /// distinguish whether a record is an asset or a term. + /// + public string ObjectType { get; } + /// The create time of the record. The Unix epoch format. + public long? CreateTime { get; } + /// The last update time of the record. The Unix epoch format. + public long? UpdateTime { get; } + /// The GUID of the record. + public string Id { get; } + /// The name of the record. + public string Name { get; } + /// The qualified name of the record. + public string QualifiedName { get; } + /// The type name of the asset. + public string EntityType { get; } + /// The description of the asset. + public string Description { get; } + /// The endorsement of the asset. + public string Endorsement { get; } + /// The owner of the record. + public string Owner { get; } + /// The classifications of the record. + public IReadOnlyList Classification { get; } + /// The labels of the asset. + public IReadOnlyList Label { get; } + /// The terms assigned to the asset. + public IReadOnlyList Term { get; } + /// The contacts of the asset. + public IReadOnlyList Contact { get; } + /// The asset types of the asset. + public IReadOnlyList AssetType { get; } + /// + /// The type name of the term. Could be AtlasGlossary, AtlasGlossaryTerm or + /// AtlasGlossaryCategory. + /// + public string GlossaryType { get; } + /// The glossary name of the term. + public string Glossary { get; } + /// The status of the term. + public string TermStatus { get; } + /// The term template names used by the term. + public IReadOnlyList TermTemplate { get; } + /// The definition of the term. + public string LongDescription { get; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/TermFilter.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/TermFilter.Serialization.cs new file mode 100644 index 0000000000000..88696d23eaf78 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/TermFilter.Serialization.cs @@ -0,0 +1,46 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class TermFilter : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + if (Optional.IsDefined(Glossary)) + { + writer.WritePropertyName("glossary"u8); + writer.WriteStringValue(Glossary); + } + if (Optional.IsDefined(Term)) + { + writer.WritePropertyName("term"u8); + writer.WriteStringValue(Term); + } + if (Optional.IsDefined(TermGuid)) + { + writer.WritePropertyName("termGuid"u8); + writer.WriteStringValue(TermGuid); + } + writer.WritePropertyName("kind"u8); + writer.WriteStringValue(Kind); + writer.WriteEndObject(); + } + + /// Convert into a Utf8JsonRequestContent. + internal override RequestContent ToRequestContent() + { + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(this); + return content; + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/TermFilter.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/TermFilter.cs new file mode 100644 index 0000000000000..d208a3b6f02b4 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/TermFilter.cs @@ -0,0 +1,38 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +namespace Azure.Analytics.Purview.DataMap +{ + /// Glossary term filter for search. + public partial class TermFilter : SearchFilter + { + /// Initializes a new instance of . + public TermFilter() + { + Kind = "TermFilter"; + } + + /// Initializes a new instance of . + /// Discriminator. + /// Glossary name. + /// Term name. + /// Term name. + internal TermFilter(string kind, string glossary, string term, string termGuid) : base(kind) + { + Glossary = glossary; + Term = term; + TermGuid = termGuid; + } + + /// Glossary name. + public string Glossary { get; set; } + /// Term name. + public string Term { get; set; } + /// Term name. + public string TermGuid { get; set; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/TermSearchResultValue.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/TermSearchResultValue.Serialization.cs new file mode 100644 index 0000000000000..45dbb3e9fa843 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/TermSearchResultValue.Serialization.cs @@ -0,0 +1,54 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class TermSearchResultValue + { + internal static TermSearchResultValue DeserializeTermSearchResultValue(JsonElement element) + { + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + Optional name = default; + Optional glossaryName = default; + Optional guid = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("name"u8)) + { + name = property.Value.GetString(); + continue; + } + if (property.NameEquals("glossaryName"u8)) + { + glossaryName = property.Value.GetString(); + continue; + } + if (property.NameEquals("guid"u8)) + { + guid = property.Value.GetString(); + continue; + } + } + return new TermSearchResultValue(name.Value, glossaryName.Value, guid.Value); + } + + /// Deserializes the model from a raw response. + /// The response to deserialize the model from. + internal static TermSearchResultValue FromResponse(Response response) + { + using var document = JsonDocument.Parse(response.Content); + return DeserializeTermSearchResultValue(document.RootElement); + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/TermSearchResultValue.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/TermSearchResultValue.cs new file mode 100644 index 0000000000000..33603786e1934 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/TermSearchResultValue.cs @@ -0,0 +1,36 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +namespace Azure.Analytics.Purview.DataMap +{ + /// The context. + public partial class TermSearchResultValue + { + /// Initializes a new instance of . + internal TermSearchResultValue() + { + } + + /// Initializes a new instance of . + /// The name of the term. + /// The name of the glossary which contains the term. + /// The GUID of the term. + internal TermSearchResultValue(string name, string glossaryName, string guid) + { + Name = name; + GlossaryName = glossaryName; + Guid = guid; + } + + /// The name of the term. + public string Name { get; } + /// The name of the glossary which contains the term. + public string GlossaryName { get; } + /// The GUID of the term. + public string Guid { get; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/TermStatus.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/TermStatus.cs new file mode 100644 index 0000000000000..cdb3016944e46 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/TermStatus.cs @@ -0,0 +1,57 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.ComponentModel; + +namespace Azure.Analytics.Purview.DataMap +{ + /// Status for term. + public readonly partial struct TermStatus : IEquatable + { + private readonly string _value; + + /// Initializes a new instance of . + /// is null. + public TermStatus(string value) + { + _value = value ?? throw new ArgumentNullException(nameof(value)); + } + + private const string DraftValue = "Draft"; + private const string ApprovedValue = "Approved"; + private const string AlertValue = "Alert"; + private const string ExpiredValue = "Expired"; + + /// draft. + public static TermStatus Draft { get; } = new TermStatus(DraftValue); + /// approved. + public static TermStatus Approved { get; } = new TermStatus(ApprovedValue); + /// alert. + public static TermStatus Alert { get; } = new TermStatus(AlertValue); + /// expired. + public static TermStatus Expired { get; } = new TermStatus(ExpiredValue); + /// Determines if two values are the same. + public static bool operator ==(TermStatus left, TermStatus right) => left.Equals(right); + /// Determines if two values are not the same. + public static bool operator !=(TermStatus left, TermStatus right) => !left.Equals(right); + /// Converts a string to a . + public static implicit operator TermStatus(string value) => new TermStatus(value); + + /// + [EditorBrowsable(EditorBrowsableState.Never)] + public override bool Equals(object obj) => obj is TermStatus other && Equals(other); + /// + public bool Equals(TermStatus other) => string.Equals(_value, other._value, StringComparison.InvariantCultureIgnoreCase); + + /// + [EditorBrowsable(EditorBrowsableState.Never)] + public override int GetHashCode() => _value?.GetHashCode() ?? 0; + /// + public override string ToString() => _value; + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/TermTemplateDef.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/TermTemplateDef.Serialization.cs new file mode 100644 index 0000000000000..6b5a18718f295 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/TermTemplateDef.Serialization.cs @@ -0,0 +1,265 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using System.Text.Json; +using Azure; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class TermTemplateDef : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + if (Optional.IsDefined(Category)) + { + writer.WritePropertyName("category"u8); + writer.WriteStringValue(Category.Value.ToString()); + } + if (Optional.IsDefined(CreateTime)) + { + writer.WritePropertyName("createTime"u8); + writer.WriteNumberValue(CreateTime.Value); + } + if (Optional.IsDefined(CreatedBy)) + { + writer.WritePropertyName("createdBy"u8); + writer.WriteStringValue(CreatedBy); + } + if (Optional.IsDefined(DateFormatter)) + { + writer.WritePropertyName("dateFormatter"u8); + writer.WriteObjectValue(DateFormatter); + } + if (Optional.IsDefined(Description)) + { + writer.WritePropertyName("description"u8); + writer.WriteStringValue(Description); + } + if (Optional.IsDefined(Guid)) + { + writer.WritePropertyName("guid"u8); + writer.WriteStringValue(Guid); + } + if (Optional.IsDefined(Name)) + { + writer.WritePropertyName("name"u8); + writer.WriteStringValue(Name); + } + if (Optional.IsCollectionDefined(Options)) + { + writer.WritePropertyName("options"u8); + writer.WriteStartObject(); + foreach (var item in Options) + { + writer.WritePropertyName(item.Key); + writer.WriteStringValue(item.Value); + } + writer.WriteEndObject(); + } + if (Optional.IsDefined(ServiceType)) + { + writer.WritePropertyName("serviceType"u8); + writer.WriteStringValue(ServiceType); + } + if (Optional.IsDefined(TypeVersion)) + { + writer.WritePropertyName("typeVersion"u8); + writer.WriteStringValue(TypeVersion); + } + if (Optional.IsDefined(UpdateTime)) + { + writer.WritePropertyName("updateTime"u8); + writer.WriteNumberValue(UpdateTime.Value); + } + if (Optional.IsDefined(UpdatedBy)) + { + writer.WritePropertyName("updatedBy"u8); + writer.WriteStringValue(UpdatedBy); + } + if (Optional.IsDefined(Version)) + { + writer.WritePropertyName("version"u8); + writer.WriteNumberValue(Version.Value); + } + if (Optional.IsDefined(LastModifiedTS)) + { + writer.WritePropertyName("lastModifiedTS"u8); + writer.WriteStringValue(LastModifiedTS); + } + if (Optional.IsCollectionDefined(AttributeDefs)) + { + writer.WritePropertyName("attributeDefs"u8); + writer.WriteStartArray(); + foreach (var item in AttributeDefs) + { + writer.WriteObjectValue(item); + } + writer.WriteEndArray(); + } + writer.WriteEndObject(); + } + + internal static TermTemplateDef DeserializeTermTemplateDef(JsonElement element) + { + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + Optional category = default; + Optional createTime = default; + Optional createdBy = default; + Optional dateFormatter = default; + Optional description = default; + Optional guid = default; + Optional name = default; + Optional> options = default; + Optional serviceType = default; + Optional typeVersion = default; + Optional updateTime = default; + Optional updatedBy = default; + Optional version = default; + Optional lastModifiedTS = default; + Optional> attributeDefs = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("category"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + category = new TypeCategory(property.Value.GetString()); + continue; + } + if (property.NameEquals("createTime"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + createTime = property.Value.GetInt64(); + continue; + } + if (property.NameEquals("createdBy"u8)) + { + createdBy = property.Value.GetString(); + continue; + } + if (property.NameEquals("dateFormatter"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + dateFormatter = DateFormat.DeserializeDateFormat(property.Value); + continue; + } + if (property.NameEquals("description"u8)) + { + description = property.Value.GetString(); + continue; + } + if (property.NameEquals("guid"u8)) + { + guid = property.Value.GetString(); + continue; + } + if (property.NameEquals("name"u8)) + { + name = property.Value.GetString(); + continue; + } + if (property.NameEquals("options"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + Dictionary dictionary = new Dictionary(); + foreach (var property0 in property.Value.EnumerateObject()) + { + dictionary.Add(property0.Name, property0.Value.GetString()); + } + options = dictionary; + continue; + } + if (property.NameEquals("serviceType"u8)) + { + serviceType = property.Value.GetString(); + continue; + } + if (property.NameEquals("typeVersion"u8)) + { + typeVersion = property.Value.GetString(); + continue; + } + if (property.NameEquals("updateTime"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + updateTime = property.Value.GetInt64(); + continue; + } + if (property.NameEquals("updatedBy"u8)) + { + updatedBy = property.Value.GetString(); + continue; + } + if (property.NameEquals("version"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + version = property.Value.GetInt64(); + continue; + } + if (property.NameEquals("lastModifiedTS"u8)) + { + lastModifiedTS = property.Value.GetString(); + continue; + } + if (property.NameEquals("attributeDefs"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(AtlasAttributeDef.DeserializeAtlasAttributeDef(item)); + } + attributeDefs = array; + continue; + } + } + return new TermTemplateDef(Optional.ToNullable(category), Optional.ToNullable(createTime), createdBy.Value, dateFormatter.Value, description.Value, guid.Value, name.Value, Optional.ToDictionary(options), serviceType.Value, typeVersion.Value, Optional.ToNullable(updateTime), updatedBy.Value, Optional.ToNullable(version), lastModifiedTS.Value, Optional.ToList(attributeDefs)); + } + + /// Deserializes the model from a raw response. + /// The response to deserialize the model from. + internal static TermTemplateDef FromResponse(Response response) + { + using var document = JsonDocument.Parse(response.Content); + return DeserializeTermTemplateDef(document.RootElement); + } + + /// Convert into a Utf8JsonRequestContent. + internal virtual RequestContent ToRequestContent() + { + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(this); + return content; + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/TermTemplateDef.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/TermTemplateDef.cs new file mode 100644 index 0000000000000..c52002749492e --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/TermTemplateDef.cs @@ -0,0 +1,89 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + /// Term template definition for glossary term. + public partial class TermTemplateDef + { + /// Initializes a new instance of . + public TermTemplateDef() + { + Options = new ChangeTrackingDictionary(); + AttributeDefs = new ChangeTrackingList(); + } + + /// Initializes a new instance of . + /// The enum of type category. + /// The created time of the record. + /// The user who created the record. + /// The date format. + /// The description of the type definition. + /// The GUID of the type definition. + /// The name of the type definition. + /// The options for the type definition. + /// The service type. + /// The version of the type. + /// The update time of the record. + /// The user who updated the record. + /// The version of the record. + /// ETag for concurrency control. + /// An array of attribute definitions. + internal TermTemplateDef(TypeCategory? category, long? createTime, string createdBy, DateFormat dateFormatter, string description, string guid, string name, IDictionary options, string serviceType, string typeVersion, long? updateTime, string updatedBy, long? version, string lastModifiedTS, IList attributeDefs) + { + Category = category; + CreateTime = createTime; + CreatedBy = createdBy; + DateFormatter = dateFormatter; + Description = description; + Guid = guid; + Name = name; + Options = options; + ServiceType = serviceType; + TypeVersion = typeVersion; + UpdateTime = updateTime; + UpdatedBy = updatedBy; + Version = version; + LastModifiedTS = lastModifiedTS; + AttributeDefs = attributeDefs; + } + + /// The enum of type category. + public TypeCategory? Category { get; set; } + /// The created time of the record. + public long? CreateTime { get; set; } + /// The user who created the record. + public string CreatedBy { get; set; } + /// The date format. + public DateFormat DateFormatter { get; set; } + /// The description of the type definition. + public string Description { get; set; } + /// The GUID of the type definition. + public string Guid { get; set; } + /// The name of the type definition. + public string Name { get; set; } + /// The options for the type definition. + public IDictionary Options { get; } + /// The service type. + public string ServiceType { get; set; } + /// The version of the type. + public string TypeVersion { get; set; } + /// The update time of the record. + public long? UpdateTime { get; set; } + /// The user who updated the record. + public string UpdatedBy { get; set; } + /// The version of the record. + public long? Version { get; set; } + /// ETag for concurrency control. + public string LastModifiedTS { get; set; } + /// An array of attribute definitions. + public IList AttributeDefs { get; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/TimeBoundary.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/TimeBoundary.Serialization.cs new file mode 100644 index 0000000000000..c770e751dd458 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/TimeBoundary.Serialization.cs @@ -0,0 +1,83 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class TimeBoundary : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + if (Optional.IsDefined(EndTime)) + { + writer.WritePropertyName("endTime"u8); + writer.WriteStringValue(EndTime); + } + if (Optional.IsDefined(StartTime)) + { + writer.WritePropertyName("startTime"u8); + writer.WriteStringValue(StartTime); + } + if (Optional.IsDefined(TimeZone)) + { + writer.WritePropertyName("timeZone"u8); + writer.WriteStringValue(TimeZone); + } + writer.WriteEndObject(); + } + + internal static TimeBoundary DeserializeTimeBoundary(JsonElement element) + { + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + Optional endTime = default; + Optional startTime = default; + Optional timeZone = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("endTime"u8)) + { + endTime = property.Value.GetString(); + continue; + } + if (property.NameEquals("startTime"u8)) + { + startTime = property.Value.GetString(); + continue; + } + if (property.NameEquals("timeZone"u8)) + { + timeZone = property.Value.GetString(); + continue; + } + } + return new TimeBoundary(endTime.Value, startTime.Value, timeZone.Value); + } + + /// Deserializes the model from a raw response. + /// The response to deserialize the model from. + internal static TimeBoundary FromResponse(Response response) + { + using var document = JsonDocument.Parse(response.Content); + return DeserializeTimeBoundary(document.RootElement); + } + + /// Convert into a Utf8JsonRequestContent. + internal virtual RequestContent ToRequestContent() + { + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(this); + return content; + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/TimeBoundary.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/TimeBoundary.cs new file mode 100644 index 0000000000000..313705bc052cc --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/TimeBoundary.cs @@ -0,0 +1,36 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +namespace Azure.Analytics.Purview.DataMap +{ + /// Captures time-boundary details. + public partial class TimeBoundary + { + /// Initializes a new instance of . + public TimeBoundary() + { + } + + /// Initializes a new instance of . + /// The end of the time boundary. + /// The start of the time boundary. + /// The timezone of the time boundary. + internal TimeBoundary(string endTime, string startTime, string timeZone) + { + EndTime = endTime; + StartTime = startTime; + TimeZone = timeZone; + } + + /// The end of the time boundary. + public string EndTime { get; set; } + /// The start of the time boundary. + public string StartTime { get; set; } + /// The timezone of the time boundary. + public string TimeZone { get; set; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/TimeZone.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/TimeZone.Serialization.cs new file mode 100644 index 0000000000000..482b2737e5fb9 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/TimeZone.Serialization.cs @@ -0,0 +1,143 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using System.Text.Json; +using Azure; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class TimeZone : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + if (Optional.IsDefined(DstSavings)) + { + writer.WritePropertyName("dstSavings"u8); + writer.WriteNumberValue(DstSavings.Value); + } + if (Optional.IsDefined(Id)) + { + writer.WritePropertyName("id"u8); + writer.WriteStringValue(Id); + } + if (Optional.IsCollectionDefined(AvailableIds)) + { + writer.WritePropertyName("availableIds"u8); + writer.WriteStartArray(); + foreach (var item in AvailableIds) + { + writer.WriteStringValue(item); + } + writer.WriteEndArray(); + } + if (Optional.IsDefined(Default)) + { + writer.WritePropertyName("default"u8); + writer.WriteObjectValue(Default); + } + if (Optional.IsDefined(DisplayName)) + { + writer.WritePropertyName("displayName"u8); + writer.WriteStringValue(DisplayName); + } + if (Optional.IsDefined(RawOffset)) + { + writer.WritePropertyName("rawOffset"u8); + writer.WriteNumberValue(RawOffset.Value); + } + writer.WriteEndObject(); + } + + internal static TimeZone DeserializeTimeZone(JsonElement element) + { + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + Optional dstSavings = default; + Optional id = default; + Optional> availableIds = default; + Optional @default = default; + Optional displayName = default; + Optional rawOffset = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("dstSavings"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + dstSavings = property.Value.GetInt32(); + continue; + } + if (property.NameEquals("id"u8)) + { + id = property.Value.GetString(); + continue; + } + if (property.NameEquals("availableIds"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(item.GetString()); + } + availableIds = array; + continue; + } + if (property.NameEquals("default"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + @default = DeserializeTimeZone(property.Value); + continue; + } + if (property.NameEquals("displayName"u8)) + { + displayName = property.Value.GetString(); + continue; + } + if (property.NameEquals("rawOffset"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + rawOffset = property.Value.GetInt32(); + continue; + } + } + return new TimeZone(Optional.ToNullable(dstSavings), id.Value, Optional.ToList(availableIds), @default.Value, displayName.Value, Optional.ToNullable(rawOffset)); + } + + /// Deserializes the model from a raw response. + /// The response to deserialize the model from. + internal static TimeZone FromResponse(Response response) + { + using var document = JsonDocument.Parse(response.Content); + return DeserializeTimeZone(document.RootElement); + } + + /// Convert into a Utf8JsonRequestContent. + internal virtual RequestContent ToRequestContent() + { + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(this); + return content; + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/TimeZone.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/TimeZone.cs new file mode 100644 index 0000000000000..82288f10fe93f --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/TimeZone.cs @@ -0,0 +1,52 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + /// The timezone information. + public partial class TimeZone + { + /// Initializes a new instance of . + public TimeZone() + { + AvailableIds = new ChangeTrackingList(); + } + + /// Initializes a new instance of . + /// The value of the daylight saving time. + /// The ID of the timezone. + /// An array of available IDs. + /// The timezone information. + /// The display name of the timezone. + /// The raw offset of the timezone. + internal TimeZone(int? dstSavings, string id, IList availableIds, TimeZone @default, string displayName, int? rawOffset) + { + DstSavings = dstSavings; + Id = id; + AvailableIds = availableIds; + Default = @default; + DisplayName = displayName; + RawOffset = rawOffset; + } + + /// The value of the daylight saving time. + public int? DstSavings { get; set; } + /// The ID of the timezone. + public string Id { get; set; } + /// An array of available IDs. + public IList AvailableIds { get; } + /// The timezone information. + public TimeZone Default { get; set; } + /// The display name of the timezone. + public string DisplayName { get; set; } + /// The raw offset of the timezone. + public int? RawOffset { get; set; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/TypeCategory.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/TypeCategory.cs new file mode 100644 index 0000000000000..ce88397ca5556 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/TypeCategory.cs @@ -0,0 +1,75 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.ComponentModel; + +namespace Azure.Analytics.Purview.DataMap +{ + /// Type Category. + public readonly partial struct TypeCategory : IEquatable + { + private readonly string _value; + + /// Initializes a new instance of . + /// is null. + public TypeCategory(string value) + { + _value = value ?? throw new ArgumentNullException(nameof(value)); + } + + private const string PrimitiveValue = "PRIMITIVE"; + private const string ObjectIdTypeValue = "OBJECT_ID_TYPE"; + private const string EnumValue = "ENUM"; + private const string StructValue = "STRUCT"; + private const string ClassificationValue = "CLASSIFICATION"; + private const string EntityValue = "ENTITY"; + private const string ArrayValue = "ARRAY"; + private const string MapValue = "MAP"; + private const string RelationshipValue = "RELATIONSHIP"; + private const string TermTemplateValue = "TERM_TEMPLATE"; + + /// primitive. + public static TypeCategory Primitive { get; } = new TypeCategory(PrimitiveValue); + /// object id type. + public static TypeCategory ObjectIdType { get; } = new TypeCategory(ObjectIdTypeValue); + /// enum. + public static TypeCategory Enum { get; } = new TypeCategory(EnumValue); + /// struct. + public static TypeCategory Struct { get; } = new TypeCategory(StructValue); + /// classification. + public static TypeCategory Classification { get; } = new TypeCategory(ClassificationValue); + /// entity. + public static TypeCategory Entity { get; } = new TypeCategory(EntityValue); + /// array. + public static TypeCategory Array { get; } = new TypeCategory(ArrayValue); + /// map. + public static TypeCategory Map { get; } = new TypeCategory(MapValue); + /// relationship. + public static TypeCategory Relationship { get; } = new TypeCategory(RelationshipValue); + /// term template. + public static TypeCategory TermTemplate { get; } = new TypeCategory(TermTemplateValue); + /// Determines if two values are the same. + public static bool operator ==(TypeCategory left, TypeCategory right) => left.Equals(right); + /// Determines if two values are not the same. + public static bool operator !=(TypeCategory left, TypeCategory right) => !left.Equals(right); + /// Converts a string to a . + public static implicit operator TypeCategory(string value) => new TypeCategory(value); + + /// + [EditorBrowsable(EditorBrowsableState.Never)] + public override bool Equals(object obj) => obj is TypeCategory other && Equals(other); + /// + public bool Equals(TypeCategory other) => string.Equals(_value, other._value, StringComparison.InvariantCultureIgnoreCase); + + /// + [EditorBrowsable(EditorBrowsableState.Never)] + public override int GetHashCode() => _value?.GetHashCode() ?? 0; + /// + public override string ToString() => _value; + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/TypeDef.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/TypeDef.cs new file mode 100644 index 0000000000000..0d0bbc6881362 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/TypeDef.cs @@ -0,0 +1,63 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.ComponentModel; + +namespace Azure.Analytics.Purview.DataMap +{ + /// Type. + public readonly partial struct TypeDef : IEquatable + { + private readonly string _value; + + /// Initializes a new instance of . + /// is null. + public TypeDef(string value) + { + _value = value ?? throw new ArgumentNullException(nameof(value)); + } + + private const string EnumValue = "enum"; + private const string EntityValue = "entity"; + private const string ClassificationValue = "classification"; + private const string RelationshipValue = "relationship"; + private const string StructValue = "struct"; + private const string TermTemplateValue = "term_template"; + + /// enum. + public static TypeDef Enum { get; } = new TypeDef(EnumValue); + /// entity. + public static TypeDef Entity { get; } = new TypeDef(EntityValue); + /// classification. + public static TypeDef Classification { get; } = new TypeDef(ClassificationValue); + /// relationship. + public static TypeDef Relationship { get; } = new TypeDef(RelationshipValue); + /// struct. + public static TypeDef Struct { get; } = new TypeDef(StructValue); + /// term template. + public static TypeDef TermTemplate { get; } = new TypeDef(TermTemplateValue); + /// Determines if two values are the same. + public static bool operator ==(TypeDef left, TypeDef right) => left.Equals(right); + /// Determines if two values are not the same. + public static bool operator !=(TypeDef left, TypeDef right) => !left.Equals(right); + /// Converts a string to a . + public static implicit operator TypeDef(string value) => new TypeDef(value); + + /// + [EditorBrowsable(EditorBrowsableState.Never)] + public override bool Equals(object obj) => obj is TypeDef other && Equals(other); + /// + public bool Equals(TypeDef other) => string.Equals(_value, other._value, StringComparison.InvariantCultureIgnoreCase); + + /// + [EditorBrowsable(EditorBrowsableState.Never)] + public override int GetHashCode() => _value?.GetHashCode() ?? 0; + /// + public override string ToString() => _value; + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/TypeDefinition.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/TypeDefinition.cs new file mode 100644 index 0000000000000..e1f7b320b929f --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/TypeDefinition.cs @@ -0,0 +1,2860 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Collections.Generic; +using System.Text.Json; +using System.Threading; +using System.Threading.Tasks; +using Azure; +using Azure.Core; +using Azure.Core.Pipeline; + +namespace Azure.Analytics.Purview.DataMap +{ + // Data plane generated sub-client. + /// The TypeDefinition sub-client. + public partial class TypeDefinition + { + private static readonly string[] AuthorizationScopes = new string[] { "https://purview.azure.net/.default" }; + private readonly TokenCredential _tokenCredential; + private readonly HttpPipeline _pipeline; + private readonly Uri _endpoint; + private readonly string _apiVersion; + + /// The ClientDiagnostics is used to provide tracing support for the client library. + internal ClientDiagnostics ClientDiagnostics { get; } + + /// The HTTP pipeline for sending and receiving REST requests and responses. + public virtual HttpPipeline Pipeline => _pipeline; + + /// Initializes a new instance of TypeDefinition for mocking. + protected TypeDefinition() + { + } + + /// Initializes a new instance of TypeDefinition. + /// The handler for diagnostic messaging in the client. + /// The HTTP pipeline for sending and receiving REST requests and responses. + /// The token credential to copy. + /// The to use. + /// The to use. + internal TypeDefinition(ClientDiagnostics clientDiagnostics, HttpPipeline pipeline, TokenCredential tokenCredential, Uri endpoint, string apiVersion) + { + ClientDiagnostics = clientDiagnostics; + _pipeline = pipeline; + _tokenCredential = tokenCredential; + _endpoint = endpoint; + _apiVersion = apiVersion; + } + + /// Get the businessMetadata definition for the given guid. + /// businessMetadata guid. + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual async Task> GetBusinessMetadataByIdAsync(string guid, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = await GetBusinessMetadataByIdAsync(guid, context).ConfigureAwait(false); + return Response.FromValue(AtlasBusinessMetadataDef.FromResponse(response), response); + } + + /// Get the businessMetadata definition for the given guid. + /// businessMetadata guid. + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual Response GetBusinessMetadataById(string guid, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = GetBusinessMetadataById(guid, context); + return Response.FromValue(AtlasBusinessMetadataDef.FromResponse(response), response); + } + + /// + /// [Protocol Method] Get the businessMetadata definition for the given guid. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// businessMetadata guid. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task GetBusinessMetadataByIdAsync(string guid, RequestContext context) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + + using var scope = ClientDiagnostics.CreateScope("TypeDefinition.GetBusinessMetadataById"); + scope.Start(); + try + { + using HttpMessage message = CreateGetBusinessMetadataByIdRequest(guid, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Get the businessMetadata definition for the given guid. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// businessMetadata guid. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response GetBusinessMetadataById(string guid, RequestContext context) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + + using var scope = ClientDiagnostics.CreateScope("TypeDefinition.GetBusinessMetadataById"); + scope.Start(); + try + { + using HttpMessage message = CreateGetBusinessMetadataByIdRequest(guid, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Get the businessMetadata definition by it's name (unique). + /// businessMetadata name. + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual async Task> GetBusinessMetadataByNameAsync(string name, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(name, nameof(name)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = await GetBusinessMetadataByNameAsync(name, context).ConfigureAwait(false); + return Response.FromValue(AtlasBusinessMetadataDef.FromResponse(response), response); + } + + /// Get the businessMetadata definition by it's name (unique). + /// businessMetadata name. + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual Response GetBusinessMetadataByName(string name, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(name, nameof(name)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = GetBusinessMetadataByName(name, context); + return Response.FromValue(AtlasBusinessMetadataDef.FromResponse(response), response); + } + + /// + /// [Protocol Method] Get the businessMetadata definition by it's name (unique). + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// businessMetadata name. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task GetBusinessMetadataByNameAsync(string name, RequestContext context) + { + Argument.AssertNotNullOrEmpty(name, nameof(name)); + + using var scope = ClientDiagnostics.CreateScope("TypeDefinition.GetBusinessMetadataByName"); + scope.Start(); + try + { + using HttpMessage message = CreateGetBusinessMetadataByNameRequest(name, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Get the businessMetadata definition by it's name (unique). + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// businessMetadata name. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response GetBusinessMetadataByName(string name, RequestContext context) + { + Argument.AssertNotNullOrEmpty(name, nameof(name)); + + using var scope = ClientDiagnostics.CreateScope("TypeDefinition.GetBusinessMetadataByName"); + scope.Start(); + try + { + using HttpMessage message = CreateGetBusinessMetadataByNameRequest(name, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Get the classification definition for the given GUID. + /// The globally unique identifier of the classification. + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual async Task> GetClassificationByIdAsync(string guid, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = await GetClassificationByIdAsync(guid, context).ConfigureAwait(false); + return Response.FromValue(AtlasClassificationDef.FromResponse(response), response); + } + + /// Get the classification definition for the given GUID. + /// The globally unique identifier of the classification. + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual Response GetClassificationById(string guid, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = GetClassificationById(guid, context); + return Response.FromValue(AtlasClassificationDef.FromResponse(response), response); + } + + /// + /// [Protocol Method] Get the classification definition for the given GUID. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier of the classification. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task GetClassificationByIdAsync(string guid, RequestContext context) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + + using var scope = ClientDiagnostics.CreateScope("TypeDefinition.GetClassificationById"); + scope.Start(); + try + { + using HttpMessage message = CreateGetClassificationByIdRequest(guid, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Get the classification definition for the given GUID. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier of the classification. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response GetClassificationById(string guid, RequestContext context) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + + using var scope = ClientDiagnostics.CreateScope("TypeDefinition.GetClassificationById"); + scope.Start(); + try + { + using HttpMessage message = CreateGetClassificationByIdRequest(guid, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Get the classification definition by its name (unique). + /// The name of the classification. + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual async Task> GetClassificationByNameAsync(string name, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(name, nameof(name)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = await GetClassificationByNameAsync(name, context).ConfigureAwait(false); + return Response.FromValue(AtlasClassificationDef.FromResponse(response), response); + } + + /// Get the classification definition by its name (unique). + /// The name of the classification. + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual Response GetClassificationByName(string name, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(name, nameof(name)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = GetClassificationByName(name, context); + return Response.FromValue(AtlasClassificationDef.FromResponse(response), response); + } + + /// + /// [Protocol Method] Get the classification definition by its name (unique). + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The name of the classification. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task GetClassificationByNameAsync(string name, RequestContext context) + { + Argument.AssertNotNullOrEmpty(name, nameof(name)); + + using var scope = ClientDiagnostics.CreateScope("TypeDefinition.GetClassificationByName"); + scope.Start(); + try + { + using HttpMessage message = CreateGetClassificationByNameRequest(name, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Get the classification definition by its name (unique). + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The name of the classification. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response GetClassificationByName(string name, RequestContext context) + { + Argument.AssertNotNullOrEmpty(name, nameof(name)); + + using var scope = ClientDiagnostics.CreateScope("TypeDefinition.GetClassificationByName"); + scope.Start(); + try + { + using HttpMessage message = CreateGetClassificationByNameRequest(name, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Get the Entity definition for the given GUID. + /// The globally unique identifier of the entity. + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual async Task> GetEntityByIdAsync(string guid, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = await GetEntityByIdAsync(guid, context).ConfigureAwait(false); + return Response.FromValue(AtlasEntityDef.FromResponse(response), response); + } + + /// Get the Entity definition for the given GUID. + /// The globally unique identifier of the entity. + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual Response GetEntityById(string guid, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = GetEntityById(guid, context); + return Response.FromValue(AtlasEntityDef.FromResponse(response), response); + } + + /// + /// [Protocol Method] Get the Entity definition for the given GUID. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier of the entity. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task GetEntityByIdAsync(string guid, RequestContext context) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + + using var scope = ClientDiagnostics.CreateScope("TypeDefinition.GetEntityById"); + scope.Start(); + try + { + using HttpMessage message = CreateGetEntityByIdRequest(guid, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Get the Entity definition for the given GUID. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier of the entity. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response GetEntityById(string guid, RequestContext context) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + + using var scope = ClientDiagnostics.CreateScope("TypeDefinition.GetEntityById"); + scope.Start(); + try + { + using HttpMessage message = CreateGetEntityByIdRequest(guid, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Get the entity definition by its name (unique). + /// The name of the entity. + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual async Task> GetEntityByNameAsync(string name, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(name, nameof(name)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = await GetEntityByNameAsync(name, context).ConfigureAwait(false); + return Response.FromValue(AtlasEntityDef.FromResponse(response), response); + } + + /// Get the entity definition by its name (unique). + /// The name of the entity. + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual Response GetEntityByName(string name, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(name, nameof(name)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = GetEntityByName(name, context); + return Response.FromValue(AtlasEntityDef.FromResponse(response), response); + } + + /// + /// [Protocol Method] Get the entity definition by its name (unique). + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The name of the entity. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task GetEntityByNameAsync(string name, RequestContext context) + { + Argument.AssertNotNullOrEmpty(name, nameof(name)); + + using var scope = ClientDiagnostics.CreateScope("TypeDefinition.GetEntityByName"); + scope.Start(); + try + { + using HttpMessage message = CreateGetEntityByNameRequest(name, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Get the entity definition by its name (unique). + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The name of the entity. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response GetEntityByName(string name, RequestContext context) + { + Argument.AssertNotNullOrEmpty(name, nameof(name)); + + using var scope = ClientDiagnostics.CreateScope("TypeDefinition.GetEntityByName"); + scope.Start(); + try + { + using HttpMessage message = CreateGetEntityByNameRequest(name, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Get the enum definition for the given GUID. + /// The globally unique identifier of the enum. + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual async Task> GetEnumByIdAsync(string guid, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = await GetEnumByIdAsync(guid, context).ConfigureAwait(false); + return Response.FromValue(AtlasEnumDef.FromResponse(response), response); + } + + /// Get the enum definition for the given GUID. + /// The globally unique identifier of the enum. + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual Response GetEnumById(string guid, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = GetEnumById(guid, context); + return Response.FromValue(AtlasEnumDef.FromResponse(response), response); + } + + /// + /// [Protocol Method] Get the enum definition for the given GUID. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier of the enum. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task GetEnumByIdAsync(string guid, RequestContext context) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + + using var scope = ClientDiagnostics.CreateScope("TypeDefinition.GetEnumById"); + scope.Start(); + try + { + using HttpMessage message = CreateGetEnumByIdRequest(guid, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Get the enum definition for the given GUID. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier of the enum. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response GetEnumById(string guid, RequestContext context) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + + using var scope = ClientDiagnostics.CreateScope("TypeDefinition.GetEnumById"); + scope.Start(); + try + { + using HttpMessage message = CreateGetEnumByIdRequest(guid, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Get the enum definition by its name (unique). + /// The name of the enum. + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual async Task> GetEnumByNameAsync(string name, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(name, nameof(name)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = await GetEnumByNameAsync(name, context).ConfigureAwait(false); + return Response.FromValue(AtlasEnumDef.FromResponse(response), response); + } + + /// Get the enum definition by its name (unique). + /// The name of the enum. + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual Response GetEnumByName(string name, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(name, nameof(name)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = GetEnumByName(name, context); + return Response.FromValue(AtlasEnumDef.FromResponse(response), response); + } + + /// + /// [Protocol Method] Get the enum definition by its name (unique). + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The name of the enum. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task GetEnumByNameAsync(string name, RequestContext context) + { + Argument.AssertNotNullOrEmpty(name, nameof(name)); + + using var scope = ClientDiagnostics.CreateScope("TypeDefinition.GetEnumByName"); + scope.Start(); + try + { + using HttpMessage message = CreateGetEnumByNameRequest(name, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Get the enum definition by its name (unique). + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The name of the enum. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response GetEnumByName(string name, RequestContext context) + { + Argument.AssertNotNullOrEmpty(name, nameof(name)); + + using var scope = ClientDiagnostics.CreateScope("TypeDefinition.GetEnumByName"); + scope.Start(); + try + { + using HttpMessage message = CreateGetEnumByNameRequest(name, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Get the relationship definition for the given GUID. + /// The globally unique identifier of the relationship. + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual async Task> GetRelationshipByIdAsync(string guid, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = await GetRelationshipByIdAsync(guid, context).ConfigureAwait(false); + return Response.FromValue(AtlasRelationshipDef.FromResponse(response), response); + } + + /// Get the relationship definition for the given GUID. + /// The globally unique identifier of the relationship. + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual Response GetRelationshipById(string guid, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = GetRelationshipById(guid, context); + return Response.FromValue(AtlasRelationshipDef.FromResponse(response), response); + } + + /// + /// [Protocol Method] Get the relationship definition for the given GUID. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier of the relationship. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task GetRelationshipByIdAsync(string guid, RequestContext context) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + + using var scope = ClientDiagnostics.CreateScope("TypeDefinition.GetRelationshipById"); + scope.Start(); + try + { + using HttpMessage message = CreateGetRelationshipByIdRequest(guid, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Get the relationship definition for the given GUID. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier of the relationship. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response GetRelationshipById(string guid, RequestContext context) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + + using var scope = ClientDiagnostics.CreateScope("TypeDefinition.GetRelationshipById"); + scope.Start(); + try + { + using HttpMessage message = CreateGetRelationshipByIdRequest(guid, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Get the relationship definition by its name (unique). + /// The name of the relationship. + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual async Task> GetRelationshipByNameAsync(string name, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(name, nameof(name)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = await GetRelationshipByNameAsync(name, context).ConfigureAwait(false); + return Response.FromValue(AtlasRelationshipDef.FromResponse(response), response); + } + + /// Get the relationship definition by its name (unique). + /// The name of the relationship. + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual Response GetRelationshipByName(string name, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(name, nameof(name)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = GetRelationshipByName(name, context); + return Response.FromValue(AtlasRelationshipDef.FromResponse(response), response); + } + + /// + /// [Protocol Method] Get the relationship definition by its name (unique). + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The name of the relationship. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task GetRelationshipByNameAsync(string name, RequestContext context) + { + Argument.AssertNotNullOrEmpty(name, nameof(name)); + + using var scope = ClientDiagnostics.CreateScope("TypeDefinition.GetRelationshipByName"); + scope.Start(); + try + { + using HttpMessage message = CreateGetRelationshipByNameRequest(name, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Get the relationship definition by its name (unique). + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The name of the relationship. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response GetRelationshipByName(string name, RequestContext context) + { + Argument.AssertNotNullOrEmpty(name, nameof(name)); + + using var scope = ClientDiagnostics.CreateScope("TypeDefinition.GetRelationshipByName"); + scope.Start(); + try + { + using HttpMessage message = CreateGetRelationshipByNameRequest(name, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Get the struct definition for the given GUID. + /// The globally unique identifier of the struct. + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual async Task> GetStructByIdAsync(string guid, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = await GetStructByIdAsync(guid, context).ConfigureAwait(false); + return Response.FromValue(AtlasStructDef.FromResponse(response), response); + } + + /// Get the struct definition for the given GUID. + /// The globally unique identifier of the struct. + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual Response GetStructById(string guid, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = GetStructById(guid, context); + return Response.FromValue(AtlasStructDef.FromResponse(response), response); + } + + /// + /// [Protocol Method] Get the struct definition for the given GUID. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier of the struct. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task GetStructByIdAsync(string guid, RequestContext context) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + + using var scope = ClientDiagnostics.CreateScope("TypeDefinition.GetStructById"); + scope.Start(); + try + { + using HttpMessage message = CreateGetStructByIdRequest(guid, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Get the struct definition for the given GUID. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier of the struct. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response GetStructById(string guid, RequestContext context) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + + using var scope = ClientDiagnostics.CreateScope("TypeDefinition.GetStructById"); + scope.Start(); + try + { + using HttpMessage message = CreateGetStructByIdRequest(guid, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Get the struct definition by its name (unique). + /// The name of the struct. + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual async Task> GetStructByNameAsync(string name, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(name, nameof(name)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = await GetStructByNameAsync(name, context).ConfigureAwait(false); + return Response.FromValue(AtlasStructDef.FromResponse(response), response); + } + + /// Get the struct definition by its name (unique). + /// The name of the struct. + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual Response GetStructByName(string name, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(name, nameof(name)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = GetStructByName(name, context); + return Response.FromValue(AtlasStructDef.FromResponse(response), response); + } + + /// + /// [Protocol Method] Get the struct definition by its name (unique). + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The name of the struct. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task GetStructByNameAsync(string name, RequestContext context) + { + Argument.AssertNotNullOrEmpty(name, nameof(name)); + + using var scope = ClientDiagnostics.CreateScope("TypeDefinition.GetStructByName"); + scope.Start(); + try + { + using HttpMessage message = CreateGetStructByNameRequest(name, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Get the struct definition by its name (unique). + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The name of the struct. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response GetStructByName(string name, RequestContext context) + { + Argument.AssertNotNullOrEmpty(name, nameof(name)); + + using var scope = ClientDiagnostics.CreateScope("TypeDefinition.GetStructByName"); + scope.Start(); + try + { + using HttpMessage message = CreateGetStructByNameRequest(name, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Get the type definition for the given GUID. + /// The globally unique identifier of the type. + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual async Task> GetByIdAsync(string guid, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = await GetByIdAsync(guid, context).ConfigureAwait(false); + return Response.FromValue(AtlasTypeDef.FromResponse(response), response); + } + + /// Get the type definition for the given GUID. + /// The globally unique identifier of the type. + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual Response GetById(string guid, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = GetById(guid, context); + return Response.FromValue(AtlasTypeDef.FromResponse(response), response); + } + + /// + /// [Protocol Method] Get the type definition for the given GUID. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier of the type. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task GetByIdAsync(string guid, RequestContext context) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + + using var scope = ClientDiagnostics.CreateScope("TypeDefinition.GetById"); + scope.Start(); + try + { + using HttpMessage message = CreateGetByIdRequest(guid, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Get the type definition for the given GUID. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier of the type. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response GetById(string guid, RequestContext context) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + + using var scope = ClientDiagnostics.CreateScope("TypeDefinition.GetById"); + scope.Start(); + try + { + using HttpMessage message = CreateGetByIdRequest(guid, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Get the type definition by its name (unique). + /// The name of the type. + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual async Task> GetByNameAsync(string name, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(name, nameof(name)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = await GetByNameAsync(name, context).ConfigureAwait(false); + return Response.FromValue(AtlasTypeDef.FromResponse(response), response); + } + + /// Get the type definition by its name (unique). + /// The name of the type. + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual Response GetByName(string name, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(name, nameof(name)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = GetByName(name, context); + return Response.FromValue(AtlasTypeDef.FromResponse(response), response); + } + + /// + /// [Protocol Method] Get the type definition by its name (unique). + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The name of the type. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task GetByNameAsync(string name, RequestContext context) + { + Argument.AssertNotNullOrEmpty(name, nameof(name)); + + using var scope = ClientDiagnostics.CreateScope("TypeDefinition.GetByName"); + scope.Start(); + try + { + using HttpMessage message = CreateGetByNameRequest(name, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Get the type definition by its name (unique). + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The name of the type. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response GetByName(string name, RequestContext context) + { + Argument.AssertNotNullOrEmpty(name, nameof(name)); + + using var scope = ClientDiagnostics.CreateScope("TypeDefinition.GetByName"); + scope.Start(); + try + { + using HttpMessage message = CreateGetByNameRequest(name, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + // The convenience method is omitted here because it has exactly the same parameter list as the corresponding protocol method + /// + /// [Protocol Method] Delete API for type identified by its name. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// The name of the type. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task DeleteAsync(string name, RequestContext context = null) + { + Argument.AssertNotNullOrEmpty(name, nameof(name)); + + using var scope = ClientDiagnostics.CreateScope("TypeDefinition.Delete"); + scope.Start(); + try + { + using HttpMessage message = CreateDeleteRequest(name, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + // The convenience method is omitted here because it has exactly the same parameter list as the corresponding protocol method + /// + /// [Protocol Method] Delete API for type identified by its name. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// The name of the type. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response Delete(string name, RequestContext context = null) + { + Argument.AssertNotNullOrEmpty(name, nameof(name)); + + using var scope = ClientDiagnostics.CreateScope("TypeDefinition.Delete"); + scope.Start(); + try + { + using HttpMessage message = CreateDeleteRequest(name, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// List all type definitions in bulk. + /// + /// Whether include termtemplatedef when return all typedefs. + /// This is always true + /// when search filter type=term_template + /// + /// Typedef name as search filter when get typedefs. + /// The cancellation token to use. + /// + public virtual async Task> GetTypeDefinitionAsync(bool? includeTermTemplate = null, TypeDef? type = null, CancellationToken cancellationToken = default) + { + RequestContext context = FromCancellationToken(cancellationToken); + Response response = await GetTypeDefinitionAsync(includeTermTemplate, type?.ToString(), context).ConfigureAwait(false); + return Response.FromValue(AtlasTypesDef.FromResponse(response), response); + } + + /// List all type definitions in bulk. + /// + /// Whether include termtemplatedef when return all typedefs. + /// This is always true + /// when search filter type=term_template + /// + /// Typedef name as search filter when get typedefs. + /// The cancellation token to use. + /// + public virtual Response GetTypeDefinition(bool? includeTermTemplate = null, TypeDef? type = null, CancellationToken cancellationToken = default) + { + RequestContext context = FromCancellationToken(cancellationToken); + Response response = GetTypeDefinition(includeTermTemplate, type?.ToString(), context); + return Response.FromValue(AtlasTypesDef.FromResponse(response), response); + } + + /// + /// [Protocol Method] List all type definitions in bulk. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// + /// Whether include termtemplatedef when return all typedefs. + /// This is always true + /// when search filter type=term_template + /// + /// Typedef name as search filter when get typedefs. Allowed values: "enum" | "entity" | "classification" | "relationship" | "struct" | "term_template". + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task GetTypeDefinitionAsync(bool? includeTermTemplate, string type, RequestContext context) + { + using var scope = ClientDiagnostics.CreateScope("TypeDefinition.GetTypeDefinition"); + scope.Start(); + try + { + using HttpMessage message = CreateGetTypeDefinitionRequest(includeTermTemplate, type, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] List all type definitions in bulk. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// + /// Whether include termtemplatedef when return all typedefs. + /// This is always true + /// when search filter type=term_template + /// + /// Typedef name as search filter when get typedefs. Allowed values: "enum" | "entity" | "classification" | "relationship" | "struct" | "term_template". + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response GetTypeDefinition(bool? includeTermTemplate, string type, RequestContext context) + { + using var scope = ClientDiagnostics.CreateScope("TypeDefinition.GetTypeDefinition"); + scope.Start(); + try + { + using HttpMessage message = CreateGetTypeDefinitionRequest(includeTermTemplate, type, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// Create all atlas type definitions in bulk, only new definitions will be + /// created. + /// Any changes to the existing definitions will be discarded. + /// + /// A composite wrapper object with corresponding lists of the type definition. + /// The cancellation token to use. + /// is null. + /// + public virtual async Task> BatchCreateAsync(AtlasTypesDef typesDef, CancellationToken cancellationToken = default) + { + Argument.AssertNotNull(typesDef, nameof(typesDef)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = typesDef.ToRequestContent(); + Response response = await BatchCreateAsync(content, context).ConfigureAwait(false); + return Response.FromValue(AtlasTypesDef.FromResponse(response), response); + } + + /// + /// Create all atlas type definitions in bulk, only new definitions will be + /// created. + /// Any changes to the existing definitions will be discarded. + /// + /// A composite wrapper object with corresponding lists of the type definition. + /// The cancellation token to use. + /// is null. + /// + public virtual Response BatchCreate(AtlasTypesDef typesDef, CancellationToken cancellationToken = default) + { + Argument.AssertNotNull(typesDef, nameof(typesDef)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = typesDef.ToRequestContent(); + Response response = BatchCreate(content, context); + return Response.FromValue(AtlasTypesDef.FromResponse(response), response); + } + + /// + /// [Protocol Method] Create all atlas type definitions in bulk, only new definitions will be + /// created. + /// Any changes to the existing definitions will be discarded. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The content to send as the body of the request. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task BatchCreateAsync(RequestContent content, RequestContext context = null) + { + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("TypeDefinition.BatchCreate"); + scope.Start(); + try + { + using HttpMessage message = CreateBatchCreateRequest(content, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Create all atlas type definitions in bulk, only new definitions will be + /// created. + /// Any changes to the existing definitions will be discarded. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The content to send as the body of the request. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response BatchCreate(RequestContent content, RequestContext context = null) + { + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("TypeDefinition.BatchCreate"); + scope.Start(); + try + { + using HttpMessage message = CreateBatchCreateRequest(content, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// Update all types in bulk, changes detected in the type definitions would be + /// persisted. + /// + /// A composite object that captures all type definition changes. + /// The cancellation token to use. + /// is null. + /// + public virtual async Task> BatchUpdateAsync(AtlasTypesDef typesDef, CancellationToken cancellationToken = default) + { + Argument.AssertNotNull(typesDef, nameof(typesDef)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = typesDef.ToRequestContent(); + Response response = await BatchUpdateAsync(content, context).ConfigureAwait(false); + return Response.FromValue(AtlasTypesDef.FromResponse(response), response); + } + + /// + /// Update all types in bulk, changes detected in the type definitions would be + /// persisted. + /// + /// A composite object that captures all type definition changes. + /// The cancellation token to use. + /// is null. + /// + public virtual Response BatchUpdate(AtlasTypesDef typesDef, CancellationToken cancellationToken = default) + { + Argument.AssertNotNull(typesDef, nameof(typesDef)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = typesDef.ToRequestContent(); + Response response = BatchUpdate(content, context); + return Response.FromValue(AtlasTypesDef.FromResponse(response), response); + } + + /// + /// [Protocol Method] Update all types in bulk, changes detected in the type definitions would be + /// persisted. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The content to send as the body of the request. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task BatchUpdateAsync(RequestContent content, RequestContext context = null) + { + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("TypeDefinition.BatchUpdate"); + scope.Start(); + try + { + using HttpMessage message = CreateBatchUpdateRequest(content, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Update all types in bulk, changes detected in the type definitions would be + /// persisted. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The content to send as the body of the request. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response BatchUpdate(RequestContent content, RequestContext context = null) + { + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("TypeDefinition.BatchUpdate"); + scope.Start(); + try + { + using HttpMessage message = CreateBatchUpdateRequest(content, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Delete API for all types in bulk. + /// A composite object that captures all types to be deleted. + /// The cancellation token to use. + /// is null. + /// + public virtual async Task BatchDeleteAsync(AtlasTypesDef typesDef, CancellationToken cancellationToken = default) + { + Argument.AssertNotNull(typesDef, nameof(typesDef)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = typesDef.ToRequestContent(); + Response response = await BatchDeleteAsync(content, context).ConfigureAwait(false); + return response; + } + + /// Delete API for all types in bulk. + /// A composite object that captures all types to be deleted. + /// The cancellation token to use. + /// is null. + /// + public virtual Response BatchDelete(AtlasTypesDef typesDef, CancellationToken cancellationToken = default) + { + Argument.AssertNotNull(typesDef, nameof(typesDef)); + + RequestContext context = FromCancellationToken(cancellationToken); + using RequestContent content = typesDef.ToRequestContent(); + Response response = BatchDelete(content, context); + return response; + } + + /// + /// [Protocol Method] Delete API for all types in bulk. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The content to send as the body of the request. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task BatchDeleteAsync(RequestContent content, RequestContext context = null) + { + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("TypeDefinition.BatchDelete"); + scope.Start(); + try + { + using HttpMessage message = CreateBatchDeleteRequest(content, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Delete API for all types in bulk. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The content to send as the body of the request. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response BatchDelete(RequestContent content, RequestContext context = null) + { + Argument.AssertNotNull(content, nameof(content)); + + using var scope = ClientDiagnostics.CreateScope("TypeDefinition.BatchDelete"); + scope.Start(); + try + { + using HttpMessage message = CreateBatchDeleteRequest(content, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// List all type definitions returned as a list of minimal information header. + /// + /// Whether include termtemplatedef when return all typedefs. + /// This is always true + /// when search filter type=term_template + /// + /// Typedef name as search filter when get typedefs. + /// The cancellation token to use. + /// + public virtual async Task>> GetHeadersAsync(bool? includeTermTemplate = null, TypeDef? type = null, CancellationToken cancellationToken = default) + { + RequestContext context = FromCancellationToken(cancellationToken); + Response response = await GetHeadersAsync(includeTermTemplate, type?.ToString(), context).ConfigureAwait(false); + IReadOnlyList value = default; + using var document = await JsonDocument.ParseAsync(response.ContentStream, default, cancellationToken).ConfigureAwait(false); + List array = new List(); + foreach (var item in document.RootElement.EnumerateArray()) + { + array.Add(AtlasTypeDefHeader.DeserializeAtlasTypeDefHeader(item)); + } + value = array; + return Response.FromValue(value, response); + } + + /// List all type definitions returned as a list of minimal information header. + /// + /// Whether include termtemplatedef when return all typedefs. + /// This is always true + /// when search filter type=term_template + /// + /// Typedef name as search filter when get typedefs. + /// The cancellation token to use. + /// + public virtual Response> GetHeaders(bool? includeTermTemplate = null, TypeDef? type = null, CancellationToken cancellationToken = default) + { + RequestContext context = FromCancellationToken(cancellationToken); + Response response = GetHeaders(includeTermTemplate, type?.ToString(), context); + IReadOnlyList value = default; + using var document = JsonDocument.Parse(response.ContentStream); + List array = new List(); + foreach (var item in document.RootElement.EnumerateArray()) + { + array.Add(AtlasTypeDefHeader.DeserializeAtlasTypeDefHeader(item)); + } + value = array; + return Response.FromValue(value, response); + } + + /// + /// [Protocol Method] List all type definitions returned as a list of minimal information header. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// + /// Whether include termtemplatedef when return all typedefs. + /// This is always true + /// when search filter type=term_template + /// + /// Typedef name as search filter when get typedefs. Allowed values: "enum" | "entity" | "classification" | "relationship" | "struct" | "term_template". + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task GetHeadersAsync(bool? includeTermTemplate, string type, RequestContext context) + { + using var scope = ClientDiagnostics.CreateScope("TypeDefinition.GetHeaders"); + scope.Start(); + try + { + using HttpMessage message = CreateGetHeadersRequest(includeTermTemplate, type, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] List all type definitions returned as a list of minimal information header. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// + /// Whether include termtemplatedef when return all typedefs. + /// This is always true + /// when search filter type=term_template + /// + /// Typedef name as search filter when get typedefs. Allowed values: "enum" | "entity" | "classification" | "relationship" | "struct" | "term_template". + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response GetHeaders(bool? includeTermTemplate, string type, RequestContext context) + { + using var scope = ClientDiagnostics.CreateScope("TypeDefinition.GetHeaders"); + scope.Start(); + try + { + using HttpMessage message = CreateGetHeadersRequest(includeTermTemplate, type, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Get the term template definition for the given GUID. + /// The globally unique identifier of the term template. + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual async Task> GetTermTemplateByIdAsync(string guid, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = await GetTermTemplateByIdAsync(guid, context).ConfigureAwait(false); + return Response.FromValue(TermTemplateDef.FromResponse(response), response); + } + + /// Get the term template definition for the given GUID. + /// The globally unique identifier of the term template. + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual Response GetTermTemplateById(string guid, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = GetTermTemplateById(guid, context); + return Response.FromValue(TermTemplateDef.FromResponse(response), response); + } + + /// + /// [Protocol Method] Get the term template definition for the given GUID. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier of the term template. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task GetTermTemplateByIdAsync(string guid, RequestContext context) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + + using var scope = ClientDiagnostics.CreateScope("TypeDefinition.GetTermTemplateById"); + scope.Start(); + try + { + using HttpMessage message = CreateGetTermTemplateByIdRequest(guid, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Get the term template definition for the given GUID. + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The globally unique identifier of the term template. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response GetTermTemplateById(string guid, RequestContext context) + { + Argument.AssertNotNullOrEmpty(guid, nameof(guid)); + + using var scope = ClientDiagnostics.CreateScope("TypeDefinition.GetTermTemplateById"); + scope.Start(); + try + { + using HttpMessage message = CreateGetTermTemplateByIdRequest(guid, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Get the term template definition by its name (unique). + /// The unique name of the term template. + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual async Task> GetTermTemplateByNameAsync(string name, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(name, nameof(name)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = await GetTermTemplateByNameAsync(name, context).ConfigureAwait(false); + return Response.FromValue(TermTemplateDef.FromResponse(response), response); + } + + /// Get the term template definition by its name (unique). + /// The unique name of the term template. + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// + public virtual Response GetTermTemplateByName(string name, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(name, nameof(name)); + + RequestContext context = FromCancellationToken(cancellationToken); + Response response = GetTermTemplateByName(name, context); + return Response.FromValue(TermTemplateDef.FromResponse(response), response); + } + + /// + /// [Protocol Method] Get the term template definition by its name (unique). + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The unique name of the term template. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual async Task GetTermTemplateByNameAsync(string name, RequestContext context) + { + Argument.AssertNotNullOrEmpty(name, nameof(name)); + + using var scope = ClientDiagnostics.CreateScope("TypeDefinition.GetTermTemplateByName"); + scope.Start(); + try + { + using HttpMessage message = CreateGetTermTemplateByNameRequest(name, context); + return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// [Protocol Method] Get the term template definition by its name (unique). + /// + /// + /// + /// This protocol method allows explicit creation of the request and processing of the response for advanced scenarios. + /// + /// + /// + /// + /// Please try the simpler convenience overload with strongly typed models first. + /// + /// + /// + /// + /// The unique name of the term template. + /// The request context, which can override default behaviors of the client pipeline on a per-call basis. + /// is null. + /// is an empty string, and was expected to be non-empty. + /// Service returned a non-success status code. + /// The response returned from the service. + /// + public virtual Response GetTermTemplateByName(string name, RequestContext context) + { + Argument.AssertNotNullOrEmpty(name, nameof(name)); + + using var scope = ClientDiagnostics.CreateScope("TypeDefinition.GetTermTemplateByName"); + scope.Start(); + try + { + using HttpMessage message = CreateGetTermTemplateByNameRequest(name, context); + return _pipeline.ProcessMessage(message, context); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + internal HttpMessage CreateGetBusinessMetadataByIdRequest(string guid, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier200); + var request = message.Request; + request.Method = RequestMethod.Get; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/types/businessmetadatadef/guid/", false); + uri.AppendPath(guid, true); + uri.AppendQuery("api-version", _apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + return message; + } + + internal HttpMessage CreateGetBusinessMetadataByNameRequest(string name, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier200); + var request = message.Request; + request.Method = RequestMethod.Get; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/types/businessmetadatadef/name/", false); + uri.AppendPath(name, true); + uri.AppendQuery("api-version", _apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + return message; + } + + internal HttpMessage CreateGetClassificationByIdRequest(string guid, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier200); + var request = message.Request; + request.Method = RequestMethod.Get; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/types/classificationdef/guid/", false); + uri.AppendPath(guid, true); + uri.AppendQuery("api-version", _apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + return message; + } + + internal HttpMessage CreateGetClassificationByNameRequest(string name, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier200); + var request = message.Request; + request.Method = RequestMethod.Get; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/types/classificationdef/name/", false); + uri.AppendPath(name, true); + uri.AppendQuery("api-version", _apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + return message; + } + + internal HttpMessage CreateGetEntityByIdRequest(string guid, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier200); + var request = message.Request; + request.Method = RequestMethod.Get; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/types/entitydef/guid/", false); + uri.AppendPath(guid, true); + uri.AppendQuery("api-version", _apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + return message; + } + + internal HttpMessage CreateGetEntityByNameRequest(string name, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier200); + var request = message.Request; + request.Method = RequestMethod.Get; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/types/entitydef/name/", false); + uri.AppendPath(name, true); + uri.AppendQuery("api-version", _apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + return message; + } + + internal HttpMessage CreateGetEnumByIdRequest(string guid, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier200); + var request = message.Request; + request.Method = RequestMethod.Get; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/types/enumdef/guid/", false); + uri.AppendPath(guid, true); + uri.AppendQuery("api-version", _apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + return message; + } + + internal HttpMessage CreateGetEnumByNameRequest(string name, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier200); + var request = message.Request; + request.Method = RequestMethod.Get; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/types/enumdef/name/", false); + uri.AppendPath(name, true); + uri.AppendQuery("api-version", _apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + return message; + } + + internal HttpMessage CreateGetRelationshipByIdRequest(string guid, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier200); + var request = message.Request; + request.Method = RequestMethod.Get; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/types/relationshipdef/guid/", false); + uri.AppendPath(guid, true); + uri.AppendQuery("api-version", _apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + return message; + } + + internal HttpMessage CreateGetRelationshipByNameRequest(string name, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier200); + var request = message.Request; + request.Method = RequestMethod.Get; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/types/relationshipdef/name/", false); + uri.AppendPath(name, true); + uri.AppendQuery("api-version", _apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + return message; + } + + internal HttpMessage CreateGetStructByIdRequest(string guid, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier200); + var request = message.Request; + request.Method = RequestMethod.Get; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/types/structdef/guid/", false); + uri.AppendPath(guid, true); + uri.AppendQuery("api-version", _apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + return message; + } + + internal HttpMessage CreateGetStructByNameRequest(string name, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier200); + var request = message.Request; + request.Method = RequestMethod.Get; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/types/structdef/name/", false); + uri.AppendPath(name, true); + uri.AppendQuery("api-version", _apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + return message; + } + + internal HttpMessage CreateGetByIdRequest(string guid, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier200); + var request = message.Request; + request.Method = RequestMethod.Get; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/types/typedef/guid/", false); + uri.AppendPath(guid, true); + uri.AppendQuery("api-version", _apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + return message; + } + + internal HttpMessage CreateGetByNameRequest(string name, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier200); + var request = message.Request; + request.Method = RequestMethod.Get; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/types/typedef/name/", false); + uri.AppendPath(name, true); + uri.AppendQuery("api-version", _apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + return message; + } + + internal HttpMessage CreateDeleteRequest(string name, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier204); + var request = message.Request; + request.Method = RequestMethod.Delete; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/types/typedef/name/", false); + uri.AppendPath(name, true); + uri.AppendQuery("api-version", _apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + return message; + } + + internal HttpMessage CreateGetTypeDefinitionRequest(bool? includeTermTemplate, string type, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier200); + var request = message.Request; + request.Method = RequestMethod.Get; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/types/typedefs", false); + uri.AppendQuery("api-version", _apiVersion, true); + if (includeTermTemplate != null) + { + uri.AppendQuery("includeTermTemplate", includeTermTemplate.Value, true); + } + if (type != null) + { + uri.AppendQuery("type", type, true); + } + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + return message; + } + + internal HttpMessage CreateBatchCreateRequest(RequestContent content, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier200); + var request = message.Request; + request.Method = RequestMethod.Post; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/types/typedefs", false); + uri.AppendQuery("api-version", _apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + request.Headers.Add("Content-Type", "application/json"); + request.Content = content; + return message; + } + + internal HttpMessage CreateBatchUpdateRequest(RequestContent content, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier200); + var request = message.Request; + request.Method = RequestMethod.Put; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/types/typedefs", false); + uri.AppendQuery("api-version", _apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + request.Headers.Add("Content-Type", "application/json"); + request.Content = content; + return message; + } + + internal HttpMessage CreateBatchDeleteRequest(RequestContent content, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier204); + var request = message.Request; + request.Method = RequestMethod.Delete; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/types/typedefs", false); + uri.AppendQuery("api-version", _apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + request.Headers.Add("Content-Type", "application/json"); + request.Content = content; + return message; + } + + internal HttpMessage CreateGetHeadersRequest(bool? includeTermTemplate, string type, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier200); + var request = message.Request; + request.Method = RequestMethod.Get; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/atlas/v2/types/typedefs/headers", false); + uri.AppendQuery("api-version", _apiVersion, true); + if (includeTermTemplate != null) + { + uri.AppendQuery("includeTermTemplate", includeTermTemplate.Value, true); + } + if (type != null) + { + uri.AppendQuery("type", type, true); + } + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + return message; + } + + internal HttpMessage CreateGetTermTemplateByIdRequest(string guid, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier200); + var request = message.Request; + request.Method = RequestMethod.Get; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/types/termtemplatedef/guid/", false); + uri.AppendPath(guid, true); + uri.AppendQuery("api-version", _apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + return message; + } + + internal HttpMessage CreateGetTermTemplateByNameRequest(string name, RequestContext context) + { + var message = _pipeline.CreateMessage(context, ResponseClassifier200); + var request = message.Request; + request.Method = RequestMethod.Get; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRaw("/datamap/api", false); + uri.AppendPath("/types/termtemplatedef/name/", false); + uri.AppendPath(name, true); + uri.AppendQuery("api-version", _apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + return message; + } + + private static RequestContext DefaultRequestContext = new RequestContext(); + internal static RequestContext FromCancellationToken(CancellationToken cancellationToken = default) + { + if (!cancellationToken.CanBeCanceled) + { + return DefaultRequestContext; + } + + return new RequestContext() { CancellationToken = cancellationToken }; + } + + private static ResponseClassifier _responseClassifier200; + private static ResponseClassifier ResponseClassifier200 => _responseClassifier200 ??= new StatusCodeClassifier(stackalloc ushort[] { 200 }); + private static ResponseClassifier _responseClassifier204; + private static ResponseClassifier ResponseClassifier204 => _responseClassifier204 ??= new StatusCodeClassifier(stackalloc ushort[] { 204 }); + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/UpdateTimeFilter.Serialization.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/UpdateTimeFilter.Serialization.cs new file mode 100644 index 0000000000000..ab9c7df379401 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/UpdateTimeFilter.Serialization.cs @@ -0,0 +1,40 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + public partial class UpdateTimeFilter : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + writer.WritePropertyName("updateTime"u8); +#if NET6_0_OR_GREATER + writer.WriteRawValue(UpdateTime); +#else + using (JsonDocument document = JsonDocument.Parse(UpdateTime)) + { + JsonSerializer.Serialize(writer, document.RootElement); + } +#endif + writer.WritePropertyName("kind"u8); + writer.WriteStringValue(Kind); + writer.WriteEndObject(); + } + + /// Convert into a Utf8JsonRequestContent. + internal override RequestContent ToRequestContent() + { + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(this); + return content; + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/UpdateTimeFilter.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/UpdateTimeFilter.cs new file mode 100644 index 0000000000000..fac3942b91e80 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Generated/UpdateTimeFilter.cs @@ -0,0 +1,86 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using Azure.Core; + +namespace Azure.Analytics.Purview.DataMap +{ + /// Update time filter for search. + public partial class UpdateTimeFilter : SearchFilter + { + /// Initializes a new instance of . + /// + /// Either using a string 'LAST_24H|LAST_7D|LAST_30D|LAST_365D|MORE_THAN_365D', or using a map for example + /// { + /// "operator": "lt", + /// "timeThreshold": 1545580800000 + /// } + /// to represent the time filter, operator must be one of gt/lt/gte/lte + /// + /// is null. + public UpdateTimeFilter(BinaryData updateTime) + { + Argument.AssertNotNull(updateTime, nameof(updateTime)); + + Kind = "UpdateTimeFilter"; + UpdateTime = updateTime; + } + + /// Initializes a new instance of . + /// Discriminator. + /// + /// Either using a string 'LAST_24H|LAST_7D|LAST_30D|LAST_365D|MORE_THAN_365D', or using a map for example + /// { + /// "operator": "lt", + /// "timeThreshold": 1545580800000 + /// } + /// to represent the time filter, operator must be one of gt/lt/gte/lte + /// + internal UpdateTimeFilter(string kind, BinaryData updateTime) : base(kind) + { + UpdateTime = updateTime; + } + + /// + /// Either using a string 'LAST_24H|LAST_7D|LAST_30D|LAST_365D|MORE_THAN_365D', or using a map for example + /// { + /// "operator": "lt", + /// "timeThreshold": 1545580800000 + /// } + /// to represent the time filter, operator must be one of gt/lt/gte/lte + /// + /// To assign an object to this property use . + /// + /// + /// To assign an already formatted json string to this property use . + /// + /// + /// Examples: + /// + /// + /// BinaryData.FromObjectAsJson("foo") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromString("\"foo\"") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromObjectAsJson(new { key = "value" }) + /// Creates a payload of { "key": "value" }. + /// + /// + /// BinaryData.FromString("{\"key\": \"value\"}") + /// Creates a payload of { "key": "value" }. + /// + /// + /// + /// + public BinaryData UpdateTime { get; } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/src/Properties/AssemblyInfo.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Properties/AssemblyInfo.cs new file mode 100644 index 0000000000000..92d2035adfab8 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/src/Properties/AssemblyInfo.cs @@ -0,0 +1,11 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +using System.Runtime.CompilerServices; + +[assembly: InternalsVisibleTo("Azure.Analytics.Purview.DataMap.Tests, PublicKey=0024000004800000940000000602000000240000525341310004000001000100d15ddcb29688295338af4b7686603fe614abd555e09efba8fb88ee09e1f7b1ccaeed2e8f823fa9eef3fdd60217fc012ea67d2479751a0b8c087a4185541b851bd8b16f8d91b840e51b1cb0ba6fe647997e57429265e85ef62d565db50a69ae1647d54d7bd855e4db3d8a91510e5bcbd0edfbbecaa20a7bd9ae74593daa7b11b4")] + +// Replace Microsoft.Test with the correct resource provider namepace for your service and uncomment. +// See https://docs.microsoft.com/en-us/azure/azure-resource-manager/management/azure-services-resource-providers +// for the list of possible values. +[assembly: Azure.Core.AzureResourceProviderNamespace("Microsoft.Template")] diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/tests/Azure.Analytics.Purview.DataMap.Tests.csproj b/sdk/purview/Azure.Analytics.Purview.DataMap/tests/Azure.Analytics.Purview.DataMap.Tests.csproj new file mode 100644 index 0000000000000..a25cd18c02203 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/tests/Azure.Analytics.Purview.DataMap.Tests.csproj @@ -0,0 +1,29 @@ + + + $(RequiredTargetFrameworks) + + + $(NoWarn);CS1591 + + + + + + + + + + + + + + + + + + + + + + + diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/tests/Generated/Samples/Samples_Discovery.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/tests/Generated/Samples/Samples_Discovery.cs new file mode 100644 index 0000000000000..c143184874197 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/tests/Generated/Samples/Samples_Discovery.cs @@ -0,0 +1,685 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Text.Json; +using System.Threading.Tasks; +using Azure; +using Azure.Analytics.Purview.DataMap; +using Azure.Core; +using Azure.Identity; +using NUnit.Framework; + +namespace Azure.Analytics.Purview.DataMap.Samples +{ + public partial class Samples_Discovery + { + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Discovery_Query_ShortVersion() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Discovery client = new DataMapClient(endpoint, credential).GetDiscoveryClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object()); + Response response = client.Query(content); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Discovery_Query_ShortVersion_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Discovery client = new DataMapClient(endpoint, credential).GetDiscoveryClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object()); + Response response = await client.QueryAsync(content); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Discovery_Query_ShortVersion_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Discovery client = new DataMapClient(endpoint, credential).GetDiscoveryClient(apiVersion: "2023-09-01"); + + SearchOptions searchRequest = new SearchOptions(); + Response response = client.Query(searchRequest); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Discovery_Query_ShortVersion_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Discovery client = new DataMapClient(endpoint, credential).GetDiscoveryClient(apiVersion: "2023-09-01"); + + SearchOptions searchRequest = new SearchOptions(); + Response response = await client.QueryAsync(searchRequest); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Discovery_Query_AllParameters() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Discovery client = new DataMapClient(endpoint, credential).GetDiscoveryClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new + { + keywords = "", + limit = 1234, + continuationToken = "", + orderby = new object[] + { +new object() + }, + filter = new object(), + facets = new object[] + { +new +{ +count = 1234, +facet = "", +sort = new +{ +count = "asc", +value = "asc", +}, +} + }, + taxonomySetting = new + { + assetTypes = new object[] + { +"" + }, + }, + }); + Response response = client.Query(content); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("@search.count").ToString()); + Console.WriteLine(result.GetProperty("@search.count.approximate").ToString()); + Console.WriteLine(result.GetProperty("continuationToken").ToString()); + Console.WriteLine(result.GetProperty("@search.facets").GetProperty("entityType")[0].GetProperty("count").ToString()); + Console.WriteLine(result.GetProperty("@search.facets").GetProperty("entityType")[0].GetProperty("value").ToString()); + Console.WriteLine(result.GetProperty("@search.facets").GetProperty("assetType")[0].GetProperty("count").ToString()); + Console.WriteLine(result.GetProperty("@search.facets").GetProperty("assetType")[0].GetProperty("value").ToString()); + Console.WriteLine(result.GetProperty("@search.facets").GetProperty("classification")[0].GetProperty("count").ToString()); + Console.WriteLine(result.GetProperty("@search.facets").GetProperty("classification")[0].GetProperty("value").ToString()); + Console.WriteLine(result.GetProperty("@search.facets").GetProperty("term")[0].GetProperty("count").ToString()); + Console.WriteLine(result.GetProperty("@search.facets").GetProperty("term")[0].GetProperty("value").ToString()); + Console.WriteLine(result.GetProperty("@search.facets").GetProperty("contactId")[0].GetProperty("count").ToString()); + Console.WriteLine(result.GetProperty("@search.facets").GetProperty("contactId")[0].GetProperty("value").ToString()); + Console.WriteLine(result.GetProperty("@search.facets").GetProperty("contactType")[0].GetProperty("count").ToString()); + Console.WriteLine(result.GetProperty("@search.facets").GetProperty("contactType")[0].GetProperty("value").ToString()); + Console.WriteLine(result.GetProperty("@search.facets").GetProperty("label")[0].GetProperty("count").ToString()); + Console.WriteLine(result.GetProperty("@search.facets").GetProperty("label")[0].GetProperty("value").ToString()); + Console.WriteLine(result.GetProperty("@search.facets").GetProperty("glossaryType")[0].GetProperty("count").ToString()); + Console.WriteLine(result.GetProperty("@search.facets").GetProperty("glossaryType")[0].GetProperty("value").ToString()); + Console.WriteLine(result.GetProperty("@search.facets").GetProperty("termStatus")[0].GetProperty("count").ToString()); + Console.WriteLine(result.GetProperty("@search.facets").GetProperty("termStatus")[0].GetProperty("value").ToString()); + Console.WriteLine(result.GetProperty("@search.facets").GetProperty("termTemplate")[0].GetProperty("count").ToString()); + Console.WriteLine(result.GetProperty("@search.facets").GetProperty("termTemplate")[0].GetProperty("value").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("@search.score").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("@search.highlights").GetProperty("id")[0].ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("@search.highlights").GetProperty("qualifiedName")[0].ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("@search.highlights").GetProperty("name")[0].ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("@search.highlights").GetProperty("description")[0].ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("@search.highlights").GetProperty("entityType")[0].ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("objectType").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("createTime").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("updateTime").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("id").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("name").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("qualifiedName").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("entityType").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("endorsement").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("owner").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("classification")[0].ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("label")[0].ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("term")[0].GetProperty("name").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("term")[0].GetProperty("glossaryName").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("term")[0].GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("contact")[0].GetProperty("id").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("contact")[0].GetProperty("info").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("contact")[0].GetProperty("contactType").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("assetType")[0].ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("glossaryType").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("glossary").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("termStatus").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("termTemplate")[0].ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("longDescription").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Discovery_Query_AllParameters_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Discovery client = new DataMapClient(endpoint, credential).GetDiscoveryClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new + { + keywords = "", + limit = 1234, + continuationToken = "", + orderby = new object[] + { +new object() + }, + filter = new object(), + facets = new object[] + { +new +{ +count = 1234, +facet = "", +sort = new +{ +count = "asc", +value = "asc", +}, +} + }, + taxonomySetting = new + { + assetTypes = new object[] + { +"" + }, + }, + }); + Response response = await client.QueryAsync(content); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("@search.count").ToString()); + Console.WriteLine(result.GetProperty("@search.count.approximate").ToString()); + Console.WriteLine(result.GetProperty("continuationToken").ToString()); + Console.WriteLine(result.GetProperty("@search.facets").GetProperty("entityType")[0].GetProperty("count").ToString()); + Console.WriteLine(result.GetProperty("@search.facets").GetProperty("entityType")[0].GetProperty("value").ToString()); + Console.WriteLine(result.GetProperty("@search.facets").GetProperty("assetType")[0].GetProperty("count").ToString()); + Console.WriteLine(result.GetProperty("@search.facets").GetProperty("assetType")[0].GetProperty("value").ToString()); + Console.WriteLine(result.GetProperty("@search.facets").GetProperty("classification")[0].GetProperty("count").ToString()); + Console.WriteLine(result.GetProperty("@search.facets").GetProperty("classification")[0].GetProperty("value").ToString()); + Console.WriteLine(result.GetProperty("@search.facets").GetProperty("term")[0].GetProperty("count").ToString()); + Console.WriteLine(result.GetProperty("@search.facets").GetProperty("term")[0].GetProperty("value").ToString()); + Console.WriteLine(result.GetProperty("@search.facets").GetProperty("contactId")[0].GetProperty("count").ToString()); + Console.WriteLine(result.GetProperty("@search.facets").GetProperty("contactId")[0].GetProperty("value").ToString()); + Console.WriteLine(result.GetProperty("@search.facets").GetProperty("contactType")[0].GetProperty("count").ToString()); + Console.WriteLine(result.GetProperty("@search.facets").GetProperty("contactType")[0].GetProperty("value").ToString()); + Console.WriteLine(result.GetProperty("@search.facets").GetProperty("label")[0].GetProperty("count").ToString()); + Console.WriteLine(result.GetProperty("@search.facets").GetProperty("label")[0].GetProperty("value").ToString()); + Console.WriteLine(result.GetProperty("@search.facets").GetProperty("glossaryType")[0].GetProperty("count").ToString()); + Console.WriteLine(result.GetProperty("@search.facets").GetProperty("glossaryType")[0].GetProperty("value").ToString()); + Console.WriteLine(result.GetProperty("@search.facets").GetProperty("termStatus")[0].GetProperty("count").ToString()); + Console.WriteLine(result.GetProperty("@search.facets").GetProperty("termStatus")[0].GetProperty("value").ToString()); + Console.WriteLine(result.GetProperty("@search.facets").GetProperty("termTemplate")[0].GetProperty("count").ToString()); + Console.WriteLine(result.GetProperty("@search.facets").GetProperty("termTemplate")[0].GetProperty("value").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("@search.score").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("@search.highlights").GetProperty("id")[0].ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("@search.highlights").GetProperty("qualifiedName")[0].ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("@search.highlights").GetProperty("name")[0].ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("@search.highlights").GetProperty("description")[0].ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("@search.highlights").GetProperty("entityType")[0].ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("objectType").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("createTime").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("updateTime").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("id").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("name").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("qualifiedName").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("entityType").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("endorsement").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("owner").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("classification")[0].ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("label")[0].ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("term")[0].GetProperty("name").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("term")[0].GetProperty("glossaryName").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("term")[0].GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("contact")[0].GetProperty("id").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("contact")[0].GetProperty("info").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("contact")[0].GetProperty("contactType").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("assetType")[0].ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("glossaryType").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("glossary").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("termStatus").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("termTemplate")[0].ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("longDescription").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Discovery_Query_AllParameters_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Discovery client = new DataMapClient(endpoint, credential).GetDiscoveryClient(apiVersion: "2023-09-01"); + + SearchOptions searchRequest = new SearchOptions + { + Keywords = "", + Limit = 1234, + ContinuationToken = "", + Orderby = { BinaryData.FromObjectAsJson(new object()) }, + Filter = BinaryData.FromObjectAsJson(new object()), + Facets = {new SearchFacetItem +{ +Count = 1234, +Facet = "", +Sort = new SearchFacetSort +{ +Count = SearchSortOrder.Ascend, +Value = SearchSortOrder.Ascend, +}, +}}, + TaxonomySetting = new SearchTaxonomySetting + { + AssetTypes = { "" }, + Facet = default, + }, + }; + Response response = client.Query(searchRequest); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Discovery_Query_AllParameters_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Discovery client = new DataMapClient(endpoint, credential).GetDiscoveryClient(apiVersion: "2023-09-01"); + + SearchOptions searchRequest = new SearchOptions + { + Keywords = "", + Limit = 1234, + ContinuationToken = "", + Orderby = { BinaryData.FromObjectAsJson(new object()) }, + Filter = BinaryData.FromObjectAsJson(new object()), + Facets = {new SearchFacetItem +{ +Count = 1234, +Facet = "", +Sort = new SearchFacetSort +{ +Count = SearchSortOrder.Ascend, +Value = SearchSortOrder.Ascend, +}, +}}, + TaxonomySetting = new SearchTaxonomySetting + { + AssetTypes = { "" }, + Facet = default, + }, + }; + Response response = await client.QueryAsync(searchRequest); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Discovery_Suggest_ShortVersion() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Discovery client = new DataMapClient(endpoint, credential).GetDiscoveryClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object()); + Response response = client.Suggest(content); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Discovery_Suggest_ShortVersion_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Discovery client = new DataMapClient(endpoint, credential).GetDiscoveryClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object()); + Response response = await client.SuggestAsync(content); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Discovery_Suggest_ShortVersion_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Discovery client = new DataMapClient(endpoint, credential).GetDiscoveryClient(apiVersion: "2023-09-01"); + + SuggestOptions suggestRequest = new SuggestOptions(); + Response response = client.Suggest(suggestRequest); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Discovery_Suggest_ShortVersion_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Discovery client = new DataMapClient(endpoint, credential).GetDiscoveryClient(apiVersion: "2023-09-01"); + + SuggestOptions suggestRequest = new SuggestOptions(); + Response response = await client.SuggestAsync(suggestRequest); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Discovery_Suggest_AllParameters() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Discovery client = new DataMapClient(endpoint, credential).GetDiscoveryClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new + { + keywords = "", + limit = 1234, + filter = new + { + and = new object[] + { +null + }, + kind = "AndFilter", + }, + }); + Response response = client.Suggest(content); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("value")[0].GetProperty("@search.score").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("@search.text").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("objectType").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("createTime").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("updateTime").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("id").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("name").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("qualifiedName").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("entityType").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("endorsement").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("owner").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("classification")[0].ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("label")[0].ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("term")[0].GetProperty("name").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("term")[0].GetProperty("glossaryName").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("term")[0].GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("contact")[0].GetProperty("id").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("contact")[0].GetProperty("info").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("contact")[0].GetProperty("contactType").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("assetType")[0].ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("glossaryType").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("glossary").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("termStatus").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("termTemplate")[0].ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("longDescription").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Discovery_Suggest_AllParameters_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Discovery client = new DataMapClient(endpoint, credential).GetDiscoveryClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new + { + keywords = "", + limit = 1234, + filter = new + { + and = new object[] + { +null + }, + kind = "AndFilter", + }, + }); + Response response = await client.SuggestAsync(content); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("value")[0].GetProperty("@search.score").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("@search.text").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("objectType").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("createTime").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("updateTime").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("id").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("name").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("qualifiedName").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("entityType").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("endorsement").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("owner").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("classification")[0].ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("label")[0].ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("term")[0].GetProperty("name").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("term")[0].GetProperty("glossaryName").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("term")[0].GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("contact")[0].GetProperty("id").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("contact")[0].GetProperty("info").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("contact")[0].GetProperty("contactType").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("assetType")[0].ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("glossaryType").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("glossary").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("termStatus").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("termTemplate")[0].ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("longDescription").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Discovery_Suggest_AllParameters_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Discovery client = new DataMapClient(endpoint, credential).GetDiscoveryClient(apiVersion: "2023-09-01"); + + SuggestOptions suggestRequest = new SuggestOptions + { + Keywords = "", + Limit = 1234, + Filter = new AndFilter(new SearchFilter[] + { +default + }), + }; + Response response = client.Suggest(suggestRequest); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Discovery_Suggest_AllParameters_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Discovery client = new DataMapClient(endpoint, credential).GetDiscoveryClient(apiVersion: "2023-09-01"); + + SuggestOptions suggestRequest = new SuggestOptions + { + Keywords = "", + Limit = 1234, + Filter = new AndFilter(new SearchFilter[] + { +default + }), + }; + Response response = await client.SuggestAsync(suggestRequest); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Discovery_AutoComplete_ShortVersion() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Discovery client = new DataMapClient(endpoint, credential).GetDiscoveryClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object()); + Response response = client.AutoComplete(content); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Discovery_AutoComplete_ShortVersion_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Discovery client = new DataMapClient(endpoint, credential).GetDiscoveryClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object()); + Response response = await client.AutoCompleteAsync(content); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Discovery_AutoComplete_ShortVersion_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Discovery client = new DataMapClient(endpoint, credential).GetDiscoveryClient(apiVersion: "2023-09-01"); + + AutoCompleteOptions autoCompleteRequest = new AutoCompleteOptions(); + Response response = client.AutoComplete(autoCompleteRequest); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Discovery_AutoComplete_ShortVersion_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Discovery client = new DataMapClient(endpoint, credential).GetDiscoveryClient(apiVersion: "2023-09-01"); + + AutoCompleteOptions autoCompleteRequest = new AutoCompleteOptions(); + Response response = await client.AutoCompleteAsync(autoCompleteRequest); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Discovery_AutoComplete_AllParameters() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Discovery client = new DataMapClient(endpoint, credential).GetDiscoveryClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new + { + keywords = "", + limit = 1234, + filter = new + { + and = new object[] + { +null + }, + kind = "AndFilter", + }, + }); + Response response = client.AutoComplete(content); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("value")[0].GetProperty("text").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("queryPlusText").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Discovery_AutoComplete_AllParameters_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Discovery client = new DataMapClient(endpoint, credential).GetDiscoveryClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new + { + keywords = "", + limit = 1234, + filter = new + { + and = new object[] + { +null + }, + kind = "AndFilter", + }, + }); + Response response = await client.AutoCompleteAsync(content); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("value")[0].GetProperty("text").ToString()); + Console.WriteLine(result.GetProperty("value")[0].GetProperty("queryPlusText").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Discovery_AutoComplete_AllParameters_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Discovery client = new DataMapClient(endpoint, credential).GetDiscoveryClient(apiVersion: "2023-09-01"); + + AutoCompleteOptions autoCompleteRequest = new AutoCompleteOptions + { + Keywords = "", + Limit = 1234, + Filter = new AndFilter(new SearchFilter[] + { +default + }), + }; + Response response = client.AutoComplete(autoCompleteRequest); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Discovery_AutoComplete_AllParameters_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Discovery client = new DataMapClient(endpoint, credential).GetDiscoveryClient(apiVersion: "2023-09-01"); + + AutoCompleteOptions autoCompleteRequest = new AutoCompleteOptions + { + Keywords = "", + Limit = 1234, + Filter = new AndFilter(new SearchFilter[] + { +default + }), + }; + Response response = await client.AutoCompleteAsync(autoCompleteRequest); + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/tests/Generated/Samples/Samples_Entity.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/tests/Generated/Samples/Samples_Entity.cs new file mode 100644 index 0000000000000..3e2388521e06f --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/tests/Generated/Samples/Samples_Entity.cs @@ -0,0 +1,7074 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Collections.Generic; +using System.Text.Json; +using System.Threading.Tasks; +using Azure; +using Azure.Analytics.Purview.DataMap; +using Azure.Core; +using Azure.Identity; +using NUnit.Framework; + +namespace Azure.Analytics.Purview.DataMap.Samples +{ + public partial class Samples_Entity + { + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_CreateOrUpdate_ShortVersion() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object()); + Response response = client.CreateOrUpdate(content); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_CreateOrUpdate_ShortVersion_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object()); + Response response = await client.CreateOrUpdateAsync(content); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_CreateOrUpdate_ShortVersion_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + AtlasEntityWithExtInfo entity = new AtlasEntityWithExtInfo(); + Response response = client.CreateOrUpdate(entity); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_CreateOrUpdate_ShortVersion_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + AtlasEntityWithExtInfo entity = new AtlasEntityWithExtInfo(); + Response response = await client.CreateOrUpdateAsync(entity); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_CreateOrUpdate_AllParameters() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new + { + referredEntities = new + { + key = new + { + attributes = new + { + key = new object(), + }, + typeName = "", + lastModifiedTS = "", + businessAttributes = new + { + key = new object(), + }, + classifications = new object[] + { +new +{ +attributes = new +{ +key = new object(), +}, +typeName = "", +lastModifiedTS = "", +entityGuid = "", +entityStatus = "ACTIVE", +removePropagationsOnEntityDelete = true, +validityPeriods = new object[] +{ +new +{ +endTime = "", +startTime = "", +timeZone = "", +} +}, +} + }, + createTime = 1234L, + createdBy = "", + customAttributes = new + { + key = "", + }, + guid = "", + homeId = "", + isIncomplete = true, + labels = new object[] + { +"" + }, + meanings = new object[] + { +new +{ +confidence = 1234, +createdBy = "", +description = "", +displayText = "", +expression = "", +relationGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", +status = "DISCOVERED", +steward = "", +termGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", +} + }, + provenanceType = 1234, + proxy = true, + relationshipAttributes = new + { + key = new object(), + }, + status = "ACTIVE", + updateTime = 1234L, + updatedBy = "", + version = 1234L, + contacts = new + { + key = new object[] + { +new +{ +id = "", +info = "", +} + }, + }, + }, + }, + }); + Response response = client.CreateOrUpdate(content, businessAttributeUpdateBehavior: "ignore", collectionId: ""); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("guidAssignments").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classificationNames")[0].ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("isIncomplete").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("labels")[0].ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meaningNames")[0].ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("confidence").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classificationNames")[0].ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("isIncomplete").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("labels")[0].ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meaningNames")[0].ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("confidence").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("status").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_CreateOrUpdate_AllParameters_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new + { + referredEntities = new + { + key = new + { + attributes = new + { + key = new object(), + }, + typeName = "", + lastModifiedTS = "", + businessAttributes = new + { + key = new object(), + }, + classifications = new object[] + { +new +{ +attributes = new +{ +key = new object(), +}, +typeName = "", +lastModifiedTS = "", +entityGuid = "", +entityStatus = "ACTIVE", +removePropagationsOnEntityDelete = true, +validityPeriods = new object[] +{ +new +{ +endTime = "", +startTime = "", +timeZone = "", +} +}, +} + }, + createTime = 1234L, + createdBy = "", + customAttributes = new + { + key = "", + }, + guid = "", + homeId = "", + isIncomplete = true, + labels = new object[] + { +"" + }, + meanings = new object[] + { +new +{ +confidence = 1234, +createdBy = "", +description = "", +displayText = "", +expression = "", +relationGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", +status = "DISCOVERED", +steward = "", +termGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", +} + }, + provenanceType = 1234, + proxy = true, + relationshipAttributes = new + { + key = new object(), + }, + status = "ACTIVE", + updateTime = 1234L, + updatedBy = "", + version = 1234L, + contacts = new + { + key = new object[] + { +new +{ +id = "", +info = "", +} + }, + }, + }, + }, + }); + Response response = await client.CreateOrUpdateAsync(content, businessAttributeUpdateBehavior: "ignore", collectionId: ""); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("guidAssignments").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classificationNames")[0].ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("isIncomplete").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("labels")[0].ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meaningNames")[0].ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("confidence").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classificationNames")[0].ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("isIncomplete").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("labels")[0].ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meaningNames")[0].ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("confidence").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("status").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_CreateOrUpdate_AllParameters_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + AtlasEntityWithExtInfo entity = new AtlasEntityWithExtInfo + { + ReferredEntities = +{ +["key"] = new AtlasEntity +{ +Attributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +TypeName = "", +LastModifiedTS = "", +BusinessAttributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +Classifications = {new AtlasClassification +{ +Attributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +TypeName = "", +LastModifiedTS = "", +EntityGuid = "", +EntityStatus = EntityStatus.Active, +RemovePropagationsOnEntityDelete = true, +ValidityPeriods = {new TimeBoundary +{ +EndTime = "", +StartTime = "", +TimeZone = "", +}}, +}}, +CreateTime = 1234L, +CreatedBy = "", +CustomAttributes = +{ +["key"] = "" +}, +Guid = "", +HomeId = "", +IsIncomplete = true, +Labels = {""}, +Meanings = {new AtlasTermAssignmentHeader +{ +Confidence = 1234, +CreatedBy = "", +Description = "", +DisplayText = "", +Expression = "", +RelationGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), +Status = AtlasTermAssignmentStatus.Discovered, +Steward = "", +TermGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), +}}, +ProvenanceType = 1234, +Proxy = true, +RelationshipAttributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +Status = EntityStatus.Active, +UpdateTime = 1234L, +UpdatedBy = "", +Version = 1234L, +Contacts = +{ +["key"] = {new ContactInfo +{ +Id = "", +Info = "", +}} +}, +} +}, + Entity = default, + }; + Response response = client.CreateOrUpdate(entity, businessAttributeUpdateBehavior: BusinessAttributeUpdateBehavior.Ignore, collectionId: ""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_CreateOrUpdate_AllParameters_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + AtlasEntityWithExtInfo entity = new AtlasEntityWithExtInfo + { + ReferredEntities = +{ +["key"] = new AtlasEntity +{ +Attributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +TypeName = "", +LastModifiedTS = "", +BusinessAttributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +Classifications = {new AtlasClassification +{ +Attributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +TypeName = "", +LastModifiedTS = "", +EntityGuid = "", +EntityStatus = EntityStatus.Active, +RemovePropagationsOnEntityDelete = true, +ValidityPeriods = {new TimeBoundary +{ +EndTime = "", +StartTime = "", +TimeZone = "", +}}, +}}, +CreateTime = 1234L, +CreatedBy = "", +CustomAttributes = +{ +["key"] = "" +}, +Guid = "", +HomeId = "", +IsIncomplete = true, +Labels = {""}, +Meanings = {new AtlasTermAssignmentHeader +{ +Confidence = 1234, +CreatedBy = "", +Description = "", +DisplayText = "", +Expression = "", +RelationGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), +Status = AtlasTermAssignmentStatus.Discovered, +Steward = "", +TermGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), +}}, +ProvenanceType = 1234, +Proxy = true, +RelationshipAttributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +Status = EntityStatus.Active, +UpdateTime = 1234L, +UpdatedBy = "", +Version = 1234L, +Contacts = +{ +["key"] = {new ContactInfo +{ +Id = "", +Info = "", +}} +}, +} +}, + Entity = default, + }; + Response response = await client.CreateOrUpdateAsync(entity, businessAttributeUpdateBehavior: BusinessAttributeUpdateBehavior.Ignore, collectionId: ""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_GetByIds_ShortVersion() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.GetByIds(new string[] { "" }, null, null, null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_GetByIds_ShortVersion_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.GetByIdsAsync(new string[] { "" }, null, null, null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_GetByIds_ShortVersion_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.GetByIds(new string[] { "" }); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_GetByIds_ShortVersion_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.GetByIdsAsync(new string[] { "" }); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_GetByIds_AllParameters() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.GetByIds(new string[] { "" }, true, true, null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("businessAttributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("createTime").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("customAttributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("homeId").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("collectionId").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("isIncomplete").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("labels")[0].ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("confidence").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("provenanceType").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("proxy").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("relationshipAttributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("updateTime").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("updatedBy").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("version").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("contacts").GetProperty("")[0].GetProperty("id").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("contacts").GetProperty("")[0].GetProperty("info").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("businessAttributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("createTime").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("customAttributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("homeId").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("collectionId").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("isIncomplete").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("labels")[0].ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("meanings")[0].GetProperty("confidence").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("meanings")[0].GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("meanings")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("meanings")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("meanings")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("meanings")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("meanings")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("meanings")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("provenanceType").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("proxy").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("relationshipAttributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("updateTime").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("updatedBy").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("version").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("contacts").GetProperty("")[0].GetProperty("id").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("contacts").GetProperty("")[0].GetProperty("info").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_GetByIds_AllParameters_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.GetByIdsAsync(new string[] { "" }, true, true, null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("businessAttributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("createTime").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("customAttributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("homeId").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("collectionId").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("isIncomplete").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("labels")[0].ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("confidence").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("provenanceType").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("proxy").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("relationshipAttributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("updateTime").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("updatedBy").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("version").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("contacts").GetProperty("")[0].GetProperty("id").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("contacts").GetProperty("")[0].GetProperty("info").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("businessAttributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("createTime").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("customAttributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("homeId").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("collectionId").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("isIncomplete").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("labels")[0].ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("meanings")[0].GetProperty("confidence").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("meanings")[0].GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("meanings")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("meanings")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("meanings")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("meanings")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("meanings")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("meanings")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("provenanceType").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("proxy").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("relationshipAttributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("updateTime").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("updatedBy").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("version").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("contacts").GetProperty("")[0].GetProperty("id").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("contacts").GetProperty("")[0].GetProperty("info").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_GetByIds_AllParameters_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.GetByIds(new string[] { "" }, minExtInfo: true, ignoreRelationships: true); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_GetByIds_AllParameters_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.GetByIdsAsync(new string[] { "" }, minExtInfo: true, ignoreRelationships: true); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_BatchCreateOrUpdate_ShortVersion() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object()); + Response response = client.BatchCreateOrUpdate(content); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_BatchCreateOrUpdate_ShortVersion_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object()); + Response response = await client.BatchCreateOrUpdateAsync(content); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_BatchCreateOrUpdate_ShortVersion_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + AtlasEntitiesWithExtInfo entities = new AtlasEntitiesWithExtInfo(); + Response response = client.BatchCreateOrUpdate(entities); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_BatchCreateOrUpdate_ShortVersion_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + AtlasEntitiesWithExtInfo entities = new AtlasEntitiesWithExtInfo(); + Response response = await client.BatchCreateOrUpdateAsync(entities); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_BatchCreateOrUpdate_AllParameters() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new + { + referredEntities = new + { + key = new + { + attributes = new + { + key = new object(), + }, + typeName = "", + lastModifiedTS = "", + businessAttributes = new + { + key = new object(), + }, + classifications = new object[] + { +new +{ +attributes = new +{ +key = new object(), +}, +typeName = "", +lastModifiedTS = "", +entityGuid = "", +entityStatus = "ACTIVE", +removePropagationsOnEntityDelete = true, +validityPeriods = new object[] +{ +new +{ +endTime = "", +startTime = "", +timeZone = "", +} +}, +} + }, + createTime = 1234L, + createdBy = "", + customAttributes = new + { + key = "", + }, + guid = "", + homeId = "", + isIncomplete = true, + labels = new object[] + { +"" + }, + meanings = new object[] + { +new +{ +confidence = 1234, +createdBy = "", +description = "", +displayText = "", +expression = "", +relationGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", +status = "DISCOVERED", +steward = "", +termGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", +} + }, + provenanceType = 1234, + proxy = true, + relationshipAttributes = new + { + key = new object(), + }, + status = "ACTIVE", + updateTime = 1234L, + updatedBy = "", + version = 1234L, + contacts = new + { + key = new object[] + { +new +{ +id = "", +info = "", +} + }, + }, + }, + }, + entities = new object[] + { +null + }, + }); + Response response = client.BatchCreateOrUpdate(content, collectionId: "", businessAttributeUpdateBehavior: "ignore"); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("guidAssignments").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classificationNames")[0].ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("isIncomplete").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("labels")[0].ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meaningNames")[0].ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("confidence").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classificationNames")[0].ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("isIncomplete").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("labels")[0].ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meaningNames")[0].ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("confidence").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("status").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_BatchCreateOrUpdate_AllParameters_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new + { + referredEntities = new + { + key = new + { + attributes = new + { + key = new object(), + }, + typeName = "", + lastModifiedTS = "", + businessAttributes = new + { + key = new object(), + }, + classifications = new object[] + { +new +{ +attributes = new +{ +key = new object(), +}, +typeName = "", +lastModifiedTS = "", +entityGuid = "", +entityStatus = "ACTIVE", +removePropagationsOnEntityDelete = true, +validityPeriods = new object[] +{ +new +{ +endTime = "", +startTime = "", +timeZone = "", +} +}, +} + }, + createTime = 1234L, + createdBy = "", + customAttributes = new + { + key = "", + }, + guid = "", + homeId = "", + isIncomplete = true, + labels = new object[] + { +"" + }, + meanings = new object[] + { +new +{ +confidence = 1234, +createdBy = "", +description = "", +displayText = "", +expression = "", +relationGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", +status = "DISCOVERED", +steward = "", +termGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", +} + }, + provenanceType = 1234, + proxy = true, + relationshipAttributes = new + { + key = new object(), + }, + status = "ACTIVE", + updateTime = 1234L, + updatedBy = "", + version = 1234L, + contacts = new + { + key = new object[] + { +new +{ +id = "", +info = "", +} + }, + }, + }, + }, + entities = new object[] + { +null + }, + }); + Response response = await client.BatchCreateOrUpdateAsync(content, collectionId: "", businessAttributeUpdateBehavior: "ignore"); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("guidAssignments").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classificationNames")[0].ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("isIncomplete").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("labels")[0].ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meaningNames")[0].ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("confidence").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classificationNames")[0].ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("isIncomplete").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("labels")[0].ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meaningNames")[0].ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("confidence").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("status").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_BatchCreateOrUpdate_AllParameters_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + AtlasEntitiesWithExtInfo entities = new AtlasEntitiesWithExtInfo + { + ReferredEntities = +{ +["key"] = new AtlasEntity +{ +Attributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +TypeName = "", +LastModifiedTS = "", +BusinessAttributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +Classifications = {new AtlasClassification +{ +Attributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +TypeName = "", +LastModifiedTS = "", +EntityGuid = "", +EntityStatus = EntityStatus.Active, +RemovePropagationsOnEntityDelete = true, +ValidityPeriods = {new TimeBoundary +{ +EndTime = "", +StartTime = "", +TimeZone = "", +}}, +}}, +CreateTime = 1234L, +CreatedBy = "", +CustomAttributes = +{ +["key"] = "" +}, +Guid = "", +HomeId = "", +IsIncomplete = true, +Labels = {""}, +Meanings = {new AtlasTermAssignmentHeader +{ +Confidence = 1234, +CreatedBy = "", +Description = "", +DisplayText = "", +Expression = "", +RelationGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), +Status = AtlasTermAssignmentStatus.Discovered, +Steward = "", +TermGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), +}}, +ProvenanceType = 1234, +Proxy = true, +RelationshipAttributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +Status = EntityStatus.Active, +UpdateTime = 1234L, +UpdatedBy = "", +Version = 1234L, +Contacts = +{ +["key"] = {new ContactInfo +{ +Id = "", +Info = "", +}} +}, +} +}, + Entities = { default }, + }; + Response response = client.BatchCreateOrUpdate(entities, collectionId: "", businessAttributeUpdateBehavior: BusinessAttributeUpdateBehavior.Ignore); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_BatchCreateOrUpdate_AllParameters_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + AtlasEntitiesWithExtInfo entities = new AtlasEntitiesWithExtInfo + { + ReferredEntities = +{ +["key"] = new AtlasEntity +{ +Attributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +TypeName = "", +LastModifiedTS = "", +BusinessAttributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +Classifications = {new AtlasClassification +{ +Attributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +TypeName = "", +LastModifiedTS = "", +EntityGuid = "", +EntityStatus = EntityStatus.Active, +RemovePropagationsOnEntityDelete = true, +ValidityPeriods = {new TimeBoundary +{ +EndTime = "", +StartTime = "", +TimeZone = "", +}}, +}}, +CreateTime = 1234L, +CreatedBy = "", +CustomAttributes = +{ +["key"] = "" +}, +Guid = "", +HomeId = "", +IsIncomplete = true, +Labels = {""}, +Meanings = {new AtlasTermAssignmentHeader +{ +Confidence = 1234, +CreatedBy = "", +Description = "", +DisplayText = "", +Expression = "", +RelationGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), +Status = AtlasTermAssignmentStatus.Discovered, +Steward = "", +TermGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), +}}, +ProvenanceType = 1234, +Proxy = true, +RelationshipAttributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +Status = EntityStatus.Active, +UpdateTime = 1234L, +UpdatedBy = "", +Version = 1234L, +Contacts = +{ +["key"] = {new ContactInfo +{ +Id = "", +Info = "", +}} +}, +} +}, + Entities = { default }, + }; + Response response = await client.BatchCreateOrUpdateAsync(entities, collectionId: "", businessAttributeUpdateBehavior: BusinessAttributeUpdateBehavior.Ignore); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_BatchDelete_ShortVersion() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.BatchDelete(new string[] { "" }, null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_BatchDelete_ShortVersion_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.BatchDeleteAsync(new string[] { "" }, null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_BatchDelete_ShortVersion_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.BatchDelete(new string[] { "" }); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_BatchDelete_ShortVersion_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.BatchDeleteAsync(new string[] { "" }); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_BatchDelete_AllParameters() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.BatchDelete(new string[] { "" }, null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("guidAssignments").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classificationNames")[0].ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("isIncomplete").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("labels")[0].ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meaningNames")[0].ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("confidence").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classificationNames")[0].ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("isIncomplete").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("labels")[0].ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meaningNames")[0].ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("confidence").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("status").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_BatchDelete_AllParameters_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.BatchDeleteAsync(new string[] { "" }, null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("guidAssignments").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classificationNames")[0].ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("isIncomplete").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("labels")[0].ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meaningNames")[0].ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("confidence").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classificationNames")[0].ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("isIncomplete").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("labels")[0].ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meaningNames")[0].ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("confidence").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("status").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_BatchDelete_AllParameters_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.BatchDelete(new string[] { "" }); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_BatchDelete_AllParameters_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.BatchDeleteAsync(new string[] { "" }); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_AddClassification_ShortVersion() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object()); + Response response = client.AddClassification(content); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_AddClassification_ShortVersion_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object()); + Response response = await client.AddClassificationAsync(content); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_AddClassification_ShortVersion_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + ClassificationAssociateOptions request = new ClassificationAssociateOptions(); + Response response = client.AddClassification(request); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_AddClassification_ShortVersion_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + ClassificationAssociateOptions request = new ClassificationAssociateOptions(); + Response response = await client.AddClassificationAsync(request); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_AddClassification_AllParameters() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new + { + classification = new + { + attributes = new + { + key = new object(), + }, + typeName = "", + lastModifiedTS = "", + entityGuid = "", + entityStatus = "ACTIVE", + removePropagationsOnEntityDelete = true, + validityPeriods = new object[] + { +new +{ +endTime = "", +startTime = "", +timeZone = "", +} + }, + }, + entityGuids = new object[] + { +"" + }, + }); + Response response = client.AddClassification(content); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_AddClassification_AllParameters_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new + { + classification = new + { + attributes = new + { + key = new object(), + }, + typeName = "", + lastModifiedTS = "", + entityGuid = "", + entityStatus = "ACTIVE", + removePropagationsOnEntityDelete = true, + validityPeriods = new object[] + { +new +{ +endTime = "", +startTime = "", +timeZone = "", +} + }, + }, + entityGuids = new object[] + { +"" + }, + }); + Response response = await client.AddClassificationAsync(content); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_AddClassification_AllParameters_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + ClassificationAssociateOptions request = new ClassificationAssociateOptions + { + Classification = new AtlasClassification + { + Attributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, + TypeName = "", + LastModifiedTS = "", + EntityGuid = "", + EntityStatus = EntityStatus.Active, + RemovePropagationsOnEntityDelete = true, + ValidityPeriods = {new TimeBoundary +{ +EndTime = "", +StartTime = "", +TimeZone = "", +}}, + }, + EntityGuids = { "" }, + }; + Response response = client.AddClassification(request); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_AddClassification_AllParameters_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + ClassificationAssociateOptions request = new ClassificationAssociateOptions + { + Classification = new AtlasClassification + { + Attributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, + TypeName = "", + LastModifiedTS = "", + EntityGuid = "", + EntityStatus = EntityStatus.Active, + RemovePropagationsOnEntityDelete = true, + ValidityPeriods = {new TimeBoundary +{ +EndTime = "", +StartTime = "", +TimeZone = "", +}}, + }, + EntityGuids = { "" }, + }; + Response response = await client.AddClassificationAsync(request); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_GetEntity_ShortVersion() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.GetEntity("", null, null, null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_GetEntity_ShortVersion_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.GetEntityAsync("", null, null, null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_GetEntity_ShortVersion_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.GetEntity(""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_GetEntity_ShortVersion_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.GetEntityAsync(""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_GetEntity_AllParameters() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.GetEntity("", true, true, null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("businessAttributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("createTime").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("customAttributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("homeId").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("collectionId").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("isIncomplete").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("labels")[0].ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("confidence").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("provenanceType").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("proxy").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("relationshipAttributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("updateTime").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("updatedBy").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("version").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("contacts").GetProperty("")[0].GetProperty("id").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("contacts").GetProperty("")[0].GetProperty("info").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("businessAttributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("createTime").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("customAttributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("homeId").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("collectionId").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("isIncomplete").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("labels")[0].ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("meanings")[0].GetProperty("confidence").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("meanings")[0].GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("meanings")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("meanings")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("meanings")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("meanings")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("meanings")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("meanings")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("provenanceType").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("proxy").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("relationshipAttributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("updateTime").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("updatedBy").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("version").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("contacts").GetProperty("")[0].GetProperty("id").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("contacts").GetProperty("")[0].GetProperty("info").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_GetEntity_AllParameters_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.GetEntityAsync("", true, true, null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("businessAttributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("createTime").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("customAttributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("homeId").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("collectionId").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("isIncomplete").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("labels")[0].ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("confidence").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("provenanceType").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("proxy").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("relationshipAttributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("updateTime").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("updatedBy").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("version").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("contacts").GetProperty("")[0].GetProperty("id").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("contacts").GetProperty("")[0].GetProperty("info").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("businessAttributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("createTime").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("customAttributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("homeId").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("collectionId").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("isIncomplete").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("labels")[0].ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("meanings")[0].GetProperty("confidence").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("meanings")[0].GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("meanings")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("meanings")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("meanings")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("meanings")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("meanings")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("meanings")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("provenanceType").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("proxy").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("relationshipAttributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("updateTime").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("updatedBy").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("version").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("contacts").GetProperty("")[0].GetProperty("id").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("contacts").GetProperty("")[0].GetProperty("info").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_GetEntity_AllParameters_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.GetEntity("", minExtInfo: true, ignoreRelationships: true); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_GetEntity_AllParameters_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.GetEntityAsync("", minExtInfo: true, ignoreRelationships: true); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_PartialUpdateAttributeById_ShortVersion() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object()); + Response response = client.PartialUpdateAttributeById("", "", content); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_PartialUpdateAttributeById_ShortVersion_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object()); + Response response = await client.PartialUpdateAttributeByIdAsync("", "", content); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_PartialUpdateAttributeById_ShortVersion_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.PartialUpdateAttributeById("", "", BinaryData.FromObjectAsJson(new object())); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_PartialUpdateAttributeById_ShortVersion_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.PartialUpdateAttributeByIdAsync("", "", BinaryData.FromObjectAsJson(new object())); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_PartialUpdateAttributeById_AllParameters() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object()); + Response response = client.PartialUpdateAttributeById("", "", content); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("guidAssignments").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classificationNames")[0].ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("isIncomplete").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("labels")[0].ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meaningNames")[0].ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("confidence").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classificationNames")[0].ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("isIncomplete").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("labels")[0].ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meaningNames")[0].ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("confidence").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("status").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_PartialUpdateAttributeById_AllParameters_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object()); + Response response = await client.PartialUpdateAttributeByIdAsync("", "", content); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("guidAssignments").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classificationNames")[0].ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("isIncomplete").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("labels")[0].ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meaningNames")[0].ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("confidence").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classificationNames")[0].ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("isIncomplete").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("labels")[0].ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meaningNames")[0].ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("confidence").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("status").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_PartialUpdateAttributeById_AllParameters_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.PartialUpdateAttributeById("", "", BinaryData.FromObjectAsJson(new object())); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_PartialUpdateAttributeById_AllParameters_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.PartialUpdateAttributeByIdAsync("", "", BinaryData.FromObjectAsJson(new object())); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_Delete_ShortVersion() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.Delete("", null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_Delete_ShortVersion_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.DeleteAsync("", null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_Delete_ShortVersion_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.Delete(""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_Delete_ShortVersion_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.DeleteAsync(""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_Delete_AllParameters() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.Delete("", null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("guidAssignments").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classificationNames")[0].ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("isIncomplete").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("labels")[0].ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meaningNames")[0].ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("confidence").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classificationNames")[0].ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("isIncomplete").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("labels")[0].ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meaningNames")[0].ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("confidence").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("status").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_Delete_AllParameters_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.DeleteAsync("", null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("guidAssignments").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classificationNames")[0].ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("isIncomplete").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("labels")[0].ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meaningNames")[0].ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("confidence").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classificationNames")[0].ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("isIncomplete").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("labels")[0].ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meaningNames")[0].ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("confidence").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("status").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_Delete_AllParameters_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.Delete(""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_Delete_AllParameters_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.DeleteAsync(""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_GetClassification_ShortVersion() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.GetClassification("", "", null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_GetClassification_ShortVersion_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.GetClassificationAsync("", "", null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_GetClassification_ShortVersion_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.GetClassification("", ""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_GetClassification_ShortVersion_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.GetClassificationAsync("", ""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_GetClassification_AllParameters() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.GetClassification("", "", null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_GetClassification_AllParameters_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.GetClassificationAsync("", "", null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_GetClassification_AllParameters_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.GetClassification("", ""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_GetClassification_AllParameters_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.GetClassificationAsync("", ""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_RemoveClassification_ShortVersion() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.RemoveClassification("", ""); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_RemoveClassification_ShortVersion_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.RemoveClassificationAsync("", ""); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_RemoveClassification_AllParameters() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.RemoveClassification("", ""); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_RemoveClassification_AllParameters_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.RemoveClassificationAsync("", ""); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_GetClassifications_ShortVersion() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.GetClassifications("", null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_GetClassifications_ShortVersion_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.GetClassificationsAsync("", null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_GetClassifications_ShortVersion_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.GetClassifications(""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_GetClassifications_ShortVersion_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.GetClassificationsAsync(""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_GetClassifications_AllParameters() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.GetClassifications("", null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("list")[0].ToString()); + Console.WriteLine(result.GetProperty("pageSize").ToString()); + Console.WriteLine(result.GetProperty("sortBy").ToString()); + Console.WriteLine(result.GetProperty("sortType").ToString()); + Console.WriteLine(result.GetProperty("startIndex").ToString()); + Console.WriteLine(result.GetProperty("totalCount").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_GetClassifications_AllParameters_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.GetClassificationsAsync("", null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("list")[0].ToString()); + Console.WriteLine(result.GetProperty("pageSize").ToString()); + Console.WriteLine(result.GetProperty("sortBy").ToString()); + Console.WriteLine(result.GetProperty("sortType").ToString()); + Console.WriteLine(result.GetProperty("startIndex").ToString()); + Console.WriteLine(result.GetProperty("totalCount").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_GetClassifications_AllParameters_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.GetClassifications(""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_GetClassifications_AllParameters_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.GetClassificationsAsync(""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_AddClassifications_ShortVersion() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object[] + { +new object() + }); + Response response = client.AddClassifications("", content); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_AddClassifications_ShortVersion_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object[] + { +new object() + }); + Response response = await client.AddClassificationsAsync("", content); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_AddClassifications_ShortVersion_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.AddClassifications("", new AtlasClassification[] + { +new AtlasClassification() + }); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_AddClassifications_ShortVersion_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.AddClassificationsAsync("", new AtlasClassification[] + { +new AtlasClassification() + }); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_AddClassifications_AllParameters() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object[] + { +new +{ +attributes = new +{ +key = new object(), +}, +typeName = "", +lastModifiedTS = "", +entityGuid = "", +entityStatus = "ACTIVE", +removePropagationsOnEntityDelete = true, +validityPeriods = new object[] +{ +new +{ +endTime = "", +startTime = "", +timeZone = "", +} +}, +} + }); + Response response = client.AddClassifications("", content); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_AddClassifications_AllParameters_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object[] + { +new +{ +attributes = new +{ +key = new object(), +}, +typeName = "", +lastModifiedTS = "", +entityGuid = "", +entityStatus = "ACTIVE", +removePropagationsOnEntityDelete = true, +validityPeriods = new object[] +{ +new +{ +endTime = "", +startTime = "", +timeZone = "", +} +}, +} + }); + Response response = await client.AddClassificationsAsync("", content); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_AddClassifications_AllParameters_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.AddClassifications("", new AtlasClassification[] + { +new AtlasClassification +{ +Attributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +TypeName = "", +LastModifiedTS = "", +EntityGuid = "", +EntityStatus = EntityStatus.Active, +RemovePropagationsOnEntityDelete = true, +ValidityPeriods = {new TimeBoundary +{ +EndTime = "", +StartTime = "", +TimeZone = "", +}}, +} + }); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_AddClassifications_AllParameters_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.AddClassificationsAsync("", new AtlasClassification[] + { +new AtlasClassification +{ +Attributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +TypeName = "", +LastModifiedTS = "", +EntityGuid = "", +EntityStatus = EntityStatus.Active, +RemovePropagationsOnEntityDelete = true, +ValidityPeriods = {new TimeBoundary +{ +EndTime = "", +StartTime = "", +TimeZone = "", +}}, +} + }); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_UpdateClassifications_ShortVersion() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object[] + { +new object() + }); + Response response = client.UpdateClassifications("", content); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_UpdateClassifications_ShortVersion_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object[] + { +new object() + }); + Response response = await client.UpdateClassificationsAsync("", content); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_UpdateClassifications_ShortVersion_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.UpdateClassifications("", new AtlasClassification[] + { +new AtlasClassification() + }); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_UpdateClassifications_ShortVersion_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.UpdateClassificationsAsync("", new AtlasClassification[] + { +new AtlasClassification() + }); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_UpdateClassifications_AllParameters() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object[] + { +new +{ +attributes = new +{ +key = new object(), +}, +typeName = "", +lastModifiedTS = "", +entityGuid = "", +entityStatus = "ACTIVE", +removePropagationsOnEntityDelete = true, +validityPeriods = new object[] +{ +new +{ +endTime = "", +startTime = "", +timeZone = "", +} +}, +} + }); + Response response = client.UpdateClassifications("", content); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_UpdateClassifications_AllParameters_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object[] + { +new +{ +attributes = new +{ +key = new object(), +}, +typeName = "", +lastModifiedTS = "", +entityGuid = "", +entityStatus = "ACTIVE", +removePropagationsOnEntityDelete = true, +validityPeriods = new object[] +{ +new +{ +endTime = "", +startTime = "", +timeZone = "", +} +}, +} + }); + Response response = await client.UpdateClassificationsAsync("", content); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_UpdateClassifications_AllParameters_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.UpdateClassifications("", new AtlasClassification[] + { +new AtlasClassification +{ +Attributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +TypeName = "", +LastModifiedTS = "", +EntityGuid = "", +EntityStatus = EntityStatus.Active, +RemovePropagationsOnEntityDelete = true, +ValidityPeriods = {new TimeBoundary +{ +EndTime = "", +StartTime = "", +TimeZone = "", +}}, +} + }); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_UpdateClassifications_AllParameters_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.UpdateClassificationsAsync("", new AtlasClassification[] + { +new AtlasClassification +{ +Attributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +TypeName = "", +LastModifiedTS = "", +EntityGuid = "", +EntityStatus = EntityStatus.Active, +RemovePropagationsOnEntityDelete = true, +ValidityPeriods = {new TimeBoundary +{ +EndTime = "", +StartTime = "", +TimeZone = "", +}}, +} + }); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_GetByAttributes_ShortVersion() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.GetByAttributes("", null, null, null, null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_GetByAttributes_ShortVersion_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.GetByAttributesAsync("", null, null, null, null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_GetByAttributes_ShortVersion_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.GetByAttributes(""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_GetByAttributes_ShortVersion_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.GetByAttributesAsync(""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_GetByAttributes_AllParameters() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.GetByAttributes("", true, true, "", null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("businessAttributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("createTime").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("customAttributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("homeId").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("collectionId").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("isIncomplete").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("labels")[0].ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("confidence").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("provenanceType").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("proxy").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("relationshipAttributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("updateTime").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("updatedBy").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("version").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("contacts").GetProperty("")[0].GetProperty("id").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("contacts").GetProperty("")[0].GetProperty("info").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("businessAttributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("createTime").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("customAttributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("homeId").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("collectionId").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("isIncomplete").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("labels")[0].ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("meanings")[0].GetProperty("confidence").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("meanings")[0].GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("meanings")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("meanings")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("meanings")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("meanings")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("meanings")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("meanings")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("provenanceType").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("proxy").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("relationshipAttributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("updateTime").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("updatedBy").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("version").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("contacts").GetProperty("")[0].GetProperty("id").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("contacts").GetProperty("")[0].GetProperty("info").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_GetByAttributes_AllParameters_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.GetByAttributesAsync("", true, true, "", null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("businessAttributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("createTime").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("customAttributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("homeId").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("collectionId").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("isIncomplete").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("labels")[0].ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("confidence").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("provenanceType").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("proxy").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("relationshipAttributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("updateTime").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("updatedBy").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("version").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("contacts").GetProperty("")[0].GetProperty("id").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("contacts").GetProperty("")[0].GetProperty("info").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("businessAttributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("createTime").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("customAttributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("homeId").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("collectionId").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("isIncomplete").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("labels")[0].ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("meanings")[0].GetProperty("confidence").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("meanings")[0].GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("meanings")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("meanings")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("meanings")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("meanings")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("meanings")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("meanings")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("provenanceType").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("proxy").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("relationshipAttributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("updateTime").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("updatedBy").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("version").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("contacts").GetProperty("")[0].GetProperty("id").ToString()); + Console.WriteLine(result.GetProperty("entity").GetProperty("contacts").GetProperty("")[0].GetProperty("info").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_GetByAttributes_AllParameters_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.GetByAttributes("", minExtInfo: true, ignoreRelationships: true, attr: ""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_GetByAttributes_AllParameters_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.GetByAttributesAsync("", minExtInfo: true, ignoreRelationships: true, attr: ""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_PartialUpdateByAttributes_ShortVersion() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object()); + Response response = client.PartialUpdateByAttributes("", content); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_PartialUpdateByAttributes_ShortVersion_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object()); + Response response = await client.PartialUpdateByAttributesAsync("", content); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_PartialUpdateByAttributes_ShortVersion_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + AtlasEntityWithExtInfo atlasEntityWithExtInfo = new AtlasEntityWithExtInfo(); + Response response = client.PartialUpdateByAttributes("", atlasEntityWithExtInfo); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_PartialUpdateByAttributes_ShortVersion_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + AtlasEntityWithExtInfo atlasEntityWithExtInfo = new AtlasEntityWithExtInfo(); + Response response = await client.PartialUpdateByAttributesAsync("", atlasEntityWithExtInfo); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_PartialUpdateByAttributes_AllParameters() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new + { + referredEntities = new + { + key = new + { + attributes = new + { + key = new object(), + }, + typeName = "", + lastModifiedTS = "", + businessAttributes = new + { + key = new object(), + }, + classifications = new object[] + { +new +{ +attributes = new +{ +key = new object(), +}, +typeName = "", +lastModifiedTS = "", +entityGuid = "", +entityStatus = "ACTIVE", +removePropagationsOnEntityDelete = true, +validityPeriods = new object[] +{ +new +{ +endTime = "", +startTime = "", +timeZone = "", +} +}, +} + }, + createTime = 1234L, + createdBy = "", + customAttributes = new + { + key = "", + }, + guid = "", + homeId = "", + isIncomplete = true, + labels = new object[] + { +"" + }, + meanings = new object[] + { +new +{ +confidence = 1234, +createdBy = "", +description = "", +displayText = "", +expression = "", +relationGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", +status = "DISCOVERED", +steward = "", +termGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", +} + }, + provenanceType = 1234, + proxy = true, + relationshipAttributes = new + { + key = new object(), + }, + status = "ACTIVE", + updateTime = 1234L, + updatedBy = "", + version = 1234L, + contacts = new + { + key = new object[] + { +new +{ +id = "", +info = "", +} + }, + }, + }, + }, + }); + Response response = client.PartialUpdateByAttributes("", content, attr: ""); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("guidAssignments").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classificationNames")[0].ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("isIncomplete").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("labels")[0].ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meaningNames")[0].ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("confidence").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classificationNames")[0].ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("isIncomplete").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("labels")[0].ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meaningNames")[0].ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("confidence").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("status").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_PartialUpdateByAttributes_AllParameters_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new + { + referredEntities = new + { + key = new + { + attributes = new + { + key = new object(), + }, + typeName = "", + lastModifiedTS = "", + businessAttributes = new + { + key = new object(), + }, + classifications = new object[] + { +new +{ +attributes = new +{ +key = new object(), +}, +typeName = "", +lastModifiedTS = "", +entityGuid = "", +entityStatus = "ACTIVE", +removePropagationsOnEntityDelete = true, +validityPeriods = new object[] +{ +new +{ +endTime = "", +startTime = "", +timeZone = "", +} +}, +} + }, + createTime = 1234L, + createdBy = "", + customAttributes = new + { + key = "", + }, + guid = "", + homeId = "", + isIncomplete = true, + labels = new object[] + { +"" + }, + meanings = new object[] + { +new +{ +confidence = 1234, +createdBy = "", +description = "", +displayText = "", +expression = "", +relationGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", +status = "DISCOVERED", +steward = "", +termGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", +} + }, + provenanceType = 1234, + proxy = true, + relationshipAttributes = new + { + key = new object(), + }, + status = "ACTIVE", + updateTime = 1234L, + updatedBy = "", + version = 1234L, + contacts = new + { + key = new object[] + { +new +{ +id = "", +info = "", +} + }, + }, + }, + }, + }); + Response response = await client.PartialUpdateByAttributesAsync("", content, attr: ""); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("guidAssignments").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classificationNames")[0].ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("isIncomplete").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("labels")[0].ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meaningNames")[0].ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("confidence").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classificationNames")[0].ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("isIncomplete").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("labels")[0].ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meaningNames")[0].ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("confidence").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("status").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_PartialUpdateByAttributes_AllParameters_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + AtlasEntityWithExtInfo atlasEntityWithExtInfo = new AtlasEntityWithExtInfo + { + ReferredEntities = +{ +["key"] = new AtlasEntity +{ +Attributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +TypeName = "", +LastModifiedTS = "", +BusinessAttributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +Classifications = {new AtlasClassification +{ +Attributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +TypeName = "", +LastModifiedTS = "", +EntityGuid = "", +EntityStatus = EntityStatus.Active, +RemovePropagationsOnEntityDelete = true, +ValidityPeriods = {new TimeBoundary +{ +EndTime = "", +StartTime = "", +TimeZone = "", +}}, +}}, +CreateTime = 1234L, +CreatedBy = "", +CustomAttributes = +{ +["key"] = "" +}, +Guid = "", +HomeId = "", +IsIncomplete = true, +Labels = {""}, +Meanings = {new AtlasTermAssignmentHeader +{ +Confidence = 1234, +CreatedBy = "", +Description = "", +DisplayText = "", +Expression = "", +RelationGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), +Status = AtlasTermAssignmentStatus.Discovered, +Steward = "", +TermGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), +}}, +ProvenanceType = 1234, +Proxy = true, +RelationshipAttributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +Status = EntityStatus.Active, +UpdateTime = 1234L, +UpdatedBy = "", +Version = 1234L, +Contacts = +{ +["key"] = {new ContactInfo +{ +Id = "", +Info = "", +}} +}, +} +}, + Entity = default, + }; + Response response = client.PartialUpdateByAttributes("", atlasEntityWithExtInfo, attr: ""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_PartialUpdateByAttributes_AllParameters_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + AtlasEntityWithExtInfo atlasEntityWithExtInfo = new AtlasEntityWithExtInfo + { + ReferredEntities = +{ +["key"] = new AtlasEntity +{ +Attributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +TypeName = "", +LastModifiedTS = "", +BusinessAttributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +Classifications = {new AtlasClassification +{ +Attributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +TypeName = "", +LastModifiedTS = "", +EntityGuid = "", +EntityStatus = EntityStatus.Active, +RemovePropagationsOnEntityDelete = true, +ValidityPeriods = {new TimeBoundary +{ +EndTime = "", +StartTime = "", +TimeZone = "", +}}, +}}, +CreateTime = 1234L, +CreatedBy = "", +CustomAttributes = +{ +["key"] = "" +}, +Guid = "", +HomeId = "", +IsIncomplete = true, +Labels = {""}, +Meanings = {new AtlasTermAssignmentHeader +{ +Confidence = 1234, +CreatedBy = "", +Description = "", +DisplayText = "", +Expression = "", +RelationGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), +Status = AtlasTermAssignmentStatus.Discovered, +Steward = "", +TermGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), +}}, +ProvenanceType = 1234, +Proxy = true, +RelationshipAttributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +Status = EntityStatus.Active, +UpdateTime = 1234L, +UpdatedBy = "", +Version = 1234L, +Contacts = +{ +["key"] = {new ContactInfo +{ +Id = "", +Info = "", +}} +}, +} +}, + Entity = default, + }; + Response response = await client.PartialUpdateByAttributesAsync("", atlasEntityWithExtInfo, attr: ""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_DeleteByAttribute_ShortVersion() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.DeleteByAttribute("", null, null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_DeleteByAttribute_ShortVersion_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.DeleteByAttributeAsync("", null, null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_DeleteByAttribute_ShortVersion_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.DeleteByAttribute(""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_DeleteByAttribute_ShortVersion_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.DeleteByAttributeAsync(""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_DeleteByAttribute_AllParameters() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.DeleteByAttribute("", "", null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("guidAssignments").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classificationNames")[0].ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("isIncomplete").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("labels")[0].ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meaningNames")[0].ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("confidence").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classificationNames")[0].ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("isIncomplete").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("labels")[0].ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meaningNames")[0].ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("confidence").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("status").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_DeleteByAttribute_AllParameters_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.DeleteByAttributeAsync("", "", null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("guidAssignments").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classificationNames")[0].ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("isIncomplete").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("labels")[0].ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meaningNames")[0].ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("confidence").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classificationNames")[0].ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("isIncomplete").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("labels")[0].ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meaningNames")[0].ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("confidence").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("status").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_DeleteByAttribute_AllParameters_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.DeleteByAttribute("", attr: ""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_DeleteByAttribute_AllParameters_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.DeleteByAttributeAsync("", attr: ""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_RemoveClassificationByAttribute_ShortVersion() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.RemoveClassificationByAttribute("", ""); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_RemoveClassificationByAttribute_ShortVersion_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.RemoveClassificationByAttributeAsync("", ""); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_RemoveClassificationByAttribute_AllParameters() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.RemoveClassificationByAttribute("", "", attr: ""); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_RemoveClassificationByAttribute_AllParameters_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.RemoveClassificationByAttributeAsync("", "", attr: ""); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_AddClassificationsByAttribute_ShortVersion() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object[] + { +new object() + }); + Response response = client.AddClassificationsByAttribute("", content); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_AddClassificationsByAttribute_ShortVersion_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object[] + { +new object() + }); + Response response = await client.AddClassificationsByAttributeAsync("", content); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_AddClassificationsByAttribute_ShortVersion_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.AddClassificationsByAttribute("", new AtlasClassification[] + { +new AtlasClassification() + }); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_AddClassificationsByAttribute_ShortVersion_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.AddClassificationsByAttributeAsync("", new AtlasClassification[] + { +new AtlasClassification() + }); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_AddClassificationsByAttribute_AllParameters() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object[] + { +new +{ +attributes = new +{ +key = new object(), +}, +typeName = "", +lastModifiedTS = "", +entityGuid = "", +entityStatus = "ACTIVE", +removePropagationsOnEntityDelete = true, +validityPeriods = new object[] +{ +new +{ +endTime = "", +startTime = "", +timeZone = "", +} +}, +} + }); + Response response = client.AddClassificationsByAttribute("", content, attr: ""); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_AddClassificationsByAttribute_AllParameters_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object[] + { +new +{ +attributes = new +{ +key = new object(), +}, +typeName = "", +lastModifiedTS = "", +entityGuid = "", +entityStatus = "ACTIVE", +removePropagationsOnEntityDelete = true, +validityPeriods = new object[] +{ +new +{ +endTime = "", +startTime = "", +timeZone = "", +} +}, +} + }); + Response response = await client.AddClassificationsByAttributeAsync("", content, attr: ""); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_AddClassificationsByAttribute_AllParameters_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.AddClassificationsByAttribute("", new AtlasClassification[] + { +new AtlasClassification +{ +Attributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +TypeName = "", +LastModifiedTS = "", +EntityGuid = "", +EntityStatus = EntityStatus.Active, +RemovePropagationsOnEntityDelete = true, +ValidityPeriods = {new TimeBoundary +{ +EndTime = "", +StartTime = "", +TimeZone = "", +}}, +} + }, attr: ""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_AddClassificationsByAttribute_AllParameters_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.AddClassificationsByAttributeAsync("", new AtlasClassification[] + { +new AtlasClassification +{ +Attributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +TypeName = "", +LastModifiedTS = "", +EntityGuid = "", +EntityStatus = EntityStatus.Active, +RemovePropagationsOnEntityDelete = true, +ValidityPeriods = {new TimeBoundary +{ +EndTime = "", +StartTime = "", +TimeZone = "", +}}, +} + }, attr: ""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_UpdateClassificationsByAttribute_ShortVersion() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object[] + { +new object() + }); + Response response = client.UpdateClassificationsByAttribute("", content); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_UpdateClassificationsByAttribute_ShortVersion_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object[] + { +new object() + }); + Response response = await client.UpdateClassificationsByAttributeAsync("", content); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_UpdateClassificationsByAttribute_ShortVersion_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.UpdateClassificationsByAttribute("", new AtlasClassification[] + { +new AtlasClassification() + }); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_UpdateClassificationsByAttribute_ShortVersion_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.UpdateClassificationsByAttributeAsync("", new AtlasClassification[] + { +new AtlasClassification() + }); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_UpdateClassificationsByAttribute_AllParameters() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object[] + { +new +{ +attributes = new +{ +key = new object(), +}, +typeName = "", +lastModifiedTS = "", +entityGuid = "", +entityStatus = "ACTIVE", +removePropagationsOnEntityDelete = true, +validityPeriods = new object[] +{ +new +{ +endTime = "", +startTime = "", +timeZone = "", +} +}, +} + }); + Response response = client.UpdateClassificationsByAttribute("", content, attr: ""); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_UpdateClassificationsByAttribute_AllParameters_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object[] + { +new +{ +attributes = new +{ +key = new object(), +}, +typeName = "", +lastModifiedTS = "", +entityGuid = "", +entityStatus = "ACTIVE", +removePropagationsOnEntityDelete = true, +validityPeriods = new object[] +{ +new +{ +endTime = "", +startTime = "", +timeZone = "", +} +}, +} + }); + Response response = await client.UpdateClassificationsByAttributeAsync("", content, attr: ""); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_UpdateClassificationsByAttribute_AllParameters_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.UpdateClassificationsByAttribute("", new AtlasClassification[] + { +new AtlasClassification +{ +Attributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +TypeName = "", +LastModifiedTS = "", +EntityGuid = "", +EntityStatus = EntityStatus.Active, +RemovePropagationsOnEntityDelete = true, +ValidityPeriods = {new TimeBoundary +{ +EndTime = "", +StartTime = "", +TimeZone = "", +}}, +} + }, attr: ""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_UpdateClassificationsByAttribute_AllParameters_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.UpdateClassificationsByAttributeAsync("", new AtlasClassification[] + { +new AtlasClassification +{ +Attributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +TypeName = "", +LastModifiedTS = "", +EntityGuid = "", +EntityStatus = EntityStatus.Active, +RemovePropagationsOnEntityDelete = true, +ValidityPeriods = {new TimeBoundary +{ +EndTime = "", +StartTime = "", +TimeZone = "", +}}, +} + }, attr: ""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_BatchSetClassifications_ShortVersion() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object()); + Response response = client.BatchSetClassifications(content); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result[0].ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_BatchSetClassifications_ShortVersion_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object()); + Response response = await client.BatchSetClassificationsAsync(content); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result[0].ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_BatchSetClassifications_ShortVersion_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + AtlasEntityHeaders entityHeaders = new AtlasEntityHeaders(); + Response> response = client.BatchSetClassifications(entityHeaders); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_BatchSetClassifications_ShortVersion_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + AtlasEntityHeaders entityHeaders = new AtlasEntityHeaders(); + Response> response = await client.BatchSetClassificationsAsync(entityHeaders); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_BatchSetClassifications_AllParameters() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new + { + guidHeaderMap = new + { + key = new + { + attributes = new + { + key = new object(), + }, + typeName = "", + lastModifiedTS = "", + classificationNames = new object[] + { +"" + }, + classifications = new object[] + { +new +{ +attributes = new +{ +key = new object(), +}, +typeName = "", +lastModifiedTS = "", +entityGuid = "", +entityStatus = "ACTIVE", +removePropagationsOnEntityDelete = true, +validityPeriods = new object[] +{ +new +{ +endTime = "", +startTime = "", +timeZone = "", +} +}, +} + }, + displayText = "", + guid = "", + isIncomplete = true, + labels = new object[] + { +"" + }, + meaningNames = new object[] + { +"" + }, + meanings = new object[] + { +new +{ +confidence = 1234, +createdBy = "", +description = "", +displayText = "", +expression = "", +relationGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", +status = "DISCOVERED", +steward = "", +termGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", +} + }, + status = "ACTIVE", + }, + }, + }); + Response response = client.BatchSetClassifications(content); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result[0].ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_BatchSetClassifications_AllParameters_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new + { + guidHeaderMap = new + { + key = new + { + attributes = new + { + key = new object(), + }, + typeName = "", + lastModifiedTS = "", + classificationNames = new object[] + { +"" + }, + classifications = new object[] + { +new +{ +attributes = new +{ +key = new object(), +}, +typeName = "", +lastModifiedTS = "", +entityGuid = "", +entityStatus = "ACTIVE", +removePropagationsOnEntityDelete = true, +validityPeriods = new object[] +{ +new +{ +endTime = "", +startTime = "", +timeZone = "", +} +}, +} + }, + displayText = "", + guid = "", + isIncomplete = true, + labels = new object[] + { +"" + }, + meaningNames = new object[] + { +"" + }, + meanings = new object[] + { +new +{ +confidence = 1234, +createdBy = "", +description = "", +displayText = "", +expression = "", +relationGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", +status = "DISCOVERED", +steward = "", +termGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", +} + }, + status = "ACTIVE", + }, + }, + }); + Response response = await client.BatchSetClassificationsAsync(content); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result[0].ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_BatchSetClassifications_AllParameters_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + AtlasEntityHeaders entityHeaders = new AtlasEntityHeaders + { + GuidHeaderMap = +{ +["key"] = new AtlasEntityHeader +{ +Attributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +TypeName = "", +LastModifiedTS = "", +ClassificationNames = {""}, +Classifications = {new AtlasClassification +{ +Attributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +TypeName = "", +LastModifiedTS = "", +EntityGuid = "", +EntityStatus = EntityStatus.Active, +RemovePropagationsOnEntityDelete = true, +ValidityPeriods = {new TimeBoundary +{ +EndTime = "", +StartTime = "", +TimeZone = "", +}}, +}}, +DisplayText = "", +Guid = "", +IsIncomplete = true, +Labels = {""}, +MeaningNames = {""}, +Meanings = {new AtlasTermAssignmentHeader +{ +Confidence = 1234, +CreatedBy = "", +Description = "", +DisplayText = "", +Expression = "", +RelationGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), +Status = AtlasTermAssignmentStatus.Discovered, +Steward = "", +TermGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), +}}, +Status = EntityStatus.Active, +} +}, + }; + Response> response = client.BatchSetClassifications(entityHeaders); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_BatchSetClassifications_AllParameters_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + AtlasEntityHeaders entityHeaders = new AtlasEntityHeaders + { + GuidHeaderMap = +{ +["key"] = new AtlasEntityHeader +{ +Attributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +TypeName = "", +LastModifiedTS = "", +ClassificationNames = {""}, +Classifications = {new AtlasClassification +{ +Attributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +TypeName = "", +LastModifiedTS = "", +EntityGuid = "", +EntityStatus = EntityStatus.Active, +RemovePropagationsOnEntityDelete = true, +ValidityPeriods = {new TimeBoundary +{ +EndTime = "", +StartTime = "", +TimeZone = "", +}}, +}}, +DisplayText = "", +Guid = "", +IsIncomplete = true, +Labels = {""}, +MeaningNames = {""}, +Meanings = {new AtlasTermAssignmentHeader +{ +Confidence = 1234, +CreatedBy = "", +Description = "", +DisplayText = "", +Expression = "", +RelationGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), +Status = AtlasTermAssignmentStatus.Discovered, +Steward = "", +TermGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), +}}, +Status = EntityStatus.Active, +} +}, + }; + Response> response = await client.BatchSetClassificationsAsync(entityHeaders); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_BatchGetByAttributes_ShortVersion() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.BatchGetByAttributes("", null, null, null, null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_BatchGetByAttributes_ShortVersion_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.BatchGetByAttributesAsync("", null, null, null, null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_BatchGetByAttributes_ShortVersion_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.BatchGetByAttributes(""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_BatchGetByAttributes_ShortVersion_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.BatchGetByAttributesAsync(""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_BatchGetByAttributes_AllParameters() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.BatchGetByAttributes("", true, true, "", null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("businessAttributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("createTime").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("customAttributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("homeId").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("collectionId").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("isIncomplete").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("labels")[0].ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("confidence").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("provenanceType").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("proxy").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("relationshipAttributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("updateTime").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("updatedBy").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("version").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("contacts").GetProperty("")[0].GetProperty("id").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("contacts").GetProperty("")[0].GetProperty("info").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("businessAttributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("createTime").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("customAttributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("homeId").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("collectionId").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("isIncomplete").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("labels")[0].ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("meanings")[0].GetProperty("confidence").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("meanings")[0].GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("meanings")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("meanings")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("meanings")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("meanings")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("meanings")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("meanings")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("provenanceType").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("proxy").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("relationshipAttributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("updateTime").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("updatedBy").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("version").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("contacts").GetProperty("")[0].GetProperty("id").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("contacts").GetProperty("")[0].GetProperty("info").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_BatchGetByAttributes_AllParameters_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.BatchGetByAttributesAsync("", true, true, "", null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("businessAttributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("createTime").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("customAttributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("homeId").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("collectionId").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("isIncomplete").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("labels")[0].ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("confidence").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("meanings")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("provenanceType").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("proxy").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("relationshipAttributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("updateTime").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("updatedBy").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("version").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("contacts").GetProperty("")[0].GetProperty("id").ToString()); + Console.WriteLine(result.GetProperty("referredEntities").GetProperty("").GetProperty("contacts").GetProperty("")[0].GetProperty("info").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("businessAttributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("createTime").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("customAttributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("homeId").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("collectionId").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("isIncomplete").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("labels")[0].ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("meanings")[0].GetProperty("confidence").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("meanings")[0].GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("meanings")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("meanings")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("meanings")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("meanings")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("meanings")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("meanings")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("provenanceType").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("proxy").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("relationshipAttributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("updateTime").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("updatedBy").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("version").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("contacts").GetProperty("")[0].GetProperty("id").ToString()); + Console.WriteLine(result.GetProperty("entities")[0].GetProperty("contacts").GetProperty("")[0].GetProperty("info").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_BatchGetByAttributes_AllParameters_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.BatchGetByAttributes("", minExtInfo: true, ignoreRelationships: true, attrNQualifiedName: ""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_BatchGetByAttributes_AllParameters_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.BatchGetByAttributesAsync("", minExtInfo: true, ignoreRelationships: true, attrNQualifiedName: ""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_GetHeader_ShortVersion() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.GetHeader("", null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_GetHeader_ShortVersion_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.GetHeaderAsync("", null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_GetHeader_ShortVersion_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.GetHeader(""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_GetHeader_ShortVersion_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.GetHeaderAsync(""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_GetHeader_AllParameters() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.GetHeader("", null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("classificationNames")[0].ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("isIncomplete").ToString()); + Console.WriteLine(result.GetProperty("labels")[0].ToString()); + Console.WriteLine(result.GetProperty("meaningNames")[0].ToString()); + Console.WriteLine(result.GetProperty("meanings")[0].GetProperty("confidence").ToString()); + Console.WriteLine(result.GetProperty("meanings")[0].GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("meanings")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("meanings")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("meanings")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("meanings")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("meanings")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("meanings")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("status").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_GetHeader_AllParameters_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.GetHeaderAsync("", null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("classificationNames")[0].ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("isIncomplete").ToString()); + Console.WriteLine(result.GetProperty("labels")[0].ToString()); + Console.WriteLine(result.GetProperty("meaningNames")[0].ToString()); + Console.WriteLine(result.GetProperty("meanings")[0].GetProperty("confidence").ToString()); + Console.WriteLine(result.GetProperty("meanings")[0].GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("meanings")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("meanings")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("meanings")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("meanings")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("meanings")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("meanings")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("status").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_GetHeader_AllParameters_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.GetHeader(""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_GetHeader_AllParameters_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.GetHeaderAsync(""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_RemoveBusinessMetadata_ShortVersion() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new + { + key = new + { + key = new object(), + }, + }); + Response response = client.RemoveBusinessMetadata("", content); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_RemoveBusinessMetadata_ShortVersion_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new + { + key = new + { + key = new object(), + }, + }); + Response response = await client.RemoveBusinessMetadataAsync("", content); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_RemoveBusinessMetadata_ShortVersion_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.RemoveBusinessMetadata("", new Dictionary> + { + ["key"] = new Dictionary + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + } + }); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_RemoveBusinessMetadata_ShortVersion_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.RemoveBusinessMetadataAsync("", new Dictionary> + { + ["key"] = new Dictionary + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + } + }); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_RemoveBusinessMetadata_AllParameters() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new + { + key = new + { + key = new object(), + }, + }); + Response response = client.RemoveBusinessMetadata("", content); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_RemoveBusinessMetadata_AllParameters_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new + { + key = new + { + key = new object(), + }, + }); + Response response = await client.RemoveBusinessMetadataAsync("", content); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_RemoveBusinessMetadata_AllParameters_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.RemoveBusinessMetadata("", new Dictionary> + { + ["key"] = new Dictionary + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + } + }); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_RemoveBusinessMetadata_AllParameters_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.RemoveBusinessMetadataAsync("", new Dictionary> + { + ["key"] = new Dictionary + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + } + }); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_AddOrUpdateBusinessMetadata_ShortVersion() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new + { + key = new + { + key = new object(), + }, + }); + Response response = client.AddOrUpdateBusinessMetadata("", content); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_AddOrUpdateBusinessMetadata_ShortVersion_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new + { + key = new + { + key = new object(), + }, + }); + Response response = await client.AddOrUpdateBusinessMetadataAsync("", content); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_AddOrUpdateBusinessMetadata_ShortVersion_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.AddOrUpdateBusinessMetadata("", new Dictionary> + { + ["key"] = new Dictionary + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + } + }); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_AddOrUpdateBusinessMetadata_ShortVersion_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.AddOrUpdateBusinessMetadataAsync("", new Dictionary> + { + ["key"] = new Dictionary + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + } + }); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_AddOrUpdateBusinessMetadata_AllParameters() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new + { + key = new + { + key = new object(), + }, + }); + Response response = client.AddOrUpdateBusinessMetadata("", content, isOverwrite: true); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_AddOrUpdateBusinessMetadata_AllParameters_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new + { + key = new + { + key = new object(), + }, + }); + Response response = await client.AddOrUpdateBusinessMetadataAsync("", content, isOverwrite: true); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_AddOrUpdateBusinessMetadata_AllParameters_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.AddOrUpdateBusinessMetadata("", new Dictionary> + { + ["key"] = new Dictionary + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + } + }, isOverwrite: true); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_AddOrUpdateBusinessMetadata_AllParameters_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.AddOrUpdateBusinessMetadataAsync("", new Dictionary> + { + ["key"] = new Dictionary + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + } + }, isOverwrite: true); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_RemoveBusinessMetadataAttributes_ShortVersion() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new + { + key = new object(), + }); + Response response = client.RemoveBusinessMetadataAttributes("", "", content); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_RemoveBusinessMetadataAttributes_ShortVersion_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new + { + key = new object(), + }); + Response response = await client.RemoveBusinessMetadataAttributesAsync("", "", content); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_RemoveBusinessMetadataAttributes_ShortVersion_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.RemoveBusinessMetadataAttributes("", "", new Dictionary + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_RemoveBusinessMetadataAttributes_ShortVersion_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.RemoveBusinessMetadataAttributesAsync("", "", new Dictionary + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_RemoveBusinessMetadataAttributes_AllParameters() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new + { + key = new object(), + }); + Response response = client.RemoveBusinessMetadataAttributes("", "", content); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_RemoveBusinessMetadataAttributes_AllParameters_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new + { + key = new object(), + }); + Response response = await client.RemoveBusinessMetadataAttributesAsync("", "", content); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_RemoveBusinessMetadataAttributes_AllParameters_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.RemoveBusinessMetadataAttributes("", "", new Dictionary + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_RemoveBusinessMetadataAttributes_AllParameters_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.RemoveBusinessMetadataAttributesAsync("", "", new Dictionary + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_AddOrUpdateBusinessMetadataAttributes_ShortVersion() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new + { + key = new object(), + }); + Response response = client.AddOrUpdateBusinessMetadataAttributes("", "", content); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_AddOrUpdateBusinessMetadataAttributes_ShortVersion_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new + { + key = new object(), + }); + Response response = await client.AddOrUpdateBusinessMetadataAttributesAsync("", "", content); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_AddOrUpdateBusinessMetadataAttributes_ShortVersion_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.AddOrUpdateBusinessMetadataAttributes("", "", new Dictionary + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_AddOrUpdateBusinessMetadataAttributes_ShortVersion_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.AddOrUpdateBusinessMetadataAttributesAsync("", "", new Dictionary + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_AddOrUpdateBusinessMetadataAttributes_AllParameters() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new + { + key = new object(), + }); + Response response = client.AddOrUpdateBusinessMetadataAttributes("", "", content); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_AddOrUpdateBusinessMetadataAttributes_AllParameters_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new + { + key = new object(), + }); + Response response = await client.AddOrUpdateBusinessMetadataAttributesAsync("", "", content); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_AddOrUpdateBusinessMetadataAttributes_AllParameters_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.AddOrUpdateBusinessMetadataAttributes("", "", new Dictionary + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_AddOrUpdateBusinessMetadataAttributes_AllParameters_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.AddOrUpdateBusinessMetadataAttributesAsync("", "", new Dictionary + { + ["key"] = BinaryData.FromObjectAsJson(new object()) + }); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_GetSampleBusinessMetadataTemplate_ShortVersion() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.GetSampleBusinessMetadataTemplate(null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_GetSampleBusinessMetadataTemplate_ShortVersion_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.GetSampleBusinessMetadataTemplateAsync(null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_GetSampleBusinessMetadataTemplate_ShortVersion_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.GetSampleBusinessMetadataTemplate(); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_GetSampleBusinessMetadataTemplate_ShortVersion_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.GetSampleBusinessMetadataTemplateAsync(); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_GetSampleBusinessMetadataTemplate_AllParameters() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.GetSampleBusinessMetadataTemplate(null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_GetSampleBusinessMetadataTemplate_AllParameters_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.GetSampleBusinessMetadataTemplateAsync(null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_GetSampleBusinessMetadataTemplate_AllParameters_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.GetSampleBusinessMetadataTemplate(); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_GetSampleBusinessMetadataTemplate_AllParameters_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.GetSampleBusinessMetadataTemplateAsync(); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_ImportBusinessMetadata_ShortVersion() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new + { + uploadedInputStream = new object(), + }); + Response response = client.ImportBusinessMetadata(content); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_ImportBusinessMetadata_ShortVersion_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new + { + uploadedInputStream = new object(), + }); + Response response = await client.ImportBusinessMetadataAsync(content); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_ImportBusinessMetadata_ShortVersion_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.ImportBusinessMetadata(BinaryData.FromObjectAsJson(new object())); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_ImportBusinessMetadata_ShortVersion_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.ImportBusinessMetadataAsync(BinaryData.FromObjectAsJson(new object())); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_ImportBusinessMetadata_AllParameters() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new + { + uploadedInputStream = new object(), + }); + Response response = client.ImportBusinessMetadata(content); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("failedImportInfoList")[0].GetProperty("childObjectName").ToString()); + Console.WriteLine(result.GetProperty("failedImportInfoList")[0].GetProperty("importStatus").ToString()); + Console.WriteLine(result.GetProperty("failedImportInfoList")[0].GetProperty("parentObjectName").ToString()); + Console.WriteLine(result.GetProperty("failedImportInfoList")[0].GetProperty("remarks").ToString()); + Console.WriteLine(result.GetProperty("successImportInfoList")[0].GetProperty("childObjectName").ToString()); + Console.WriteLine(result.GetProperty("successImportInfoList")[0].GetProperty("importStatus").ToString()); + Console.WriteLine(result.GetProperty("successImportInfoList")[0].GetProperty("parentObjectName").ToString()); + Console.WriteLine(result.GetProperty("successImportInfoList")[0].GetProperty("remarks").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_ImportBusinessMetadata_AllParameters_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new + { + uploadedInputStream = new object(), + }); + Response response = await client.ImportBusinessMetadataAsync(content); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("failedImportInfoList")[0].GetProperty("childObjectName").ToString()); + Console.WriteLine(result.GetProperty("failedImportInfoList")[0].GetProperty("importStatus").ToString()); + Console.WriteLine(result.GetProperty("failedImportInfoList")[0].GetProperty("parentObjectName").ToString()); + Console.WriteLine(result.GetProperty("failedImportInfoList")[0].GetProperty("remarks").ToString()); + Console.WriteLine(result.GetProperty("successImportInfoList")[0].GetProperty("childObjectName").ToString()); + Console.WriteLine(result.GetProperty("successImportInfoList")[0].GetProperty("importStatus").ToString()); + Console.WriteLine(result.GetProperty("successImportInfoList")[0].GetProperty("parentObjectName").ToString()); + Console.WriteLine(result.GetProperty("successImportInfoList")[0].GetProperty("remarks").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_ImportBusinessMetadata_AllParameters_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.ImportBusinessMetadata(BinaryData.FromObjectAsJson(new object())); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_ImportBusinessMetadata_AllParameters_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.ImportBusinessMetadataAsync(BinaryData.FromObjectAsJson(new object())); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_RemoveLabels_ShortVersion() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object[] + { +"" + }); + Response response = client.RemoveLabels("", content); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_RemoveLabels_ShortVersion_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object[] + { +"" + }); + Response response = await client.RemoveLabelsAsync("", content); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_RemoveLabels_ShortVersion_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.RemoveLabels("", new string[] { "" }); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_RemoveLabels_ShortVersion_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.RemoveLabelsAsync("", new string[] { "" }); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_RemoveLabels_AllParameters() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object[] + { +"" + }); + Response response = client.RemoveLabels("", content); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_RemoveLabels_AllParameters_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object[] + { +"" + }); + Response response = await client.RemoveLabelsAsync("", content); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_RemoveLabels_AllParameters_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.RemoveLabels("", new string[] { "" }); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_RemoveLabels_AllParameters_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.RemoveLabelsAsync("", new string[] { "" }); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_SetLabels_ShortVersion() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object[] + { +"" + }); + Response response = client.SetLabels("", content); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_SetLabels_ShortVersion_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object[] + { +"" + }); + Response response = await client.SetLabelsAsync("", content); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_SetLabels_ShortVersion_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.SetLabels("", new string[] { "" }); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_SetLabels_ShortVersion_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.SetLabelsAsync("", new string[] { "" }); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_SetLabels_AllParameters() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object[] + { +"" + }); + Response response = client.SetLabels("", content); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_SetLabels_AllParameters_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object[] + { +"" + }); + Response response = await client.SetLabelsAsync("", content); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_SetLabels_AllParameters_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.SetLabels("", new string[] { "" }); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_SetLabels_AllParameters_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.SetLabelsAsync("", new string[] { "" }); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_AddLabel_ShortVersion() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object[] + { +"" + }); + Response response = client.AddLabel("", content); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_AddLabel_ShortVersion_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object[] + { +"" + }); + Response response = await client.AddLabelAsync("", content); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_AddLabel_ShortVersion_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.AddLabel("", new string[] { "" }); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_AddLabel_ShortVersion_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.AddLabelAsync("", new string[] { "" }); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_AddLabel_AllParameters() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object[] + { +"" + }); + Response response = client.AddLabel("", content); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_AddLabel_AllParameters_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object[] + { +"" + }); + Response response = await client.AddLabelAsync("", content); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_AddLabel_AllParameters_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.AddLabel("", new string[] { "" }); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_AddLabel_AllParameters_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.AddLabelAsync("", new string[] { "" }); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_RemoveLabelsByAttribute_ShortVersion() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object[] + { +"" + }); + Response response = client.RemoveLabelsByAttribute("", content); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_RemoveLabelsByAttribute_ShortVersion_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object[] + { +"" + }); + Response response = await client.RemoveLabelsByAttributeAsync("", content); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_RemoveLabelsByAttribute_ShortVersion_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.RemoveLabelsByAttribute("", new string[] { "" }); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_RemoveLabelsByAttribute_ShortVersion_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.RemoveLabelsByAttributeAsync("", new string[] { "" }); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_RemoveLabelsByAttribute_AllParameters() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object[] + { +"" + }); + Response response = client.RemoveLabelsByAttribute("", content, attr: ""); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_RemoveLabelsByAttribute_AllParameters_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object[] + { +"" + }); + Response response = await client.RemoveLabelsByAttributeAsync("", content, attr: ""); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_RemoveLabelsByAttribute_AllParameters_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.RemoveLabelsByAttribute("", new string[] { "" }, attr: ""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_RemoveLabelsByAttribute_AllParameters_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.RemoveLabelsByAttributeAsync("", new string[] { "" }, attr: ""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_SetLabelsByAttribute_ShortVersion() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object[] + { +"" + }); + Response response = client.SetLabelsByAttribute("", content); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_SetLabelsByAttribute_ShortVersion_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object[] + { +"" + }); + Response response = await client.SetLabelsByAttributeAsync("", content); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_SetLabelsByAttribute_ShortVersion_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.SetLabelsByAttribute("", new string[] { "" }); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_SetLabelsByAttribute_ShortVersion_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.SetLabelsByAttributeAsync("", new string[] { "" }); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_SetLabelsByAttribute_AllParameters() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object[] + { +"" + }); + Response response = client.SetLabelsByAttribute("", content, attr: ""); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_SetLabelsByAttribute_AllParameters_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object[] + { +"" + }); + Response response = await client.SetLabelsByAttributeAsync("", content, attr: ""); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_SetLabelsByAttribute_AllParameters_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.SetLabelsByAttribute("", new string[] { "" }, attr: ""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_SetLabelsByAttribute_AllParameters_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.SetLabelsByAttributeAsync("", new string[] { "" }, attr: ""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_AddLabelsByAttribute_ShortVersion() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object[] + { +"" + }); + Response response = client.AddLabelsByAttribute("", content); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_AddLabelsByAttribute_ShortVersion_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object[] + { +"" + }); + Response response = await client.AddLabelsByAttributeAsync("", content); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_AddLabelsByAttribute_ShortVersion_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.AddLabelsByAttribute("", new string[] { "" }); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_AddLabelsByAttribute_ShortVersion_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.AddLabelsByAttributeAsync("", new string[] { "" }); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_AddLabelsByAttribute_AllParameters() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object[] + { +"" + }); + Response response = client.AddLabelsByAttribute("", content, attr: ""); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_AddLabelsByAttribute_AllParameters_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object[] + { +"" + }); + Response response = await client.AddLabelsByAttributeAsync("", content, attr: ""); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_AddLabelsByAttribute_AllParameters_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = client.AddLabelsByAttribute("", new string[] { "" }, attr: ""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_AddLabelsByAttribute_AllParameters_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + Response response = await client.AddLabelsByAttributeAsync("", new string[] { "" }, attr: ""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_MoveEntitiesToCollection_ShortVersion() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object()); + Response response = client.MoveEntitiesToCollection("", content); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_MoveEntitiesToCollection_ShortVersion_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object()); + Response response = await client.MoveEntitiesToCollectionAsync("", content); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_MoveEntitiesToCollection_ShortVersion_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + MoveEntitiesOptions moveEntitiesRequest = new MoveEntitiesOptions(); + Response response = client.MoveEntitiesToCollection("", moveEntitiesRequest); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_MoveEntitiesToCollection_ShortVersion_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + MoveEntitiesOptions moveEntitiesRequest = new MoveEntitiesOptions(); + Response response = await client.MoveEntitiesToCollectionAsync("", moveEntitiesRequest); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_MoveEntitiesToCollection_AllParameters() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new + { + entityGuids = new object[] + { +"" + }, + }); + Response response = client.MoveEntitiesToCollection("", content); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("guidAssignments").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classificationNames")[0].ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("isIncomplete").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("labels")[0].ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meaningNames")[0].ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("confidence").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classificationNames")[0].ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("isIncomplete").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("labels")[0].ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meaningNames")[0].ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("confidence").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("status").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_MoveEntitiesToCollection_AllParameters_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new + { + entityGuids = new object[] + { +"" + }, + }); + Response response = await client.MoveEntitiesToCollectionAsync("", content); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("guidAssignments").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classificationNames")[0].ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("isIncomplete").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("labels")[0].ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meaningNames")[0].ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("confidence").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("meanings")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("mutatedEntities").GetProperty("")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classificationNames")[0].ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("isIncomplete").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("labels")[0].ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meaningNames")[0].ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("confidence").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("meanings")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("partialUpdatedEntities")[0].GetProperty("status").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Entity_MoveEntitiesToCollection_AllParameters_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + MoveEntitiesOptions moveEntitiesRequest = new MoveEntitiesOptions + { + EntityGuids = { "" }, + }; + Response response = client.MoveEntitiesToCollection("", moveEntitiesRequest); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Entity_MoveEntitiesToCollection_AllParameters_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Entity client = new DataMapClient(endpoint, credential).GetEntityClient(apiVersion: "2023-09-01"); + + MoveEntitiesOptions moveEntitiesRequest = new MoveEntitiesOptions + { + EntityGuids = { "" }, + }; + Response response = await client.MoveEntitiesToCollectionAsync("", moveEntitiesRequest); + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/tests/Generated/Samples/Samples_Glossary.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/tests/Generated/Samples/Samples_Glossary.cs new file mode 100644 index 0000000000000..193b66be717ef --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/tests/Generated/Samples/Samples_Glossary.cs @@ -0,0 +1,9322 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Collections.Generic; +using System.Text.Json; +using System.Threading.Tasks; +using Azure; +using Azure.Analytics.Purview.DataMap; +using Azure.Core; +using Azure.Identity; +using NUnit.Framework; + +namespace Azure.Analytics.Purview.DataMap.Samples +{ + public partial class Samples_Glossary + { + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_BatchGet_ShortVersion() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = client.BatchGet(null, null, null, null, null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result[0].ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_BatchGet_ShortVersion_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = await client.BatchGetAsync(null, null, null, null, null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result[0].ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_BatchGet_ShortVersion_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response> response = client.BatchGet(); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_BatchGet_ShortVersion_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response> response = await client.BatchGetAsync(); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_BatchGet_AllParameters() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = client.BatchGet(1234, 1234, "", true, null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result[0].GetProperty("guid").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result[0].GetProperty("longDescription").ToString()); + Console.WriteLine(result[0].GetProperty("name").ToString()); + Console.WriteLine(result[0].GetProperty("qualifiedName").ToString()); + Console.WriteLine(result[0].GetProperty("shortDescription").ToString()); + Console.WriteLine(result[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result[0].GetProperty("createTime").ToString()); + Console.WriteLine(result[0].GetProperty("createdBy").ToString()); + Console.WriteLine(result[0].GetProperty("updateTime").ToString()); + Console.WriteLine(result[0].GetProperty("updatedBy").ToString()); + Console.WriteLine(result[0].GetProperty("categories")[0].GetProperty("categoryGuid").ToString()); + Console.WriteLine(result[0].GetProperty("categories")[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("categories")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("categories")[0].GetProperty("parentCategoryGuid").ToString()); + Console.WriteLine(result[0].GetProperty("categories")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("language").ToString()); + Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("status").ToString()); + Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result[0].GetProperty("usage").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_BatchGet_AllParameters_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = await client.BatchGetAsync(1234, 1234, "", true, null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result[0].GetProperty("guid").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result[0].GetProperty("longDescription").ToString()); + Console.WriteLine(result[0].GetProperty("name").ToString()); + Console.WriteLine(result[0].GetProperty("qualifiedName").ToString()); + Console.WriteLine(result[0].GetProperty("shortDescription").ToString()); + Console.WriteLine(result[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result[0].GetProperty("createTime").ToString()); + Console.WriteLine(result[0].GetProperty("createdBy").ToString()); + Console.WriteLine(result[0].GetProperty("updateTime").ToString()); + Console.WriteLine(result[0].GetProperty("updatedBy").ToString()); + Console.WriteLine(result[0].GetProperty("categories")[0].GetProperty("categoryGuid").ToString()); + Console.WriteLine(result[0].GetProperty("categories")[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("categories")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("categories")[0].GetProperty("parentCategoryGuid").ToString()); + Console.WriteLine(result[0].GetProperty("categories")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("language").ToString()); + Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("status").ToString()); + Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result[0].GetProperty("usage").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_BatchGet_AllParameters_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response> response = client.BatchGet(limit: 1234, offset: 1234, sort: "", ignoreTermsAndCategories: true); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_BatchGet_AllParameters_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response> response = await client.BatchGetAsync(limit: 1234, offset: 1234, sort: "", ignoreTermsAndCategories: true); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_Create_ShortVersion() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object()); + Response response = client.Create(content); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_Create_ShortVersion_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object()); + Response response = await client.CreateAsync(content); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_Create_ShortVersion_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + AtlasGlossary atlasGlossary = new AtlasGlossary(); + Response response = client.Create(atlasGlossary); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_Create_ShortVersion_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + AtlasGlossary atlasGlossary = new AtlasGlossary(); + Response response = await client.CreateAsync(atlasGlossary); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_Create_AllParameters() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new + { + guid = "", + classifications = new object[] + { +new +{ +attributes = new +{ +key = new object(), +}, +typeName = "", +lastModifiedTS = "", +entityGuid = "", +entityStatus = "ACTIVE", +removePropagationsOnEntityDelete = true, +validityPeriods = new object[] +{ +new +{ +endTime = "", +startTime = "", +timeZone = "", +} +}, +} + }, + longDescription = "", + name = "", + qualifiedName = "", + shortDescription = "", + lastModifiedTS = "", + createTime = 1234L, + createdBy = "", + updateTime = 1234L, + updatedBy = "", + categories = new object[] + { +new +{ +categoryGuid = "", +description = "", +displayText = "", +parentCategoryGuid = "", +relationGuid = "", +} + }, + language = "", + terms = new object[] + { +new +{ +description = "", +displayText = "", +expression = "", +relationGuid = "", +status = "DRAFT", +steward = "", +termGuid = "", +} + }, + usage = "", + }); + Response response = client.Create(content); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("longDescription").ToString()); + Console.WriteLine(result.GetProperty("name").ToString()); + Console.WriteLine(result.GetProperty("qualifiedName").ToString()); + Console.WriteLine(result.GetProperty("shortDescription").ToString()); + Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("createTime").ToString()); + Console.WriteLine(result.GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("updateTime").ToString()); + Console.WriteLine(result.GetProperty("updatedBy").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("categoryGuid").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("parentCategoryGuid").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("language").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("usage").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_Create_AllParameters_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new + { + guid = "", + classifications = new object[] + { +new +{ +attributes = new +{ +key = new object(), +}, +typeName = "", +lastModifiedTS = "", +entityGuid = "", +entityStatus = "ACTIVE", +removePropagationsOnEntityDelete = true, +validityPeriods = new object[] +{ +new +{ +endTime = "", +startTime = "", +timeZone = "", +} +}, +} + }, + longDescription = "", + name = "", + qualifiedName = "", + shortDescription = "", + lastModifiedTS = "", + createTime = 1234L, + createdBy = "", + updateTime = 1234L, + updatedBy = "", + categories = new object[] + { +new +{ +categoryGuid = "", +description = "", +displayText = "", +parentCategoryGuid = "", +relationGuid = "", +} + }, + language = "", + terms = new object[] + { +new +{ +description = "", +displayText = "", +expression = "", +relationGuid = "", +status = "DRAFT", +steward = "", +termGuid = "", +} + }, + usage = "", + }); + Response response = await client.CreateAsync(content); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("longDescription").ToString()); + Console.WriteLine(result.GetProperty("name").ToString()); + Console.WriteLine(result.GetProperty("qualifiedName").ToString()); + Console.WriteLine(result.GetProperty("shortDescription").ToString()); + Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("createTime").ToString()); + Console.WriteLine(result.GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("updateTime").ToString()); + Console.WriteLine(result.GetProperty("updatedBy").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("categoryGuid").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("parentCategoryGuid").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("language").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("usage").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_Create_AllParameters_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + AtlasGlossary atlasGlossary = new AtlasGlossary + { + Guid = "", + Classifications = {new AtlasClassification +{ +Attributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +TypeName = "", +LastModifiedTS = "", +EntityGuid = "", +EntityStatus = EntityStatus.Active, +RemovePropagationsOnEntityDelete = true, +ValidityPeriods = {new TimeBoundary +{ +EndTime = "", +StartTime = "", +TimeZone = "", +}}, +}}, + LongDescription = "", + Name = "", + QualifiedName = "", + ShortDescription = "", + LastModifiedTS = "", + CreateTime = 1234L, + CreatedBy = "", + UpdateTime = 1234L, + UpdatedBy = "", + Categories = {new AtlasRelatedCategoryHeader +{ +CategoryGuid = "", +Description = "", +DisplayText = "", +ParentCategoryGuid = "", +RelationGuid = "", +}}, + Language = "", + Terms = {new AtlasRelatedTermHeader +{ +Description = "", +DisplayText = "", +Expression = "", +RelationGuid = "", +Status = AtlasTermRelationshipStatus.Draft, +Steward = "", +TermGuid = "", +}}, + Usage = "", + }; + Response response = client.Create(atlasGlossary); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_Create_AllParameters_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + AtlasGlossary atlasGlossary = new AtlasGlossary + { + Guid = "", + Classifications = {new AtlasClassification +{ +Attributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +TypeName = "", +LastModifiedTS = "", +EntityGuid = "", +EntityStatus = EntityStatus.Active, +RemovePropagationsOnEntityDelete = true, +ValidityPeriods = {new TimeBoundary +{ +EndTime = "", +StartTime = "", +TimeZone = "", +}}, +}}, + LongDescription = "", + Name = "", + QualifiedName = "", + ShortDescription = "", + LastModifiedTS = "", + CreateTime = 1234L, + CreatedBy = "", + UpdateTime = 1234L, + UpdatedBy = "", + Categories = {new AtlasRelatedCategoryHeader +{ +CategoryGuid = "", +Description = "", +DisplayText = "", +ParentCategoryGuid = "", +RelationGuid = "", +}}, + Language = "", + Terms = {new AtlasRelatedTermHeader +{ +Description = "", +DisplayText = "", +Expression = "", +RelationGuid = "", +Status = AtlasTermRelationshipStatus.Draft, +Steward = "", +TermGuid = "", +}}, + Usage = "", + }; + Response response = await client.CreateAsync(atlasGlossary); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_CreateCategories_ShortVersion() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object[] + { +new object() + }); + Response response = client.CreateCategories(content); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result[0].ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_CreateCategories_ShortVersion_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object[] + { +new object() + }); + Response response = await client.CreateCategoriesAsync(content); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result[0].ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_CreateCategories_ShortVersion_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response> response = client.CreateCategories(new AtlasGlossaryCategory[] + { +new AtlasGlossaryCategory() + }); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_CreateCategories_ShortVersion_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response> response = await client.CreateCategoriesAsync(new AtlasGlossaryCategory[] + { +new AtlasGlossaryCategory() + }); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_CreateCategories_AllParameters() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object[] + { +new +{ +guid = "", +classifications = new object[] +{ +new +{ +attributes = new +{ +key = new object(), +}, +typeName = "", +lastModifiedTS = "", +entityGuid = "", +entityStatus = "ACTIVE", +removePropagationsOnEntityDelete = true, +validityPeriods = new object[] +{ +new +{ +endTime = "", +startTime = "", +timeZone = "", +} +}, +} +}, +longDescription = "", +name = "", +qualifiedName = "", +shortDescription = "", +lastModifiedTS = "", +createTime = 1234L, +createdBy = "", +updateTime = 1234L, +updatedBy = "", +anchor = new +{ +displayText = "", +glossaryGuid = "", +relationGuid = "", +}, +childrenCategories = new object[] +{ +new +{ +categoryGuid = "", +description = "", +displayText = "", +parentCategoryGuid = "", +relationGuid = "", +} +}, +terms = new object[] +{ +new +{ +description = "", +displayText = "", +expression = "", +relationGuid = "", +status = "DRAFT", +steward = "", +termGuid = "", +} +}, +} + }); + Response response = client.CreateCategories(content); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result[0].GetProperty("guid").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result[0].GetProperty("longDescription").ToString()); + Console.WriteLine(result[0].GetProperty("name").ToString()); + Console.WriteLine(result[0].GetProperty("qualifiedName").ToString()); + Console.WriteLine(result[0].GetProperty("shortDescription").ToString()); + Console.WriteLine(result[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result[0].GetProperty("createTime").ToString()); + Console.WriteLine(result[0].GetProperty("createdBy").ToString()); + Console.WriteLine(result[0].GetProperty("updateTime").ToString()); + Console.WriteLine(result[0].GetProperty("updatedBy").ToString()); + Console.WriteLine(result[0].GetProperty("anchor").GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("anchor").GetProperty("glossaryGuid").ToString()); + Console.WriteLine(result[0].GetProperty("anchor").GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("childrenCategories")[0].GetProperty("categoryGuid").ToString()); + Console.WriteLine(result[0].GetProperty("childrenCategories")[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("childrenCategories")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("childrenCategories")[0].GetProperty("parentCategoryGuid").ToString()); + Console.WriteLine(result[0].GetProperty("childrenCategories")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("parentCategory").GetProperty("categoryGuid").ToString()); + Console.WriteLine(result[0].GetProperty("parentCategory").GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("parentCategory").GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("parentCategory").GetProperty("parentCategoryGuid").ToString()); + Console.WriteLine(result[0].GetProperty("parentCategory").GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("status").ToString()); + Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("termGuid").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_CreateCategories_AllParameters_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object[] + { +new +{ +guid = "", +classifications = new object[] +{ +new +{ +attributes = new +{ +key = new object(), +}, +typeName = "", +lastModifiedTS = "", +entityGuid = "", +entityStatus = "ACTIVE", +removePropagationsOnEntityDelete = true, +validityPeriods = new object[] +{ +new +{ +endTime = "", +startTime = "", +timeZone = "", +} +}, +} +}, +longDescription = "", +name = "", +qualifiedName = "", +shortDescription = "", +lastModifiedTS = "", +createTime = 1234L, +createdBy = "", +updateTime = 1234L, +updatedBy = "", +anchor = new +{ +displayText = "", +glossaryGuid = "", +relationGuid = "", +}, +childrenCategories = new object[] +{ +new +{ +categoryGuid = "", +description = "", +displayText = "", +parentCategoryGuid = "", +relationGuid = "", +} +}, +terms = new object[] +{ +new +{ +description = "", +displayText = "", +expression = "", +relationGuid = "", +status = "DRAFT", +steward = "", +termGuid = "", +} +}, +} + }); + Response response = await client.CreateCategoriesAsync(content); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result[0].GetProperty("guid").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result[0].GetProperty("longDescription").ToString()); + Console.WriteLine(result[0].GetProperty("name").ToString()); + Console.WriteLine(result[0].GetProperty("qualifiedName").ToString()); + Console.WriteLine(result[0].GetProperty("shortDescription").ToString()); + Console.WriteLine(result[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result[0].GetProperty("createTime").ToString()); + Console.WriteLine(result[0].GetProperty("createdBy").ToString()); + Console.WriteLine(result[0].GetProperty("updateTime").ToString()); + Console.WriteLine(result[0].GetProperty("updatedBy").ToString()); + Console.WriteLine(result[0].GetProperty("anchor").GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("anchor").GetProperty("glossaryGuid").ToString()); + Console.WriteLine(result[0].GetProperty("anchor").GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("childrenCategories")[0].GetProperty("categoryGuid").ToString()); + Console.WriteLine(result[0].GetProperty("childrenCategories")[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("childrenCategories")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("childrenCategories")[0].GetProperty("parentCategoryGuid").ToString()); + Console.WriteLine(result[0].GetProperty("childrenCategories")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("parentCategory").GetProperty("categoryGuid").ToString()); + Console.WriteLine(result[0].GetProperty("parentCategory").GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("parentCategory").GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("parentCategory").GetProperty("parentCategoryGuid").ToString()); + Console.WriteLine(result[0].GetProperty("parentCategory").GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("status").ToString()); + Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("termGuid").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_CreateCategories_AllParameters_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response> response = client.CreateCategories(new AtlasGlossaryCategory[] + { +new AtlasGlossaryCategory +{ +Guid = "", +Classifications = {new AtlasClassification +{ +Attributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +TypeName = "", +LastModifiedTS = "", +EntityGuid = "", +EntityStatus = EntityStatus.Active, +RemovePropagationsOnEntityDelete = true, +ValidityPeriods = {new TimeBoundary +{ +EndTime = "", +StartTime = "", +TimeZone = "", +}}, +}}, +LongDescription = "", +Name = "", +QualifiedName = "", +ShortDescription = "", +LastModifiedTS = "", +CreateTime = 1234L, +CreatedBy = "", +UpdateTime = 1234L, +UpdatedBy = "", +Anchor = new AtlasGlossaryHeader +{ +DisplayText = "", +GlossaryGuid = "", +RelationGuid = "", +}, +ChildrenCategories = {new AtlasRelatedCategoryHeader +{ +CategoryGuid = "", +Description = "", +DisplayText = "", +ParentCategoryGuid = "", +RelationGuid = "", +}}, +ParentCategory = default, +Terms = {new AtlasRelatedTermHeader +{ +Description = "", +DisplayText = "", +Expression = "", +RelationGuid = "", +Status = AtlasTermRelationshipStatus.Draft, +Steward = "", +TermGuid = "", +}}, +} + }); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_CreateCategories_AllParameters_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response> response = await client.CreateCategoriesAsync(new AtlasGlossaryCategory[] + { +new AtlasGlossaryCategory +{ +Guid = "", +Classifications = {new AtlasClassification +{ +Attributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +TypeName = "", +LastModifiedTS = "", +EntityGuid = "", +EntityStatus = EntityStatus.Active, +RemovePropagationsOnEntityDelete = true, +ValidityPeriods = {new TimeBoundary +{ +EndTime = "", +StartTime = "", +TimeZone = "", +}}, +}}, +LongDescription = "", +Name = "", +QualifiedName = "", +ShortDescription = "", +LastModifiedTS = "", +CreateTime = 1234L, +CreatedBy = "", +UpdateTime = 1234L, +UpdatedBy = "", +Anchor = new AtlasGlossaryHeader +{ +DisplayText = "", +GlossaryGuid = "", +RelationGuid = "", +}, +ChildrenCategories = {new AtlasRelatedCategoryHeader +{ +CategoryGuid = "", +Description = "", +DisplayText = "", +ParentCategoryGuid = "", +RelationGuid = "", +}}, +ParentCategory = default, +Terms = {new AtlasRelatedTermHeader +{ +Description = "", +DisplayText = "", +Expression = "", +RelationGuid = "", +Status = AtlasTermRelationshipStatus.Draft, +Steward = "", +TermGuid = "", +}}, +} + }); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_CreateCategory_ShortVersion() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object()); + Response response = client.CreateCategory(content); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_CreateCategory_ShortVersion_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object()); + Response response = await client.CreateCategoryAsync(content); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_CreateCategory_ShortVersion_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + AtlasGlossaryCategory glossaryCategory = new AtlasGlossaryCategory(); + Response response = client.CreateCategory(glossaryCategory); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_CreateCategory_ShortVersion_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + AtlasGlossaryCategory glossaryCategory = new AtlasGlossaryCategory(); + Response response = await client.CreateCategoryAsync(glossaryCategory); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_CreateCategory_AllParameters() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new + { + guid = "", + classifications = new object[] + { +new +{ +attributes = new +{ +key = new object(), +}, +typeName = "", +lastModifiedTS = "", +entityGuid = "", +entityStatus = "ACTIVE", +removePropagationsOnEntityDelete = true, +validityPeriods = new object[] +{ +new +{ +endTime = "", +startTime = "", +timeZone = "", +} +}, +} + }, + longDescription = "", + name = "", + qualifiedName = "", + shortDescription = "", + lastModifiedTS = "", + createTime = 1234L, + createdBy = "", + updateTime = 1234L, + updatedBy = "", + anchor = new + { + displayText = "", + glossaryGuid = "", + relationGuid = "", + }, + childrenCategories = new object[] + { +new +{ +categoryGuid = "", +description = "", +displayText = "", +parentCategoryGuid = "", +relationGuid = "", +} + }, + terms = new object[] + { +new +{ +description = "", +displayText = "", +expression = "", +relationGuid = "", +status = "DRAFT", +steward = "", +termGuid = "", +} + }, + }); + Response response = client.CreateCategory(content); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("longDescription").ToString()); + Console.WriteLine(result.GetProperty("name").ToString()); + Console.WriteLine(result.GetProperty("qualifiedName").ToString()); + Console.WriteLine(result.GetProperty("shortDescription").ToString()); + Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("createTime").ToString()); + Console.WriteLine(result.GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("updateTime").ToString()); + Console.WriteLine(result.GetProperty("updatedBy").ToString()); + Console.WriteLine(result.GetProperty("anchor").GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("anchor").GetProperty("glossaryGuid").ToString()); + Console.WriteLine(result.GetProperty("anchor").GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("categoryGuid").ToString()); + Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("parentCategoryGuid").ToString()); + Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("parentCategory").GetProperty("categoryGuid").ToString()); + Console.WriteLine(result.GetProperty("parentCategory").GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("parentCategory").GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("parentCategory").GetProperty("parentCategoryGuid").ToString()); + Console.WriteLine(result.GetProperty("parentCategory").GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("termGuid").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_CreateCategory_AllParameters_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new + { + guid = "", + classifications = new object[] + { +new +{ +attributes = new +{ +key = new object(), +}, +typeName = "", +lastModifiedTS = "", +entityGuid = "", +entityStatus = "ACTIVE", +removePropagationsOnEntityDelete = true, +validityPeriods = new object[] +{ +new +{ +endTime = "", +startTime = "", +timeZone = "", +} +}, +} + }, + longDescription = "", + name = "", + qualifiedName = "", + shortDescription = "", + lastModifiedTS = "", + createTime = 1234L, + createdBy = "", + updateTime = 1234L, + updatedBy = "", + anchor = new + { + displayText = "", + glossaryGuid = "", + relationGuid = "", + }, + childrenCategories = new object[] + { +new +{ +categoryGuid = "", +description = "", +displayText = "", +parentCategoryGuid = "", +relationGuid = "", +} + }, + terms = new object[] + { +new +{ +description = "", +displayText = "", +expression = "", +relationGuid = "", +status = "DRAFT", +steward = "", +termGuid = "", +} + }, + }); + Response response = await client.CreateCategoryAsync(content); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("longDescription").ToString()); + Console.WriteLine(result.GetProperty("name").ToString()); + Console.WriteLine(result.GetProperty("qualifiedName").ToString()); + Console.WriteLine(result.GetProperty("shortDescription").ToString()); + Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("createTime").ToString()); + Console.WriteLine(result.GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("updateTime").ToString()); + Console.WriteLine(result.GetProperty("updatedBy").ToString()); + Console.WriteLine(result.GetProperty("anchor").GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("anchor").GetProperty("glossaryGuid").ToString()); + Console.WriteLine(result.GetProperty("anchor").GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("categoryGuid").ToString()); + Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("parentCategoryGuid").ToString()); + Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("parentCategory").GetProperty("categoryGuid").ToString()); + Console.WriteLine(result.GetProperty("parentCategory").GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("parentCategory").GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("parentCategory").GetProperty("parentCategoryGuid").ToString()); + Console.WriteLine(result.GetProperty("parentCategory").GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("termGuid").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_CreateCategory_AllParameters_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + AtlasGlossaryCategory glossaryCategory = new AtlasGlossaryCategory + { + Guid = "", + Classifications = {new AtlasClassification +{ +Attributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +TypeName = "", +LastModifiedTS = "", +EntityGuid = "", +EntityStatus = EntityStatus.Active, +RemovePropagationsOnEntityDelete = true, +ValidityPeriods = {new TimeBoundary +{ +EndTime = "", +StartTime = "", +TimeZone = "", +}}, +}}, + LongDescription = "", + Name = "", + QualifiedName = "", + ShortDescription = "", + LastModifiedTS = "", + CreateTime = 1234L, + CreatedBy = "", + UpdateTime = 1234L, + UpdatedBy = "", + Anchor = new AtlasGlossaryHeader + { + DisplayText = "", + GlossaryGuid = "", + RelationGuid = "", + }, + ChildrenCategories = {new AtlasRelatedCategoryHeader +{ +CategoryGuid = "", +Description = "", +DisplayText = "", +ParentCategoryGuid = "", +RelationGuid = "", +}}, + ParentCategory = default, + Terms = {new AtlasRelatedTermHeader +{ +Description = "", +DisplayText = "", +Expression = "", +RelationGuid = "", +Status = AtlasTermRelationshipStatus.Draft, +Steward = "", +TermGuid = "", +}}, + }; + Response response = client.CreateCategory(glossaryCategory); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_CreateCategory_AllParameters_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + AtlasGlossaryCategory glossaryCategory = new AtlasGlossaryCategory + { + Guid = "", + Classifications = {new AtlasClassification +{ +Attributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +TypeName = "", +LastModifiedTS = "", +EntityGuid = "", +EntityStatus = EntityStatus.Active, +RemovePropagationsOnEntityDelete = true, +ValidityPeriods = {new TimeBoundary +{ +EndTime = "", +StartTime = "", +TimeZone = "", +}}, +}}, + LongDescription = "", + Name = "", + QualifiedName = "", + ShortDescription = "", + LastModifiedTS = "", + CreateTime = 1234L, + CreatedBy = "", + UpdateTime = 1234L, + UpdatedBy = "", + Anchor = new AtlasGlossaryHeader + { + DisplayText = "", + GlossaryGuid = "", + RelationGuid = "", + }, + ChildrenCategories = {new AtlasRelatedCategoryHeader +{ +CategoryGuid = "", +Description = "", +DisplayText = "", +ParentCategoryGuid = "", +RelationGuid = "", +}}, + ParentCategory = default, + Terms = {new AtlasRelatedTermHeader +{ +Description = "", +DisplayText = "", +Expression = "", +RelationGuid = "", +Status = AtlasTermRelationshipStatus.Draft, +Steward = "", +TermGuid = "", +}}, + }; + Response response = await client.CreateCategoryAsync(glossaryCategory); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_GetCategory_ShortVersion() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = client.GetCategory("", null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_GetCategory_ShortVersion_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = await client.GetCategoryAsync("", null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_GetCategory_ShortVersion_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = client.GetCategory(""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_GetCategory_ShortVersion_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = await client.GetCategoryAsync(""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_GetCategory_AllParameters() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = client.GetCategory("", null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("longDescription").ToString()); + Console.WriteLine(result.GetProperty("name").ToString()); + Console.WriteLine(result.GetProperty("qualifiedName").ToString()); + Console.WriteLine(result.GetProperty("shortDescription").ToString()); + Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("createTime").ToString()); + Console.WriteLine(result.GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("updateTime").ToString()); + Console.WriteLine(result.GetProperty("updatedBy").ToString()); + Console.WriteLine(result.GetProperty("anchor").GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("anchor").GetProperty("glossaryGuid").ToString()); + Console.WriteLine(result.GetProperty("anchor").GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("categoryGuid").ToString()); + Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("parentCategoryGuid").ToString()); + Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("parentCategory").GetProperty("categoryGuid").ToString()); + Console.WriteLine(result.GetProperty("parentCategory").GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("parentCategory").GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("parentCategory").GetProperty("parentCategoryGuid").ToString()); + Console.WriteLine(result.GetProperty("parentCategory").GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("termGuid").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_GetCategory_AllParameters_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = await client.GetCategoryAsync("", null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("longDescription").ToString()); + Console.WriteLine(result.GetProperty("name").ToString()); + Console.WriteLine(result.GetProperty("qualifiedName").ToString()); + Console.WriteLine(result.GetProperty("shortDescription").ToString()); + Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("createTime").ToString()); + Console.WriteLine(result.GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("updateTime").ToString()); + Console.WriteLine(result.GetProperty("updatedBy").ToString()); + Console.WriteLine(result.GetProperty("anchor").GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("anchor").GetProperty("glossaryGuid").ToString()); + Console.WriteLine(result.GetProperty("anchor").GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("categoryGuid").ToString()); + Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("parentCategoryGuid").ToString()); + Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("parentCategory").GetProperty("categoryGuid").ToString()); + Console.WriteLine(result.GetProperty("parentCategory").GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("parentCategory").GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("parentCategory").GetProperty("parentCategoryGuid").ToString()); + Console.WriteLine(result.GetProperty("parentCategory").GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("termGuid").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_GetCategory_AllParameters_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = client.GetCategory(""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_GetCategory_AllParameters_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = await client.GetCategoryAsync(""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_UpdateCategory_ShortVersion() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object()); + Response response = client.UpdateCategory("", content); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_UpdateCategory_ShortVersion_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object()); + Response response = await client.UpdateCategoryAsync("", content); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_UpdateCategory_ShortVersion_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + AtlasGlossaryCategory glossaryCategory = new AtlasGlossaryCategory(); + Response response = client.UpdateCategory("", glossaryCategory); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_UpdateCategory_ShortVersion_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + AtlasGlossaryCategory glossaryCategory = new AtlasGlossaryCategory(); + Response response = await client.UpdateCategoryAsync("", glossaryCategory); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_UpdateCategory_AllParameters() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new + { + guid = "", + classifications = new object[] + { +new +{ +attributes = new +{ +key = new object(), +}, +typeName = "", +lastModifiedTS = "", +entityGuid = "", +entityStatus = "ACTIVE", +removePropagationsOnEntityDelete = true, +validityPeriods = new object[] +{ +new +{ +endTime = "", +startTime = "", +timeZone = "", +} +}, +} + }, + longDescription = "", + name = "", + qualifiedName = "", + shortDescription = "", + lastModifiedTS = "", + createTime = 1234L, + createdBy = "", + updateTime = 1234L, + updatedBy = "", + anchor = new + { + displayText = "", + glossaryGuid = "", + relationGuid = "", + }, + childrenCategories = new object[] + { +new +{ +categoryGuid = "", +description = "", +displayText = "", +parentCategoryGuid = "", +relationGuid = "", +} + }, + terms = new object[] + { +new +{ +description = "", +displayText = "", +expression = "", +relationGuid = "", +status = "DRAFT", +steward = "", +termGuid = "", +} + }, + }); + Response response = client.UpdateCategory("", content); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("longDescription").ToString()); + Console.WriteLine(result.GetProperty("name").ToString()); + Console.WriteLine(result.GetProperty("qualifiedName").ToString()); + Console.WriteLine(result.GetProperty("shortDescription").ToString()); + Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("createTime").ToString()); + Console.WriteLine(result.GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("updateTime").ToString()); + Console.WriteLine(result.GetProperty("updatedBy").ToString()); + Console.WriteLine(result.GetProperty("anchor").GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("anchor").GetProperty("glossaryGuid").ToString()); + Console.WriteLine(result.GetProperty("anchor").GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("categoryGuid").ToString()); + Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("parentCategoryGuid").ToString()); + Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("parentCategory").GetProperty("categoryGuid").ToString()); + Console.WriteLine(result.GetProperty("parentCategory").GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("parentCategory").GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("parentCategory").GetProperty("parentCategoryGuid").ToString()); + Console.WriteLine(result.GetProperty("parentCategory").GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("termGuid").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_UpdateCategory_AllParameters_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new + { + guid = "", + classifications = new object[] + { +new +{ +attributes = new +{ +key = new object(), +}, +typeName = "", +lastModifiedTS = "", +entityGuid = "", +entityStatus = "ACTIVE", +removePropagationsOnEntityDelete = true, +validityPeriods = new object[] +{ +new +{ +endTime = "", +startTime = "", +timeZone = "", +} +}, +} + }, + longDescription = "", + name = "", + qualifiedName = "", + shortDescription = "", + lastModifiedTS = "", + createTime = 1234L, + createdBy = "", + updateTime = 1234L, + updatedBy = "", + anchor = new + { + displayText = "", + glossaryGuid = "", + relationGuid = "", + }, + childrenCategories = new object[] + { +new +{ +categoryGuid = "", +description = "", +displayText = "", +parentCategoryGuid = "", +relationGuid = "", +} + }, + terms = new object[] + { +new +{ +description = "", +displayText = "", +expression = "", +relationGuid = "", +status = "DRAFT", +steward = "", +termGuid = "", +} + }, + }); + Response response = await client.UpdateCategoryAsync("", content); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("longDescription").ToString()); + Console.WriteLine(result.GetProperty("name").ToString()); + Console.WriteLine(result.GetProperty("qualifiedName").ToString()); + Console.WriteLine(result.GetProperty("shortDescription").ToString()); + Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("createTime").ToString()); + Console.WriteLine(result.GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("updateTime").ToString()); + Console.WriteLine(result.GetProperty("updatedBy").ToString()); + Console.WriteLine(result.GetProperty("anchor").GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("anchor").GetProperty("glossaryGuid").ToString()); + Console.WriteLine(result.GetProperty("anchor").GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("categoryGuid").ToString()); + Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("parentCategoryGuid").ToString()); + Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("parentCategory").GetProperty("categoryGuid").ToString()); + Console.WriteLine(result.GetProperty("parentCategory").GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("parentCategory").GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("parentCategory").GetProperty("parentCategoryGuid").ToString()); + Console.WriteLine(result.GetProperty("parentCategory").GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("termGuid").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_UpdateCategory_AllParameters_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + AtlasGlossaryCategory glossaryCategory = new AtlasGlossaryCategory + { + Guid = "", + Classifications = {new AtlasClassification +{ +Attributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +TypeName = "", +LastModifiedTS = "", +EntityGuid = "", +EntityStatus = EntityStatus.Active, +RemovePropagationsOnEntityDelete = true, +ValidityPeriods = {new TimeBoundary +{ +EndTime = "", +StartTime = "", +TimeZone = "", +}}, +}}, + LongDescription = "", + Name = "", + QualifiedName = "", + ShortDescription = "", + LastModifiedTS = "", + CreateTime = 1234L, + CreatedBy = "", + UpdateTime = 1234L, + UpdatedBy = "", + Anchor = new AtlasGlossaryHeader + { + DisplayText = "", + GlossaryGuid = "", + RelationGuid = "", + }, + ChildrenCategories = {new AtlasRelatedCategoryHeader +{ +CategoryGuid = "", +Description = "", +DisplayText = "", +ParentCategoryGuid = "", +RelationGuid = "", +}}, + ParentCategory = default, + Terms = {new AtlasRelatedTermHeader +{ +Description = "", +DisplayText = "", +Expression = "", +RelationGuid = "", +Status = AtlasTermRelationshipStatus.Draft, +Steward = "", +TermGuid = "", +}}, + }; + Response response = client.UpdateCategory("", glossaryCategory); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_UpdateCategory_AllParameters_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + AtlasGlossaryCategory glossaryCategory = new AtlasGlossaryCategory + { + Guid = "", + Classifications = {new AtlasClassification +{ +Attributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +TypeName = "", +LastModifiedTS = "", +EntityGuid = "", +EntityStatus = EntityStatus.Active, +RemovePropagationsOnEntityDelete = true, +ValidityPeriods = {new TimeBoundary +{ +EndTime = "", +StartTime = "", +TimeZone = "", +}}, +}}, + LongDescription = "", + Name = "", + QualifiedName = "", + ShortDescription = "", + LastModifiedTS = "", + CreateTime = 1234L, + CreatedBy = "", + UpdateTime = 1234L, + UpdatedBy = "", + Anchor = new AtlasGlossaryHeader + { + DisplayText = "", + GlossaryGuid = "", + RelationGuid = "", + }, + ChildrenCategories = {new AtlasRelatedCategoryHeader +{ +CategoryGuid = "", +Description = "", +DisplayText = "", +ParentCategoryGuid = "", +RelationGuid = "", +}}, + ParentCategory = default, + Terms = {new AtlasRelatedTermHeader +{ +Description = "", +DisplayText = "", +Expression = "", +RelationGuid = "", +Status = AtlasTermRelationshipStatus.Draft, +Steward = "", +TermGuid = "", +}}, + }; + Response response = await client.UpdateCategoryAsync("", glossaryCategory); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_DeleteCategory_ShortVersion() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = client.DeleteCategory(""); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_DeleteCategory_ShortVersion_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = await client.DeleteCategoryAsync(""); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_DeleteCategory_AllParameters() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = client.DeleteCategory(""); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_DeleteCategory_AllParameters_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = await client.DeleteCategoryAsync(""); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_PartialUpdateCategory_ShortVersion() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object()); + Response response = client.PartialUpdateCategory("", content); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_PartialUpdateCategory_ShortVersion_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object()); + Response response = await client.PartialUpdateCategoryAsync("", content); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_PartialUpdateCategory_ShortVersion_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = client.PartialUpdateCategory("", BinaryData.FromObjectAsJson(new object())); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_PartialUpdateCategory_ShortVersion_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = await client.PartialUpdateCategoryAsync("", BinaryData.FromObjectAsJson(new object())); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_PartialUpdateCategory_AllParameters() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object()); + Response response = client.PartialUpdateCategory("", content); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("longDescription").ToString()); + Console.WriteLine(result.GetProperty("name").ToString()); + Console.WriteLine(result.GetProperty("qualifiedName").ToString()); + Console.WriteLine(result.GetProperty("shortDescription").ToString()); + Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("createTime").ToString()); + Console.WriteLine(result.GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("updateTime").ToString()); + Console.WriteLine(result.GetProperty("updatedBy").ToString()); + Console.WriteLine(result.GetProperty("anchor").GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("anchor").GetProperty("glossaryGuid").ToString()); + Console.WriteLine(result.GetProperty("anchor").GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("categoryGuid").ToString()); + Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("parentCategoryGuid").ToString()); + Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("parentCategory").GetProperty("categoryGuid").ToString()); + Console.WriteLine(result.GetProperty("parentCategory").GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("parentCategory").GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("parentCategory").GetProperty("parentCategoryGuid").ToString()); + Console.WriteLine(result.GetProperty("parentCategory").GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("termGuid").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_PartialUpdateCategory_AllParameters_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object()); + Response response = await client.PartialUpdateCategoryAsync("", content); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("longDescription").ToString()); + Console.WriteLine(result.GetProperty("name").ToString()); + Console.WriteLine(result.GetProperty("qualifiedName").ToString()); + Console.WriteLine(result.GetProperty("shortDescription").ToString()); + Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("createTime").ToString()); + Console.WriteLine(result.GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("updateTime").ToString()); + Console.WriteLine(result.GetProperty("updatedBy").ToString()); + Console.WriteLine(result.GetProperty("anchor").GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("anchor").GetProperty("glossaryGuid").ToString()); + Console.WriteLine(result.GetProperty("anchor").GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("categoryGuid").ToString()); + Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("parentCategoryGuid").ToString()); + Console.WriteLine(result.GetProperty("childrenCategories")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("parentCategory").GetProperty("categoryGuid").ToString()); + Console.WriteLine(result.GetProperty("parentCategory").GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("parentCategory").GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("parentCategory").GetProperty("parentCategoryGuid").ToString()); + Console.WriteLine(result.GetProperty("parentCategory").GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("termGuid").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_PartialUpdateCategory_AllParameters_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = client.PartialUpdateCategory("", BinaryData.FromObjectAsJson(new object())); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_PartialUpdateCategory_AllParameters_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = await client.PartialUpdateCategoryAsync("", BinaryData.FromObjectAsJson(new object())); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_GetRelatedCategories_ShortVersion() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = client.GetRelatedCategories("", null, null, null, null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("")[0].ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_GetRelatedCategories_ShortVersion_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = await client.GetRelatedCategoriesAsync("", null, null, null, null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("")[0].ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_GetRelatedCategories_ShortVersion_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response>> response = client.GetRelatedCategories(""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_GetRelatedCategories_ShortVersion_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response>> response = await client.GetRelatedCategoriesAsync(""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_GetRelatedCategories_AllParameters() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = client.GetRelatedCategories("", 1234, 1234, "", null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("")[0].GetProperty("categoryGuid").ToString()); + Console.WriteLine(result.GetProperty("")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("")[0].GetProperty("parentCategoryGuid").ToString()); + Console.WriteLine(result.GetProperty("")[0].GetProperty("relationGuid").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_GetRelatedCategories_AllParameters_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = await client.GetRelatedCategoriesAsync("", 1234, 1234, "", null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("")[0].GetProperty("categoryGuid").ToString()); + Console.WriteLine(result.GetProperty("")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("")[0].GetProperty("parentCategoryGuid").ToString()); + Console.WriteLine(result.GetProperty("")[0].GetProperty("relationGuid").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_GetRelatedCategories_AllParameters_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response>> response = client.GetRelatedCategories("", limit: 1234, offset: 1234, sort: ""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_GetRelatedCategories_AllParameters_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response>> response = await client.GetRelatedCategoriesAsync("", limit: 1234, offset: 1234, sort: ""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_GetCategoryTerms_ShortVersion() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = client.GetCategoryTerms("", null, null, null, null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result[0].ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_GetCategoryTerms_ShortVersion_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = await client.GetCategoryTermsAsync("", null, null, null, null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result[0].ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_GetCategoryTerms_ShortVersion_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response> response = client.GetCategoryTerms(""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_GetCategoryTerms_ShortVersion_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response> response = await client.GetCategoryTermsAsync(""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_GetCategoryTerms_AllParameters() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = client.GetCategoryTerms("", 1234, 1234, "", null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("expression").ToString()); + Console.WriteLine(result[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("status").ToString()); + Console.WriteLine(result[0].GetProperty("steward").ToString()); + Console.WriteLine(result[0].GetProperty("termGuid").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_GetCategoryTerms_AllParameters_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = await client.GetCategoryTermsAsync("", 1234, 1234, "", null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("expression").ToString()); + Console.WriteLine(result[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("status").ToString()); + Console.WriteLine(result[0].GetProperty("steward").ToString()); + Console.WriteLine(result[0].GetProperty("termGuid").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_GetCategoryTerms_AllParameters_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response> response = client.GetCategoryTerms("", limit: 1234, offset: 1234, sort: ""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_GetCategoryTerms_AllParameters_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response> response = await client.GetCategoryTermsAsync("", limit: 1234, offset: 1234, sort: ""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_CreateTerm_ShortVersion() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object()); + Response response = client.CreateTerm(content); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_CreateTerm_ShortVersion_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object()); + Response response = await client.CreateTermAsync(content); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_CreateTerm_ShortVersion_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + AtlasGlossaryTerm glossaryTerm = new AtlasGlossaryTerm(); + Response response = client.CreateTerm(glossaryTerm); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_CreateTerm_ShortVersion_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + AtlasGlossaryTerm glossaryTerm = new AtlasGlossaryTerm(); + Response response = await client.CreateTermAsync(glossaryTerm); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_CreateTerm_AllParameters() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new + { + guid = "", + classifications = new object[] + { +new +{ +attributes = new +{ +key = new object(), +}, +typeName = "", +lastModifiedTS = "", +entityGuid = "", +entityStatus = "ACTIVE", +removePropagationsOnEntityDelete = true, +validityPeriods = new object[] +{ +new +{ +endTime = "", +startTime = "", +timeZone = "", +} +}, +} + }, + longDescription = "", + name = "", + qualifiedName = "", + shortDescription = "", + lastModifiedTS = "", + createTime = 1234L, + createdBy = "", + updateTime = 1234L, + updatedBy = "", + abbreviation = "", + templateName = new object[] + { +new object() + }, + anchor = new + { + displayText = "", + glossaryGuid = "", + relationGuid = "", + }, + antonyms = new object[] + { +new +{ +description = "", +displayText = "", +expression = "", +relationGuid = "", +status = "DRAFT", +steward = "", +termGuid = "", +} + }, + status = "Draft", + nickName = "", + hierarchyInfo = new object[] + { +new +{ +guid = "", +typeName = "", +uniqueAttributes = new +{ +key = new object(), +}, +name = "", +displayText = "", +itemPath = "", +resourceId = "", +properties = new +{ +key = new object(), +}, +} + }, + resources = new object[] + { +new +{ +displayName = "", +url = "", +} + }, + contacts = new + { + key = new object[] + { +new +{ +id = "", +info = "", +} + }, + }, + attributes = new + { + key = new + { + key = new object(), + }, + }, + assignedEntities = new object[] + { +new +{ +guid = "", +typeName = "", +uniqueAttributes = new +{ +key = new object(), +}, +displayText = "", +entityStatus = "ACTIVE", +relationshipType = "", +relationshipAttributes = new +{ +attributes = new +{ +key = new object(), +}, +typeName = "", +lastModifiedTS = "", +}, +relationshipGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", +relationshipStatus = "ACTIVE", +} + }, + categories = new object[] + { +new +{ +categoryGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", +description = "", +displayText = "", +relationGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", +status = "DRAFT", +} + }, + classifies = new object[] + { +null + }, + examples = new object[] + { +"" + }, + isA = new object[] + { +null + }, + preferredTerms = new object[] + { +null + }, + preferredToTerms = new object[] + { +null + }, + replacedBy = new object[] + { +null + }, + replacementTerms = new object[] + { +null + }, + seeAlso = new object[] + { +null + }, + synonyms = new object[] + { +null + }, + translatedTerms = new object[] + { +null + }, + translationTerms = new object[] + { +null + }, + usage = "", + validValues = new object[] + { +null + }, + validValuesFor = new object[] + { +null + }, + }); + Response response = client.CreateTerm(content, includeTermHierarchy: true); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("longDescription").ToString()); + Console.WriteLine(result.GetProperty("name").ToString()); + Console.WriteLine(result.GetProperty("qualifiedName").ToString()); + Console.WriteLine(result.GetProperty("shortDescription").ToString()); + Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("createTime").ToString()); + Console.WriteLine(result.GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("updateTime").ToString()); + Console.WriteLine(result.GetProperty("updatedBy").ToString()); + Console.WriteLine(result.GetProperty("abbreviation").ToString()); + Console.WriteLine(result.GetProperty("templateName")[0].ToString()); + Console.WriteLine(result.GetProperty("anchor").GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("anchor").GetProperty("glossaryGuid").ToString()); + Console.WriteLine(result.GetProperty("anchor").GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("nickName").ToString()); + Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("uniqueAttributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("name").ToString()); + Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("itemPath").ToString()); + Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("resourceId").ToString()); + Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("properties").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("resources")[0].GetProperty("displayName").ToString()); + Console.WriteLine(result.GetProperty("resources")[0].GetProperty("url").ToString()); + Console.WriteLine(result.GetProperty("contacts").GetProperty("")[0].GetProperty("id").ToString()); + Console.WriteLine(result.GetProperty("contacts").GetProperty("")[0].GetProperty("info").ToString()); + Console.WriteLine(result.GetProperty("attributes").GetProperty("").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("uniqueAttributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipType").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipGuid").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipStatus").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("categoryGuid").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("examples")[0].ToString()); + Console.WriteLine(result.GetProperty("isA")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("isA")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("isA")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("isA")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("isA")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("isA")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("isA")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("usage").ToString()); + Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("termGuid").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_CreateTerm_AllParameters_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new + { + guid = "", + classifications = new object[] + { +new +{ +attributes = new +{ +key = new object(), +}, +typeName = "", +lastModifiedTS = "", +entityGuid = "", +entityStatus = "ACTIVE", +removePropagationsOnEntityDelete = true, +validityPeriods = new object[] +{ +new +{ +endTime = "", +startTime = "", +timeZone = "", +} +}, +} + }, + longDescription = "", + name = "", + qualifiedName = "", + shortDescription = "", + lastModifiedTS = "", + createTime = 1234L, + createdBy = "", + updateTime = 1234L, + updatedBy = "", + abbreviation = "", + templateName = new object[] + { +new object() + }, + anchor = new + { + displayText = "", + glossaryGuid = "", + relationGuid = "", + }, + antonyms = new object[] + { +new +{ +description = "", +displayText = "", +expression = "", +relationGuid = "", +status = "DRAFT", +steward = "", +termGuid = "", +} + }, + status = "Draft", + nickName = "", + hierarchyInfo = new object[] + { +new +{ +guid = "", +typeName = "", +uniqueAttributes = new +{ +key = new object(), +}, +name = "", +displayText = "", +itemPath = "", +resourceId = "", +properties = new +{ +key = new object(), +}, +} + }, + resources = new object[] + { +new +{ +displayName = "", +url = "", +} + }, + contacts = new + { + key = new object[] + { +new +{ +id = "", +info = "", +} + }, + }, + attributes = new + { + key = new + { + key = new object(), + }, + }, + assignedEntities = new object[] + { +new +{ +guid = "", +typeName = "", +uniqueAttributes = new +{ +key = new object(), +}, +displayText = "", +entityStatus = "ACTIVE", +relationshipType = "", +relationshipAttributes = new +{ +attributes = new +{ +key = new object(), +}, +typeName = "", +lastModifiedTS = "", +}, +relationshipGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", +relationshipStatus = "ACTIVE", +} + }, + categories = new object[] + { +new +{ +categoryGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", +description = "", +displayText = "", +relationGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", +status = "DRAFT", +} + }, + classifies = new object[] + { +null + }, + examples = new object[] + { +"" + }, + isA = new object[] + { +null + }, + preferredTerms = new object[] + { +null + }, + preferredToTerms = new object[] + { +null + }, + replacedBy = new object[] + { +null + }, + replacementTerms = new object[] + { +null + }, + seeAlso = new object[] + { +null + }, + synonyms = new object[] + { +null + }, + translatedTerms = new object[] + { +null + }, + translationTerms = new object[] + { +null + }, + usage = "", + validValues = new object[] + { +null + }, + validValuesFor = new object[] + { +null + }, + }); + Response response = await client.CreateTermAsync(content, includeTermHierarchy: true); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("longDescription").ToString()); + Console.WriteLine(result.GetProperty("name").ToString()); + Console.WriteLine(result.GetProperty("qualifiedName").ToString()); + Console.WriteLine(result.GetProperty("shortDescription").ToString()); + Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("createTime").ToString()); + Console.WriteLine(result.GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("updateTime").ToString()); + Console.WriteLine(result.GetProperty("updatedBy").ToString()); + Console.WriteLine(result.GetProperty("abbreviation").ToString()); + Console.WriteLine(result.GetProperty("templateName")[0].ToString()); + Console.WriteLine(result.GetProperty("anchor").GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("anchor").GetProperty("glossaryGuid").ToString()); + Console.WriteLine(result.GetProperty("anchor").GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("nickName").ToString()); + Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("uniqueAttributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("name").ToString()); + Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("itemPath").ToString()); + Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("resourceId").ToString()); + Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("properties").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("resources")[0].GetProperty("displayName").ToString()); + Console.WriteLine(result.GetProperty("resources")[0].GetProperty("url").ToString()); + Console.WriteLine(result.GetProperty("contacts").GetProperty("")[0].GetProperty("id").ToString()); + Console.WriteLine(result.GetProperty("contacts").GetProperty("")[0].GetProperty("info").ToString()); + Console.WriteLine(result.GetProperty("attributes").GetProperty("").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("uniqueAttributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipType").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipGuid").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipStatus").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("categoryGuid").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("examples")[0].ToString()); + Console.WriteLine(result.GetProperty("isA")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("isA")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("isA")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("isA")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("isA")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("isA")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("isA")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("usage").ToString()); + Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("termGuid").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_CreateTerm_AllParameters_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + AtlasGlossaryTerm glossaryTerm = new AtlasGlossaryTerm + { + Guid = "", + Classifications = {new AtlasClassification +{ +Attributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +TypeName = "", +LastModifiedTS = "", +EntityGuid = "", +EntityStatus = EntityStatus.Active, +RemovePropagationsOnEntityDelete = true, +ValidityPeriods = {new TimeBoundary +{ +EndTime = "", +StartTime = "", +TimeZone = "", +}}, +}}, + LongDescription = "", + Name = "", + QualifiedName = "", + ShortDescription = "", + LastModifiedTS = "", + CreateTime = 1234L, + CreatedBy = "", + UpdateTime = 1234L, + UpdatedBy = "", + Abbreviation = "", + TemplateName = { BinaryData.FromObjectAsJson(new object()) }, + Anchor = new AtlasGlossaryHeader + { + DisplayText = "", + GlossaryGuid = "", + RelationGuid = "", + }, + Antonyms = {new AtlasRelatedTermHeader +{ +Description = "", +DisplayText = "", +Expression = "", +RelationGuid = "", +Status = AtlasTermRelationshipStatus.Draft, +Steward = "", +TermGuid = "", +}}, + Status = TermStatus.Draft, + NickName = "", + HierarchyInfo = {new PurviewObjectId +{ +Guid = "", +TypeName = "", +UniqueAttributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +Name = "", +DisplayText = "", +ItemPath = "", +ResourceId = "", +Properties = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +}}, + Resources = {new ResourceLink +{ +DisplayName = "", +Url = "", +}}, + Contacts = +{ +["key"] = {new ContactInfo +{ +Id = "", +Info = "", +}} +}, + Attributes = +{ +["key"] = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +} +}, + AssignedEntities = {new AtlasRelatedObjectId +{ +Guid = "", +TypeName = "", +UniqueAttributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +DisplayText = "", +EntityStatus = EntityStatus.Active, +RelationshipType = "", +RelationshipAttributes = new AtlasStruct +{ +Attributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +TypeName = "", +LastModifiedTS = "", +}, +RelationshipGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), +RelationshipStatus = StatusAtlasRelationship.Active, +}}, + Categories = {new AtlasTermCategorizationHeader +{ +CategoryGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), +Description = "", +DisplayText = "", +RelationGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), +Status = AtlasTermRelationshipStatus.Draft, +}}, + Classifies = { default }, + Examples = { "" }, + IsA = { default }, + PreferredTerms = { default }, + PreferredToTerms = { default }, + ReplacedBy = { default }, + ReplacementTerms = { default }, + SeeAlso = { default }, + Synonyms = { default }, + TranslatedTerms = { default }, + TranslationTerms = { default }, + Usage = "", + ValidValues = { default }, + ValidValuesFor = { default }, + }; + Response response = client.CreateTerm(glossaryTerm, includeTermHierarchy: true); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_CreateTerm_AllParameters_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + AtlasGlossaryTerm glossaryTerm = new AtlasGlossaryTerm + { + Guid = "", + Classifications = {new AtlasClassification +{ +Attributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +TypeName = "", +LastModifiedTS = "", +EntityGuid = "", +EntityStatus = EntityStatus.Active, +RemovePropagationsOnEntityDelete = true, +ValidityPeriods = {new TimeBoundary +{ +EndTime = "", +StartTime = "", +TimeZone = "", +}}, +}}, + LongDescription = "", + Name = "", + QualifiedName = "", + ShortDescription = "", + LastModifiedTS = "", + CreateTime = 1234L, + CreatedBy = "", + UpdateTime = 1234L, + UpdatedBy = "", + Abbreviation = "", + TemplateName = { BinaryData.FromObjectAsJson(new object()) }, + Anchor = new AtlasGlossaryHeader + { + DisplayText = "", + GlossaryGuid = "", + RelationGuid = "", + }, + Antonyms = {new AtlasRelatedTermHeader +{ +Description = "", +DisplayText = "", +Expression = "", +RelationGuid = "", +Status = AtlasTermRelationshipStatus.Draft, +Steward = "", +TermGuid = "", +}}, + Status = TermStatus.Draft, + NickName = "", + HierarchyInfo = {new PurviewObjectId +{ +Guid = "", +TypeName = "", +UniqueAttributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +Name = "", +DisplayText = "", +ItemPath = "", +ResourceId = "", +Properties = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +}}, + Resources = {new ResourceLink +{ +DisplayName = "", +Url = "", +}}, + Contacts = +{ +["key"] = {new ContactInfo +{ +Id = "", +Info = "", +}} +}, + Attributes = +{ +["key"] = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +} +}, + AssignedEntities = {new AtlasRelatedObjectId +{ +Guid = "", +TypeName = "", +UniqueAttributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +DisplayText = "", +EntityStatus = EntityStatus.Active, +RelationshipType = "", +RelationshipAttributes = new AtlasStruct +{ +Attributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +TypeName = "", +LastModifiedTS = "", +}, +RelationshipGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), +RelationshipStatus = StatusAtlasRelationship.Active, +}}, + Categories = {new AtlasTermCategorizationHeader +{ +CategoryGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), +Description = "", +DisplayText = "", +RelationGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), +Status = AtlasTermRelationshipStatus.Draft, +}}, + Classifies = { default }, + Examples = { "" }, + IsA = { default }, + PreferredTerms = { default }, + PreferredToTerms = { default }, + ReplacedBy = { default }, + ReplacementTerms = { default }, + SeeAlso = { default }, + Synonyms = { default }, + TranslatedTerms = { default }, + TranslationTerms = { default }, + Usage = "", + ValidValues = { default }, + ValidValuesFor = { default }, + }; + Response response = await client.CreateTermAsync(glossaryTerm, includeTermHierarchy: true); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_GetTerm_ShortVersion() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = client.GetTerm("", null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_GetTerm_ShortVersion_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = await client.GetTermAsync("", null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_GetTerm_ShortVersion_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = client.GetTerm(""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_GetTerm_ShortVersion_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = await client.GetTermAsync(""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_GetTerm_AllParameters() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = client.GetTerm("", null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("longDescription").ToString()); + Console.WriteLine(result.GetProperty("name").ToString()); + Console.WriteLine(result.GetProperty("qualifiedName").ToString()); + Console.WriteLine(result.GetProperty("shortDescription").ToString()); + Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("createTime").ToString()); + Console.WriteLine(result.GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("updateTime").ToString()); + Console.WriteLine(result.GetProperty("updatedBy").ToString()); + Console.WriteLine(result.GetProperty("abbreviation").ToString()); + Console.WriteLine(result.GetProperty("templateName")[0].ToString()); + Console.WriteLine(result.GetProperty("anchor").GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("anchor").GetProperty("glossaryGuid").ToString()); + Console.WriteLine(result.GetProperty("anchor").GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("nickName").ToString()); + Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("uniqueAttributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("name").ToString()); + Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("itemPath").ToString()); + Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("resourceId").ToString()); + Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("properties").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("resources")[0].GetProperty("displayName").ToString()); + Console.WriteLine(result.GetProperty("resources")[0].GetProperty("url").ToString()); + Console.WriteLine(result.GetProperty("contacts").GetProperty("")[0].GetProperty("id").ToString()); + Console.WriteLine(result.GetProperty("contacts").GetProperty("")[0].GetProperty("info").ToString()); + Console.WriteLine(result.GetProperty("attributes").GetProperty("").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("uniqueAttributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipType").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipGuid").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipStatus").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("categoryGuid").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("examples")[0].ToString()); + Console.WriteLine(result.GetProperty("isA")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("isA")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("isA")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("isA")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("isA")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("isA")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("isA")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("usage").ToString()); + Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("termGuid").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_GetTerm_AllParameters_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = await client.GetTermAsync("", null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("longDescription").ToString()); + Console.WriteLine(result.GetProperty("name").ToString()); + Console.WriteLine(result.GetProperty("qualifiedName").ToString()); + Console.WriteLine(result.GetProperty("shortDescription").ToString()); + Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("createTime").ToString()); + Console.WriteLine(result.GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("updateTime").ToString()); + Console.WriteLine(result.GetProperty("updatedBy").ToString()); + Console.WriteLine(result.GetProperty("abbreviation").ToString()); + Console.WriteLine(result.GetProperty("templateName")[0].ToString()); + Console.WriteLine(result.GetProperty("anchor").GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("anchor").GetProperty("glossaryGuid").ToString()); + Console.WriteLine(result.GetProperty("anchor").GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("nickName").ToString()); + Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("uniqueAttributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("name").ToString()); + Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("itemPath").ToString()); + Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("resourceId").ToString()); + Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("properties").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("resources")[0].GetProperty("displayName").ToString()); + Console.WriteLine(result.GetProperty("resources")[0].GetProperty("url").ToString()); + Console.WriteLine(result.GetProperty("contacts").GetProperty("")[0].GetProperty("id").ToString()); + Console.WriteLine(result.GetProperty("contacts").GetProperty("")[0].GetProperty("info").ToString()); + Console.WriteLine(result.GetProperty("attributes").GetProperty("").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("uniqueAttributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipType").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipGuid").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipStatus").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("categoryGuid").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("examples")[0].ToString()); + Console.WriteLine(result.GetProperty("isA")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("isA")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("isA")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("isA")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("isA")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("isA")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("isA")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("usage").ToString()); + Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("termGuid").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_GetTerm_AllParameters_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = client.GetTerm(""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_GetTerm_AllParameters_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = await client.GetTermAsync(""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_UpdateTerm_ShortVersion() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object()); + Response response = client.UpdateTerm("", content); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_UpdateTerm_ShortVersion_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object()); + Response response = await client.UpdateTermAsync("", content); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_UpdateTerm_ShortVersion_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + AtlasGlossaryTerm glossaryTerm = new AtlasGlossaryTerm(); + Response response = client.UpdateTerm("", glossaryTerm); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_UpdateTerm_ShortVersion_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + AtlasGlossaryTerm glossaryTerm = new AtlasGlossaryTerm(); + Response response = await client.UpdateTermAsync("", glossaryTerm); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_UpdateTerm_AllParameters() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new + { + guid = "", + classifications = new object[] + { +new +{ +attributes = new +{ +key = new object(), +}, +typeName = "", +lastModifiedTS = "", +entityGuid = "", +entityStatus = "ACTIVE", +removePropagationsOnEntityDelete = true, +validityPeriods = new object[] +{ +new +{ +endTime = "", +startTime = "", +timeZone = "", +} +}, +} + }, + longDescription = "", + name = "", + qualifiedName = "", + shortDescription = "", + lastModifiedTS = "", + createTime = 1234L, + createdBy = "", + updateTime = 1234L, + updatedBy = "", + abbreviation = "", + templateName = new object[] + { +new object() + }, + anchor = new + { + displayText = "", + glossaryGuid = "", + relationGuid = "", + }, + antonyms = new object[] + { +new +{ +description = "", +displayText = "", +expression = "", +relationGuid = "", +status = "DRAFT", +steward = "", +termGuid = "", +} + }, + status = "Draft", + nickName = "", + hierarchyInfo = new object[] + { +new +{ +guid = "", +typeName = "", +uniqueAttributes = new +{ +key = new object(), +}, +name = "", +displayText = "", +itemPath = "", +resourceId = "", +properties = new +{ +key = new object(), +}, +} + }, + resources = new object[] + { +new +{ +displayName = "", +url = "", +} + }, + contacts = new + { + key = new object[] + { +new +{ +id = "", +info = "", +} + }, + }, + attributes = new + { + key = new + { + key = new object(), + }, + }, + assignedEntities = new object[] + { +new +{ +guid = "", +typeName = "", +uniqueAttributes = new +{ +key = new object(), +}, +displayText = "", +entityStatus = "ACTIVE", +relationshipType = "", +relationshipAttributes = new +{ +attributes = new +{ +key = new object(), +}, +typeName = "", +lastModifiedTS = "", +}, +relationshipGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", +relationshipStatus = "ACTIVE", +} + }, + categories = new object[] + { +new +{ +categoryGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", +description = "", +displayText = "", +relationGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", +status = "DRAFT", +} + }, + classifies = new object[] + { +null + }, + examples = new object[] + { +"" + }, + isA = new object[] + { +null + }, + preferredTerms = new object[] + { +null + }, + preferredToTerms = new object[] + { +null + }, + replacedBy = new object[] + { +null + }, + replacementTerms = new object[] + { +null + }, + seeAlso = new object[] + { +null + }, + synonyms = new object[] + { +null + }, + translatedTerms = new object[] + { +null + }, + translationTerms = new object[] + { +null + }, + usage = "", + validValues = new object[] + { +null + }, + validValuesFor = new object[] + { +null + }, + }); + Response response = client.UpdateTerm("", content, includeTermHierarchy: true); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("longDescription").ToString()); + Console.WriteLine(result.GetProperty("name").ToString()); + Console.WriteLine(result.GetProperty("qualifiedName").ToString()); + Console.WriteLine(result.GetProperty("shortDescription").ToString()); + Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("createTime").ToString()); + Console.WriteLine(result.GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("updateTime").ToString()); + Console.WriteLine(result.GetProperty("updatedBy").ToString()); + Console.WriteLine(result.GetProperty("abbreviation").ToString()); + Console.WriteLine(result.GetProperty("templateName")[0].ToString()); + Console.WriteLine(result.GetProperty("anchor").GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("anchor").GetProperty("glossaryGuid").ToString()); + Console.WriteLine(result.GetProperty("anchor").GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("nickName").ToString()); + Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("uniqueAttributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("name").ToString()); + Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("itemPath").ToString()); + Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("resourceId").ToString()); + Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("properties").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("resources")[0].GetProperty("displayName").ToString()); + Console.WriteLine(result.GetProperty("resources")[0].GetProperty("url").ToString()); + Console.WriteLine(result.GetProperty("contacts").GetProperty("")[0].GetProperty("id").ToString()); + Console.WriteLine(result.GetProperty("contacts").GetProperty("")[0].GetProperty("info").ToString()); + Console.WriteLine(result.GetProperty("attributes").GetProperty("").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("uniqueAttributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipType").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipGuid").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipStatus").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("categoryGuid").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("examples")[0].ToString()); + Console.WriteLine(result.GetProperty("isA")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("isA")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("isA")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("isA")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("isA")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("isA")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("isA")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("usage").ToString()); + Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("termGuid").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_UpdateTerm_AllParameters_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new + { + guid = "", + classifications = new object[] + { +new +{ +attributes = new +{ +key = new object(), +}, +typeName = "", +lastModifiedTS = "", +entityGuid = "", +entityStatus = "ACTIVE", +removePropagationsOnEntityDelete = true, +validityPeriods = new object[] +{ +new +{ +endTime = "", +startTime = "", +timeZone = "", +} +}, +} + }, + longDescription = "", + name = "", + qualifiedName = "", + shortDescription = "", + lastModifiedTS = "", + createTime = 1234L, + createdBy = "", + updateTime = 1234L, + updatedBy = "", + abbreviation = "", + templateName = new object[] + { +new object() + }, + anchor = new + { + displayText = "", + glossaryGuid = "", + relationGuid = "", + }, + antonyms = new object[] + { +new +{ +description = "", +displayText = "", +expression = "", +relationGuid = "", +status = "DRAFT", +steward = "", +termGuid = "", +} + }, + status = "Draft", + nickName = "", + hierarchyInfo = new object[] + { +new +{ +guid = "", +typeName = "", +uniqueAttributes = new +{ +key = new object(), +}, +name = "", +displayText = "", +itemPath = "", +resourceId = "", +properties = new +{ +key = new object(), +}, +} + }, + resources = new object[] + { +new +{ +displayName = "", +url = "", +} + }, + contacts = new + { + key = new object[] + { +new +{ +id = "", +info = "", +} + }, + }, + attributes = new + { + key = new + { + key = new object(), + }, + }, + assignedEntities = new object[] + { +new +{ +guid = "", +typeName = "", +uniqueAttributes = new +{ +key = new object(), +}, +displayText = "", +entityStatus = "ACTIVE", +relationshipType = "", +relationshipAttributes = new +{ +attributes = new +{ +key = new object(), +}, +typeName = "", +lastModifiedTS = "", +}, +relationshipGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", +relationshipStatus = "ACTIVE", +} + }, + categories = new object[] + { +new +{ +categoryGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", +description = "", +displayText = "", +relationGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", +status = "DRAFT", +} + }, + classifies = new object[] + { +null + }, + examples = new object[] + { +"" + }, + isA = new object[] + { +null + }, + preferredTerms = new object[] + { +null + }, + preferredToTerms = new object[] + { +null + }, + replacedBy = new object[] + { +null + }, + replacementTerms = new object[] + { +null + }, + seeAlso = new object[] + { +null + }, + synonyms = new object[] + { +null + }, + translatedTerms = new object[] + { +null + }, + translationTerms = new object[] + { +null + }, + usage = "", + validValues = new object[] + { +null + }, + validValuesFor = new object[] + { +null + }, + }); + Response response = await client.UpdateTermAsync("", content, includeTermHierarchy: true); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("longDescription").ToString()); + Console.WriteLine(result.GetProperty("name").ToString()); + Console.WriteLine(result.GetProperty("qualifiedName").ToString()); + Console.WriteLine(result.GetProperty("shortDescription").ToString()); + Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("createTime").ToString()); + Console.WriteLine(result.GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("updateTime").ToString()); + Console.WriteLine(result.GetProperty("updatedBy").ToString()); + Console.WriteLine(result.GetProperty("abbreviation").ToString()); + Console.WriteLine(result.GetProperty("templateName")[0].ToString()); + Console.WriteLine(result.GetProperty("anchor").GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("anchor").GetProperty("glossaryGuid").ToString()); + Console.WriteLine(result.GetProperty("anchor").GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("nickName").ToString()); + Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("uniqueAttributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("name").ToString()); + Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("itemPath").ToString()); + Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("resourceId").ToString()); + Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("properties").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("resources")[0].GetProperty("displayName").ToString()); + Console.WriteLine(result.GetProperty("resources")[0].GetProperty("url").ToString()); + Console.WriteLine(result.GetProperty("contacts").GetProperty("")[0].GetProperty("id").ToString()); + Console.WriteLine(result.GetProperty("contacts").GetProperty("")[0].GetProperty("info").ToString()); + Console.WriteLine(result.GetProperty("attributes").GetProperty("").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("uniqueAttributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipType").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipGuid").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipStatus").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("categoryGuid").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("examples")[0].ToString()); + Console.WriteLine(result.GetProperty("isA")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("isA")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("isA")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("isA")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("isA")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("isA")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("isA")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("usage").ToString()); + Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("termGuid").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_UpdateTerm_AllParameters_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + AtlasGlossaryTerm glossaryTerm = new AtlasGlossaryTerm + { + Guid = "", + Classifications = {new AtlasClassification +{ +Attributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +TypeName = "", +LastModifiedTS = "", +EntityGuid = "", +EntityStatus = EntityStatus.Active, +RemovePropagationsOnEntityDelete = true, +ValidityPeriods = {new TimeBoundary +{ +EndTime = "", +StartTime = "", +TimeZone = "", +}}, +}}, + LongDescription = "", + Name = "", + QualifiedName = "", + ShortDescription = "", + LastModifiedTS = "", + CreateTime = 1234L, + CreatedBy = "", + UpdateTime = 1234L, + UpdatedBy = "", + Abbreviation = "", + TemplateName = { BinaryData.FromObjectAsJson(new object()) }, + Anchor = new AtlasGlossaryHeader + { + DisplayText = "", + GlossaryGuid = "", + RelationGuid = "", + }, + Antonyms = {new AtlasRelatedTermHeader +{ +Description = "", +DisplayText = "", +Expression = "", +RelationGuid = "", +Status = AtlasTermRelationshipStatus.Draft, +Steward = "", +TermGuid = "", +}}, + Status = TermStatus.Draft, + NickName = "", + HierarchyInfo = {new PurviewObjectId +{ +Guid = "", +TypeName = "", +UniqueAttributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +Name = "", +DisplayText = "", +ItemPath = "", +ResourceId = "", +Properties = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +}}, + Resources = {new ResourceLink +{ +DisplayName = "", +Url = "", +}}, + Contacts = +{ +["key"] = {new ContactInfo +{ +Id = "", +Info = "", +}} +}, + Attributes = +{ +["key"] = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +} +}, + AssignedEntities = {new AtlasRelatedObjectId +{ +Guid = "", +TypeName = "", +UniqueAttributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +DisplayText = "", +EntityStatus = EntityStatus.Active, +RelationshipType = "", +RelationshipAttributes = new AtlasStruct +{ +Attributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +TypeName = "", +LastModifiedTS = "", +}, +RelationshipGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), +RelationshipStatus = StatusAtlasRelationship.Active, +}}, + Categories = {new AtlasTermCategorizationHeader +{ +CategoryGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), +Description = "", +DisplayText = "", +RelationGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), +Status = AtlasTermRelationshipStatus.Draft, +}}, + Classifies = { default }, + Examples = { "" }, + IsA = { default }, + PreferredTerms = { default }, + PreferredToTerms = { default }, + ReplacedBy = { default }, + ReplacementTerms = { default }, + SeeAlso = { default }, + Synonyms = { default }, + TranslatedTerms = { default }, + TranslationTerms = { default }, + Usage = "", + ValidValues = { default }, + ValidValuesFor = { default }, + }; + Response response = client.UpdateTerm("", glossaryTerm, includeTermHierarchy: true); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_UpdateTerm_AllParameters_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + AtlasGlossaryTerm glossaryTerm = new AtlasGlossaryTerm + { + Guid = "", + Classifications = {new AtlasClassification +{ +Attributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +TypeName = "", +LastModifiedTS = "", +EntityGuid = "", +EntityStatus = EntityStatus.Active, +RemovePropagationsOnEntityDelete = true, +ValidityPeriods = {new TimeBoundary +{ +EndTime = "", +StartTime = "", +TimeZone = "", +}}, +}}, + LongDescription = "", + Name = "", + QualifiedName = "", + ShortDescription = "", + LastModifiedTS = "", + CreateTime = 1234L, + CreatedBy = "", + UpdateTime = 1234L, + UpdatedBy = "", + Abbreviation = "", + TemplateName = { BinaryData.FromObjectAsJson(new object()) }, + Anchor = new AtlasGlossaryHeader + { + DisplayText = "", + GlossaryGuid = "", + RelationGuid = "", + }, + Antonyms = {new AtlasRelatedTermHeader +{ +Description = "", +DisplayText = "", +Expression = "", +RelationGuid = "", +Status = AtlasTermRelationshipStatus.Draft, +Steward = "", +TermGuid = "", +}}, + Status = TermStatus.Draft, + NickName = "", + HierarchyInfo = {new PurviewObjectId +{ +Guid = "", +TypeName = "", +UniqueAttributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +Name = "", +DisplayText = "", +ItemPath = "", +ResourceId = "", +Properties = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +}}, + Resources = {new ResourceLink +{ +DisplayName = "", +Url = "", +}}, + Contacts = +{ +["key"] = {new ContactInfo +{ +Id = "", +Info = "", +}} +}, + Attributes = +{ +["key"] = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +} +}, + AssignedEntities = {new AtlasRelatedObjectId +{ +Guid = "", +TypeName = "", +UniqueAttributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +DisplayText = "", +EntityStatus = EntityStatus.Active, +RelationshipType = "", +RelationshipAttributes = new AtlasStruct +{ +Attributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +TypeName = "", +LastModifiedTS = "", +}, +RelationshipGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), +RelationshipStatus = StatusAtlasRelationship.Active, +}}, + Categories = {new AtlasTermCategorizationHeader +{ +CategoryGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), +Description = "", +DisplayText = "", +RelationGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), +Status = AtlasTermRelationshipStatus.Draft, +}}, + Classifies = { default }, + Examples = { "" }, + IsA = { default }, + PreferredTerms = { default }, + PreferredToTerms = { default }, + ReplacedBy = { default }, + ReplacementTerms = { default }, + SeeAlso = { default }, + Synonyms = { default }, + TranslatedTerms = { default }, + TranslationTerms = { default }, + Usage = "", + ValidValues = { default }, + ValidValuesFor = { default }, + }; + Response response = await client.UpdateTermAsync("", glossaryTerm, includeTermHierarchy: true); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_DeleteTerm_ShortVersion() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = client.DeleteTerm(""); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_DeleteTerm_ShortVersion_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = await client.DeleteTermAsync(""); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_DeleteTerm_AllParameters() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = client.DeleteTerm(""); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_DeleteTerm_AllParameters_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = await client.DeleteTermAsync(""); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_PartialUpdateTerm_ShortVersion() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object()); + Response response = client.PartialUpdateTerm("", content); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_PartialUpdateTerm_ShortVersion_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object()); + Response response = await client.PartialUpdateTermAsync("", content); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_PartialUpdateTerm_ShortVersion_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = client.PartialUpdateTerm("", BinaryData.FromObjectAsJson(new object())); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_PartialUpdateTerm_ShortVersion_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = await client.PartialUpdateTermAsync("", BinaryData.FromObjectAsJson(new object())); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_PartialUpdateTerm_AllParameters() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object()); + Response response = client.PartialUpdateTerm("", content, includeTermHierarchy: true); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("longDescription").ToString()); + Console.WriteLine(result.GetProperty("name").ToString()); + Console.WriteLine(result.GetProperty("qualifiedName").ToString()); + Console.WriteLine(result.GetProperty("shortDescription").ToString()); + Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("createTime").ToString()); + Console.WriteLine(result.GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("updateTime").ToString()); + Console.WriteLine(result.GetProperty("updatedBy").ToString()); + Console.WriteLine(result.GetProperty("abbreviation").ToString()); + Console.WriteLine(result.GetProperty("templateName")[0].ToString()); + Console.WriteLine(result.GetProperty("anchor").GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("anchor").GetProperty("glossaryGuid").ToString()); + Console.WriteLine(result.GetProperty("anchor").GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("nickName").ToString()); + Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("uniqueAttributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("name").ToString()); + Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("itemPath").ToString()); + Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("resourceId").ToString()); + Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("properties").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("resources")[0].GetProperty("displayName").ToString()); + Console.WriteLine(result.GetProperty("resources")[0].GetProperty("url").ToString()); + Console.WriteLine(result.GetProperty("contacts").GetProperty("")[0].GetProperty("id").ToString()); + Console.WriteLine(result.GetProperty("contacts").GetProperty("")[0].GetProperty("info").ToString()); + Console.WriteLine(result.GetProperty("attributes").GetProperty("").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("uniqueAttributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipType").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipGuid").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipStatus").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("categoryGuid").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("examples")[0].ToString()); + Console.WriteLine(result.GetProperty("isA")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("isA")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("isA")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("isA")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("isA")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("isA")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("isA")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("usage").ToString()); + Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("termGuid").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_PartialUpdateTerm_AllParameters_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object()); + Response response = await client.PartialUpdateTermAsync("", content, includeTermHierarchy: true); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("longDescription").ToString()); + Console.WriteLine(result.GetProperty("name").ToString()); + Console.WriteLine(result.GetProperty("qualifiedName").ToString()); + Console.WriteLine(result.GetProperty("shortDescription").ToString()); + Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("createTime").ToString()); + Console.WriteLine(result.GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("updateTime").ToString()); + Console.WriteLine(result.GetProperty("updatedBy").ToString()); + Console.WriteLine(result.GetProperty("abbreviation").ToString()); + Console.WriteLine(result.GetProperty("templateName")[0].ToString()); + Console.WriteLine(result.GetProperty("anchor").GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("anchor").GetProperty("glossaryGuid").ToString()); + Console.WriteLine(result.GetProperty("anchor").GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("antonyms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("nickName").ToString()); + Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("uniqueAttributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("name").ToString()); + Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("itemPath").ToString()); + Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("resourceId").ToString()); + Console.WriteLine(result.GetProperty("hierarchyInfo")[0].GetProperty("properties").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("resources")[0].GetProperty("displayName").ToString()); + Console.WriteLine(result.GetProperty("resources")[0].GetProperty("url").ToString()); + Console.WriteLine(result.GetProperty("contacts").GetProperty("")[0].GetProperty("id").ToString()); + Console.WriteLine(result.GetProperty("contacts").GetProperty("")[0].GetProperty("info").ToString()); + Console.WriteLine(result.GetProperty("attributes").GetProperty("").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("uniqueAttributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipType").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipGuid").ToString()); + Console.WriteLine(result.GetProperty("assignedEntities")[0].GetProperty("relationshipStatus").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("categoryGuid").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("classifies")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("examples")[0].ToString()); + Console.WriteLine(result.GetProperty("isA")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("isA")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("isA")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("isA")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("isA")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("isA")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("isA")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("preferredTerms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("preferredToTerms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("replacedBy")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("replacementTerms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("seeAlso")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("synonyms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("translatedTerms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("translationTerms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("usage").ToString()); + Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("validValues")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("validValuesFor")[0].GetProperty("termGuid").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_PartialUpdateTerm_AllParameters_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = client.PartialUpdateTerm("", BinaryData.FromObjectAsJson(new object()), includeTermHierarchy: true); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_PartialUpdateTerm_AllParameters_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = await client.PartialUpdateTermAsync("", BinaryData.FromObjectAsJson(new object()), includeTermHierarchy: true); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_CreateTerms_ShortVersion() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object[] + { +new object() + }); + Response response = client.CreateTerms(content); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result[0].ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_CreateTerms_ShortVersion_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object[] + { +new object() + }); + Response response = await client.CreateTermsAsync(content); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result[0].ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_CreateTerms_ShortVersion_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response> response = client.CreateTerms(new AtlasGlossaryTerm[] + { +new AtlasGlossaryTerm() + }); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_CreateTerms_ShortVersion_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response> response = await client.CreateTermsAsync(new AtlasGlossaryTerm[] + { +new AtlasGlossaryTerm() + }); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_CreateTerms_AllParameters() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object[] + { +new +{ +guid = "", +classifications = new object[] +{ +new +{ +attributes = new +{ +key = new object(), +}, +typeName = "", +lastModifiedTS = "", +entityGuid = "", +entityStatus = "ACTIVE", +removePropagationsOnEntityDelete = true, +validityPeriods = new object[] +{ +new +{ +endTime = "", +startTime = "", +timeZone = "", +} +}, +} +}, +longDescription = "", +name = "", +qualifiedName = "", +shortDescription = "", +lastModifiedTS = "", +createTime = 1234L, +createdBy = "", +updateTime = 1234L, +updatedBy = "", +abbreviation = "", +templateName = new object[] +{ +new object() +}, +anchor = new +{ +displayText = "", +glossaryGuid = "", +relationGuid = "", +}, +antonyms = new object[] +{ +new +{ +description = "", +displayText = "", +expression = "", +relationGuid = "", +status = "DRAFT", +steward = "", +termGuid = "", +} +}, +status = "Draft", +nickName = "", +hierarchyInfo = new object[] +{ +new +{ +guid = "", +typeName = "", +uniqueAttributes = new +{ +key = new object(), +}, +name = "", +displayText = "", +itemPath = "", +resourceId = "", +properties = new +{ +key = new object(), +}, +} +}, +resources = new object[] +{ +new +{ +displayName = "", +url = "", +} +}, +contacts = new +{ +key = new object[] +{ +new +{ +id = "", +info = "", +} +}, +}, +attributes = new +{ +key = new +{ +key = new object(), +}, +}, +assignedEntities = new object[] +{ +new +{ +guid = "", +typeName = "", +uniqueAttributes = new +{ +key = new object(), +}, +displayText = "", +entityStatus = "ACTIVE", +relationshipType = "", +relationshipAttributes = new +{ +attributes = new +{ +key = new object(), +}, +typeName = "", +lastModifiedTS = "", +}, +relationshipGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", +relationshipStatus = "ACTIVE", +} +}, +categories = new object[] +{ +new +{ +categoryGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", +description = "", +displayText = "", +relationGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", +status = "DRAFT", +} +}, +classifies = new object[] +{ +null +}, +examples = new object[] +{ +"" +}, +isA = new object[] +{ +null +}, +preferredTerms = new object[] +{ +null +}, +preferredToTerms = new object[] +{ +null +}, +replacedBy = new object[] +{ +null +}, +replacementTerms = new object[] +{ +null +}, +seeAlso = new object[] +{ +null +}, +synonyms = new object[] +{ +null +}, +translatedTerms = new object[] +{ +null +}, +translationTerms = new object[] +{ +null +}, +usage = "", +validValues = new object[] +{ +null +}, +validValuesFor = new object[] +{ +null +}, +} + }); + Response response = client.CreateTerms(content, includeTermHierarchy: true); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result[0].GetProperty("guid").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result[0].GetProperty("longDescription").ToString()); + Console.WriteLine(result[0].GetProperty("name").ToString()); + Console.WriteLine(result[0].GetProperty("qualifiedName").ToString()); + Console.WriteLine(result[0].GetProperty("shortDescription").ToString()); + Console.WriteLine(result[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result[0].GetProperty("createTime").ToString()); + Console.WriteLine(result[0].GetProperty("createdBy").ToString()); + Console.WriteLine(result[0].GetProperty("updateTime").ToString()); + Console.WriteLine(result[0].GetProperty("updatedBy").ToString()); + Console.WriteLine(result[0].GetProperty("abbreviation").ToString()); + Console.WriteLine(result[0].GetProperty("templateName")[0].ToString()); + Console.WriteLine(result[0].GetProperty("anchor").GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("anchor").GetProperty("glossaryGuid").ToString()); + Console.WriteLine(result[0].GetProperty("anchor").GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("antonyms")[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("antonyms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("antonyms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result[0].GetProperty("antonyms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("antonyms")[0].GetProperty("status").ToString()); + Console.WriteLine(result[0].GetProperty("antonyms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result[0].GetProperty("antonyms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result[0].GetProperty("status").ToString()); + Console.WriteLine(result[0].GetProperty("nickName").ToString()); + Console.WriteLine(result[0].GetProperty("hierarchyInfo")[0].GetProperty("guid").ToString()); + Console.WriteLine(result[0].GetProperty("hierarchyInfo")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result[0].GetProperty("hierarchyInfo")[0].GetProperty("uniqueAttributes").GetProperty("").ToString()); + Console.WriteLine(result[0].GetProperty("hierarchyInfo")[0].GetProperty("name").ToString()); + Console.WriteLine(result[0].GetProperty("hierarchyInfo")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("hierarchyInfo")[0].GetProperty("itemPath").ToString()); + Console.WriteLine(result[0].GetProperty("hierarchyInfo")[0].GetProperty("resourceId").ToString()); + Console.WriteLine(result[0].GetProperty("hierarchyInfo")[0].GetProperty("properties").GetProperty("").ToString()); + Console.WriteLine(result[0].GetProperty("resources")[0].GetProperty("displayName").ToString()); + Console.WriteLine(result[0].GetProperty("resources")[0].GetProperty("url").ToString()); + Console.WriteLine(result[0].GetProperty("contacts").GetProperty("")[0].GetProperty("id").ToString()); + Console.WriteLine(result[0].GetProperty("contacts").GetProperty("")[0].GetProperty("info").ToString()); + Console.WriteLine(result[0].GetProperty("attributes").GetProperty("").GetProperty("").ToString()); + Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("guid").ToString()); + Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("uniqueAttributes").GetProperty("").ToString()); + Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("relationshipType").ToString()); + Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("typeName").ToString()); + Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("relationshipGuid").ToString()); + Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("relationshipStatus").ToString()); + Console.WriteLine(result[0].GetProperty("categories")[0].GetProperty("categoryGuid").ToString()); + Console.WriteLine(result[0].GetProperty("categories")[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("categories")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("categories")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("categories")[0].GetProperty("status").ToString()); + Console.WriteLine(result[0].GetProperty("classifies")[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("classifies")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("classifies")[0].GetProperty("expression").ToString()); + Console.WriteLine(result[0].GetProperty("classifies")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("classifies")[0].GetProperty("status").ToString()); + Console.WriteLine(result[0].GetProperty("classifies")[0].GetProperty("steward").ToString()); + Console.WriteLine(result[0].GetProperty("classifies")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result[0].GetProperty("examples")[0].ToString()); + Console.WriteLine(result[0].GetProperty("isA")[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("isA")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("isA")[0].GetProperty("expression").ToString()); + Console.WriteLine(result[0].GetProperty("isA")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("isA")[0].GetProperty("status").ToString()); + Console.WriteLine(result[0].GetProperty("isA")[0].GetProperty("steward").ToString()); + Console.WriteLine(result[0].GetProperty("isA")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result[0].GetProperty("preferredTerms")[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("preferredTerms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("preferredTerms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result[0].GetProperty("preferredTerms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("preferredTerms")[0].GetProperty("status").ToString()); + Console.WriteLine(result[0].GetProperty("preferredTerms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result[0].GetProperty("preferredTerms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result[0].GetProperty("preferredToTerms")[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("preferredToTerms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("preferredToTerms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result[0].GetProperty("preferredToTerms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("preferredToTerms")[0].GetProperty("status").ToString()); + Console.WriteLine(result[0].GetProperty("preferredToTerms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result[0].GetProperty("preferredToTerms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result[0].GetProperty("replacedBy")[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("replacedBy")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("replacedBy")[0].GetProperty("expression").ToString()); + Console.WriteLine(result[0].GetProperty("replacedBy")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("replacedBy")[0].GetProperty("status").ToString()); + Console.WriteLine(result[0].GetProperty("replacedBy")[0].GetProperty("steward").ToString()); + Console.WriteLine(result[0].GetProperty("replacedBy")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result[0].GetProperty("replacementTerms")[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("replacementTerms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("replacementTerms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result[0].GetProperty("replacementTerms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("replacementTerms")[0].GetProperty("status").ToString()); + Console.WriteLine(result[0].GetProperty("replacementTerms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result[0].GetProperty("replacementTerms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result[0].GetProperty("seeAlso")[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("seeAlso")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("seeAlso")[0].GetProperty("expression").ToString()); + Console.WriteLine(result[0].GetProperty("seeAlso")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("seeAlso")[0].GetProperty("status").ToString()); + Console.WriteLine(result[0].GetProperty("seeAlso")[0].GetProperty("steward").ToString()); + Console.WriteLine(result[0].GetProperty("seeAlso")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result[0].GetProperty("synonyms")[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("synonyms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("synonyms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result[0].GetProperty("synonyms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("synonyms")[0].GetProperty("status").ToString()); + Console.WriteLine(result[0].GetProperty("synonyms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result[0].GetProperty("synonyms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result[0].GetProperty("translatedTerms")[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("translatedTerms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("translatedTerms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result[0].GetProperty("translatedTerms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("translatedTerms")[0].GetProperty("status").ToString()); + Console.WriteLine(result[0].GetProperty("translatedTerms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result[0].GetProperty("translatedTerms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result[0].GetProperty("translationTerms")[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("translationTerms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("translationTerms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result[0].GetProperty("translationTerms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("translationTerms")[0].GetProperty("status").ToString()); + Console.WriteLine(result[0].GetProperty("translationTerms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result[0].GetProperty("translationTerms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result[0].GetProperty("usage").ToString()); + Console.WriteLine(result[0].GetProperty("validValues")[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("validValues")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("validValues")[0].GetProperty("expression").ToString()); + Console.WriteLine(result[0].GetProperty("validValues")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("validValues")[0].GetProperty("status").ToString()); + Console.WriteLine(result[0].GetProperty("validValues")[0].GetProperty("steward").ToString()); + Console.WriteLine(result[0].GetProperty("validValues")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result[0].GetProperty("validValuesFor")[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("validValuesFor")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("validValuesFor")[0].GetProperty("expression").ToString()); + Console.WriteLine(result[0].GetProperty("validValuesFor")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("validValuesFor")[0].GetProperty("status").ToString()); + Console.WriteLine(result[0].GetProperty("validValuesFor")[0].GetProperty("steward").ToString()); + Console.WriteLine(result[0].GetProperty("validValuesFor")[0].GetProperty("termGuid").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_CreateTerms_AllParameters_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object[] + { +new +{ +guid = "", +classifications = new object[] +{ +new +{ +attributes = new +{ +key = new object(), +}, +typeName = "", +lastModifiedTS = "", +entityGuid = "", +entityStatus = "ACTIVE", +removePropagationsOnEntityDelete = true, +validityPeriods = new object[] +{ +new +{ +endTime = "", +startTime = "", +timeZone = "", +} +}, +} +}, +longDescription = "", +name = "", +qualifiedName = "", +shortDescription = "", +lastModifiedTS = "", +createTime = 1234L, +createdBy = "", +updateTime = 1234L, +updatedBy = "", +abbreviation = "", +templateName = new object[] +{ +new object() +}, +anchor = new +{ +displayText = "", +glossaryGuid = "", +relationGuid = "", +}, +antonyms = new object[] +{ +new +{ +description = "", +displayText = "", +expression = "", +relationGuid = "", +status = "DRAFT", +steward = "", +termGuid = "", +} +}, +status = "Draft", +nickName = "", +hierarchyInfo = new object[] +{ +new +{ +guid = "", +typeName = "", +uniqueAttributes = new +{ +key = new object(), +}, +name = "", +displayText = "", +itemPath = "", +resourceId = "", +properties = new +{ +key = new object(), +}, +} +}, +resources = new object[] +{ +new +{ +displayName = "", +url = "", +} +}, +contacts = new +{ +key = new object[] +{ +new +{ +id = "", +info = "", +} +}, +}, +attributes = new +{ +key = new +{ +key = new object(), +}, +}, +assignedEntities = new object[] +{ +new +{ +guid = "", +typeName = "", +uniqueAttributes = new +{ +key = new object(), +}, +displayText = "", +entityStatus = "ACTIVE", +relationshipType = "", +relationshipAttributes = new +{ +attributes = new +{ +key = new object(), +}, +typeName = "", +lastModifiedTS = "", +}, +relationshipGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", +relationshipStatus = "ACTIVE", +} +}, +categories = new object[] +{ +new +{ +categoryGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", +description = "", +displayText = "", +relationGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", +status = "DRAFT", +} +}, +classifies = new object[] +{ +null +}, +examples = new object[] +{ +"" +}, +isA = new object[] +{ +null +}, +preferredTerms = new object[] +{ +null +}, +preferredToTerms = new object[] +{ +null +}, +replacedBy = new object[] +{ +null +}, +replacementTerms = new object[] +{ +null +}, +seeAlso = new object[] +{ +null +}, +synonyms = new object[] +{ +null +}, +translatedTerms = new object[] +{ +null +}, +translationTerms = new object[] +{ +null +}, +usage = "", +validValues = new object[] +{ +null +}, +validValuesFor = new object[] +{ +null +}, +} + }); + Response response = await client.CreateTermsAsync(content, includeTermHierarchy: true); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result[0].GetProperty("guid").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result[0].GetProperty("longDescription").ToString()); + Console.WriteLine(result[0].GetProperty("name").ToString()); + Console.WriteLine(result[0].GetProperty("qualifiedName").ToString()); + Console.WriteLine(result[0].GetProperty("shortDescription").ToString()); + Console.WriteLine(result[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result[0].GetProperty("createTime").ToString()); + Console.WriteLine(result[0].GetProperty("createdBy").ToString()); + Console.WriteLine(result[0].GetProperty("updateTime").ToString()); + Console.WriteLine(result[0].GetProperty("updatedBy").ToString()); + Console.WriteLine(result[0].GetProperty("abbreviation").ToString()); + Console.WriteLine(result[0].GetProperty("templateName")[0].ToString()); + Console.WriteLine(result[0].GetProperty("anchor").GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("anchor").GetProperty("glossaryGuid").ToString()); + Console.WriteLine(result[0].GetProperty("anchor").GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("antonyms")[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("antonyms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("antonyms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result[0].GetProperty("antonyms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("antonyms")[0].GetProperty("status").ToString()); + Console.WriteLine(result[0].GetProperty("antonyms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result[0].GetProperty("antonyms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result[0].GetProperty("status").ToString()); + Console.WriteLine(result[0].GetProperty("nickName").ToString()); + Console.WriteLine(result[0].GetProperty("hierarchyInfo")[0].GetProperty("guid").ToString()); + Console.WriteLine(result[0].GetProperty("hierarchyInfo")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result[0].GetProperty("hierarchyInfo")[0].GetProperty("uniqueAttributes").GetProperty("").ToString()); + Console.WriteLine(result[0].GetProperty("hierarchyInfo")[0].GetProperty("name").ToString()); + Console.WriteLine(result[0].GetProperty("hierarchyInfo")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("hierarchyInfo")[0].GetProperty("itemPath").ToString()); + Console.WriteLine(result[0].GetProperty("hierarchyInfo")[0].GetProperty("resourceId").ToString()); + Console.WriteLine(result[0].GetProperty("hierarchyInfo")[0].GetProperty("properties").GetProperty("").ToString()); + Console.WriteLine(result[0].GetProperty("resources")[0].GetProperty("displayName").ToString()); + Console.WriteLine(result[0].GetProperty("resources")[0].GetProperty("url").ToString()); + Console.WriteLine(result[0].GetProperty("contacts").GetProperty("")[0].GetProperty("id").ToString()); + Console.WriteLine(result[0].GetProperty("contacts").GetProperty("")[0].GetProperty("info").ToString()); + Console.WriteLine(result[0].GetProperty("attributes").GetProperty("").GetProperty("").ToString()); + Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("guid").ToString()); + Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("uniqueAttributes").GetProperty("").ToString()); + Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("relationshipType").ToString()); + Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("typeName").ToString()); + Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("relationshipGuid").ToString()); + Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("relationshipStatus").ToString()); + Console.WriteLine(result[0].GetProperty("categories")[0].GetProperty("categoryGuid").ToString()); + Console.WriteLine(result[0].GetProperty("categories")[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("categories")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("categories")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("categories")[0].GetProperty("status").ToString()); + Console.WriteLine(result[0].GetProperty("classifies")[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("classifies")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("classifies")[0].GetProperty("expression").ToString()); + Console.WriteLine(result[0].GetProperty("classifies")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("classifies")[0].GetProperty("status").ToString()); + Console.WriteLine(result[0].GetProperty("classifies")[0].GetProperty("steward").ToString()); + Console.WriteLine(result[0].GetProperty("classifies")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result[0].GetProperty("examples")[0].ToString()); + Console.WriteLine(result[0].GetProperty("isA")[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("isA")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("isA")[0].GetProperty("expression").ToString()); + Console.WriteLine(result[0].GetProperty("isA")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("isA")[0].GetProperty("status").ToString()); + Console.WriteLine(result[0].GetProperty("isA")[0].GetProperty("steward").ToString()); + Console.WriteLine(result[0].GetProperty("isA")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result[0].GetProperty("preferredTerms")[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("preferredTerms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("preferredTerms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result[0].GetProperty("preferredTerms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("preferredTerms")[0].GetProperty("status").ToString()); + Console.WriteLine(result[0].GetProperty("preferredTerms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result[0].GetProperty("preferredTerms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result[0].GetProperty("preferredToTerms")[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("preferredToTerms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("preferredToTerms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result[0].GetProperty("preferredToTerms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("preferredToTerms")[0].GetProperty("status").ToString()); + Console.WriteLine(result[0].GetProperty("preferredToTerms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result[0].GetProperty("preferredToTerms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result[0].GetProperty("replacedBy")[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("replacedBy")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("replacedBy")[0].GetProperty("expression").ToString()); + Console.WriteLine(result[0].GetProperty("replacedBy")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("replacedBy")[0].GetProperty("status").ToString()); + Console.WriteLine(result[0].GetProperty("replacedBy")[0].GetProperty("steward").ToString()); + Console.WriteLine(result[0].GetProperty("replacedBy")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result[0].GetProperty("replacementTerms")[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("replacementTerms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("replacementTerms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result[0].GetProperty("replacementTerms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("replacementTerms")[0].GetProperty("status").ToString()); + Console.WriteLine(result[0].GetProperty("replacementTerms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result[0].GetProperty("replacementTerms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result[0].GetProperty("seeAlso")[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("seeAlso")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("seeAlso")[0].GetProperty("expression").ToString()); + Console.WriteLine(result[0].GetProperty("seeAlso")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("seeAlso")[0].GetProperty("status").ToString()); + Console.WriteLine(result[0].GetProperty("seeAlso")[0].GetProperty("steward").ToString()); + Console.WriteLine(result[0].GetProperty("seeAlso")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result[0].GetProperty("synonyms")[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("synonyms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("synonyms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result[0].GetProperty("synonyms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("synonyms")[0].GetProperty("status").ToString()); + Console.WriteLine(result[0].GetProperty("synonyms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result[0].GetProperty("synonyms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result[0].GetProperty("translatedTerms")[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("translatedTerms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("translatedTerms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result[0].GetProperty("translatedTerms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("translatedTerms")[0].GetProperty("status").ToString()); + Console.WriteLine(result[0].GetProperty("translatedTerms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result[0].GetProperty("translatedTerms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result[0].GetProperty("translationTerms")[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("translationTerms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("translationTerms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result[0].GetProperty("translationTerms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("translationTerms")[0].GetProperty("status").ToString()); + Console.WriteLine(result[0].GetProperty("translationTerms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result[0].GetProperty("translationTerms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result[0].GetProperty("usage").ToString()); + Console.WriteLine(result[0].GetProperty("validValues")[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("validValues")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("validValues")[0].GetProperty("expression").ToString()); + Console.WriteLine(result[0].GetProperty("validValues")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("validValues")[0].GetProperty("status").ToString()); + Console.WriteLine(result[0].GetProperty("validValues")[0].GetProperty("steward").ToString()); + Console.WriteLine(result[0].GetProperty("validValues")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result[0].GetProperty("validValuesFor")[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("validValuesFor")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("validValuesFor")[0].GetProperty("expression").ToString()); + Console.WriteLine(result[0].GetProperty("validValuesFor")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("validValuesFor")[0].GetProperty("status").ToString()); + Console.WriteLine(result[0].GetProperty("validValuesFor")[0].GetProperty("steward").ToString()); + Console.WriteLine(result[0].GetProperty("validValuesFor")[0].GetProperty("termGuid").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_CreateTerms_AllParameters_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response> response = client.CreateTerms(new AtlasGlossaryTerm[] + { +new AtlasGlossaryTerm +{ +Guid = "", +Classifications = {new AtlasClassification +{ +Attributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +TypeName = "", +LastModifiedTS = "", +EntityGuid = "", +EntityStatus = EntityStatus.Active, +RemovePropagationsOnEntityDelete = true, +ValidityPeriods = {new TimeBoundary +{ +EndTime = "", +StartTime = "", +TimeZone = "", +}}, +}}, +LongDescription = "", +Name = "", +QualifiedName = "", +ShortDescription = "", +LastModifiedTS = "", +CreateTime = 1234L, +CreatedBy = "", +UpdateTime = 1234L, +UpdatedBy = "", +Abbreviation = "", +TemplateName = {BinaryData.FromObjectAsJson(new object())}, +Anchor = new AtlasGlossaryHeader +{ +DisplayText = "", +GlossaryGuid = "", +RelationGuid = "", +}, +Antonyms = {new AtlasRelatedTermHeader +{ +Description = "", +DisplayText = "", +Expression = "", +RelationGuid = "", +Status = AtlasTermRelationshipStatus.Draft, +Steward = "", +TermGuid = "", +}}, +Status = TermStatus.Draft, +NickName = "", +HierarchyInfo = {new PurviewObjectId +{ +Guid = "", +TypeName = "", +UniqueAttributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +Name = "", +DisplayText = "", +ItemPath = "", +ResourceId = "", +Properties = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +}}, +Resources = {new ResourceLink +{ +DisplayName = "", +Url = "", +}}, +Contacts = +{ +["key"] = {new ContactInfo +{ +Id = "", +Info = "", +}} +}, +Attributes = +{ +["key"] = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +} +}, +AssignedEntities = {new AtlasRelatedObjectId +{ +Guid = "", +TypeName = "", +UniqueAttributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +DisplayText = "", +EntityStatus = EntityStatus.Active, +RelationshipType = "", +RelationshipAttributes = new AtlasStruct +{ +Attributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +TypeName = "", +LastModifiedTS = "", +}, +RelationshipGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), +RelationshipStatus = StatusAtlasRelationship.Active, +}}, +Categories = {new AtlasTermCategorizationHeader +{ +CategoryGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), +Description = "", +DisplayText = "", +RelationGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), +Status = AtlasTermRelationshipStatus.Draft, +}}, +Classifies = {default}, +Examples = {""}, +IsA = {default}, +PreferredTerms = {default}, +PreferredToTerms = {default}, +ReplacedBy = {default}, +ReplacementTerms = {default}, +SeeAlso = {default}, +Synonyms = {default}, +TranslatedTerms = {default}, +TranslationTerms = {default}, +Usage = "", +ValidValues = {default}, +ValidValuesFor = {default}, +} + }, includeTermHierarchy: true); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_CreateTerms_AllParameters_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response> response = await client.CreateTermsAsync(new AtlasGlossaryTerm[] + { +new AtlasGlossaryTerm +{ +Guid = "", +Classifications = {new AtlasClassification +{ +Attributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +TypeName = "", +LastModifiedTS = "", +EntityGuid = "", +EntityStatus = EntityStatus.Active, +RemovePropagationsOnEntityDelete = true, +ValidityPeriods = {new TimeBoundary +{ +EndTime = "", +StartTime = "", +TimeZone = "", +}}, +}}, +LongDescription = "", +Name = "", +QualifiedName = "", +ShortDescription = "", +LastModifiedTS = "", +CreateTime = 1234L, +CreatedBy = "", +UpdateTime = 1234L, +UpdatedBy = "", +Abbreviation = "", +TemplateName = {BinaryData.FromObjectAsJson(new object())}, +Anchor = new AtlasGlossaryHeader +{ +DisplayText = "", +GlossaryGuid = "", +RelationGuid = "", +}, +Antonyms = {new AtlasRelatedTermHeader +{ +Description = "", +DisplayText = "", +Expression = "", +RelationGuid = "", +Status = AtlasTermRelationshipStatus.Draft, +Steward = "", +TermGuid = "", +}}, +Status = TermStatus.Draft, +NickName = "", +HierarchyInfo = {new PurviewObjectId +{ +Guid = "", +TypeName = "", +UniqueAttributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +Name = "", +DisplayText = "", +ItemPath = "", +ResourceId = "", +Properties = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +}}, +Resources = {new ResourceLink +{ +DisplayName = "", +Url = "", +}}, +Contacts = +{ +["key"] = {new ContactInfo +{ +Id = "", +Info = "", +}} +}, +Attributes = +{ +["key"] = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +} +}, +AssignedEntities = {new AtlasRelatedObjectId +{ +Guid = "", +TypeName = "", +UniqueAttributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +DisplayText = "", +EntityStatus = EntityStatus.Active, +RelationshipType = "", +RelationshipAttributes = new AtlasStruct +{ +Attributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +TypeName = "", +LastModifiedTS = "", +}, +RelationshipGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), +RelationshipStatus = StatusAtlasRelationship.Active, +}}, +Categories = {new AtlasTermCategorizationHeader +{ +CategoryGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), +Description = "", +DisplayText = "", +RelationGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), +Status = AtlasTermRelationshipStatus.Draft, +}}, +Classifies = {default}, +Examples = {""}, +IsA = {default}, +PreferredTerms = {default}, +PreferredToTerms = {default}, +ReplacedBy = {default}, +ReplacementTerms = {default}, +SeeAlso = {default}, +Synonyms = {default}, +TranslatedTerms = {default}, +TranslationTerms = {default}, +Usage = "", +ValidValues = {default}, +ValidValuesFor = {default}, +} + }, includeTermHierarchy: true); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_GetEntitiesAssignedWithTerm_ShortVersion() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = client.GetEntitiesAssignedWithTerm("", null, null, null, null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result[0].ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_GetEntitiesAssignedWithTerm_ShortVersion_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = await client.GetEntitiesAssignedWithTermAsync("", null, null, null, null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result[0].ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_GetEntitiesAssignedWithTerm_ShortVersion_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response> response = client.GetEntitiesAssignedWithTerm(""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_GetEntitiesAssignedWithTerm_ShortVersion_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response> response = await client.GetEntitiesAssignedWithTermAsync(""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_GetEntitiesAssignedWithTerm_AllParameters() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = client.GetEntitiesAssignedWithTerm("", 1234, 1234, "", null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result[0].GetProperty("guid").ToString()); + Console.WriteLine(result[0].GetProperty("typeName").ToString()); + Console.WriteLine(result[0].GetProperty("uniqueAttributes").GetProperty("").ToString()); + Console.WriteLine(result[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result[0].GetProperty("relationshipType").ToString()); + Console.WriteLine(result[0].GetProperty("relationshipAttributes").GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result[0].GetProperty("relationshipAttributes").GetProperty("typeName").ToString()); + Console.WriteLine(result[0].GetProperty("relationshipAttributes").GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result[0].GetProperty("relationshipGuid").ToString()); + Console.WriteLine(result[0].GetProperty("relationshipStatus").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_GetEntitiesAssignedWithTerm_AllParameters_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = await client.GetEntitiesAssignedWithTermAsync("", 1234, 1234, "", null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result[0].GetProperty("guid").ToString()); + Console.WriteLine(result[0].GetProperty("typeName").ToString()); + Console.WriteLine(result[0].GetProperty("uniqueAttributes").GetProperty("").ToString()); + Console.WriteLine(result[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result[0].GetProperty("relationshipType").ToString()); + Console.WriteLine(result[0].GetProperty("relationshipAttributes").GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result[0].GetProperty("relationshipAttributes").GetProperty("typeName").ToString()); + Console.WriteLine(result[0].GetProperty("relationshipAttributes").GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result[0].GetProperty("relationshipGuid").ToString()); + Console.WriteLine(result[0].GetProperty("relationshipStatus").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_GetEntitiesAssignedWithTerm_AllParameters_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response> response = client.GetEntitiesAssignedWithTerm("", limit: 1234, offset: 1234, sort: ""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_GetEntitiesAssignedWithTerm_AllParameters_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response> response = await client.GetEntitiesAssignedWithTermAsync("", limit: 1234, offset: 1234, sort: ""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_AssignTermToEntities_ShortVersion() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object[] + { +new object() + }); + Response response = client.AssignTermToEntities("", content); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_AssignTermToEntities_ShortVersion_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object[] + { +new object() + }); + Response response = await client.AssignTermToEntitiesAsync("", content); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_AssignTermToEntities_ShortVersion_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = client.AssignTermToEntities("", new AtlasRelatedObjectId[] + { +new AtlasRelatedObjectId() + }); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_AssignTermToEntities_ShortVersion_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = await client.AssignTermToEntitiesAsync("", new AtlasRelatedObjectId[] + { +new AtlasRelatedObjectId() + }); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_AssignTermToEntities_AllParameters() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object[] + { +new +{ +guid = "", +typeName = "", +uniqueAttributes = new +{ +key = new object(), +}, +displayText = "", +entityStatus = "ACTIVE", +relationshipType = "", +relationshipAttributes = new +{ +attributes = new +{ +key = new object(), +}, +typeName = "", +lastModifiedTS = "", +}, +relationshipGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", +relationshipStatus = "ACTIVE", +} + }); + Response response = client.AssignTermToEntities("", content); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_AssignTermToEntities_AllParameters_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object[] + { +new +{ +guid = "", +typeName = "", +uniqueAttributes = new +{ +key = new object(), +}, +displayText = "", +entityStatus = "ACTIVE", +relationshipType = "", +relationshipAttributes = new +{ +attributes = new +{ +key = new object(), +}, +typeName = "", +lastModifiedTS = "", +}, +relationshipGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", +relationshipStatus = "ACTIVE", +} + }); + Response response = await client.AssignTermToEntitiesAsync("", content); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_AssignTermToEntities_AllParameters_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = client.AssignTermToEntities("", new AtlasRelatedObjectId[] + { +new AtlasRelatedObjectId +{ +Guid = "", +TypeName = "", +UniqueAttributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +DisplayText = "", +EntityStatus = EntityStatus.Active, +RelationshipType = "", +RelationshipAttributes = new AtlasStruct +{ +Attributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +TypeName = "", +LastModifiedTS = "", +}, +RelationshipGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), +RelationshipStatus = StatusAtlasRelationship.Active, +} + }); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_AssignTermToEntities_AllParameters_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = await client.AssignTermToEntitiesAsync("", new AtlasRelatedObjectId[] + { +new AtlasRelatedObjectId +{ +Guid = "", +TypeName = "", +UniqueAttributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +DisplayText = "", +EntityStatus = EntityStatus.Active, +RelationshipType = "", +RelationshipAttributes = new AtlasStruct +{ +Attributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +TypeName = "", +LastModifiedTS = "", +}, +RelationshipGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), +RelationshipStatus = StatusAtlasRelationship.Active, +} + }); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_DeleteTermAssignmentFromEntities_ShortVersion() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object[] + { +new object() + }); + Response response = client.DeleteTermAssignmentFromEntities("", content); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_DeleteTermAssignmentFromEntities_ShortVersion_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object[] + { +new object() + }); + Response response = await client.DeleteTermAssignmentFromEntitiesAsync("", content); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_DeleteTermAssignmentFromEntities_ShortVersion_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = client.DeleteTermAssignmentFromEntities("", new AtlasRelatedObjectId[] + { +new AtlasRelatedObjectId() + }); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_DeleteTermAssignmentFromEntities_ShortVersion_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = await client.DeleteTermAssignmentFromEntitiesAsync("", new AtlasRelatedObjectId[] + { +new AtlasRelatedObjectId() + }); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_DeleteTermAssignmentFromEntities_AllParameters() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object[] + { +new +{ +guid = "", +typeName = "", +uniqueAttributes = new +{ +key = new object(), +}, +displayText = "", +entityStatus = "ACTIVE", +relationshipType = "", +relationshipAttributes = new +{ +attributes = new +{ +key = new object(), +}, +typeName = "", +lastModifiedTS = "", +}, +relationshipGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", +relationshipStatus = "ACTIVE", +} + }); + Response response = client.DeleteTermAssignmentFromEntities("", content); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_DeleteTermAssignmentFromEntities_AllParameters_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object[] + { +new +{ +guid = "", +typeName = "", +uniqueAttributes = new +{ +key = new object(), +}, +displayText = "", +entityStatus = "ACTIVE", +relationshipType = "", +relationshipAttributes = new +{ +attributes = new +{ +key = new object(), +}, +typeName = "", +lastModifiedTS = "", +}, +relationshipGuid = "73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a", +relationshipStatus = "ACTIVE", +} + }); + Response response = await client.DeleteTermAssignmentFromEntitiesAsync("", content); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_DeleteTermAssignmentFromEntities_AllParameters_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = client.DeleteTermAssignmentFromEntities("", new AtlasRelatedObjectId[] + { +new AtlasRelatedObjectId +{ +Guid = "", +TypeName = "", +UniqueAttributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +DisplayText = "", +EntityStatus = EntityStatus.Active, +RelationshipType = "", +RelationshipAttributes = new AtlasStruct +{ +Attributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +TypeName = "", +LastModifiedTS = "", +}, +RelationshipGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), +RelationshipStatus = StatusAtlasRelationship.Active, +} + }); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_DeleteTermAssignmentFromEntities_AllParameters_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = await client.DeleteTermAssignmentFromEntitiesAsync("", new AtlasRelatedObjectId[] + { +new AtlasRelatedObjectId +{ +Guid = "", +TypeName = "", +UniqueAttributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +DisplayText = "", +EntityStatus = EntityStatus.Active, +RelationshipType = "", +RelationshipAttributes = new AtlasStruct +{ +Attributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +TypeName = "", +LastModifiedTS = "", +}, +RelationshipGuid = Guid.Parse("73f411fe-4f43-4b4b-9cbd-6828d8f4cf9a"), +RelationshipStatus = StatusAtlasRelationship.Active, +} + }); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_GetRelatedTerms_ShortVersion() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = client.GetRelatedTerms("", null, null, null, null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("")[0].ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_GetRelatedTerms_ShortVersion_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = await client.GetRelatedTermsAsync("", null, null, null, null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("")[0].ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_GetRelatedTerms_ShortVersion_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response>> response = client.GetRelatedTerms(""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_GetRelatedTerms_ShortVersion_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response>> response = await client.GetRelatedTermsAsync(""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_GetRelatedTerms_AllParameters() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = client.GetRelatedTerms("", 1234, 1234, "", null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("")[0].GetProperty("termGuid").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_GetRelatedTerms_AllParameters_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = await client.GetRelatedTermsAsync("", 1234, 1234, "", null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("")[0].GetProperty("termGuid").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_GetRelatedTerms_AllParameters_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response>> response = client.GetRelatedTerms("", limit: 1234, offset: 1234, sort: ""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_GetRelatedTerms_AllParameters_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response>> response = await client.GetRelatedTermsAsync("", limit: 1234, offset: 1234, sort: ""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_GetGlossary_ShortVersion() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = client.GetGlossary("", null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_GetGlossary_ShortVersion_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = await client.GetGlossaryAsync("", null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_GetGlossary_ShortVersion_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = client.GetGlossary(""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_GetGlossary_ShortVersion_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = await client.GetGlossaryAsync(""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_GetGlossary_AllParameters() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = client.GetGlossary("", null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("longDescription").ToString()); + Console.WriteLine(result.GetProperty("name").ToString()); + Console.WriteLine(result.GetProperty("qualifiedName").ToString()); + Console.WriteLine(result.GetProperty("shortDescription").ToString()); + Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("createTime").ToString()); + Console.WriteLine(result.GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("updateTime").ToString()); + Console.WriteLine(result.GetProperty("updatedBy").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("categoryGuid").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("parentCategoryGuid").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("language").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("usage").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_GetGlossary_AllParameters_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = await client.GetGlossaryAsync("", null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("longDescription").ToString()); + Console.WriteLine(result.GetProperty("name").ToString()); + Console.WriteLine(result.GetProperty("qualifiedName").ToString()); + Console.WriteLine(result.GetProperty("shortDescription").ToString()); + Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("createTime").ToString()); + Console.WriteLine(result.GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("updateTime").ToString()); + Console.WriteLine(result.GetProperty("updatedBy").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("categoryGuid").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("parentCategoryGuid").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("language").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("usage").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_GetGlossary_AllParameters_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = client.GetGlossary(""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_GetGlossary_AllParameters_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = await client.GetGlossaryAsync(""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_Update_ShortVersion() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object()); + Response response = client.Update("", content); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_Update_ShortVersion_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object()); + Response response = await client.UpdateAsync("", content); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_Update_ShortVersion_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + AtlasGlossary updatedGlossary = new AtlasGlossary(); + Response response = client.Update("", updatedGlossary); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_Update_ShortVersion_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + AtlasGlossary updatedGlossary = new AtlasGlossary(); + Response response = await client.UpdateAsync("", updatedGlossary); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_Update_AllParameters() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new + { + guid = "", + classifications = new object[] + { +new +{ +attributes = new +{ +key = new object(), +}, +typeName = "", +lastModifiedTS = "", +entityGuid = "", +entityStatus = "ACTIVE", +removePropagationsOnEntityDelete = true, +validityPeriods = new object[] +{ +new +{ +endTime = "", +startTime = "", +timeZone = "", +} +}, +} + }, + longDescription = "", + name = "", + qualifiedName = "", + shortDescription = "", + lastModifiedTS = "", + createTime = 1234L, + createdBy = "", + updateTime = 1234L, + updatedBy = "", + categories = new object[] + { +new +{ +categoryGuid = "", +description = "", +displayText = "", +parentCategoryGuid = "", +relationGuid = "", +} + }, + language = "", + terms = new object[] + { +new +{ +description = "", +displayText = "", +expression = "", +relationGuid = "", +status = "DRAFT", +steward = "", +termGuid = "", +} + }, + usage = "", + }); + Response response = client.Update("", content, ignoreTermsAndCategories: true); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("longDescription").ToString()); + Console.WriteLine(result.GetProperty("name").ToString()); + Console.WriteLine(result.GetProperty("qualifiedName").ToString()); + Console.WriteLine(result.GetProperty("shortDescription").ToString()); + Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("createTime").ToString()); + Console.WriteLine(result.GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("updateTime").ToString()); + Console.WriteLine(result.GetProperty("updatedBy").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("categoryGuid").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("parentCategoryGuid").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("language").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("usage").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_Update_AllParameters_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new + { + guid = "", + classifications = new object[] + { +new +{ +attributes = new +{ +key = new object(), +}, +typeName = "", +lastModifiedTS = "", +entityGuid = "", +entityStatus = "ACTIVE", +removePropagationsOnEntityDelete = true, +validityPeriods = new object[] +{ +new +{ +endTime = "", +startTime = "", +timeZone = "", +} +}, +} + }, + longDescription = "", + name = "", + qualifiedName = "", + shortDescription = "", + lastModifiedTS = "", + createTime = 1234L, + createdBy = "", + updateTime = 1234L, + updatedBy = "", + categories = new object[] + { +new +{ +categoryGuid = "", +description = "", +displayText = "", +parentCategoryGuid = "", +relationGuid = "", +} + }, + language = "", + terms = new object[] + { +new +{ +description = "", +displayText = "", +expression = "", +relationGuid = "", +status = "DRAFT", +steward = "", +termGuid = "", +} + }, + usage = "", + }); + Response response = await client.UpdateAsync("", content, ignoreTermsAndCategories: true); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("longDescription").ToString()); + Console.WriteLine(result.GetProperty("name").ToString()); + Console.WriteLine(result.GetProperty("qualifiedName").ToString()); + Console.WriteLine(result.GetProperty("shortDescription").ToString()); + Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("createTime").ToString()); + Console.WriteLine(result.GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("updateTime").ToString()); + Console.WriteLine(result.GetProperty("updatedBy").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("categoryGuid").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("parentCategoryGuid").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("language").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("usage").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_Update_AllParameters_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + AtlasGlossary updatedGlossary = new AtlasGlossary + { + Guid = "", + Classifications = {new AtlasClassification +{ +Attributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +TypeName = "", +LastModifiedTS = "", +EntityGuid = "", +EntityStatus = EntityStatus.Active, +RemovePropagationsOnEntityDelete = true, +ValidityPeriods = {new TimeBoundary +{ +EndTime = "", +StartTime = "", +TimeZone = "", +}}, +}}, + LongDescription = "", + Name = "", + QualifiedName = "", + ShortDescription = "", + LastModifiedTS = "", + CreateTime = 1234L, + CreatedBy = "", + UpdateTime = 1234L, + UpdatedBy = "", + Categories = {new AtlasRelatedCategoryHeader +{ +CategoryGuid = "", +Description = "", +DisplayText = "", +ParentCategoryGuid = "", +RelationGuid = "", +}}, + Language = "", + Terms = {new AtlasRelatedTermHeader +{ +Description = "", +DisplayText = "", +Expression = "", +RelationGuid = "", +Status = AtlasTermRelationshipStatus.Draft, +Steward = "", +TermGuid = "", +}}, + Usage = "", + }; + Response response = client.Update("", updatedGlossary, ignoreTermsAndCategories: true); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_Update_AllParameters_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + AtlasGlossary updatedGlossary = new AtlasGlossary + { + Guid = "", + Classifications = {new AtlasClassification +{ +Attributes = +{ +["key"] = BinaryData.FromObjectAsJson(new object()) +}, +TypeName = "", +LastModifiedTS = "", +EntityGuid = "", +EntityStatus = EntityStatus.Active, +RemovePropagationsOnEntityDelete = true, +ValidityPeriods = {new TimeBoundary +{ +EndTime = "", +StartTime = "", +TimeZone = "", +}}, +}}, + LongDescription = "", + Name = "", + QualifiedName = "", + ShortDescription = "", + LastModifiedTS = "", + CreateTime = 1234L, + CreatedBy = "", + UpdateTime = 1234L, + UpdatedBy = "", + Categories = {new AtlasRelatedCategoryHeader +{ +CategoryGuid = "", +Description = "", +DisplayText = "", +ParentCategoryGuid = "", +RelationGuid = "", +}}, + Language = "", + Terms = {new AtlasRelatedTermHeader +{ +Description = "", +DisplayText = "", +Expression = "", +RelationGuid = "", +Status = AtlasTermRelationshipStatus.Draft, +Steward = "", +TermGuid = "", +}}, + Usage = "", + }; + Response response = await client.UpdateAsync("", updatedGlossary, ignoreTermsAndCategories: true); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_Delete_ShortVersion() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = client.Delete(""); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_Delete_ShortVersion_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = await client.DeleteAsync(""); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_Delete_AllParameters() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = client.Delete(""); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_Delete_AllParameters_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = await client.DeleteAsync(""); + + Console.WriteLine(response.Status); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_GetCategories_ShortVersion() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = client.GetCategories("", null, null, null, null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result[0].ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_GetCategories_ShortVersion_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = await client.GetCategoriesAsync("", null, null, null, null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result[0].ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_GetCategories_ShortVersion_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response> response = client.GetCategories(""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_GetCategories_ShortVersion_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response> response = await client.GetCategoriesAsync(""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_GetCategories_AllParameters() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = client.GetCategories("", 1234, 1234, "", null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result[0].GetProperty("guid").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result[0].GetProperty("longDescription").ToString()); + Console.WriteLine(result[0].GetProperty("name").ToString()); + Console.WriteLine(result[0].GetProperty("qualifiedName").ToString()); + Console.WriteLine(result[0].GetProperty("shortDescription").ToString()); + Console.WriteLine(result[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result[0].GetProperty("createTime").ToString()); + Console.WriteLine(result[0].GetProperty("createdBy").ToString()); + Console.WriteLine(result[0].GetProperty("updateTime").ToString()); + Console.WriteLine(result[0].GetProperty("updatedBy").ToString()); + Console.WriteLine(result[0].GetProperty("anchor").GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("anchor").GetProperty("glossaryGuid").ToString()); + Console.WriteLine(result[0].GetProperty("anchor").GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("childrenCategories")[0].GetProperty("categoryGuid").ToString()); + Console.WriteLine(result[0].GetProperty("childrenCategories")[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("childrenCategories")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("childrenCategories")[0].GetProperty("parentCategoryGuid").ToString()); + Console.WriteLine(result[0].GetProperty("childrenCategories")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("parentCategory").GetProperty("categoryGuid").ToString()); + Console.WriteLine(result[0].GetProperty("parentCategory").GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("parentCategory").GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("parentCategory").GetProperty("parentCategoryGuid").ToString()); + Console.WriteLine(result[0].GetProperty("parentCategory").GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("status").ToString()); + Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("termGuid").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_GetCategories_AllParameters_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = await client.GetCategoriesAsync("", 1234, 1234, "", null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result[0].GetProperty("guid").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result[0].GetProperty("longDescription").ToString()); + Console.WriteLine(result[0].GetProperty("name").ToString()); + Console.WriteLine(result[0].GetProperty("qualifiedName").ToString()); + Console.WriteLine(result[0].GetProperty("shortDescription").ToString()); + Console.WriteLine(result[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result[0].GetProperty("createTime").ToString()); + Console.WriteLine(result[0].GetProperty("createdBy").ToString()); + Console.WriteLine(result[0].GetProperty("updateTime").ToString()); + Console.WriteLine(result[0].GetProperty("updatedBy").ToString()); + Console.WriteLine(result[0].GetProperty("anchor").GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("anchor").GetProperty("glossaryGuid").ToString()); + Console.WriteLine(result[0].GetProperty("anchor").GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("childrenCategories")[0].GetProperty("categoryGuid").ToString()); + Console.WriteLine(result[0].GetProperty("childrenCategories")[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("childrenCategories")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("childrenCategories")[0].GetProperty("parentCategoryGuid").ToString()); + Console.WriteLine(result[0].GetProperty("childrenCategories")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("parentCategory").GetProperty("categoryGuid").ToString()); + Console.WriteLine(result[0].GetProperty("parentCategory").GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("parentCategory").GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("parentCategory").GetProperty("parentCategoryGuid").ToString()); + Console.WriteLine(result[0].GetProperty("parentCategory").GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("status").ToString()); + Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result[0].GetProperty("terms")[0].GetProperty("termGuid").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_GetCategories_AllParameters_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response> response = client.GetCategories("", limit: 1234, offset: 1234, sort: ""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_GetCategories_AllParameters_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response> response = await client.GetCategoriesAsync("", limit: 1234, offset: 1234, sort: ""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_GetCategoriesHeaders_ShortVersion() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = client.GetCategoriesHeaders("", null, null, null, null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result[0].ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_GetCategoriesHeaders_ShortVersion_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = await client.GetCategoriesHeadersAsync("", null, null, null, null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result[0].ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_GetCategoriesHeaders_ShortVersion_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response> response = client.GetCategoriesHeaders(""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_GetCategoriesHeaders_ShortVersion_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response> response = await client.GetCategoriesHeadersAsync(""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_GetCategoriesHeaders_AllParameters() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = client.GetCategoriesHeaders("", 1234, 1234, "", null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result[0].GetProperty("categoryGuid").ToString()); + Console.WriteLine(result[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("parentCategoryGuid").ToString()); + Console.WriteLine(result[0].GetProperty("relationGuid").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_GetCategoriesHeaders_AllParameters_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = await client.GetCategoriesHeadersAsync("", 1234, 1234, "", null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result[0].GetProperty("categoryGuid").ToString()); + Console.WriteLine(result[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("parentCategoryGuid").ToString()); + Console.WriteLine(result[0].GetProperty("relationGuid").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_GetCategoriesHeaders_AllParameters_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response> response = client.GetCategoriesHeaders("", limit: 1234, offset: 1234, sort: ""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_GetCategoriesHeaders_AllParameters_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response> response = await client.GetCategoriesHeadersAsync("", limit: 1234, offset: 1234, sort: ""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_GetDetailed_ShortVersion() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = client.GetDetailed("", null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_GetDetailed_ShortVersion_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = await client.GetDetailedAsync("", null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_GetDetailed_ShortVersion_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = client.GetDetailed(""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_GetDetailed_ShortVersion_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = await client.GetDetailedAsync(""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_GetDetailed_AllParameters() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = client.GetDetailed("", null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("longDescription").ToString()); + Console.WriteLine(result.GetProperty("name").ToString()); + Console.WriteLine(result.GetProperty("qualifiedName").ToString()); + Console.WriteLine(result.GetProperty("shortDescription").ToString()); + Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("createTime").ToString()); + Console.WriteLine(result.GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("updateTime").ToString()); + Console.WriteLine(result.GetProperty("updatedBy").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("categoryGuid").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("parentCategoryGuid").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("language").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("usage").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("longDescription").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("name").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("qualifiedName").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("shortDescription").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("createTime").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("updateTime").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("updatedBy").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("anchor").GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("anchor").GetProperty("glossaryGuid").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("anchor").GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("childrenCategories")[0].GetProperty("categoryGuid").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("childrenCategories")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("childrenCategories")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("childrenCategories")[0].GetProperty("parentCategoryGuid").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("childrenCategories")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("parentCategory").GetProperty("categoryGuid").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("parentCategory").GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("parentCategory").GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("parentCategory").GetProperty("parentCategoryGuid").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("parentCategory").GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("terms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("terms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("terms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("terms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("terms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("terms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("terms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("longDescription").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("name").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("qualifiedName").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("shortDescription").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("createTime").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("updateTime").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("updatedBy").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("abbreviation").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("templateName")[0].ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("anchor").GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("anchor").GetProperty("glossaryGuid").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("anchor").GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("antonyms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("antonyms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("antonyms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("antonyms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("antonyms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("antonyms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("antonyms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("nickName").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("hierarchyInfo")[0].GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("hierarchyInfo")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("hierarchyInfo")[0].GetProperty("uniqueAttributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("hierarchyInfo")[0].GetProperty("name").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("hierarchyInfo")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("hierarchyInfo")[0].GetProperty("itemPath").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("hierarchyInfo")[0].GetProperty("resourceId").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("hierarchyInfo")[0].GetProperty("properties").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("resources")[0].GetProperty("displayName").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("resources")[0].GetProperty("url").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("contacts").GetProperty("")[0].GetProperty("id").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("contacts").GetProperty("")[0].GetProperty("info").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("attributes").GetProperty("").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("assignedEntities")[0].GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("assignedEntities")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("assignedEntities")[0].GetProperty("uniqueAttributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("assignedEntities")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("assignedEntities")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("assignedEntities")[0].GetProperty("relationshipType").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("assignedEntities")[0].GetProperty("relationshipGuid").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("assignedEntities")[0].GetProperty("relationshipStatus").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("categories")[0].GetProperty("categoryGuid").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("categories")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("categories")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("categories")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("categories")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("classifies")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("classifies")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("classifies")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("classifies")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("classifies")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("classifies")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("classifies")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("examples")[0].ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("isA")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("isA")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("isA")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("isA")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("isA")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("isA")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("isA")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("preferredTerms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("preferredTerms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("preferredTerms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("preferredTerms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("preferredTerms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("preferredTerms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("preferredTerms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("preferredToTerms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("preferredToTerms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("preferredToTerms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("preferredToTerms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("preferredToTerms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("preferredToTerms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("preferredToTerms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("replacedBy")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("replacedBy")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("replacedBy")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("replacedBy")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("replacedBy")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("replacedBy")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("replacedBy")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("replacementTerms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("replacementTerms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("replacementTerms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("replacementTerms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("replacementTerms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("replacementTerms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("replacementTerms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("seeAlso")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("seeAlso")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("seeAlso")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("seeAlso")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("seeAlso")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("seeAlso")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("seeAlso")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("synonyms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("synonyms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("synonyms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("synonyms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("synonyms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("synonyms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("synonyms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("translatedTerms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("translatedTerms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("translatedTerms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("translatedTerms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("translatedTerms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("translatedTerms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("translatedTerms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("translationTerms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("translationTerms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("translationTerms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("translationTerms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("translationTerms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("translationTerms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("translationTerms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("usage").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("validValues")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("validValues")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("validValues")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("validValues")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("validValues")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("validValues")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("validValues")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("validValuesFor")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("validValuesFor")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("validValuesFor")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("validValuesFor")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("validValuesFor")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("validValuesFor")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("validValuesFor")[0].GetProperty("termGuid").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_GetDetailed_AllParameters_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = await client.GetDetailedAsync("", null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("longDescription").ToString()); + Console.WriteLine(result.GetProperty("name").ToString()); + Console.WriteLine(result.GetProperty("qualifiedName").ToString()); + Console.WriteLine(result.GetProperty("shortDescription").ToString()); + Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("createTime").ToString()); + Console.WriteLine(result.GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("updateTime").ToString()); + Console.WriteLine(result.GetProperty("updatedBy").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("categoryGuid").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("parentCategoryGuid").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("language").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("usage").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("longDescription").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("name").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("qualifiedName").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("shortDescription").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("createTime").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("updateTime").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("updatedBy").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("anchor").GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("anchor").GetProperty("glossaryGuid").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("anchor").GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("childrenCategories")[0].GetProperty("categoryGuid").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("childrenCategories")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("childrenCategories")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("childrenCategories")[0].GetProperty("parentCategoryGuid").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("childrenCategories")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("parentCategory").GetProperty("categoryGuid").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("parentCategory").GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("parentCategory").GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("parentCategory").GetProperty("parentCategoryGuid").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("parentCategory").GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("terms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("terms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("terms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("terms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("terms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("terms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("categoryInfo").GetProperty("").GetProperty("terms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("longDescription").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("name").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("qualifiedName").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("shortDescription").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("createTime").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("updateTime").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("updatedBy").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("abbreviation").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("templateName")[0].ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("anchor").GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("anchor").GetProperty("glossaryGuid").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("anchor").GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("antonyms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("antonyms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("antonyms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("antonyms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("antonyms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("antonyms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("antonyms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("nickName").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("hierarchyInfo")[0].GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("hierarchyInfo")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("hierarchyInfo")[0].GetProperty("uniqueAttributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("hierarchyInfo")[0].GetProperty("name").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("hierarchyInfo")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("hierarchyInfo")[0].GetProperty("itemPath").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("hierarchyInfo")[0].GetProperty("resourceId").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("hierarchyInfo")[0].GetProperty("properties").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("resources")[0].GetProperty("displayName").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("resources")[0].GetProperty("url").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("contacts").GetProperty("")[0].GetProperty("id").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("contacts").GetProperty("")[0].GetProperty("info").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("attributes").GetProperty("").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("assignedEntities")[0].GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("assignedEntities")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("assignedEntities")[0].GetProperty("uniqueAttributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("assignedEntities")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("assignedEntities")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("assignedEntities")[0].GetProperty("relationshipType").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("assignedEntities")[0].GetProperty("relationshipGuid").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("assignedEntities")[0].GetProperty("relationshipStatus").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("categories")[0].GetProperty("categoryGuid").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("categories")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("categories")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("categories")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("categories")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("classifies")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("classifies")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("classifies")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("classifies")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("classifies")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("classifies")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("classifies")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("examples")[0].ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("isA")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("isA")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("isA")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("isA")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("isA")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("isA")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("isA")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("preferredTerms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("preferredTerms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("preferredTerms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("preferredTerms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("preferredTerms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("preferredTerms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("preferredTerms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("preferredToTerms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("preferredToTerms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("preferredToTerms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("preferredToTerms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("preferredToTerms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("preferredToTerms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("preferredToTerms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("replacedBy")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("replacedBy")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("replacedBy")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("replacedBy")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("replacedBy")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("replacedBy")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("replacedBy")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("replacementTerms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("replacementTerms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("replacementTerms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("replacementTerms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("replacementTerms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("replacementTerms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("replacementTerms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("seeAlso")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("seeAlso")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("seeAlso")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("seeAlso")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("seeAlso")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("seeAlso")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("seeAlso")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("synonyms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("synonyms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("synonyms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("synonyms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("synonyms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("synonyms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("synonyms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("translatedTerms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("translatedTerms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("translatedTerms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("translatedTerms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("translatedTerms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("translatedTerms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("translatedTerms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("translationTerms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("translationTerms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("translationTerms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("translationTerms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("translationTerms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("translationTerms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("translationTerms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("usage").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("validValues")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("validValues")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("validValues")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("validValues")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("validValues")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("validValues")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("validValues")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("validValuesFor")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("validValuesFor")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("validValuesFor")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("validValuesFor")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("validValuesFor")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("validValuesFor")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("termInfo").GetProperty("").GetProperty("validValuesFor")[0].GetProperty("termGuid").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_GetDetailed_AllParameters_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = client.GetDetailed(""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_GetDetailed_AllParameters_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = await client.GetDetailedAsync(""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_PartialUpdate_ShortVersion() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object()); + Response response = client.PartialUpdate("", content); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_PartialUpdate_ShortVersion_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object()); + Response response = await client.PartialUpdateAsync("", content); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_PartialUpdate_ShortVersion_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = client.PartialUpdate("", BinaryData.FromObjectAsJson(new object())); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_PartialUpdate_ShortVersion_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = await client.PartialUpdateAsync("", BinaryData.FromObjectAsJson(new object())); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_PartialUpdate_AllParameters() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object()); + Response response = client.PartialUpdate("", content, ignoreTermsAndCategories: true); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("longDescription").ToString()); + Console.WriteLine(result.GetProperty("name").ToString()); + Console.WriteLine(result.GetProperty("qualifiedName").ToString()); + Console.WriteLine(result.GetProperty("shortDescription").ToString()); + Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("createTime").ToString()); + Console.WriteLine(result.GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("updateTime").ToString()); + Console.WriteLine(result.GetProperty("updatedBy").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("categoryGuid").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("parentCategoryGuid").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("language").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("usage").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_PartialUpdate_AllParameters_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object()); + Response response = await client.PartialUpdateAsync("", content, ignoreTermsAndCategories: true); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("longDescription").ToString()); + Console.WriteLine(result.GetProperty("name").ToString()); + Console.WriteLine(result.GetProperty("qualifiedName").ToString()); + Console.WriteLine(result.GetProperty("shortDescription").ToString()); + Console.WriteLine(result.GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("createTime").ToString()); + Console.WriteLine(result.GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("updateTime").ToString()); + Console.WriteLine(result.GetProperty("updatedBy").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("categoryGuid").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("parentCategoryGuid").ToString()); + Console.WriteLine(result.GetProperty("categories")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("language").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("terms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("usage").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_PartialUpdate_AllParameters_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = client.PartialUpdate("", BinaryData.FromObjectAsJson(new object()), ignoreTermsAndCategories: true); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_PartialUpdate_AllParameters_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = await client.PartialUpdateAsync("", BinaryData.FromObjectAsJson(new object()), ignoreTermsAndCategories: true); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_GetTerms_ShortVersion() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = client.GetTerms("", null, null, null, null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result[0].ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_GetTerms_ShortVersion_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = await client.GetTermsAsync("", null, null, null, null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result[0].ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_GetTerms_ShortVersion_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response> response = client.GetTerms(""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_GetTerms_ShortVersion_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response> response = await client.GetTermsAsync(""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_GetTerms_AllParameters() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = client.GetTerms("", 1234, 1234, "", null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result[0].GetProperty("guid").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result[0].GetProperty("longDescription").ToString()); + Console.WriteLine(result[0].GetProperty("name").ToString()); + Console.WriteLine(result[0].GetProperty("qualifiedName").ToString()); + Console.WriteLine(result[0].GetProperty("shortDescription").ToString()); + Console.WriteLine(result[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result[0].GetProperty("createTime").ToString()); + Console.WriteLine(result[0].GetProperty("createdBy").ToString()); + Console.WriteLine(result[0].GetProperty("updateTime").ToString()); + Console.WriteLine(result[0].GetProperty("updatedBy").ToString()); + Console.WriteLine(result[0].GetProperty("abbreviation").ToString()); + Console.WriteLine(result[0].GetProperty("templateName")[0].ToString()); + Console.WriteLine(result[0].GetProperty("anchor").GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("anchor").GetProperty("glossaryGuid").ToString()); + Console.WriteLine(result[0].GetProperty("anchor").GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("antonyms")[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("antonyms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("antonyms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result[0].GetProperty("antonyms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("antonyms")[0].GetProperty("status").ToString()); + Console.WriteLine(result[0].GetProperty("antonyms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result[0].GetProperty("antonyms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result[0].GetProperty("status").ToString()); + Console.WriteLine(result[0].GetProperty("nickName").ToString()); + Console.WriteLine(result[0].GetProperty("hierarchyInfo")[0].GetProperty("guid").ToString()); + Console.WriteLine(result[0].GetProperty("hierarchyInfo")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result[0].GetProperty("hierarchyInfo")[0].GetProperty("uniqueAttributes").GetProperty("").ToString()); + Console.WriteLine(result[0].GetProperty("hierarchyInfo")[0].GetProperty("name").ToString()); + Console.WriteLine(result[0].GetProperty("hierarchyInfo")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("hierarchyInfo")[0].GetProperty("itemPath").ToString()); + Console.WriteLine(result[0].GetProperty("hierarchyInfo")[0].GetProperty("resourceId").ToString()); + Console.WriteLine(result[0].GetProperty("hierarchyInfo")[0].GetProperty("properties").GetProperty("").ToString()); + Console.WriteLine(result[0].GetProperty("resources")[0].GetProperty("displayName").ToString()); + Console.WriteLine(result[0].GetProperty("resources")[0].GetProperty("url").ToString()); + Console.WriteLine(result[0].GetProperty("contacts").GetProperty("")[0].GetProperty("id").ToString()); + Console.WriteLine(result[0].GetProperty("contacts").GetProperty("")[0].GetProperty("info").ToString()); + Console.WriteLine(result[0].GetProperty("attributes").GetProperty("").GetProperty("").ToString()); + Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("guid").ToString()); + Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("uniqueAttributes").GetProperty("").ToString()); + Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("relationshipType").ToString()); + Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("typeName").ToString()); + Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("relationshipGuid").ToString()); + Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("relationshipStatus").ToString()); + Console.WriteLine(result[0].GetProperty("categories")[0].GetProperty("categoryGuid").ToString()); + Console.WriteLine(result[0].GetProperty("categories")[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("categories")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("categories")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("categories")[0].GetProperty("status").ToString()); + Console.WriteLine(result[0].GetProperty("classifies")[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("classifies")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("classifies")[0].GetProperty("expression").ToString()); + Console.WriteLine(result[0].GetProperty("classifies")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("classifies")[0].GetProperty("status").ToString()); + Console.WriteLine(result[0].GetProperty("classifies")[0].GetProperty("steward").ToString()); + Console.WriteLine(result[0].GetProperty("classifies")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result[0].GetProperty("examples")[0].ToString()); + Console.WriteLine(result[0].GetProperty("isA")[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("isA")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("isA")[0].GetProperty("expression").ToString()); + Console.WriteLine(result[0].GetProperty("isA")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("isA")[0].GetProperty("status").ToString()); + Console.WriteLine(result[0].GetProperty("isA")[0].GetProperty("steward").ToString()); + Console.WriteLine(result[0].GetProperty("isA")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result[0].GetProperty("preferredTerms")[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("preferredTerms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("preferredTerms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result[0].GetProperty("preferredTerms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("preferredTerms")[0].GetProperty("status").ToString()); + Console.WriteLine(result[0].GetProperty("preferredTerms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result[0].GetProperty("preferredTerms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result[0].GetProperty("preferredToTerms")[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("preferredToTerms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("preferredToTerms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result[0].GetProperty("preferredToTerms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("preferredToTerms")[0].GetProperty("status").ToString()); + Console.WriteLine(result[0].GetProperty("preferredToTerms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result[0].GetProperty("preferredToTerms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result[0].GetProperty("replacedBy")[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("replacedBy")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("replacedBy")[0].GetProperty("expression").ToString()); + Console.WriteLine(result[0].GetProperty("replacedBy")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("replacedBy")[0].GetProperty("status").ToString()); + Console.WriteLine(result[0].GetProperty("replacedBy")[0].GetProperty("steward").ToString()); + Console.WriteLine(result[0].GetProperty("replacedBy")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result[0].GetProperty("replacementTerms")[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("replacementTerms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("replacementTerms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result[0].GetProperty("replacementTerms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("replacementTerms")[0].GetProperty("status").ToString()); + Console.WriteLine(result[0].GetProperty("replacementTerms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result[0].GetProperty("replacementTerms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result[0].GetProperty("seeAlso")[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("seeAlso")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("seeAlso")[0].GetProperty("expression").ToString()); + Console.WriteLine(result[0].GetProperty("seeAlso")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("seeAlso")[0].GetProperty("status").ToString()); + Console.WriteLine(result[0].GetProperty("seeAlso")[0].GetProperty("steward").ToString()); + Console.WriteLine(result[0].GetProperty("seeAlso")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result[0].GetProperty("synonyms")[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("synonyms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("synonyms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result[0].GetProperty("synonyms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("synonyms")[0].GetProperty("status").ToString()); + Console.WriteLine(result[0].GetProperty("synonyms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result[0].GetProperty("synonyms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result[0].GetProperty("translatedTerms")[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("translatedTerms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("translatedTerms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result[0].GetProperty("translatedTerms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("translatedTerms")[0].GetProperty("status").ToString()); + Console.WriteLine(result[0].GetProperty("translatedTerms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result[0].GetProperty("translatedTerms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result[0].GetProperty("translationTerms")[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("translationTerms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("translationTerms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result[0].GetProperty("translationTerms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("translationTerms")[0].GetProperty("status").ToString()); + Console.WriteLine(result[0].GetProperty("translationTerms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result[0].GetProperty("translationTerms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result[0].GetProperty("usage").ToString()); + Console.WriteLine(result[0].GetProperty("validValues")[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("validValues")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("validValues")[0].GetProperty("expression").ToString()); + Console.WriteLine(result[0].GetProperty("validValues")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("validValues")[0].GetProperty("status").ToString()); + Console.WriteLine(result[0].GetProperty("validValues")[0].GetProperty("steward").ToString()); + Console.WriteLine(result[0].GetProperty("validValues")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result[0].GetProperty("validValuesFor")[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("validValuesFor")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("validValuesFor")[0].GetProperty("expression").ToString()); + Console.WriteLine(result[0].GetProperty("validValuesFor")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("validValuesFor")[0].GetProperty("status").ToString()); + Console.WriteLine(result[0].GetProperty("validValuesFor")[0].GetProperty("steward").ToString()); + Console.WriteLine(result[0].GetProperty("validValuesFor")[0].GetProperty("termGuid").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_GetTerms_AllParameters_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = await client.GetTermsAsync("", 1234, 1234, "", null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result[0].GetProperty("guid").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result[0].GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result[0].GetProperty("longDescription").ToString()); + Console.WriteLine(result[0].GetProperty("name").ToString()); + Console.WriteLine(result[0].GetProperty("qualifiedName").ToString()); + Console.WriteLine(result[0].GetProperty("shortDescription").ToString()); + Console.WriteLine(result[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result[0].GetProperty("createTime").ToString()); + Console.WriteLine(result[0].GetProperty("createdBy").ToString()); + Console.WriteLine(result[0].GetProperty("updateTime").ToString()); + Console.WriteLine(result[0].GetProperty("updatedBy").ToString()); + Console.WriteLine(result[0].GetProperty("abbreviation").ToString()); + Console.WriteLine(result[0].GetProperty("templateName")[0].ToString()); + Console.WriteLine(result[0].GetProperty("anchor").GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("anchor").GetProperty("glossaryGuid").ToString()); + Console.WriteLine(result[0].GetProperty("anchor").GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("antonyms")[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("antonyms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("antonyms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result[0].GetProperty("antonyms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("antonyms")[0].GetProperty("status").ToString()); + Console.WriteLine(result[0].GetProperty("antonyms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result[0].GetProperty("antonyms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result[0].GetProperty("status").ToString()); + Console.WriteLine(result[0].GetProperty("nickName").ToString()); + Console.WriteLine(result[0].GetProperty("hierarchyInfo")[0].GetProperty("guid").ToString()); + Console.WriteLine(result[0].GetProperty("hierarchyInfo")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result[0].GetProperty("hierarchyInfo")[0].GetProperty("uniqueAttributes").GetProperty("").ToString()); + Console.WriteLine(result[0].GetProperty("hierarchyInfo")[0].GetProperty("name").ToString()); + Console.WriteLine(result[0].GetProperty("hierarchyInfo")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("hierarchyInfo")[0].GetProperty("itemPath").ToString()); + Console.WriteLine(result[0].GetProperty("hierarchyInfo")[0].GetProperty("resourceId").ToString()); + Console.WriteLine(result[0].GetProperty("hierarchyInfo")[0].GetProperty("properties").GetProperty("").ToString()); + Console.WriteLine(result[0].GetProperty("resources")[0].GetProperty("displayName").ToString()); + Console.WriteLine(result[0].GetProperty("resources")[0].GetProperty("url").ToString()); + Console.WriteLine(result[0].GetProperty("contacts").GetProperty("")[0].GetProperty("id").ToString()); + Console.WriteLine(result[0].GetProperty("contacts").GetProperty("")[0].GetProperty("info").ToString()); + Console.WriteLine(result[0].GetProperty("attributes").GetProperty("").GetProperty("").ToString()); + Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("guid").ToString()); + Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("uniqueAttributes").GetProperty("").ToString()); + Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("relationshipType").ToString()); + Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("typeName").ToString()); + Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("relationshipAttributes").GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("relationshipGuid").ToString()); + Console.WriteLine(result[0].GetProperty("assignedEntities")[0].GetProperty("relationshipStatus").ToString()); + Console.WriteLine(result[0].GetProperty("categories")[0].GetProperty("categoryGuid").ToString()); + Console.WriteLine(result[0].GetProperty("categories")[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("categories")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("categories")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("categories")[0].GetProperty("status").ToString()); + Console.WriteLine(result[0].GetProperty("classifies")[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("classifies")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("classifies")[0].GetProperty("expression").ToString()); + Console.WriteLine(result[0].GetProperty("classifies")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("classifies")[0].GetProperty("status").ToString()); + Console.WriteLine(result[0].GetProperty("classifies")[0].GetProperty("steward").ToString()); + Console.WriteLine(result[0].GetProperty("classifies")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result[0].GetProperty("examples")[0].ToString()); + Console.WriteLine(result[0].GetProperty("isA")[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("isA")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("isA")[0].GetProperty("expression").ToString()); + Console.WriteLine(result[0].GetProperty("isA")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("isA")[0].GetProperty("status").ToString()); + Console.WriteLine(result[0].GetProperty("isA")[0].GetProperty("steward").ToString()); + Console.WriteLine(result[0].GetProperty("isA")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result[0].GetProperty("preferredTerms")[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("preferredTerms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("preferredTerms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result[0].GetProperty("preferredTerms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("preferredTerms")[0].GetProperty("status").ToString()); + Console.WriteLine(result[0].GetProperty("preferredTerms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result[0].GetProperty("preferredTerms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result[0].GetProperty("preferredToTerms")[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("preferredToTerms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("preferredToTerms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result[0].GetProperty("preferredToTerms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("preferredToTerms")[0].GetProperty("status").ToString()); + Console.WriteLine(result[0].GetProperty("preferredToTerms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result[0].GetProperty("preferredToTerms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result[0].GetProperty("replacedBy")[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("replacedBy")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("replacedBy")[0].GetProperty("expression").ToString()); + Console.WriteLine(result[0].GetProperty("replacedBy")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("replacedBy")[0].GetProperty("status").ToString()); + Console.WriteLine(result[0].GetProperty("replacedBy")[0].GetProperty("steward").ToString()); + Console.WriteLine(result[0].GetProperty("replacedBy")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result[0].GetProperty("replacementTerms")[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("replacementTerms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("replacementTerms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result[0].GetProperty("replacementTerms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("replacementTerms")[0].GetProperty("status").ToString()); + Console.WriteLine(result[0].GetProperty("replacementTerms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result[0].GetProperty("replacementTerms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result[0].GetProperty("seeAlso")[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("seeAlso")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("seeAlso")[0].GetProperty("expression").ToString()); + Console.WriteLine(result[0].GetProperty("seeAlso")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("seeAlso")[0].GetProperty("status").ToString()); + Console.WriteLine(result[0].GetProperty("seeAlso")[0].GetProperty("steward").ToString()); + Console.WriteLine(result[0].GetProperty("seeAlso")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result[0].GetProperty("synonyms")[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("synonyms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("synonyms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result[0].GetProperty("synonyms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("synonyms")[0].GetProperty("status").ToString()); + Console.WriteLine(result[0].GetProperty("synonyms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result[0].GetProperty("synonyms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result[0].GetProperty("translatedTerms")[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("translatedTerms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("translatedTerms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result[0].GetProperty("translatedTerms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("translatedTerms")[0].GetProperty("status").ToString()); + Console.WriteLine(result[0].GetProperty("translatedTerms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result[0].GetProperty("translatedTerms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result[0].GetProperty("translationTerms")[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("translationTerms")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("translationTerms")[0].GetProperty("expression").ToString()); + Console.WriteLine(result[0].GetProperty("translationTerms")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("translationTerms")[0].GetProperty("status").ToString()); + Console.WriteLine(result[0].GetProperty("translationTerms")[0].GetProperty("steward").ToString()); + Console.WriteLine(result[0].GetProperty("translationTerms")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result[0].GetProperty("usage").ToString()); + Console.WriteLine(result[0].GetProperty("validValues")[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("validValues")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("validValues")[0].GetProperty("expression").ToString()); + Console.WriteLine(result[0].GetProperty("validValues")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("validValues")[0].GetProperty("status").ToString()); + Console.WriteLine(result[0].GetProperty("validValues")[0].GetProperty("steward").ToString()); + Console.WriteLine(result[0].GetProperty("validValues")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result[0].GetProperty("validValuesFor")[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("validValuesFor")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("validValuesFor")[0].GetProperty("expression").ToString()); + Console.WriteLine(result[0].GetProperty("validValuesFor")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("validValuesFor")[0].GetProperty("status").ToString()); + Console.WriteLine(result[0].GetProperty("validValuesFor")[0].GetProperty("steward").ToString()); + Console.WriteLine(result[0].GetProperty("validValuesFor")[0].GetProperty("termGuid").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_GetTerms_AllParameters_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response> response = client.GetTerms("", limit: 1234, offset: 1234, sort: ""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_GetTerms_AllParameters_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response> response = await client.GetTermsAsync("", limit: 1234, offset: 1234, sort: ""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_GetTermHeaders_ShortVersion() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = client.GetTermHeaders("", null, null, null, null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result[0].ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_GetTermHeaders_ShortVersion_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = await client.GetTermHeadersAsync("", null, null, null, null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result[0].ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_GetTermHeaders_ShortVersion_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response> response = client.GetTermHeaders(""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_GetTermHeaders_ShortVersion_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response> response = await client.GetTermHeadersAsync(""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_GetTermHeaders_AllParameters() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = client.GetTermHeaders("", 1234, 1234, "", null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("expression").ToString()); + Console.WriteLine(result[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("status").ToString()); + Console.WriteLine(result[0].GetProperty("steward").ToString()); + Console.WriteLine(result[0].GetProperty("termGuid").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_GetTermHeaders_AllParameters_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response response = await client.GetTermHeadersAsync("", 1234, 1234, "", null); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result[0].GetProperty("description").ToString()); + Console.WriteLine(result[0].GetProperty("displayText").ToString()); + Console.WriteLine(result[0].GetProperty("expression").ToString()); + Console.WriteLine(result[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result[0].GetProperty("status").ToString()); + Console.WriteLine(result[0].GetProperty("steward").ToString()); + Console.WriteLine(result[0].GetProperty("termGuid").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Glossary_GetTermHeaders_AllParameters_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response> response = client.GetTermHeaders("", limit: 1234, offset: 1234, sort: ""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Glossary_GetTermHeaders_AllParameters_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Glossary client = new DataMapClient(endpoint, credential).GetGlossaryClient(apiVersion: "2023-09-01"); + + Response> response = await client.GetTermHeadersAsync("", limit: 1234, offset: 1234, sort: ""); + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/tests/Generated/Samples/Samples_Lineage.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/tests/Generated/Samples/Samples_Lineage.cs new file mode 100644 index 0000000000000..e4be8dc95179c --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/tests/Generated/Samples/Samples_Lineage.cs @@ -0,0 +1,555 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Text.Json; +using System.Threading.Tasks; +using Azure; +using Azure.Analytics.Purview.DataMap; +using Azure.Core; +using Azure.Identity; +using NUnit.Framework; + +namespace Azure.Analytics.Purview.DataMap.Samples +{ + public partial class Samples_Lineage + { + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Lineage_GetLineage_ShortVersion() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Lineage client = new DataMapClient(endpoint, credential).GetLineageClient(apiVersion: "2023-09-01"); + + Response response = client.GetLineage("", "INPUT"); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Lineage_GetLineage_ShortVersion_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Lineage client = new DataMapClient(endpoint, credential).GetLineageClient(apiVersion: "2023-09-01"); + + Response response = await client.GetLineageAsync("", "INPUT"); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Lineage_GetLineage_ShortVersion_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Lineage client = new DataMapClient(endpoint, credential).GetLineageClient(apiVersion: "2023-09-01"); + + Response response = client.GetLineage("", LineageDirection.Input); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Lineage_GetLineage_ShortVersion_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Lineage client = new DataMapClient(endpoint, credential).GetLineageClient(apiVersion: "2023-09-01"); + + Response response = await client.GetLineageAsync("", LineageDirection.Input); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Lineage_GetLineage_AllParameters() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Lineage client = new DataMapClient(endpoint, credential).GetLineageClient(apiVersion: "2023-09-01"); + + Response response = client.GetLineage("", "INPUT", depth: 1234); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("baseEntityGuid").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classificationNames")[0].ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("isIncomplete").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("labels")[0].ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meaningNames")[0].ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("confidence").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("widthCounts").GetProperty("").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("lineageDepth").ToString()); + Console.WriteLine(result.GetProperty("lineageWidth").ToString()); + Console.WriteLine(result.GetProperty("childrenCount").ToString()); + Console.WriteLine(result.GetProperty("lineageDirection").ToString()); + Console.WriteLine(result.GetProperty("parentRelations")[0].GetProperty("childEntityId").ToString()); + Console.WriteLine(result.GetProperty("parentRelations")[0].GetProperty("relationshipId").ToString()); + Console.WriteLine(result.GetProperty("parentRelations")[0].GetProperty("parentEntityId").ToString()); + Console.WriteLine(result.GetProperty("relations")[0].GetProperty("fromEntityId").ToString()); + Console.WriteLine(result.GetProperty("relations")[0].GetProperty("relationshipId").ToString()); + Console.WriteLine(result.GetProperty("relations")[0].GetProperty("toEntityId").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Lineage_GetLineage_AllParameters_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Lineage client = new DataMapClient(endpoint, credential).GetLineageClient(apiVersion: "2023-09-01"); + + Response response = await client.GetLineageAsync("", "INPUT", depth: 1234); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("baseEntityGuid").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classificationNames")[0].ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("isIncomplete").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("labels")[0].ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meaningNames")[0].ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("confidence").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("widthCounts").GetProperty("").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("lineageDepth").ToString()); + Console.WriteLine(result.GetProperty("lineageWidth").ToString()); + Console.WriteLine(result.GetProperty("childrenCount").ToString()); + Console.WriteLine(result.GetProperty("lineageDirection").ToString()); + Console.WriteLine(result.GetProperty("parentRelations")[0].GetProperty("childEntityId").ToString()); + Console.WriteLine(result.GetProperty("parentRelations")[0].GetProperty("relationshipId").ToString()); + Console.WriteLine(result.GetProperty("parentRelations")[0].GetProperty("parentEntityId").ToString()); + Console.WriteLine(result.GetProperty("relations")[0].GetProperty("fromEntityId").ToString()); + Console.WriteLine(result.GetProperty("relations")[0].GetProperty("relationshipId").ToString()); + Console.WriteLine(result.GetProperty("relations")[0].GetProperty("toEntityId").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Lineage_GetLineage_AllParameters_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Lineage client = new DataMapClient(endpoint, credential).GetLineageClient(apiVersion: "2023-09-01"); + + Response response = client.GetLineage("", LineageDirection.Input, depth: 1234); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Lineage_GetLineage_AllParameters_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Lineage client = new DataMapClient(endpoint, credential).GetLineageClient(apiVersion: "2023-09-01"); + + Response response = await client.GetLineageAsync("", LineageDirection.Input, depth: 1234); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Lineage_GetNextPage_ShortVersion() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Lineage client = new DataMapClient(endpoint, credential).GetLineageClient(apiVersion: "2023-09-01"); + + Response response = client.GetNextPage("", "INPUT"); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Lineage_GetNextPage_ShortVersion_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Lineage client = new DataMapClient(endpoint, credential).GetLineageClient(apiVersion: "2023-09-01"); + + Response response = await client.GetNextPageAsync("", "INPUT"); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Lineage_GetNextPage_ShortVersion_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Lineage client = new DataMapClient(endpoint, credential).GetLineageClient(apiVersion: "2023-09-01"); + + Response response = client.GetNextPage("", LineageDirection.Input); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Lineage_GetNextPage_ShortVersion_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Lineage client = new DataMapClient(endpoint, credential).GetLineageClient(apiVersion: "2023-09-01"); + + Response response = await client.GetNextPageAsync("", LineageDirection.Input); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Lineage_GetNextPage_AllParameters() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Lineage client = new DataMapClient(endpoint, credential).GetLineageClient(apiVersion: "2023-09-01"); + + Response response = client.GetNextPage("", "INPUT", offset: 1234, limit: 1234); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("baseEntityGuid").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classificationNames")[0].ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("isIncomplete").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("labels")[0].ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meaningNames")[0].ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("confidence").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("widthCounts").GetProperty("").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("lineageDepth").ToString()); + Console.WriteLine(result.GetProperty("lineageWidth").ToString()); + Console.WriteLine(result.GetProperty("childrenCount").ToString()); + Console.WriteLine(result.GetProperty("lineageDirection").ToString()); + Console.WriteLine(result.GetProperty("parentRelations")[0].GetProperty("childEntityId").ToString()); + Console.WriteLine(result.GetProperty("parentRelations")[0].GetProperty("relationshipId").ToString()); + Console.WriteLine(result.GetProperty("parentRelations")[0].GetProperty("parentEntityId").ToString()); + Console.WriteLine(result.GetProperty("relations")[0].GetProperty("fromEntityId").ToString()); + Console.WriteLine(result.GetProperty("relations")[0].GetProperty("relationshipId").ToString()); + Console.WriteLine(result.GetProperty("relations")[0].GetProperty("toEntityId").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Lineage_GetNextPage_AllParameters_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Lineage client = new DataMapClient(endpoint, credential).GetLineageClient(apiVersion: "2023-09-01"); + + Response response = await client.GetNextPageAsync("", "INPUT", offset: 1234, limit: 1234); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("baseEntityGuid").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classificationNames")[0].ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("isIncomplete").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("labels")[0].ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meaningNames")[0].ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("confidence").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("widthCounts").GetProperty("").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("lineageDepth").ToString()); + Console.WriteLine(result.GetProperty("lineageWidth").ToString()); + Console.WriteLine(result.GetProperty("childrenCount").ToString()); + Console.WriteLine(result.GetProperty("lineageDirection").ToString()); + Console.WriteLine(result.GetProperty("parentRelations")[0].GetProperty("childEntityId").ToString()); + Console.WriteLine(result.GetProperty("parentRelations")[0].GetProperty("relationshipId").ToString()); + Console.WriteLine(result.GetProperty("parentRelations")[0].GetProperty("parentEntityId").ToString()); + Console.WriteLine(result.GetProperty("relations")[0].GetProperty("fromEntityId").ToString()); + Console.WriteLine(result.GetProperty("relations")[0].GetProperty("relationshipId").ToString()); + Console.WriteLine(result.GetProperty("relations")[0].GetProperty("toEntityId").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Lineage_GetNextPage_AllParameters_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Lineage client = new DataMapClient(endpoint, credential).GetLineageClient(apiVersion: "2023-09-01"); + + Response response = client.GetNextPage("", LineageDirection.Input, offset: 1234, limit: 1234); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Lineage_GetNextPage_AllParameters_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Lineage client = new DataMapClient(endpoint, credential).GetLineageClient(apiVersion: "2023-09-01"); + + Response response = await client.GetNextPageAsync("", LineageDirection.Input, offset: 1234, limit: 1234); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Lineage_GetByUniqueAttribute_ShortVersion() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Lineage client = new DataMapClient(endpoint, credential).GetLineageClient(apiVersion: "2023-09-01"); + + Response response = client.GetByUniqueAttribute("", "INPUT"); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Lineage_GetByUniqueAttribute_ShortVersion_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Lineage client = new DataMapClient(endpoint, credential).GetLineageClient(apiVersion: "2023-09-01"); + + Response response = await client.GetByUniqueAttributeAsync("", "INPUT"); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Lineage_GetByUniqueAttribute_ShortVersion_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Lineage client = new DataMapClient(endpoint, credential).GetLineageClient(apiVersion: "2023-09-01"); + + Response response = client.GetByUniqueAttribute("", LineageDirection.Input); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Lineage_GetByUniqueAttribute_ShortVersion_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Lineage client = new DataMapClient(endpoint, credential).GetLineageClient(apiVersion: "2023-09-01"); + + Response response = await client.GetByUniqueAttributeAsync("", LineageDirection.Input); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Lineage_GetByUniqueAttribute_AllParameters() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Lineage client = new DataMapClient(endpoint, credential).GetLineageClient(apiVersion: "2023-09-01"); + + Response response = client.GetByUniqueAttribute("", "INPUT", depth: 1234, attr: ""); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("baseEntityGuid").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classificationNames")[0].ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("isIncomplete").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("labels")[0].ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meaningNames")[0].ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("confidence").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("widthCounts").GetProperty("").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("lineageDepth").ToString()); + Console.WriteLine(result.GetProperty("lineageWidth").ToString()); + Console.WriteLine(result.GetProperty("childrenCount").ToString()); + Console.WriteLine(result.GetProperty("lineageDirection").ToString()); + Console.WriteLine(result.GetProperty("parentRelations")[0].GetProperty("childEntityId").ToString()); + Console.WriteLine(result.GetProperty("parentRelations")[0].GetProperty("relationshipId").ToString()); + Console.WriteLine(result.GetProperty("parentRelations")[0].GetProperty("parentEntityId").ToString()); + Console.WriteLine(result.GetProperty("relations")[0].GetProperty("fromEntityId").ToString()); + Console.WriteLine(result.GetProperty("relations")[0].GetProperty("relationshipId").ToString()); + Console.WriteLine(result.GetProperty("relations")[0].GetProperty("toEntityId").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Lineage_GetByUniqueAttribute_AllParameters_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Lineage client = new DataMapClient(endpoint, credential).GetLineageClient(apiVersion: "2023-09-01"); + + Response response = await client.GetByUniqueAttributeAsync("", "INPUT", depth: 1234, attr: ""); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.GetProperty("baseEntityGuid").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classificationNames")[0].ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("attributes").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("typeName").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("lastModifiedTS").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("entityGuid").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("entityStatus").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("removePropagationsOnEntityDelete").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("endTime").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("startTime").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("classifications")[0].GetProperty("validityPeriods")[0].GetProperty("timeZone").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("guid").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("isIncomplete").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("labels")[0].ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meaningNames")[0].ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("confidence").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("createdBy").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("description").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("displayText").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("expression").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("relationGuid").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("steward").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("meanings")[0].GetProperty("termGuid").ToString()); + Console.WriteLine(result.GetProperty("guidEntityMap").GetProperty("").GetProperty("status").ToString()); + Console.WriteLine(result.GetProperty("widthCounts").GetProperty("").GetProperty("").ToString()); + Console.WriteLine(result.GetProperty("lineageDepth").ToString()); + Console.WriteLine(result.GetProperty("lineageWidth").ToString()); + Console.WriteLine(result.GetProperty("childrenCount").ToString()); + Console.WriteLine(result.GetProperty("lineageDirection").ToString()); + Console.WriteLine(result.GetProperty("parentRelations")[0].GetProperty("childEntityId").ToString()); + Console.WriteLine(result.GetProperty("parentRelations")[0].GetProperty("relationshipId").ToString()); + Console.WriteLine(result.GetProperty("parentRelations")[0].GetProperty("parentEntityId").ToString()); + Console.WriteLine(result.GetProperty("relations")[0].GetProperty("fromEntityId").ToString()); + Console.WriteLine(result.GetProperty("relations")[0].GetProperty("relationshipId").ToString()); + Console.WriteLine(result.GetProperty("relations")[0].GetProperty("toEntityId").ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Lineage_GetByUniqueAttribute_AllParameters_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Lineage client = new DataMapClient(endpoint, credential).GetLineageClient(apiVersion: "2023-09-01"); + + Response response = client.GetByUniqueAttribute("", LineageDirection.Input, depth: 1234, attr: ""); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Lineage_GetByUniqueAttribute_AllParameters_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Lineage client = new DataMapClient(endpoint, credential).GetLineageClient(apiVersion: "2023-09-01"); + + Response response = await client.GetByUniqueAttributeAsync("", LineageDirection.Input, depth: 1234, attr: ""); + } + } +} diff --git a/sdk/purview/Azure.Analytics.Purview.DataMap/tests/Generated/Samples/Samples_Relationship.cs b/sdk/purview/Azure.Analytics.Purview.DataMap/tests/Generated/Samples/Samples_Relationship.cs new file mode 100644 index 0000000000000..b129f83b1d1d4 --- /dev/null +++ b/sdk/purview/Azure.Analytics.Purview.DataMap/tests/Generated/Samples/Samples_Relationship.cs @@ -0,0 +1,773 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Text.Json; +using System.Threading.Tasks; +using Azure; +using Azure.Analytics.Purview.DataMap; +using Azure.Core; +using Azure.Identity; +using NUnit.Framework; + +namespace Azure.Analytics.Purview.DataMap.Samples +{ + public partial class Samples_Relationship + { + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Relationship_Create_ShortVersion() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Relationship client = new DataMapClient(endpoint, credential).GetRelationshipClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object()); + Response response = client.Create(content); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Relationship_Create_ShortVersion_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Relationship client = new DataMapClient(endpoint, credential).GetRelationshipClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new object()); + Response response = await client.CreateAsync(content); + + JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement; + Console.WriteLine(result.ToString()); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Relationship_Create_ShortVersion_Convenience() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Relationship client = new DataMapClient(endpoint, credential).GetRelationshipClient(apiVersion: "2023-09-01"); + + AtlasRelationship relationship = new AtlasRelationship(); + Response response = client.Create(relationship); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Example_Relationship_Create_ShortVersion_Convenience_Async() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Relationship client = new DataMapClient(endpoint, credential).GetRelationshipClient(apiVersion: "2023-09-01"); + + AtlasRelationship relationship = new AtlasRelationship(); + Response response = await client.CreateAsync(relationship); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public void Example_Relationship_Create_AllParameters() + { + Uri endpoint = new Uri(""); + TokenCredential credential = new DefaultAzureCredential(); + Relationship client = new DataMapClient(endpoint, credential).GetRelationshipClient(apiVersion: "2023-09-01"); + + using RequestContent content = RequestContent.Create(new + { + attributes = new + { + key = new object(), + }, + typeName = "", + lastModifiedTS = "", + createTime = 1234L, + createdBy = "", + end1 = new + { + guid = "", + typeName = "", + uniqueAttributes = new + { + key = new object(), + }, + }, + guid = "", + homeId = "", + label = "