publicvoidDeleteNode(BFS bfs) { if(_next.Count==0) thrownew ArgumentException($"paramater:_next is null"); var b = _next.FirstOrDefault(x => x._wall.Id.Equals(bfs._wall.Id)); _next.Remove(b); }
public List<BFS> GetNextNode() => _next;
}
public List<BFS> GetInsertWalls(Wall wall,List<Wall> walls) { if(wall==null) thrownew ArgumentNullException($"paramater:wall is null"); if (walls.Count==0) thrownew ArgumentNullException($"paramater:walls is null"); var f = BIMTools.Geometry.GetFace(wall, Geometry.FaceNormal.Bottom); var loops = f.GetEdgesAsCurveLoops(); var solid = CreateNewSolid(loops.ToList(), 10, 3000 / 304.8); List<BFS> intersectWalls = new List<BFS>(); foreach (var wall1 in walls) { if(wall1.Id.Equals(wall.Id)) continue; var s = BIMTools.Geometry.GetSolid(wall1); if (solid != null && s != null) { Solid intersect = BooleanOperationsUtils.ExecuteBooleanOperation(solid, s, BooleanOperationsType.Intersect); if (intersect.Volume > 0.0001) { BFS bfs = new BFS(wall1); intersectWalls.Add(bfs); } } }