repositories
/
TP_POO.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Include everything in the same class.
[TP_POO.git]
/
Listes
/
Liste.java
diff --git
a/Listes/Liste.java
b/Listes/Liste.java
index 6dd1c5fb58abc7194f905d2bda87f75b385b9139..711b9830aab8c81dd8c72060ca5cb06a1700e02d 100644
(file)
--- a/
Listes/Liste.java
+++ b/
Listes/Liste.java
@@
-1,38
+1,39
@@
-class IntNode {
- private int data;
- private IntNode next;
+public class Liste {
- IntNode(int value) {
- setData(value);
- setNext(null);
- }
+ private class IntNode {
+ private int data;
+ private IntNode next;
-
IntNode(int value, IntNode nextNod
e) {
- setData(value);
-
setNext(nextNode
);
- }
+
IntNode(int valu
e) {
+
setData(value);
+
setNext(null
);
+
}
- public int getData() {
- return data;
- }
+ IntNode(int value, IntNode nextNode) {
+ setData(value);
+ setNext(nextNode);
+ }
-
public void setData(int value
) {
-
data = value
;
- }
+
private int getData(
) {
+
return data
;
+
}
-
public IntNode getNext(
) {
-
return next
;
- }
+
private void setData(int value
) {
+
data = value
;
+
}
-
public void setNext(IntNode nextNode
) {
-
next = nextNode
;
- }
+
private IntNode getNext(
) {
+
return next
;
+
}
-}
+ private void setNext(IntNode nextNode) {
+ next = nextNode;
+ }
+
+ }
-class Liste {
private IntNode headNode;
private int list_counter;
private IntNode headNode;
private int list_counter;