Package de.timefinder.algo

Examples of de.timefinder.algo.Algorithm


    protected void doOnce() {
        ApplicationWindow aw = getApplicationWindow();
        aw.getStatusBar().clear();

        // inject via spring and using the same optimizer command class?
        final Algorithm algorithm = new UniTimeOptimization();
        ((UniTimeOptimization) algorithm).setInitialAssignment(true);

        // TODO make seconds editable via GUI
        int sec = 5 * 60;
        algorithm.setCondition(new AlgorithmConditionTime(sec));
        String msg = tr.get(ID + ".startTask", sec / 60.0f);

        aw.getStatusBar().getProgressMonitor().taskStarted(msg, -1);
        MySwingWorker sw = new MySwingWorker(ID) {

            @Override
            protected void myconstruct() throws Exception {
                algorithm.setDataPoolSettings(settings);
                algorithm.setDataPool(dataPool);
                algorithm.setStatusBar(new StatusBarBridge(getApplicationWindow().getStatusBar()));
                algorithm.doWork();
            }
        };
        sw.execute();
    }
View Full Code Here

TOP

Related Classes of de.timefinder.algo.Algorithm

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.