Added NotImplementedException, edited some DatabaseGoodCasesTest tests.
This commit is contained in:
@@ -1,10 +1,12 @@
|
||||
package hhn.temp.project.provider;
|
||||
|
||||
import jdk.jshell.spi.ExecutionControl;
|
||||
|
||||
import java.util.Collection;
|
||||
|
||||
public interface DatabaseManager<E> extends Database {
|
||||
public void saveObjects(Collection<E> objects);
|
||||
public Collection<E> getObjects();
|
||||
public void saveObject(E object);
|
||||
public E getObject(int id);
|
||||
public Collection<E> getObjects() throws ExecutionControl.NotImplementedException;
|
||||
public void saveObject(E object) throws ExecutionControl.NotImplementedException;
|
||||
public E getObject(int id) throws ExecutionControl.NotImplementedException;
|
||||
}
|
||||
@@ -1,5 +1,7 @@
|
||||
package hhn.temp.project.provider;
|
||||
|
||||
import jdk.jshell.spi.ExecutionControl;
|
||||
|
||||
import java.io.File;
|
||||
import java.io.IOException;
|
||||
import java.nio.file.Files;
|
||||
@@ -20,18 +22,18 @@ public class SimpleDatabaseManager<E> implements DatabaseManager<E> {
|
||||
}
|
||||
|
||||
@Override
|
||||
public Collection<E> getObjects() {
|
||||
return List.of();
|
||||
public Collection<E> getObjects() throws ExecutionControl.NotImplementedException {
|
||||
throw new ExecutionControl.NotImplementedException("Not Implemented!");
|
||||
}
|
||||
|
||||
@Override
|
||||
public void saveObject(E object) {
|
||||
g
|
||||
public void saveObject(E object) throws ExecutionControl.NotImplementedException {
|
||||
throw new ExecutionControl.NotImplementedException("Not Implemented!");
|
||||
}
|
||||
|
||||
@Override
|
||||
public E getObject(int id) {
|
||||
return null;
|
||||
public E getObject(int id) throws ExecutionControl.NotImplementedException {
|
||||
throw new ExecutionControl.NotImplementedException("Not Implemented!");
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
Reference in New Issue
Block a user