package design.persistence; import design.model.League; import design.persistence.importexport.DataSource; import java.io.IOException; public interface LeagueDatabase extends DataSource { static LeagueDatabase instance() { return JSONLeagueDatabase.instance(); } League getLeague(int id); League[] getLeagues(); void addLeague(League league) throws IOException; void removeLeague(League league) throws IOException; void updateLeague(League league) throws IOException; @Override void importData(Object data) throws IOException; @Override Object exportData() throws IOException; }