Implementato NodeSequence e aggiunto alcuni costruttori alle eccezioni
This commit is contained in:
@@ -11,4 +11,7 @@ public class EmptyDequeException extends RuntimeException {
|
||||
public EmptyDequeException(){
|
||||
super("Deque Empty");
|
||||
}
|
||||
public EmptyDequeException(String msg){
|
||||
super(msg);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -11,4 +11,7 @@ public class EmptyQueueException extends RuntimeException {
|
||||
public EmptyQueueException(){
|
||||
super("Queue Empty");
|
||||
}
|
||||
public EmptyQueueException(String msg){
|
||||
super(msg);
|
||||
}
|
||||
}
|
||||
|
||||
18
exceptions/EmptySequenceException.java
Normal file
18
exceptions/EmptySequenceException.java
Normal file
@@ -0,0 +1,18 @@
|
||||
package exceptions;
|
||||
|
||||
/**
|
||||
* Signals that the boundaries of a data structure have been illegally
|
||||
* traversed (e.g. past the end of a list).
|
||||
* @author Roberto Tamassia
|
||||
*/
|
||||
//Copyright (c) 2003 Brown University, Providence, RI
|
||||
//Additional modifications and methods by xgiovio
|
||||
|
||||
public class EmptySequenceException extends RuntimeException {
|
||||
public EmptySequenceException(String message) {
|
||||
super (message);
|
||||
}
|
||||
public EmptySequenceException() {
|
||||
super ("EmptySequenceException");
|
||||
}
|
||||
}
|
||||
@@ -11,4 +11,7 @@ public class EmptyStackException extends RuntimeException {
|
||||
public EmptyStackException(){
|
||||
super("Stack Empty");
|
||||
}
|
||||
public EmptyStackException(String msg){
|
||||
super(msg);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user