public void notify(OtpActorMbox mbox) { OtpActorSchedTask task = mbox.Task; Monitor.Enter(runnable); try { Monitor.Enter(task); try { if (mbox.Task.Active) { runnable.Enqueue(mbox.Task); if (runnable.Count == 1) { Monitor.Pulse(runnable); } } } finally { Monitor.Exit(task); } } finally { Monitor.Exit(runnable); } }
public void canncel(OtpActorMbox mbox) { OtpActorSchedTask task = mbox.Task; Monitor.Enter(runnable); try { lock (task) { task.Active = false; } } finally { Monitor.Exit(runnable); } }
public PCVMActor(Scene scene, IConfigSource source, OtpNode node, OtpActorMbox mbox) : base(mbox) { m_scene = scene; m_source = source; m_node = node; m_mbox = mbox; m_dict = new PCDict(); m_vm = new PCVM(m_scene, m_source, m_dict); }
public KernelActor(Scene scene, IConfigSource source, OtpNode node, OtpActorMbox mbox) : base(mbox) { m_scene = scene; m_source = source; m_node = node; m_mbox = mbox; }
public void PostInitialise() { if (m_node != null) { m_mbox = (OtpActorMbox)m_node.createMbox("kernel", false); m_kernel = new KernelActor(m_scene, m_source, m_node, m_mbox); m_node.react(m_kernel); } }
public OtpEchoActor(OtpActorMbox mbox) : base(mbox) { }
public OtpActor(OtpActorMbox mbox) { this.mbox = mbox; }