Skip to content
Snippets Groups Projects
Select Git revision
  • 669a2a627be1352040cfc387342f4a3e1bbb914a
  • main default protected
  • correction_video
  • going_further
  • ImprovedMouseInteraction
  • final2023
  • template
  • ModifGUI
8 results

Lens.java

Blame
  • Forked from YAGOUBI Rim / Game of life Template
    Source project has a limited visibility.
    Code owners
    Assign users and groups as approvers for specific file changes. Learn more.
    SquareCell.java 817 B
    package model;
    
    import javafx.scene.paint.Color;
    
    import java.util.AbstractList;
    import java.util.ArrayList;
    import java.util.Iterator;
    import java.util.List;
    
    public class SquareCell extends AbstractCell {
    
        List<Cell> neighbours;
    
    
        public SquareCell() {
            AbstractCell cell = new SquareCell();
        }
    
        public SquareCell(Color color){
            AbstractCell cell = new SquareCell(color);
        }
    
        public SquareCell(Color color,List<Cell>neighbours){
            AbstractCell cell = new SquareCell(color,neighbours);
        }
    
        @Override
        public List<Cell> getNeighbours() {
            return this.neighbours;
        }
    
    
        @Override
        public void setNeighbours(List<Cell> cells) {
            for (int i = 0; i < neighbours.size()  ; i++) {
                this.neighbours.set(i,cells.get(i));
            }
        }
    
    }