internal PrivateLinkResource(ArmResource options, PrivateLinkResourceData resource) : base(options, resource.Id)
 {
     HasData            = true;
     _data              = resource;
     _clientDiagnostics = new ClientDiagnostics(ClientOptions);
     _privateLinkResourcesRestClient = new PrivateLinkResourcesRestOperations(_clientDiagnostics, Pipeline, ClientOptions, BaseUri);
 }
        internal PrivateLinkResource(ArmClient armClient, ResourceIdentifier id) : base(armClient, id)
        {
            _privateLinkResourceClientDiagnostics = new ClientDiagnostics("Azure.ResourceManager.CosmosDB", ResourceType.Namespace, DiagnosticOptions);
            ArmClient.TryGetApiVersion(ResourceType, out string privateLinkResourceApiVersion);
            _privateLinkResourceRestClient = new PrivateLinkResourcesRestOperations(_privateLinkResourceClientDiagnostics, Pipeline, DiagnosticOptions.ApplicationId, BaseUri, privateLinkResourceApiVersion);
#if DEBUG
            ValidateResourceId(Id);
#endif
        }
        internal PrivateLinkResourceCollection(ArmClient client, ResourceIdentifier id) : base(client, id)
        {
            _privateLinkResourceClientDiagnostics = new ClientDiagnostics("Azure.ResourceManager.CosmosDB", PrivateLinkResource.ResourceType.Namespace, Diagnostics);
            TryGetApiVersion(PrivateLinkResource.ResourceType, out string privateLinkResourceApiVersion);
            _privateLinkResourceRestClient = new PrivateLinkResourcesRestOperations(Pipeline, Diagnostics.ApplicationId, Endpoint, privateLinkResourceApiVersion);
#if DEBUG
            ValidateResourceId(Id);
#endif
        }
 internal PrivateLinkResource(ArmClientOptions clientOptions, TokenCredential credential, Uri uri, HttpPipeline pipeline, ResourceIdentifier id) : base(clientOptions, credential, uri, pipeline, id)
 {
     _clientDiagnostics = new ClientDiagnostics(ClientOptions);
     _privateLinkResourcesRestClient = new PrivateLinkResourcesRestOperations(_clientDiagnostics, Pipeline, ClientOptions, BaseUri);
 }
 internal PrivateLinkResource(ArmResource options, ResourceIdentifier id) : base(options, id)
 {
     _clientDiagnostics = new ClientDiagnostics(ClientOptions);
     _privateLinkResourcesRestClient = new PrivateLinkResourcesRestOperations(_clientDiagnostics, Pipeline, ClientOptions, BaseUri);
 }
Example #6
0
 internal PrivateLinkResourcesOperations(ClientDiagnostics clientDiagnostics, HttpPipeline pipeline, string subscriptionId, Uri endpoint = null)
 {
     RestClient         = new PrivateLinkResourcesRestOperations(clientDiagnostics, pipeline, subscriptionId, endpoint);
     _clientDiagnostics = clientDiagnostics;
     _pipeline          = pipeline;
 }
 internal PrivateLinkResourceCollection(ArmResource parent) : base(parent)
 {
     _clientDiagnostics = new ClientDiagnostics(ClientOptions);
     _privateLinkResourcesRestClient = new PrivateLinkResourcesRestOperations(_clientDiagnostics, Pipeline, ClientOptions, BaseUri);
 }