IAdmManagedDomainLyncOps
The IAdmManagedDomainLyncOps interface provides information about Skype for Business Registrar pools available in the managed domain.
Methods
-
Method
-
Description
-
FindAvailableLyncPools()
-
Returns an array of Skype for Business Registrar pools available in the managed domain.
-
GetAvailableLyncPolicies()
-
Returns identities of Skype for Business policies of the given type.
Details
FindAvailableLyncPools()
Returns an array of Skype for Business Registrar pools available in the managed domain.
IAdmLyncPoolInfo[] FindAvailableLyncPools()
Examples
The following code sample outputs Skype for Business Registrar pools available in a managed domain.
- PowerShell
-
[Reflection.Assembly]::LoadWithPartialName("Softerra.Adaxes.Adsi") # Connect to the Adaxes service $ns = New-Object "Softerra.Adaxes.Adsi.AdmNamespace" $service = $ns.GetServiceDirectly("localhost") # Bind to the managed domain $domainName = "example.com" $managedDomainsPath = $service.Backend.GetConfigurationContainerPath("ManagedDomains") $managedDomainsPathObj = New-Object "Softerra.Adaxes.Adsi.AdsPath" $managedDomainsPath $managedDomainPath = $managedDomainsPathObj.CreateChildPath("DC=$domainName") $managedDomain = $service.OpenObject($managedDomainPath, $null, $null, 0) # Retrieve registrar pools $registrarPools = $managedDomain.FindAvailableLyncPools() Write-Host "Registrar pools:" foreach ($registrarPool in $registrarPools) { Write-Host "`t" $registrarPool.DisplayName }
- C#
-
using System; using Softerra.Adaxes.Adsi; using Softerra.Adaxes.Interop.Adsi.PersistentObjects; class Program { static void Main(string[] args) { // Connect to the Adaxes service AdmNamespace ns = new AdmNamespace(); IAdmService service = ns.GetServiceDirectly("localhost"); // Bind to the domain const string domainName = "example.com"; string managedDomainsPath = service.Backend.GetConfigurationContainerPath( "ManagedDomains"); AdsPath managedDomainsPathObj = new AdsPath(managedDomainsPath); AdsPath managedDomainPath = managedDomainsPathObj.CreateChildPath("DC=" + domainName); IAdmManagedDomainLyncOps managedDomain = (IAdmManagedDomainLyncOps)service.OpenObject( managedDomainPath.ToString(), null, null, 0); // Retrieve registrar pools IAdmLyncPoolInfo[] registrarPools = managedDomain.FindAvailableLyncPools(); Console.WriteLine("Registrar pools:"); foreach (IAdmLyncPoolInfo registrarPool in registrarPools) { Console.WriteLine("\t" + registrarPool.DisplayName); } } }
GetAvailableLyncPolicies()
Returns identities of Skype for Business policies of the given type.
string[] GetAvailableLyncPolicies(string poolFqdn, ADM_LYNCPOLICY_ENUM type)
Parameters
- poolFqdn - Specifies the fully qualified domain name (FQDN) of the Skype for Business Registrar pool.
- type - Specifies the type of Skype for Business policies.
Return value
The method returns identities of per-user policies only.
Examples
The following code sample outputs identities of conferencing Skype for Business policies.
- PowerShell
-
[Reflection.Assembly]::LoadWithPartialName("Softerra.Adaxes.Adsi") # Connect to the Adaxes service $ns = New-Object "Softerra.Adaxes.Adsi.AdmNamespace" $service = $ns.GetServiceDirectly("localhost") # Bind to the managed domain $domainName = "example.com" $managedDomainsPath = $service.Backend.GetConfigurationContainerPath("ManagedDomains") $managedDomainsPathObj = New-Object "Softerra.Adaxes.Adsi.AdsPath" $managedDomainsPath $managedDomainPath = $managedDomainsPathObj.CreateChildPath("DC=$domainName") $managedDomain = $service.OpenObject($managedDomainPath, $null, $null, 0) # Retrieve policy identities $registrarPoolFqdn = "myregistrarpool.example.com" $policiesType = "ADM_LYNCPOLICY_CONFERENCING" $policyIdentities = $managedDomain.GetAvailableLyncPolicies($registrarPoolFqdn, $policiesType) Write-Host "Policies:" foreach ($policyIdentity in $policyIdentities) { Write-Host "`t" $policyIdentity }
- C#
-
using System; using Softerra.Adaxes.Adsi; using Softerra.Adaxes.Interop.Adsi; using Softerra.Adaxes.Interop.Adsi.PersistentObjects; class Program { static void Main(string[] args) { // Connect to the Adaxes service AdmNamespace ns = new AdmNamespace(); IAdmService service = ns.GetServiceDirectly("localhost"); // Bind to the managed domain const string domainName = "example.com"; string managedDomainsPath = service.Backend.GetConfigurationContainerPath( "ManagedDomains"); AdsPath managedDomainsPathObj = new AdsPath(managedDomainsPath); AdsPath managedDomainPath = managedDomainsPathObj.CreateChildPath("DC=" + domainName); IAdmManagedDomainLyncOps managedDomain = (IAdmManagedDomainLyncOps)service.OpenObject( managedDomainPath.ToString(), null, null, 0); // Retrieve policy identities const string registrarPoolFqdn = "myregistrarpool.example.com"; ADM_LYNCPOLICY_ENUM policiesType = ADM_LYNCPOLICY_ENUM.ADM_LYNCPOLICY_CONFERENCING; var policyIdentities = managedDomain.GetAvailableLyncPolicies( registrarPoolFqdn, policiesType); foreach (string policyIdentity in policyIdentities) { Console.WriteLine(policyIdentity); } } }
Requirements
Minimum required version: 2023