Last active
March 10, 2016 14:42
-
-
Save renatorozas/4a4e8807e3f78c4751bb to your computer and use it in GitHub Desktop.
Getting started with gen_server
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
% Defines the module. | |
-module(kv_db_server). | |
% Makes the module implement the gen_server behaviour. | |
-behaviour(gen_server). | |
% Exports the required gen_server callbacks. | |
-export([init/1, handle_call/3, handle_cast/2, handle_info/2, | |
terminate/2, code_change/3]). | |
% Exports public functions that will ease interaction | |
% with the gen server. | |
-export([start/0]). |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment