diff --git a/apps/kolab_guam/src/kolab_guam_rule.erl b/apps/kolab_guam/src/kolab_guam_rule.erl index 7578932..f82d1b7 100644 --- a/apps/kolab_guam/src/kolab_guam_rule.erl +++ b/apps/kolab_guam/src/kolab_guam_rule.erl @@ -1,26 +1,35 @@ %% Copyright 2015 Kolab Systems AG (http://www.kolabsys.com) %% %% Aaron Seigo (Kolab Systems) %% %% This program is free software: you can redistribute it and/or modify %% it under the terms of the GNU General Public License as published by %% the Free Software Foundation, either version 3 of the License, or %% (at your option) any later version. %% %% This program is distributed in the hope that it will be useful, %% but WITHOUT ANY WARRANTY; without even the implied warranty of %% MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the %% GNU General Public License for more details. %% %% You should have received a copy of the GNU General Public License %% along with this program. If not, see . -module(kolab_guam_rule). --callback new(Args :: any()) -> any(). --callback applies(ConnectionDetails :: list(), Buffer :: binary(), SplitBinary :: { Tag :: binary(), Command :: binary(), Data :: binary() }, State :: any()) -> { true, State :: any() } | - { false, State :: any() } | - { notyet, State :: any() }. --callback apply_to_client_message(ImapSession :: pid(), Command :: binary(), SplitBinary :: { Tag :: binary(), Command :: binary(), Data :: binary() }, State :: any()) -> { ProcessedCommand :: binary(), State :: any() }. --callback apply_to_server_message(ImapSession :: pid(), Command :: binary(), State :: any()) -> { ProcessedCommand :: binary(), State :: any() }. --callback imap_data(ResponseToken :: any(), Response :: any(), State :: any()) -> State ::any(). +-callback new(Args :: any()) -> + State :: any(). + +-callback applies(ConnectionDetails :: list(), Buffer :: binary(), SplitBinary :: { Tag :: binary(), Command :: binary(), Data :: binary() }, State :: any()) -> + { true, State :: any() } | + { false, State :: any() } | + { notyet, State :: any() }. + +-callback apply_to_client_message(ImapSession :: pid(), Command :: binary(), SplitBinary :: { Tag :: binary(), Command :: binary(), Data :: binary() }, State :: any()) -> + { ProcessedCommand :: binary(), State :: any() }. + +-callback apply_to_server_message(ImapSession :: pid(), Command :: binary(), State :: any()) -> + { ProcessedCommand :: binary(), State :: any() }. + +-callback imap_data(ResponseToken :: any(), Response :: any(), State :: any()) -> + State :: any().