public InstanceBuilder(IStorageEngine engine)
		{
			this.triggerManager = OdbConfiguration.GetCoreProvider().GetLocalTriggerManager(engine);
			this.classIntrospector = OdbConfiguration.GetCoreProvider().GetClassIntrospector();
			this.classPool = OdbConfiguration.GetCoreProvider().GetClassPool();
			this.engine = engine;
		}
Esempio n. 2
0
 public InstanceBuilder(IStorageEngine engine)
 {
     this.triggerManager    = OdbConfiguration.GetCoreProvider().GetLocalTriggerManager(engine);
     this.classIntrospector = OdbConfiguration.GetCoreProvider().GetClassIntrospector();
     this.classPool         = OdbConfiguration.GetCoreProvider().GetClassPool();
     this.engine            = engine;
 }
Esempio n. 3
0
 public static void getParentEventTest(ITriggerManager manager, IEventArg e1, IEventArg e2, IEventArg e3)
 {
     _ = manager.doEvent(e1, arg =>
     {
         _ = manager.doEvent(e2);
         _ = manager.doEvent(e3);
         return(Task.CompletedTask);
     });
     Assert.AreEqual(e1, e2.parent);
     Assert.AreEqual(e1, e3.parent);
 }
Esempio n. 4
0
 public AgentBase(Action <IAgent <TAction, TGoal>, IMaps <TAction, TGoal> > onInitGameData)
 {
     _onInitGameData       = onInitGameData;
     DebugMsgBase.Instance = InitDebugMsg();
     AgentState            = InitAgentState();
     ActionManager         = InitActionManager();
     GoalManager           = InitGoalManager();
     Maps            = InitMaps();
     _triggerManager = InitTriggerManager();
     Performer       = new Performer <TAction, TGoal>(this);
     AgentState.AddStateChangeListener(UpdateData);
 }
Esempio n. 5
0
 public QuartzService(ISchedulerFactory schedulerFactory, ITaskRepository task, IJobFactory jobFactory,
                      ITaskLogRepository taskLogService, ILogRepository log, IJobManager jobManager, ITriggerManager triggerManager,
                      ILogger <QuartzService> logger)
 {
     _logger           = logger;
     _triggerManager   = triggerManager;
     _jobManager       = jobManager;
     _log              = log;
     _taskLog          = taskLogService;
     _jobFactory       = jobFactory;
     _task             = task;
     _schedulerFactory = schedulerFactory;
 }
Esempio n. 6
0
        string[] ITriggerEffect.getEvents(ITriggerManager manager)
        {
            List <string> eventList = new List <string>();

            if (!string.IsNullOrEmpty(trigger))
            {
                eventList.Add(trigger);
            }
            foreach (var triggerTime in triggerTimes)
            {
                eventList.Add(triggerTime.getEventName(manager));
            }
            return(eventList.ToArray());
        }
Esempio n. 7
0
        public Job_Scheduler(ISchedulerManager schedulermanager,
                             IJobGroupManager jobgroupmanager,
                             IJob_RPTEmailManager job_rptemailmanager,
                             IJob_SqlManager job_sqlmanager,
                             ITriggerManager triggermanager,
                             IUBPQuartzScheduleJobManager jobManager)
        {
            _SchedulerManager    = schedulermanager;
            _JobGroupManager     = jobgroupmanager;
            _Job_RPTEmailManager = job_rptemailmanager;
            _Job_SqlManager      = job_sqlmanager;
            _TriggerManager      = triggermanager;

            _jobManager = jobManager;
        }
        public virtual NeoDatis.Odb.Core.Trigger.ITriggerManager GetLocalTriggerManager(NeoDatis.Odb.Core.Layers.Layer3.IStorageEngine
                                                                                        engine)
        {
            // First check if trigger manager has already been built for the engine
            ITriggerManager triggerManager = null;

            triggerManagers.TryGetValue(engine, out triggerManager);
            if (triggerManager != null)
            {
                return(triggerManager);
            }
            triggerManager          = new DefaultTriggerManager(engine);
            triggerManagers[engine] = triggerManager;
            return(triggerManager);
        }
Esempio n. 9
0
        public AgentBase(Action <IAgent <TAction, TGoal>, IMaps <TAction, TGoal> > onInitGameData)
        {
            //初始化所有的系统
            _onInitGameData       = onInitGameData;
            DebugMsgBase.Instance = InitDebugMsg();
            AgentState            = InitAgentState();
            Maps            = InitMaps();
            ActionManager   = InitActionManager();
            GoalManager     = InitGoalManager();
            _triggerManager = InitTriggerManager();
            Performer       = new Performer <TAction, TGoal>(this);

            AgentState.AddStateChangeListener(UpdateData);

            JudgeException(Maps, "Maps");
            JudgeException(ActionManager, "ActionManager");
            JudgeException(GoalManager, "GoalManager");
            JudgeException(_triggerManager, "_triggerManager");
        }
Esempio n. 10
0
 public void SetId(int i, ITriggerManager m)
 {
     id      = i;
     manager = m;
 }
 public TriggerAppService(
     ITriggerManager triggermanager
     )
 {
     _TriggerManager = triggermanager;
 }
Esempio n. 12
0
 public abstract string getEventName(ITriggerManager manager);
Esempio n. 13
0
 public override string getEventName(ITriggerManager manager)
 {
     return(manager.getNameAfter <T>());
 }
Esempio n. 14
0
 public string[] getEvents(ITriggerManager manager)
 {
     return(new string[] { manager.getName <THHPlayer.ActiveEventArg>() });
 }
Esempio n. 15
0
 public string[] getEvents(ITriggerManager manager)
 {
     return(new string[0]);
 }
Esempio n. 16
0
 string[] ITriggerEffect.getEvents(ITriggerManager manager)
 {
     return(triggers.Select(t => t.getEventName(manager)).ToArray());
 }