Class ModuleServiceImpl

java.lang.Object
com.tyndalehouse.step.core.service.impl.ModuleServiceImpl
All Implemented Interfaces:
ModuleService

@Singleton public class ModuleServiceImpl extends Object implements ModuleService
Looks up module information, for example lexicon definitions for particular references
  • Constructor Details

    • ModuleServiceImpl

      @Inject public ModuleServiceImpl(JSwordModuleService jswordModuleService, javax.inject.Provider<ClientSession> clientSession, VersionResolver resolver)
      constructs a service to give module information and content.
      Parameters:
      jswordModuleService - the service to register and manipulate modules
      clientSession - the client session to validate security
  • Method Details

    • getAvailableModules

      public List<BibleVersion> getAvailableModules()
      Specified by:
      getAvailableModules in interface ModuleService
      Returns:
      all installed modules
    • getAllInstallableModules

      public List<BibleVersion> getAllInstallableModules(int installerIndex, org.crosswire.jsword.book.BookCategory... categories)
      Specified by:
      getAllInstallableModules in interface ModuleService
      Parameters:
      installerIndex - installer index to look up modules from
      categories - the types of modules to include
      Returns:
      a list of all modules that could be installed
    • subtract

      public static Collection<org.crosswire.jsword.book.Book> subtract(List<org.crosswire.jsword.book.Book> originalBooks, List<org.crosswire.jsword.book.Book> booksToRemove)
      Parameters:
      originalBooks - list a the master list
      booksToRemove - list b the list of items to take out
      Returns:
      the trimmed list