[erlang-questions] Erlang way for process-as-library?
Tue Feb 6 09:15:34 CET 2007
On 2/6/07, Robert Baruch <autophile@REDACTED> wrote:
> Now, the next question I have is: is there an Erlang way to forbid
> "ordinary users" from calling the server's callback functions
> directly (e.g. init, terminate, and so on), while allowing gen_server
> access to them?
No, you can't. One way to protect against inadvertent use is to put
the process' API (and only that) in a separate module from the one
implementing the functionality.
More information about the erlang-questions