reactor icon indicating copy to clipboard operation
reactor copied to clipboard

Provide more standard functions

Open leostera opened this issue 6 years ago • 0 comments

I'd like to keep track of some standard functions that we will need to build up more general patterns a la OTP.

Processes

  • [ ] exit : (Pid.t, ~reason:string) => unit — force termination of an actor.
  • [ ] is_alive : Pid.t => bool — whether a Pid is alive or not
  • [ ] register : (Pid.t, ~name:string) => unit — register a Pid with a well-known name
  • [ ] unregister (~name:string) => unit — unregisters a process if it's registered.
  • [ ] where_is : (~name:string) => option(Pid.t) — find a pid registered with a name
  • [ ] registered : unit => list((Pid.t, string)) — returns a list of tuples with the Pid and name they were registered with

System

  • [x] halt : unit => unit — notify the main scheduler we should take the system down.

leostera avatar Mar 03 '19 10:03 leostera