use of com.tyndalehouse.step.core.models.BibleInstaller in project step by STEPBible.
the class JSwordModuleServiceImpl method addDirectoryInstaller.
@Override
public BibleInstaller addDirectoryInstaller(final String directoryPath) {
final DirectoryListingInstaller installer = new DirectoryListingInstaller(directoryPath, directoryPath);
this.bookInstallers.add(installer);
return new BibleInstaller(this.bookInstallers.size() - 1, installer.getInstallerName(), false);
}
use of com.tyndalehouse.step.core.models.BibleInstaller in project step by STEPBible.
the class BibleInformationServiceImpl method getInstallers.
@Override
public List<BibleInstaller> getInstallers() {
List<BibleInstaller> bibleInstallers = new ArrayList<BibleInstaller>();
final List<Installer> installers = this.jswordModule.getInstallers();
for (int ii = 0; ii < installers.size(); ii++) {
final Installer installer = installers.get(ii);
String name = installer.getInstallerDefinition();
boolean accessesInternet = true;
if (installer instanceof StepHttpSwordInstaller) {
name = ((StepHttpSwordInstaller) installer).getInstallerName();
accessesInternet = true;
} else if (installer instanceof DirectoryInstaller) {
name = ((DirectoryInstaller) installer).getInstallerName();
accessesInternet = false;
}
bibleInstallers.add(new BibleInstaller(ii, name, accessesInternet));
}
return bibleInstallers;
}
Aggregations