Esempio n. 1
0
        public void CreatePortionerControl(IItemProvider itemProvider, uint nBins)
        {
            var ctrlLog = new SimpleTextLog();
            var binLog  = new SimpleTextLog();

            var control = new Control(itemProvider, ctrlLog, new RoundRobinPortioningAlgorithm());

            for (uint i = 0; i < nBins; i++)
            {
                control.AddBin(new Bin(i, 2000, binLog));
            }
        }
        public void CreatePortionerControl(IItemProvider itemProvider, uint nBins)
        {
            var ctrlLog = new FileTextLog("c:\\PortionerCtrlLog.txt");
            var binLog  = new SimpleTextLog();
            //var binLog = new ConsoleLog();

            var control = new Control(itemProvider, ctrlLog, new BinScorePortioningAlgorithm());
            var scorer  = new MultipleOfMeanItemScorer(125);

            for (uint i = 0; i < nBins; i++)
            {
                control.AddBin(new Bin(i, 2000, binLog)
                {
                    ItemScorer = scorer
                });
            }
        }