// Token: 0x06001D65 RID: 7525 RVA: 0x0007A88C File Offset: 0x00078A8C private static NetID GetNetIDWithPrefix(string netIdPrefix, IPropertyBag propertyBag) { ProxyAddressCollection proxyAddressCollection = (ProxyAddressCollection)propertyBag[ADRecipientSchema.EmailAddresses]; if (proxyAddressCollection != null) { ProxyAddress proxyAddress = proxyAddressCollection.FindPrimary(ProxyAddressPrefix.GetPrefix(netIdPrefix)); if (null != proxyAddress) { return(NetID.Parse(proxyAddress.ValueString)); } } return(null); }
private ADRawEntry[] SearchByNetIDType(ADObjectId rootId, string netID, bool searchForConsumerNetID, QueryFilter excludeExternalNetIDFilter, params PropertyDefinition[] properties) { QueryFilter queryFilter; if (!searchForConsumerNetID) { queryFilter = new ComparisonFilter(ComparisonOperator.Equal, IADSecurityPrincipalSchema.NetID, NetID.Parse(netID)); } else { queryFilter = new ComparisonFilter(ComparisonOperator.Equal, IADSecurityPrincipalSchema.ConsumerNetID, NetID.Parse(netID)); } QueryFilter filter; if (excludeExternalNetIDFilter != null) { filter = new AndFilter(new QueryFilter[] { queryFilter, excludeExternalNetIDFilter }); } else { filter = queryFilter; } return(base.Find <ADRawEntry>(rootId, QueryScope.SubTree, filter, null, 0, properties, false)); }