private bool TakesAColumnPlace(Wall newWall)
        {
            bool existColumnInWallPlace = false;

            foreach (ISinglePointComponent column in materials.GetColumns())
            {
                if (newWall.DoesContainComponent(column) || column.GetPosition().Equals(newWall.End()) || column.GetPosition().Equals(newWall.Beginning()))
                {
                    existColumnInWallPlace = true;
                }
            }
            return(existColumnInWallPlace);
        }
 public override ICollection <ISinglePointComponent> GetColumns()
 {
     return((ICollection <ISinglePointComponent>)materials.GetColumns());
 }
Ejemplo n.º 3
0
 public bool OccupiedPosition(ISinglePointComponent punctualComponent)
 {
     return(materials.GetOpenings().Any(op => op.GetPosition().Equals(punctualComponent.GetPosition())) ||
            materials.GetBeams().Any(bm => bm.GetPosition().Equals(punctualComponent.GetPosition())) ||
            materials.GetColumns().Any(cm => cm.GetPosition().Equals(punctualComponent.GetPosition())));
 }