Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
flooding-template_EL-GHAOUTI_AYMANE
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
EL GHAOUTI Aymane
flooding-template_EL-GHAOUTI_AYMANE
Commits
e35dbf8c
Commit
e35dbf8c
authored
2 years ago
by
dragapsy
Browse files
Options
Downloads
Patches
Plain Diff
Tache 5 (Constructeur ColoredCellIterator(Cell startCell)).
parent
428ae57f
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
app/src/main/java/model/ColoredCellIterator.java
+18
-1
18 additions, 1 deletion
app/src/main/java/model/ColoredCellIterator.java
with
18 additions
and
1 deletion
app/src/main/java/model/ColoredCellIterator.java
+
18
−
1
View file @
e35dbf8c
package
model
;
import
javafx.scene.paint.Color
;
import
java.awt.*
;
import
java.util.HashSet
;
import
java.util.Iterator
;
import
java.util.Set
;
public
class
ColoredCellIterator
implements
Iterator
<
Cell
>
{
public
ColoredCellIterator
(
SquareCell
squareCell
)
{
private
Color
color
;
private
Set
<
Cell
>
visitedCells
;
private
Set
<
Cell
>
pendingCells
;
private
Cell
startCell
;
public
ColoredCellIterator
(
Cell
startCell
){
this
.
startCell
=
startCell
;
visitedCells
=
new
HashSet
<>();
this
.
pendingCells
=
new
HashSet
<>();
this
.
pendingCells
.
add
(
startCell
);
this
.
color
=
startCell
.
getColor
();
}
@Override
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment