Skip to content
Snippets Groups Projects
Commit e07b17ba authored by RAKOTOARISOA Andrianinarisaina cy's avatar RAKOTOARISOA Andrianinarisaina cy
Browse files

Tâche 3 (6.2) : Création de la classe CellGridIterator et mise en place de son constructeur

parent 994e693c
No related branches found
No related tags found
No related merge requests found
package model;
import java.util.Iterator;
public class ArrayGrid implements model.Grid {
//Tableau pour stocker les cellules
......@@ -42,6 +44,11 @@ public class ArrayGrid implements model.Grid {
return null;
}
@Override
public Iterator<Cell> iterator() {
return null;
}
@Override
public int getNumberOfRows() {
return 0;
......
package model;
import java.util.Iterator;
public class CellGridIterator implements Iterator<Cell> {
ArrayGrid[] grid ;
//Constructeur de la classe
public void CellGridIterator(ArrayGrid[] grid) {
grid = new ArrayGrid[]{} ;
}
//Méthode à implémenter
@Override
public boolean hasNext() {
return false;
}
//Méthode à implémenter
@Override
public Cell next() {
return null;
}
}
package model;
import javafx.scene.paint.Color;
public interface ColorGenerator {
......
package model;
import java.util.Iterator;
public class GrayGrid implements Grid{
private final int numberOfRows;
......@@ -27,6 +29,11 @@ public class GrayGrid implements Grid{
return GrayCell.GRAY_CELL;
}
@Override
public Iterator<Cell> iterator() {
return null;
}
/**
* Return the number of rows of this {@code Grid}
*
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment