Антон Загорский wrote:
Hello.
I'm writing a voicemail/voicebox service and I want to use SEMS msg_storage
app. Is it possible to invoke its functions? Or I should write a separate
DSM module?
you can invoke DI functions with DI action:
DI(factory, function [, params...])
e.g. DI(factory, function, $var_param, (int)int_param, "str param",
@select_par, (array)arrayname, (struct)structname, (json)json_object...)
DI(user_timer, setTimer, (int)1, (int)5, @local_tag);
set($sweets.candy="nice");
set($sweets.fruit="superb");
set($sweets.cake.tahini="great");
DI(myfactory, myfunc, (struct)sweets);
set($bi[0]="ba");
set($bi[1]="butzki");
DI(myfactory, myfunc, (array)bi);
set($js="{"x":"y", "a": 1}");
DI(myfactory, myfunc, (json)$js);
* sets $errno (arg,config)
DIgetResult(factory, function, param,...)
saves result from DI call to DI_res or DI_res0, DI_res1, ...
* sets $errno (arg,config)
For passing the fp to and from msg_storage, you might need to adapt
this a little, or add some function.
Depending on your system and application, it might also be an option
to use a mysql DB for the message list, and just use the normal
playFile/recordFile/sys.unlink actions. OTOH, using msg_storage is
very simple and everything self-contained.
Stefan
[email protected]
www.oyster-telecom.ru
_______________________________________________
Sems mailing list
[email protected]
http://lists.iptel.org/mailman/listinfo/sems
--
Stefan Sayer
VoIP Services Consulting and Development
Warschauer Str. 24
10243 Berlin
tel:+491621366449
sip:[email protected]
email/xmpp:[email protected]
_______________________________________________
Sems mailing list
[email protected]
http://lists.iptel.org/mailman/listinfo/sems