Package de.timefinder.algo.ncp

Examples of de.timefinder.algo.ncp.NoCollisionPrinciple


        settings.setMillisPerTimeslot(60 * 60 * 1000L);
        settings.setNumberOfDays(5);
        // 9 hours per day
        settings.setTimeslotsPerDay(9);

        NoCollisionPrinciple ncpInstance = new NoCollisionPrinciple();
        ncpInstance.setRandom(new Random(seed));//123456L
        ncpInstance.setCondition(new AlgorithmConditionTime(seconds));
        ncpInstance.setDataPoolSettings(settings);
        ncpInstance.setStatusBar(new SilentConsoleStatusBar());
        ncpInstance.setDataPool(dataPool);

        loadData(dataPool, new File(fileOrFolder), settings);

        long start = System.currentTimeMillis();
        Solution solution = ncpInstance.doWork();
//        ConstraintChecker.printStatistics(solution);

        return start;
    }
View Full Code Here


        ImportBTXml importer = new ImportBTXml(dataPool, new File("/home/peterk/Dokumente/timefinder/import-bt/"));
        ImportBTXml.overwriteSettings(settings);
        importer.setDataPoolSettings(settings);       
        importer.doWork();

        NoCollisionPrinciple ncpInstance = new NoCollisionPrinciple();
        ncpInstance.setRandom(new Random(123456L));
        ncpInstance.setCondition(new AlgorithmConditionIteration(5));
        ncpInstance.setDataPoolSettings(settings);
        ncpInstance.setStatusBar(new SilentConsoleStatusBar());
        ncpInstance.setDataPool(dataPool);

        ncpInstance.doWork();
    }
View Full Code Here

        }
    }

    @Test
    public void testNcp() {
        NoCollisionPrinciple ncp = (NoCollisionPrinciple) ctx.getBean("ncp");
        assertNotNull(ncp);
        assertNotNull(ncp.getDataPool());
    }
View Full Code Here

    @Test
    public void testRunAlgorithm() {
        importer.setSemester(11);
        importer.doWork();

        NoCollisionPrinciple ncpInstance = new NoCollisionPrinciple();
        ncpInstance.setRandom(new Random(181282L));
        ncpInstance.setCondition(new AlgorithmConditionIteration(1000));
        ncpInstance.setDataPoolSettings(settings);
        ncpInstance.setStatusBar(new SilentConsoleStatusBar());
        ncpInstance.setDataPool(dataPool);

        ncpInstance.doWork();
    }
View Full Code Here

TOP

Related Classes of de.timefinder.algo.ncp.NoCollisionPrinciple

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.