Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
G
graphic-2024
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
MESSAOUDI Melissa
graphic-2024
Compare revisions
master to a0ff5b3b9a304282a63e20f75ceb9dcd93189c3e
Compare revisions
Changes are shown as if the
source
revision was being merged into the
target
revision.
Learn more about comparing revisions.
Source
m23000189/graphic-2024
Select target project
No results found
a0ff5b3b9a304282a63e20f75ceb9dcd93189c3e
Select Git revision
Branches
master
1 result
Swap
Target
couetoux.b/graphic-2020
Select target project
b21228304/graphic-2020-2-0
l21221596/graphic-2020
c19014407/graphic-2020
b23019494/graphic-2020
g21212987/graphic-2020
couetoux.b/graphic-2020
s22029480/graphic-2020
c23025119/tp-3-graphique
m19023837/graphic-2020-tp-5
s22029480/graphic-tp-4
m19023837/graphic-2020-tp-7
n22021899/tp-3-programmation-conception
r24025701/graphic-2020
a23022716/exo-2-tp-3-algo
m23000189/graphic-2024
b21228304/graphic-2020
t21234458/graphic-2020
v23014723/graphic-2020
h22021483/graphic-2020
t21234458/graphic-2020-tiakout-khaled
m19023837/graphic-2020-chadi
b20031964/graphic-2020
22 results
master
Select Git revision
Branches
master
1 result
Show changes
Only incoming changes from source
Include changes to target since source was created
Compare
Commits on Source (2)
polygone
· 0f94f229
TOUMERT Said
authored
7 months ago
0f94f229
classe AbstractShape
· a0ff5b3b
BOUCHAL Stella
authored
7 months ago
a0ff5b3b
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
src/main/java/shape/AbstractShape.java
+36
-0
36 additions, 0 deletions
src/main/java/shape/AbstractShape.java
src/main/java/shape/Polygone.java
+4
-0
4 additions, 0 deletions
src/main/java/shape/Polygone.java
with
40 additions
and
0 deletions
src/main/java/shape/AbstractShape.java
0 → 100644
View file @
a0ff5b3b
package
shape
;
import
java.awt.*
;
import
java.util.ArrayList
;
import
java.util.List
;
import
javafx.geometry.Point2D
;
import
javafx.scene.canvas.GraphicsContext
;
public
abstract
class
AbstractShape
implements
Shape
{
private
List
<
Point2D
>
points
;
public
AbstractShape
(){
points
=
new
ArrayList
<>();
}
public
void
addPoint
(
Point2D
...
points
){
for
(
Point2D
point
:
points
){
this
.
points
.
add
(
point
);
}
}
public
int
pointsCount
(){
return
points
.
size
();
}
public
Point2D
getPoint
(
int
index
){
if
(
index
<
0
||
index
>=
points
.
size
()){
throw
new
IndexOutOfBoundsException
(
"index out of bounds"
);
}
return
points
.
get
(
index
);
}
public
abstract
void
draw
(
GraphicsContext
graphicsContent
);
}
This diff is collapsed.
Click to expand it.
src/main/java/shape/Polygone.java
0 → 100644
View file @
a0ff5b3b
package
shape
;
public
class
Polygone
{
}
This diff is collapsed.
Click to expand it.