private void AddPath(Grid <T> grid, T start, T end) { lock (_addPathLock) { _paths.Add(start, end, grid); } }