/** * Set the default commentary. * * @param book the default commentary */ public static void setCommentary(Book book) { commentaryDeft.setDefault(book); }
/** * Set the default Greek Strong's Numbers dictionary. * * @param book the default Greek Strong's Numbers dictionary. */ public static void setGreekDefinitions(Book book) { greekDefinitionsDeft.setDefault(book); }
/** * Set the default Book conditionally. It has to satisfy the filter and the * book must not currently be set. * * @param newBook * The version to use as default. */ public void setDefaultConditionally(Book newBook) { if (book == null) { setDefault(newBook); } }
/** * Set the default Bible. * * @param book the default Bible */ public static void setBible(Book book) { bibleDeft.setDefault(book); }
/** * Set the default Hebrew Strong's Numbers dictionary. * * @param book the default Hebrew Strong's Numbers dictionary. */ public static void setHebrewDefinitions(Book book) { hebrewDefinitionsDeft.setDefault(book); }
/** * Set the default dictionary. * * @param book the default dictionary */ public static void setDictionary(Book book) { dictionaryDeft.setDefault(book); }
/** * Set the default daily devotional. * * @param book the default daily devotional */ public static void setDailyDevotional(Book book) { dictionaryDeft.setDefault(book); }
/** * Set the default Greek morphology dictionary. * * @param book the default Greek morphology dictionary. */ public static void setGreekParse(Book book) { greekParseDeft.setDefault(book); }
/** * Set the default Hebrew morphology dictionary by name. * * @param book the default Hebrew morphology dictionary by name. */ public static void setHebrewParse(Book book) { hebrewParseDeft.setDefault(book); }
/** * Trawl through all the known Books satisfying the filter looking for the * one matching the given name. * <p> * This method is for use with config scripts and other things that * <b>need</b> to work with Strings. The preferred method is to use Book * objects. * <p> * This method is picky in that it only matches when the driver and the * version are the same. The user (probably) only cares about the version * though, and so might be disappointed when we fail to match AV (FooDriver) * against AV (BarDriver). * * @param name * The version to use as default. */ public void setDefaultByName(String name) { if (name == null || name.length() == 0) { LOGGER.warn("Attempt to set empty book as default. Ignoring"); return; } for (Book aBook : books.getBooks(filter)) { if (aBook.match(name)) { setDefault(aBook); return; } } LOGGER.warn("Book not found. Ignoring: {}", name); }