forked from IF-LK-2020/queue-stack
Cleaned contentType
This commit is contained in:
@@ -9,11 +9,11 @@ public class Stack<ContentType> {
|
||||
|
||||
public void push( ContentType pContentObject ) {
|
||||
if (head != null) {
|
||||
StackNode<ContentType> node = new StackNode<ContentType>(pContentObject);
|
||||
StackNode<ContentType> node = new StackNode<>(pContentObject);
|
||||
node.setNext(head);
|
||||
head = node;
|
||||
} else {
|
||||
head = new StackNode<ContentType>(pContentObject);
|
||||
head = new StackNode<>(pContentObject);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user