@Override
    public void closeDatabaseConnection() {
        try {
            FileOutputStream fileOut = new FileOutputStream(DB_PATH);
            ObjectOutputStream out = new ObjectOutputStream(fileOut);
            out.writeObject(this);
            out.close();
            fileOut.close();
            System.out.println("Serialized data is saved in " + DB_PATH);
        } catch (IOException i) {
            i.printStackTrace();
        }
    }