// Token: 0x0600116E RID: 4462 RVA: 0x00053E5C File Offset: 0x0005205C public static SharedConfiguration GetSharedConfiguration(OrganizationId orgId) { ExchangeConfigurationUnit[] array = SharedConfiguration.LoadSharedConfigurationsSorted(orgId); if (array == null) { return(null); } ExchangeConfigurationUnit exchangeConfigurationUnit = null; if (array.Length == 1) { exchangeConfigurationUnit = array[0]; } else if (array.Length > 1) { ExchangeConfigurationUnit exchangeConfigurationUnit2 = null; int i = 0; while (i < array.Length) { exchangeConfigurationUnit = array[i]; int num = ServerVersion.Compare(exchangeConfigurationUnit.SharedConfigurationInfo.CurrentVersion, ServerVersion.InstalledVersion); if (num == 0) { break; } if (num > 0) { if (exchangeConfigurationUnit.SharedConfigurationInfo.CurrentVersion.Major > ServerVersion.InstalledVersion.Major && exchangeConfigurationUnit2 != null) { exchangeConfigurationUnit = exchangeConfigurationUnit2; break; } break; } else { exchangeConfigurationUnit2 = array[i]; i++; } } } if (exchangeConfigurationUnit != null) { return(new SharedConfiguration(orgId, exchangeConfigurationUnit)); } return(null); }
// Token: 0x06001182 RID: 4482 RVA: 0x0005459C File Offset: 0x0005279C internal static OrganizationId FindMostRecentSharedConfigurationInPartition(OrganizationId sourceOrganizationId, PartitionId targetAccountPartitionId, out Exception ex) { ex = null; OrganizationId organizationId = null; ExchangeConfigurationUnit[] array = SharedConfiguration.LoadSharedConfigurationsSorted(sourceOrganizationId); if (array != null && array.Length > 0) { int num = array.Length; SharedConfigurationInfo sharedConfigurationInfo = array[num - 1].SharedConfigurationInfo; organizationId = SharedConfiguration.FindOneSharedConfigurationId(sharedConfigurationInfo, targetAccountPartitionId); if (organizationId == null) { ex = new InvalidOperationException(DirectoryStrings.ErrorTargetPartitionSctMissing(sourceOrganizationId.ConfigurationUnit.DistinguishedName, targetAccountPartitionId.ForestFQDN, sharedConfigurationInfo.ToString())); } } return(organizationId); }