コード例 #1
0
        public void Setup()
        {
            _vo = new ValueObject();

            _taskChain1 = new TaskChain();
            _taskChain2 = new TaskChain();

            _serialTasks1   = new Svelto.Tasks.Chain.SerialTaskCollection <ValueObject>(_vo);
            _parallelTasks1 = new Svelto.Tasks.Chain.ParallelTaskCollection <ValueObject>(_vo);
            _serialTasks2   = new Svelto.Tasks.Chain.SerialTaskCollection <ValueObject>(_vo);
        }
コード例 #2
0
        public void Setup()
        {
            vo = new ValueObject();

            serialTasks1   = new SerialTaskCollection <ValueObject>(vo);
            parallelTasks1 = new ParallelTaskCollection <ValueObject>(vo);
            serialTasks2   = new SerialTaskCollection <ValueObject>(vo);
            parallelTasks2 = new ParallelTaskCollection <ValueObject>(vo);

            task1 = new Task();
            task2 = new Task();

            taskChain1 = new TaskChain();
            taskChain2 = new TaskChain();

            iterable1             = new Enumerable(10000);
            iterable2             = new Enumerable(10000);
            iterableWithException = new Enumerable(-5);

            _taskRunner          = TaskRunner.Instance;
            _reusableTaskRoutine = TaskRunner.Instance.AllocateNewTaskRoutine().SetScheduler(StandardSchedulers.syncScheduler); //the taskroutine will stall the thread because it runs on the SyncScheduler
        }