public static bool PtrIsAllocated(IntPtr ptr) { lock (allocationsLock) { return(Allocations.Any(a => a == ptr)); } }
private string GetAccountNames(Func <AccountAllocation, bool> filter) { if (Allocations == null) { return(string.Empty); } if (!Allocations.Any()) { return(string.Empty); } var matches = Allocations.Where(filter); if (!matches.Any()) { return(string.Empty); } return(string.Join(L.f, matches.Select(_ => _.Account?.Name))); }