protected override JobHandle OnUpdate(JobHandle inputDependencies) { ComponentDataFromEntity <SleepArea> sleepAreas = GetComponentDataFromEntity <SleepArea>(); ComponentDataFromEntity <FoodArea> foodAreas = GetComponentDataFromEntity <FoodArea>(); var ecb = m_EndSimulationEcbSystem.CreateCommandBuffer().ToConcurrent(); var job = new ExecuteActionJob() { sleepAreaLookup = sleepAreas, foodAreaLookup = foodAreas, ecb = ecb, incrMultiplier = Experiment.incrMultiplier, turnAngle = Experiment.turnAngleRadian }; var jobHandle = job.Schedule(m_Group, inputDependencies); m_EndSimulationEcbSystem.AddJobHandleForProducer(jobHandle); return(jobHandle); }
private static ObjectView CreateView(this XafApplication application, ExecuteActionJob job, IModelView modelView, IObjectSpace space, Type objectType) => modelView is IModelListView modelListView
private static IObservable <View> CreateView(this XafApplication application, ExecuteActionJob job, IModelView modelView) => application.WhenViewCreating() .Select(t => { var objectType = modelView.AsObjectView.ModelClass.TypeInfo.Type; t.e.View = application.CreateView(job, modelView, application.CreateObjectSpace(objectType, true), objectType); return(t.e.View); }).FirstAsync().IgnoreElements();