Package penny.downloadmanager.model.db

Examples of penny.downloadmanager.model.db.DownloadDAO


                Logger.getLogger(Model.class.getName()).log(Level.SEVERE, null, ex);
            }
            startupDialogModel.setStartupModel(applicationSettings.getStartupModel());
            splashScreenModel.setStage("Initializing DB...");
            JavaDBDataSource.getInstance().initDB();
            DownloadDAO dao = DAOFactory.getInstance().getDownloadDAO();
            splashScreenModel.setStage("Loading Downloads...");
            List<Download> downloads1 = new ArrayList<Download>();
            List<UUID> ids = dao.getIds();
            splashScreenModel.setCurrent(0);
            splashScreenModel.setSize(ids.size());
            for(UUID id : ids) {
                splashScreenModel.setMessage("Loading " + id);
                downloads1.add(dao.getDownload(id));
                splashScreenModel.setCurrent(splashScreenModel.getCurrent() + 1);
            }
            downloads.addAll(downloads1);
            downloadSaver = new DownloadSaver(downloads);
            mainWindowModel.setDownloadSaver(downloadSaver);
View Full Code Here

TOP

Related Classes of penny.downloadmanager.model.db.DownloadDAO

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.