Freeswitch-svn
Threads by month
- ----- 2026 -----
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2025 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2024 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2023 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2022 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2021 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2020 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2019 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2018 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2017 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2016 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2015 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2014 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2013 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2012 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2011 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2010 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2009 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2008 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2007 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2006 -----
- December
- November
- October
- September
- August
- July
- June
April 2009
- 20 participants
- 351 discussions
09 Apr '09
Author: rupa
Date: Thu Apr 9 15:58:34 2009
New Revision: 12972
Log:
add static to functions
Modified:
freeswitch/trunk/src/mod/applications/mod_lcr/mod_lcr.c
Modified: freeswitch/trunk/src/mod/applications/mod_lcr/mod_lcr.c
==============================================================================
--- freeswitch/trunk/src/mod/applications/mod_lcr/mod_lcr.c (original)
+++ freeswitch/trunk/src/mod/applications/mod_lcr/mod_lcr.c Thu Apr 9 15:58:34 2009
@@ -63,7 +63,7 @@
#define LCR_HEADERS_CID 5
#define LCR_
-char headers[LCR_HEADERS_COUNT][32] = {
+static char headers[LCR_HEADERS_COUNT][32] = {
"Digit Match",
"Carrier",
"Rate",
@@ -73,7 +73,7 @@
};
/* sql for random function */
-char *db_random = NULL;
+static char *db_random = NULL;
struct odbc_obj {
switch_odbc_handle_t *handle;
@@ -262,7 +262,7 @@
return data;
}
-profile_t *locate_profile(const char *profile_name)
+static profile_t *locate_profile(const char *profile_name)
{
profile_t *profile = NULL;
@@ -276,7 +276,7 @@
}
-void init_max_lens(max_len maxes)
+static void init_max_lens(max_len maxes)
{
maxes->digit_str = (headers[LCR_HEADERS_DIGITS] == NULL ? 0 : strlen(headers[LCR_HEADERS_DIGITS]));
maxes->carrier_name = (headers[LCR_HEADERS_CARRIER] == NULL ? 0 : strlen(headers[LCR_HEADERS_CARRIER]));
@@ -286,7 +286,7 @@
maxes->cid = (headers[LCR_HEADERS_CID] == NULL ? 0 : strlen(headers[LCR_HEADERS_CID]));
}
-switch_status_t process_max_lengths(max_obj_t *maxes, lcr_route routes, char *destination_number)
+static switch_status_t process_max_lengths(max_obj_t *maxes, lcr_route routes, char *destination_number)
{
lcr_route current = NULL;
@@ -491,7 +491,7 @@
return retval;
}
-int route_add_callback(void *pArg, int argc, char **argv, char **columnNames)
+static int route_add_callback(void *pArg, int argc, char **argv, char **columnNames)
{
lcr_route additional = NULL;
lcr_route current = NULL;
@@ -610,7 +610,7 @@
return SWITCH_STATUS_SUCCESS;
}
-switch_status_t lcr_do_lookup(callback_t *cb_struct)
+static switch_status_t lcr_do_lookup(callback_t *cb_struct)
{
switch_stream_handle_t sql_stream = { 0 };
char *digits = cb_struct->lookup_number;
@@ -684,7 +684,7 @@
}
}
-switch_bool_t test_profile(char *lcr_profile)
+static switch_bool_t test_profile(char *lcr_profile)
{
callback_t routes = { 0 };
switch_memory_pool_t *pool = NULL;
1
0
Author: buklov
Date: Thu Apr 9 15:50:52 2009
New Revision: 12971
Log:
Russian translate
Added:
freeswitch/trunk/docs/phrase/phrase_ru.xml
Added: freeswitch/trunk/docs/phrase/phrase_ru.xml
==============================================================================
--- (empty file)
+++ freeswitch/trunk/docs/phrase/phrase_ru.xml Thu Apr 9 15:50:52 2009
@@ -0,0 +1,506 @@
+<language>
+ <ru>
+ <ascii>
+ <prompt phrase="������ " filename= "32"/>
+ <prompt phrase="����� " filename= "35"/>
+ <prompt phrase="��������� " filename= "42"/>
+ <prompt phrase="����� " filename= "46"/>
+ <prompt phrase="A " filename= "97"/>
+ <prompt phrase="B " filename= "98"/>
+ <prompt phrase="C " filename= "99"/>
+ <prompt phrase="D " filename= "100"/>
+ <prompt phrase="E " filename= "101"/>
+ <prompt phrase="F " filename= "102"/>
+ <prompt phrase="G " filename= "103"/>
+ <prompt phrase="H " filename= "104"/>
+ <prompt phrase="I " filename= "105"/>
+ <prompt phrase="J " filename= "106"/>
+ <prompt phrase="K " filename= "107"/>
+ <prompt phrase="L " filename= "108"/>
+ <prompt phrase="M " filename= "109"/>
+ <prompt phrase="N " filename= "110"/>
+ <prompt phrase="O " filename= "111"/>
+ <prompt phrase="P " filename= "112"/>
+ <prompt phrase="Q " filename= "112"/>
+ <prompt phrase="R " filename= "114"/>
+ <prompt phrase="S " filename= "115"/>
+ <prompt phrase="T " filename= "116"/>
+ <prompt phrase="U " filename= "117"/>
+ <prompt phrase="V " filename= "118"/>
+ <prompt phrase="W " filename= "119"/>
+ <prompt phrase="X " filename= "120"/>
+ <prompt phrase="Y " filename= "121"/>
+ <prompt phrase="Z " filename= "122"/>
+ </ascii>
+ <phonetic>
+ <prompt phrase="������ " filename= "32"/>
+ <prompt phrase="����� " filename= "46"/>
+ <prompt phrase="Alpha " filename= "97"/>
+ <prompt phrase="Bravo " filename= "98"/>
+ <prompt phrase="Charlie " filename= "99"/>
+ <prompt phrase="Delta " filename= "100"/>
+ <prompt phrase="Echo " filename= "101"/>
+ <prompt phrase="Foxtrot " filename= "102"/>
+ <prompt phrase="Golf " filename= "103"/>
+ <prompt phrase="Hotel " filename= "104"/>
+ <prompt phrase="India " filename= "105"/>
+ <prompt phrase="Juliet " filename= "106"/>
+ <prompt phrase="Kilo " filename= "107"/>
+ <prompt phrase="Lima " filename= "108"/>
+ <prompt phrase="Mike " filename= "109"/>
+ <prompt phrase="November " filename= "110"/>
+ <prompt phrase="Oscar " filename= "111"/>
+ <prompt phrase="Papa " filename= "112"/>
+ <prompt phrase="Quebec " filename= "113"/>
+ <prompt phrase="Romeo " filename= "114"/>
+ <prompt phrase="Sierra " filename= "115"/>
+ <prompt phrase="Tango " filename= "116"/>
+ <prompt phrase="Unifor " filename= "117"/>
+ <prompt phrase="Victor " filename= "118"/>
+ <prompt phrase="Whiskey " filename= "119"/>
+ <prompt phrase="Xray " filename= "120"/>
+ <prompt phrase="Yankee " filename= "121"/>
+ <prompt phrase="Zulu " filename= "122"/>
+ </phonetic>
+ <digits>
+ <prompt phrase="���� " filename= "0"/>
+ <prompt phrase="�������" filename= "h-0f"/>
+ <prompt phrase="�������" filename= "h-0m"/>
+ <prompt phrase="�������" filename= "h-0n"/>
+ <prompt phrase="��������" filename= "h-0x"/>
+ <prompt phrase="���� " filename= "1"/>
+ <prompt phrase="���� " filename= "1f"/>
+ <prompt phrase="���� " filename= "1n"/>
+ <prompt phrase="������" filename= "1x"/>
+ <prompt phrase="������� " filename= "h-1x"/>
+ <prompt phrase="������ " filename= "h-1m"/>
+ <prompt phrase="������" filename= "h-1n"/>
+ <prompt phrase="������" filename= "h-1f"/>
+ <prompt phrase="����" filename= "h-1xx"/>
+ <prompt phrase="��� " filename= "2"/>
+ <prompt phrase="��� " filename= "2f"/>
+ <prompt phrase="��� " filename= "2n"/>
+ <prompt phrase="������" filename= "h-2n"/>
+ <prompt phrase="������� " filename= "h-2x"/>
+ <prompt phrase="������ " filename= "h-2m"/>
+ <prompt phrase="������" filename= "h-2f"/>
+ <prompt phrase="����" filename= "h-2xx"/>
+ <prompt phrase="��� " filename= "3"/>
+ <prompt phrase="�������� " filename= "h-3x"/>
+ <prompt phrase="������ " filename= "h-3m"/>
+ <prompt phrase="������" filename= "h-3f"/>
+ <prompt phrase="������" filename= "h-3n"/>
+ <prompt phrase="���" filename= "h-3xx"/>
+ <prompt phrase="������ " filename= "4"/>
+ <prompt phrase="��������" filename= "h-4f"/>
+ <prompt phrase="��������� " filename= "h-4x"/>
+ <prompt phrase="�������� " filename= "h-4m"/>
+ <prompt phrase="��������" filename= "h-4n"/>
+ <prompt phrase="������" filename= "h-4xx"/>
+ <prompt phrase="����" filename= "5"/>
+ <prompt phrase="�����" filename= "h-5f"/>
+ <prompt phrase="������" filename= "h-5x"/>
+ <prompt phrase="�������� " filename= "h-5m"/>
+ <prompt phrase="��������" filename= "h-5n"/>
+ <prompt phrase="����" filename= "h-5xx"/>
+ <prompt phrase="�����" filename= "6"/>
+ <prompt phrase="������" filename= "h-6f"/>
+ <prompt phrase="�������" filename= "h-6x"/>
+ <prompt phrase="������" filename= "h-6m"/>
+ <prompt phrase="������" filename= "h-6n"/>
+ <prompt phrase="�����" filename= "h-6xx"/>
+ <prompt phrase="����" filename= "7"/>
+ <prompt phrase="�������" filename= "h-7f"/>
+ <prompt phrase="��������" filename= "h-7x"/>
+ <prompt phrase="�������" filename= "h-7m"/>
+ <prompt phrase="�������" filename= "h-7n"/>
+ <prompt phrase="����" filename= "h-7xx"/>
+ <prompt phrase="������" filename= "8"/>
+ <prompt phrase="�������" filename= "h-8f"/>
+ <prompt phrase="��������" filename= "h-8x"/>
+ <prompt phrase="�������" filename= "h-8m"/>
+ <prompt phrase="�������" filename= "h-8n"/>
+ <prompt phrase="������" filename= "h-8xx"/>
+ <prompt phrase="������" filename= "9"/>
+ <prompt phrase="�������" filename= "h-9f"/>
+ <prompt phrase="��������" filename= "h-9x"/>
+ <prompt phrase="�������" filename= "h-9m"/>
+ <prompt phrase="�������" filename= "h-9n"/>
+ <prompt phrase="������" filename= "h-9xx"/>
+ <prompt phrase="������" filename= "10"/>
+ <prompt phrase="�������" filename= "h-10f"/>
+ <prompt phrase="��������" filename= "h-10x"/>
+ <prompt phrase="�������" filename= "h-10m"/>
+ <prompt phrase="�������" filename= "h-10n"/>
+ <prompt phrase="������" filename= "h-10xx"/>
+ <prompt phrase="����������" filename= "11"/>
+ <prompt phrase="�����������" filename= "h-11f"/>
+ <prompt phrase="������������" filename= "h-11x"/>
+ <prompt phrase="�����������" filename= "h-11m"/>
+ <prompt phrase="�����������" filename= "h-11n"/>
+ <prompt phrase="����������" filename= "h-11xx"/>
+ <prompt phrase="����������" filename= "12"/>
+ <prompt phrase="�����������" filename= "h-12f"/>
+ <prompt phrase="������������" filename= "h-12x"/>
+ <prompt phrase="�����������" filename= "h-12m"/>
+ <prompt phrase="�����������" filename= "h-12n"/>
+ <prompt phrase="����������" filename= "h-12xx"/>
+ <prompt phrase="����������" filename= "13"/>
+ <prompt phrase="�����������" filename= "h-13f"/>
+ <prompt phrase="������������" filename= "h-13x"/>
+ <prompt phrase="�����������" filename= "h-13m"/>
+ <prompt phrase="�����������" filename= "h-13n"/>
+ <prompt phrase="����������" filename= "h-13xx"/>
+ <prompt phrase="������������" filename= "14"/>
+ <prompt phrase="�������������" filename= "h-14f"/>
+ <prompt phrase="��������������" filename= "h-14x"/>
+ <prompt phrase="�������������" filename= "h-14m"/>
+ <prompt phrase="�������������" filename= "h-14n"/>
+ <prompt phrase="������������" filename= "h-14xx"/>
+ <prompt phrase="����������" filename= "15"/>
+ <prompt phrase="�����������" filename= "h-15f"/>
+ <prompt phrase="������������" filename= "h-15x"/>
+ <prompt phrase="�����������" filename= "h-15m"/>
+ <prompt phrase="�����������" filename= "h-15n"/>
+ <prompt phrase="����������" filename= "h-15xx"/>
+ <prompt phrase="�����������" filename= "16"/>
+ <prompt phrase="������������" filename= "h-16f"/>
+ <prompt phrase="�������������" filename= "h-16x"/>
+ <prompt phrase="������������" filename= "h-16m"/>
+ <prompt phrase="������������" filename= "h-16n"/>
+ <prompt phrase="�����������" filename= "h-16xx"/>
+ <prompt phrase="����������" filename= "17"/>
+ <prompt phrase="�����������" filename= "h-17f"/>
+ <prompt phrase="������������" filename= "h-17x"/>
+ <prompt phrase="�����������" filename= "h-17m"/>
+ <prompt phrase="�����������" filename= "h-17n"/>
+ <prompt phrase="����������" filename= "h-17xx"/>
+ <prompt phrase="������������" filename= "18"/>
+ <prompt phrase="�������������" filename= "h-18f"/>
+ <prompt phrase="��������������" filename= "h-18x"/>
+ <prompt phrase="�������������" filename= "h-18m"/>
+ <prompt phrase="�������������" filename= "h-18n"/>
+ <prompt phrase="������������" filename= "h-18xx"/>
+ <prompt phrase="������������" filename= "19"/>
+ <prompt phrase="�������������" filename= "h-19f"/>
+ <prompt phrase="��������������" filename= "h-19x"/>
+ <prompt phrase="�������������" filename= "h-19m"/>
+ <prompt phrase="�������������" filename= "h-19n"/>
+ <prompt phrase="������������" filename= "h-19xx"/>
+ <prompt phrase="��������" filename= "20"/>
+ <prompt phrase="���������" filename= "h-20f"/>
+ <prompt phrase="����������" filename= "h-20x"/>
+ <prompt phrase="���������" filename= "h-20m"/>
+ <prompt phrase="���������" filename= "h-20n"/>
+ <prompt phrase="��������" filename= "h-20xx"/>
+ <prompt phrase="��������" filename= "30"/>
+ <prompt phrase="���������" filename= "h-30f"/>
+ <prompt phrase="����������" filename= "h-30x"/>
+ <prompt phrase="���������" filename= "h-30m"/>
+ <prompt phrase="���������" filename= "h-30n"/>
+ <prompt phrase="��������" filename= "h-30xx"/>
+ <prompt phrase="�����" filename= "40"/>
+ <prompt phrase="���������" filename= "h-40f"/>
+ <prompt phrase="����������" filename= "h-40x"/>
+ <prompt phrase="���������" filename= "h-40m"/>
+ <prompt phrase="���������" filename= "h-40n"/>
+ <prompt phrase="������" filename= "h-40xx"/>
+ <prompt phrase="���������" filename= "50"/>
+ <prompt phrase="�����������" filename= "h-50f"/>
+ <prompt phrase="������������" filename= "h-50x"/>
+ <prompt phrase="�����������" filename= "h-50m"/>
+ <prompt phrase="�����������" filename= "h-50n"/>
+ <prompt phrase="����������" filename= "h-50xx"/>
+ <prompt phrase="����������" filename= "60"/>
+ <prompt phrase="������������" filename= "h-60f"/>
+ <prompt phrase="�������������" filename= "h-60x"/>
+ <prompt phrase="������������" filename= "h-60m"/>
+ <prompt phrase="������������" filename= "h-60n"/>
+ <prompt phrase="�����������" filename= "h-60xx"/>
+ <prompt phrase="���������" filename= "70"/>
+ <prompt phrase="�����������" filename= "h-70f"/>
+ <prompt phrase="������������" filename= "h-70x"/>
+ <prompt phrase="�����������" filename= "h-70m"/>
+ <prompt phrase="�����������" filename= "h-70n"/>
+ <prompt phrase="����������" filename= "h-70xx"/>
+ <prompt phrase="�����������" filename= "80"/>
+ <prompt phrase="�������������" filename= "h-80f"/>
+ <prompt phrase="��������������" filename= "h-80x"/>
+ <prompt phrase="�������������" filename= "h-80m"/>
+ <prompt phrase="�������������" filename= "h-80n"/>
+ <prompt phrase="������������" filename= "h-80xx"/>
+ <prompt phrase="���������" filename= "90"/>
+ <prompt phrase="����������" filename= "h-90f"/>
+ <prompt phrase="�����������" filename= "h-90x"/>
+ <prompt phrase="����������" filename= "h-90m"/>
+ <prompt phrase="����������" filename= "h-90n"/>
+ <prompt phrase="���������" filename= "h-90xx"/>
+ <prompt phrase="���" filename= "100"/>
+ <prompt phrase="�����" filename= "h-100f"/>
+ <prompt phrase="������" filename= "h-100x"/>
+ <prompt phrase="�����" filename= "h-100m"/>
+ <prompt phrase="�����" filename= "h-100n"/>
+ <prompt phrase="���" filename= "h-100xx"/>
+ <prompt phrase="������" filename= "200"/>
+ <prompt phrase="���������" filename= "h-200f"/>
+ <prompt phrase="����������" filename= "h-200x"/>
+ <prompt phrase="���������" filename= "h-200m"/>
+ <prompt phrase="���������" filename= "h-200n"/>
+ <prompt phrase="�������" filename= "h-200xx"/>
+ <prompt phrase="������" filename= "300"/>
+ <prompt phrase="��������" filename= "h-300f"/>
+ <prompt phrase="���������" filename= "h-300x"/>
+ <prompt phrase="��������" filename= "h-300m"/>
+ <prompt phrase="��������" filename= "h-300n"/>
+ <prompt phrase="������" filename= "h-300xx"/>
+ <prompt phrase="���������" filename= "400"/>
+ <prompt phrase="�����������" filename= "h-400f"/>
+ <prompt phrase="������������" filename= "h-400x"/>
+ <prompt phrase="�����������" filename= "h-400m"/>
+ <prompt phrase="�����������" filename= "h-400n"/>
+ <prompt phrase="���������" filename= "h-400xx"/>
+ <prompt phrase="�������" filename= "500"/>
+ <prompt phrase="���������" filename= "h-500f"/>
+ <prompt phrase="����������" filename= "h-500x"/>
+ <prompt phrase="���������" filename= "h-500m"/>
+ <prompt phrase="���������" filename= "h-500n"/>
+ <prompt phrase="�������" filename= "h-500xx"/>
+ <prompt phrase="��������" filename= "600"/>
+ <prompt phrase="����������" filename= "h-600f"/>
+ <prompt phrase="�����������" filename= "h-600x"/>
+ <prompt phrase="����������" filename= "h-600m"/>
+ <prompt phrase="����������" filename= "h-600n"/>
+ <prompt phrase="��������" filename= "h-600xx"/>
+ <prompt phrase="�������" filename= "700"/>
+ <prompt phrase="���������" filename= "h-700f"/>
+ <prompt phrase="����������" filename= "h-700x"/>
+ <prompt phrase="���������" filename= "h-700m"/>
+ <prompt phrase="���������" filename= "h-700n"/>
+ <prompt phrase="�������" filename= "h-700xx"/>
+ <prompt phrase="���������" filename= "800"/>
+ <prompt phrase="�����������" filename= "h-800f"/>
+ <prompt phrase="������������" filename= "h-800x"/>
+ <prompt phrase="�����������" filename= "h-800m"/>
+ <prompt phrase="�����������" filename= "h-800n"/>
+ <prompt phrase="���������" filename= "h-800xx"/>
+ <prompt phrase="���������" filename= "900"/>
+ <prompt phrase="�����������" filename= "h-900f"/>
+ <prompt phrase="������������" filename= "h-900x"/>
+ <prompt phrase="�����������" filename= "h-900m"/>
+ <prompt phrase="�����������" filename= "h-900n"/>
+ <prompt phrase="���������" filename= "h-900xx"/>
+ <prompt phrase="������ " filename= "thousand"/>
+ <prompt phrase="������ " filename= "thousands-i"/>
+ <prompt phrase="����� " filename= "thousands"/>
+ <prompt phrase="��������" filename= "h-thousandf"/>
+ <prompt phrase="���������" filename= "h-thousandx"/>
+ <prompt phrase="��������" filename= "h-thousandm"/>
+ <prompt phrase="��������" filename= "h-thousandn"/>
+ <prompt phrase="������� " filename= "million"/>
+ <prompt phrase="�������� " filename= "million-a"/>
+ <prompt phrase="��������� " filename= "millions"/>
+ <prompt phrase="����������" filename= "h-millionf"/>
+ <prompt phrase="����������� " filename= "h-millionx"/>
+ <prompt phrase="����������" filename= "h-millionm"/>
+ <prompt phrase="����������" filename= "h-millionn"/>
+ <prompt phrase="����� " filename= "dot"/>
+ <prompt phrase="������ " filename= "period"/>
+ <prompt phrase="����� " filename= "point"/>
+ <prompt phrase="������� " filename= "pound"/>
+ <prompt phrase="�������� " filename= "star"/>
+ </digits>
+ <currency>
+ <prompt phrase="� " filename= "and"/>
+ <prompt phrase="���� " filename= "cent"/>
+ <prompt phrase="����������� " filename= "central"/>
+ <prompt phrase="������ � ������ " filename= "cents-per-minute"/>
+ <prompt phrase="����� " filename= "cents"/>
+ <prompt phrase="������ " filename= "dollar"/>
+ <prompt phrase="�������� " filename= "dollars"/>
+ <prompt phrase="����� " filename= "minus"/>
+ <prompt phrase="������������� " filename= "negative"/>
+ <prompt phrase="������ " filename= "kopx "/>
+ <prompt phrase="������� " filename= "kop "/>
+ <prompt phrase="������� " filename= "kops "/>
+ <prompt phrase="����� " filename= "rubl "/>
+ <prompt phrase="����� " filename= "rublx "/>
+ <prompt phrase="������ " filename= "rubls "/>
+ </currency>
+ <time>
+ <prompt phrase="�� ������� " filename= "a-m"/>
+ <prompt phrase="� " filename= "at"/>
+ <prompt phrase="����������� " filename= "day-0"/>
+ <prompt phrase="����������� " filename= "day-1"/>
+ <prompt phrase="������� " filename= "day-2"/>
+ <prompt phrase="����� " filename= "day-3"/>
+ <prompt phrase="������� " filename= "day-4"/>
+ <prompt phrase="������� " filename= "day-5"/>
+ <prompt phrase="������� " filename= "day-6"/>
+ <prompt phrase="���" filename= "hour"/>
+ <prompt phrase="���� " filename= "hours-a"/>
+ <prompt phrase="����� " filename= "hours"/>
+ <prompt phrase="������ " filename= "minute"/>
+ <prompt phrase="������" filename= "minutes-i"/>
+ <prompt phrase="����� " filename= "minutes"/>
+ <prompt phrase="������� " filename= "second"/>
+ <prompt phrase="������� " filename= "seconds-i"/>
+ <prompt phrase="������" filename= "seconds"/>
+ <prompt phrase="������ " filename= "mon-0"/>
+ <prompt phrase="������� " filename= "mon-1"/>
+ <prompt phrase="����� " filename= "mon-2"/>
+ <prompt phrase="������ " filename= "mon-3"/>
+ <prompt phrase="��� " filename= "mon-4"/>
+ <prompt phrase="���� " filename= "mon-5"/>
+ <prompt phrase="���� " filename= "mon-6"/>
+ <prompt phrase="������� " filename= "mon-7"/>
+ <prompt phrase="�������� " filename= "mon-8"/>
+ <prompt phrase="������� " filename= "mon-9"/>
+ <prompt phrase="������ " filename= "mon-10"/>
+ <prompt phrase="������� " filename= "mon-11"/>
+ <prompt phrase="����� ������� " filename= "p-m"/>
+ <prompt phrase="������� " filename= "today"/>
+ <prompt phrase="������ " filename= "tomorrow"/>
+ <prompt phrase="����� " filename= "yesterday"/>
+ <prompt phrase="���" filename= "year"/>
+ <prompt phrase="����" filename= "h-year"/>
+ <prompt phrase="�����" filename= "years"/>
+ <prompt phrase="���" filename= "yearsx"/>
+ </time>
+ <voicemail>
+ <prompt phrase="������� � ������� " filename= "vm-person"/>
+ <prompt phrase="�������� ��� ������ " filename= "vm-marked_urgent"/>
+ <prompt phrase="��������� �� ����������� �����" filename= "vm-emailed"/>
+ <prompt phrase="� ��� " filename= "vm-you_have"/>
+ <prompt phrase="����������, ������� ���� ���� " filename= "vm-enter_id"/>
+ <prompt phrase="����������, ������� ���� ������ " filename= "vm-enter_pass"/>
+ <prompt phrase="������������ ����� " filename= "vm-fail_auth"/>
+ <prompt phrase="����� ���������� � ���� ��������� ����� " filename= "vm-hello"/>
+ <prompt phrase="�� �������� " filename= "vm-goodbye"/>
+ <prompt phrase="����� �������, ����������, �������� ���� ���, ��� ��������� ������ ������� ����� ������� ��� ����������� ��������. " filename= "vm-record_name1"/>
+ <prompt phrase="�������� ����������� �� ������� �� ������ " filename= "vm-choose_greeting_choose"/>
+ <prompt phrase="������������ �������� " filename= "vm-choose_greeting_fail"/>
+ <prompt phrase="������� ����� ��������� ������� " filename= "vm-abort"/>
+ <prompt phrase="��� ��������� ������ ������ " filename= "vm-change_password"/>
+ <prompt phrase="����� �������, �������� ���� �����������, ��� ��������� ������ ������� ����� ������� ��� ����������� �������� " filename= "vm-to_record_greeting"/>
+ <prompt phrase="����� �������, �������� ���� ���������, ��� ��������� ������ ������� ����� ������� ��� ����������� �������� " filename= "vm-record_message"/>
+ <prompt phrase="�� �������� " filename= "vm-play_greeting"/>
+ <prompt phrase="����� ������" filename= "vm-urgent-newx"/>
+ <prompt phrase="����� ������ " filename= "vm-urgent-new"/>
+ <prompt phrase="����� " filename= "vm-new"/>
+ <prompt phrase="����� " filename= "vm-newx "/>
+ <prompt phrase="������ ��������� " filename= "vm-urgent-saved"/>
+ <prompt phrase="��������� " filename= "vm-saved"/>
+ <prompt phrase="��������� " filename= "vm-message"/>
+ <prompt phrase="��������� " filename= "vm-messagex"/>
+ <prompt phrase="��������� " filename= "vm-messages"/>
+ <prompt phrase="������� " filename= "vm-press"/>
+ <prompt phrase="��� ������������� ����� ��������� " filename= "vm-listen_new"/>
+ <prompt phrase="��� ������������� ����������� ��������� " filename= "vm-listen_saved"/>
+ <prompt phrase="��� �������������� ���������� " filename= "vm-advanced"/>
+ <prompt phrase="��� ������ " filename= "vm-to_exit"/>
+ <prompt phrase="��� ������ ����������� " filename= "vm-record_greeting"/>
+ <prompt phrase="��� ������ ����������� " filename= "vm-choose_greeting"/>
+ <prompt phrase="��� ������ ������ ����� " filename= "vm-record_name2"/>
+ <prompt phrase="��� �������� � ������� ���� " filename= "vm-main_menu"/>
+ <prompt phrase="���������� ������ " filename= "vm-listen_to_recording"/>
+ <prompt phrase="��������� ������ " filename= "vm-save_recording"/>
+ <prompt phrase="�������� " filename= "vm-rerecord"/>
+ <prompt phrase="�������� ��� ��������� ������� " filename= "vm-mark-urgent"/>
+ <prompt phrase="��� ����������� " filename= "vm-continue"/>
+ <prompt phrase="���������� ������ ����� " filename= "vm-listen_to_recording_again"/>
+ <prompt phrase="������� ������ " filename= "vm-delete_recording"/>
+ <prompt phrase="����������������������" filename= "vm-to_forward"/>
+ <prompt phrase="��������� ������ �� ����������� ����� " filename= "vm-forward_to_email"/>
+ <prompt phrase="����������� " filename= "vm-greeting"/>
+ <prompt phrase="������� " filename= "vm-selected"/>
+ <prompt phrase="�� �������� " filename= "vm-not_available"/>
+ <prompt phrase="��������� ����� " filename= "vm-message_number"/>
+ <prompt phrase="������� " filename= "vm-deleted"/>
+ <prompt phrase="���� ������ ������ ���������� ���������� ������, ���������� ���������� ����� " filename= "vm-too-small"/>
+ <prompt phrase="� ����� �������� " filename= "vm-in_folder"/>
+ <prompt phrase="��� �� �����������" filename= "vm-return_call_1"/>
+ <prompt phrase="��� �������� ������ " filename= "vm-return_call"/>
+ <prompt phrase="������" filename= "vm-urgent"/>
+ <prompt phrase="�������� ���������� � ���������" filename= "vm-forward_add_intro"/>
+ <prompt phrase="��� ���� ��� �� ������� ��������� " filename= "vm-send_message_now"/>
+ <prompt phrase="����������, ������� ���������� ����� ��� �������� ���������" filename= "vm-forward_enter_ext"/>
+ <prompt phrase="������������ ���������� �����" filename= "vm-that_was_an_invalid_ext"/>
+ </voicemail>
+ <conference>
+ <prompt phrase="NULL " filename= "conf-ack type"/>
+ <prompt phrase="NULL " filename= "conf-nack type"/>
+ <prompt phrase="��� �������� �������� " filename= "conf-mute"/>
+ <prompt phrase="��� �������� ������� " filename= "conf-unmuted"/>
+ <prompt phrase="�� ������������ �������� �����������" filename= "conf-alone"/>
+ <prompt phrase="NULL " filename= "conf-perpetual type"/>
+ <prompt phrase="NULL " filename= "conf-enter type"/>
+ <prompt phrase="NULL " filename= "conf-exit type"/>
+ <prompt phrase="�� ���� ��������� �� ����������� " filename= "conf-kicked"/>
+ <prompt phrase="��� ����������� ������������� " filename= "conf-locked"/>
+ <prompt phrase="����������� ������������� " filename= "conf-is-locked"/>
+ <prompt phrase="����������� �������������� " filename= "conf-is-unlocked"/>
+ <prompt phrase="����������, ������� ���-��� ����������� " filename= "conf-pin"/>
+ <prompt phrase="������������ ���-���, ���������� ����� " filename= "conf-bad-pin"/>
+ <prompt phrase="�� �������� " filename= "conf-goodbye"/>
+ <prompt phrase="����� ���������� � ����������� " filename= "conf-welcome"/>
+ </conference>
+ <ivr>
+ <prompt phrase="����� ����� " filename= "ivr-account_number"/>
+ <prompt phrase="���������� � ���������� ��������� " filename= "ivr-connect_to_caller"/>
+ <prompt phrase="���� ��� �������� ���������� ����� ����������� ��������, ���������� ������� ��� ������ " filename= "ivr-enter_ext_pound"/>
+ <prompt phrase="����������, ������� ���������� ����� �������� ����� ����� ������� " filename= "ivr-enter_ext"/>
+ <prompt phrase="��� ����� �������� " filename= "ivr-for_this_person"/>
+ <prompt phrase="����������, ����������� �� �����, ���� ���������� " filename= "ivr-hold_connect_call"/>
+ <prompt phrase="�������� " filename= "ivr-im_sorry"/>
+ <prompt phrase="���������� " filename= "ivr-please"/>
+ <prompt phrase="����������, ����������� ��� � � " filename= "ivr-please_return_our_call_at"/>
+ <prompt phrase="�������� ������ ������ " filename= "ivr-regarding_reference_number"/>
+ <prompt phrase="��� ������� ivr ������� " filename= "ivr-sample_submenu"/>
+ <prompt phrase="����������, �������� ���� ��� ����� ������� " filename= "ivr-say_name"/>
+ <prompt phrase="������������� �� ��������� ����� " filename= "ivr-send_to_voicemail"/>
+ <prompt phrase="��� ��������� � �������������� �� ������������ �������� " filename= "ivr-speak_to_a_customer_service_representative"/>
+ <prompt phrase="������� ��������� " filename= "ivr-take_a_message"/>
+ <prompt phrase="������� " filename= "ivr-thank_you"/>
+ <prompt phrase="������������ �������� " filename= "ivr-that_was_an_invalid_entry"/>
+ <prompt phrase="���� ������ �� " filename= "ivr-this_is_a_call_from"/>
+ <prompt phrase="��� ��������� ����������� �������� ��� �������������� ��������� ������� " filename= "ivr-this_ivr_will_let_you_test_features"/>
+ <prompt phrase="��� ���� ����� ������� ����������� �� ___ " filename= "ivr-to_call_the_freeswitch_conference"/>
+ <prompt phrase="��� ���������� ���-����� � �� " filename= "ivr-to_do_a_freeswitch_echo_test"/>
+ <prompt phrase="��� ���������� ���-����� free world dialed " filename= "ivr-to_do_a_fwd_echo_test"/>
+ <prompt phrase="��� ������������� ������� ���������� ������� " filename= "ivr-to_hear_sample_submenu"/>
+ <prompt phrase="����� �������� �������� ������� " filename= "ivr-to_hear_screaming_monkeys"/>
+ <prompt phrase="��� ������ ������� � ������ �������� " filename= "ivr-to_listen_to_moh"/>
+ <prompt phrase="��� ������� ���� ���������� " filename= "ivr-to_repeat_these_options"/>
+ <prompt phrase="��� �������� � ����������� ���� " filename= "ivr-to_return_to_previous_menu"/>
+ <prompt phrase="��� ��������� � ���������� " filename= "ivr-to_speak_with_an_operator"/>
+ <prompt phrase="����� ���������� � FreeSwitch, ������� ��������� " filename= "ivr-welcome_to_freeswitch"/>
+ <prompt phrase="�� ������ ����� � ����� ����� ������� ������ " filename= "ivr-you_may_exit_by_hanging_up"/>
+ <prompt phrase="��� " filename= "ivr-or"/>
+ <prompt phrase="�� " filename= "ivr-not"/>
+ <prompt phrase="������ " filename= "ivr-call"/>
+ <prompt phrase="�� ������ " filename= "ivr-you_may"/>
+ <prompt phrase="������������ " filename= "ivr-hello"/>
+ <prompt phrase="��������� ���������� ��������� " filename= "ivr-use_telephone_keypad"/>
+ <prompt phrase="����������, �������� ��� ����������, �������� ��������� ����������� " filename= "ivr-spell_name"/>
+ <prompt phrase="������� ������� " filename= "ivr-last_name_first"/>
+ <prompt phrase="������� ��� " filename= "ivr-first_name_first"/>
+ <prompt phrase="������� 1 ��� Q ��� Z. " filename= "ivr-press_one_q_or_z"/>
+ <prompt phrase="����� ������ " filename= "ivr-sales"/>
+ <prompt phrase="����� ������������ �������� " filename= "ivr-customer_service"/>
+ <prompt phrase="����� ����������� ��������� " filename= "ivr-technical_support"/>
+ <prompt phrase="�������� " filename= "ivr-operator"/>
+ </ivr>
+ <misc>
+ <prompt phrase="���� ������ ��������� " filename= "call_secured"/>
+ <prompt phrase="����������� �������� �� ������� ������� " filename= "vm-followed_by"/>
+ <prompt phrase="���� �� ���� ������� " filename= "if_you_are_this_person"/>
+ <prompt phrase="���� �� ������ " filename= "if_you_would_like_to"/>
+ <prompt phrase="������������ ����� ������ " filename= "provide_reference_number"/>
+ <prompt phrase="����������, ������� ���������� ����� �� ������� ������ ��������� ������ " filename= "transfer1"/>
+ <prompt phrase="�������" filename= "transfer2"/>
+ <prompt phrase="�� �������� ����������� " filename= "we_are_trying_to_reach"/>
+ <prompt phrase="��������� ������, ���������� ���������� � �������������� " filename= "error"/>
+ </misc>
+ </ru>
+</language>
+
1
0
Author: buklov
Date: Thu Apr 9 15:20:07 2009
New Revision: 12970
Log:
Russian translate
Added:
freeswitch/trunk/conf/lang/ru/demo/demo-ivr.xml
freeswitch/trunk/conf/lang/ru/demo/demo.xml
freeswitch/trunk/conf/lang/ru/vm/sounds.xml
freeswitch/trunk/conf/lang/ru/vm/tts.xml
Added: freeswitch/trunk/conf/lang/ru/demo/demo-ivr.xml
==============================================================================
--- (empty file)
+++ freeswitch/trunk/conf/lang/ru/demo/demo-ivr.xml Thu Apr 9 15:20:07 2009
@@ -0,0 +1,161 @@
+<?xml version="1.0" encoding="utf-8"?>
+<include><!--This line will be ignored it's here to validate the xml and is optional -->
+
+
+ <macro name="demo_ivr_count">
+ <input pattern="^(\d+)$">
+ <match>
+ <action function="play-file" data="voicemail/vm-you_have.wav"/>
+ <action function="say" data="$1" method="pronounced" type="name_spelled"/>
+ <action function="play-file" data="voicemail/vm-messages.wav"/>
+ </match>
+ </input>
+ </macro>
+
+ <macro name="demo_ivr_main_menu"> <!-- See conf/autoload_config/ivr.conf.xml for an example on how to use this macro in an IVR -->
+ <input pattern="(.*)">
+ <match>
+ <!-- string together several existing sound files to create one long greeting -->
+ <action function="play-file" data="ivr/ivr-welcome_to_freeswitch.wav"/>
+ <action function="execute" data="sleep(250)"/>
+ <action function="play-file" data="ivr/ivr-this_ivr_will_let_you_test_features.wav"/>
+ <action function="execute" data="sleep(250)"/>
+ <action function="play-file" data="ivr/ivr-you_may_exit_by_hanging_up.wav"/>
+ <!-- note that you can do more than just play files, e.g. have pauses and do TTS -->
+ <action function="execute" data="sleep(250)"/>
+ <!-- Menu option 1: Call FreeSWITCH conference-->
+ <action function="play-file" data="ivr/ivr-enter_ext_pound.wav"/>
+ <action function="execute" data="sleep(1500)"/>
+ <action function="play-file" data="ivr/ivr-to_call_the_freeswitch_conference.wav"/>
+ <action function="execute" data="sleep(250)"/>
+ <action function="play-file" data="ivr/ivr-please.wav"/>
+ <action function="play-file" data="voicemail/vm-press.wav"/>
+ <action function="play-file" data="digits/1.wav"/>
+ <action function="execute" data="sleep(250)"/>
+ <!-- Menu option 2: Do FreeSWITCH echo test -->
+ <action function="play-file" data="ivr/ivr-to_do_a_freeswitch_echo_test.wav"/>
+ <action function="execute" data="sleep(250)"/>
+ <action function="play-file" data="ivr/ivr-please.wav"/>
+ <action function="play-file" data="voicemail/vm-press.wav"/>
+ <action function="play-file" data="digits/2.wav"/>
+ <action function="execute" data="sleep(250)"/>
+ <!-- Menu option 3: Listen to Music on Hold -->
+ <action function="play-file" data="ivr/ivr-to_listen_to_moh.wav"/>
+ <action function="execute" data="sleep(250)"/>
+ <action function="play-file" data="ivr/ivr-please.wav"/>
+ <action function="play-file" data="voicemail/vm-press.wav"/>
+ <action function="play-file" data="digits/3.wav"/>
+ <action function="execute" data="sleep(250)"/>
+ <!-- Menu option 4: Hear a sample submenu -->
+ <action function="play-file" data="ivr/ivr-to_hear_sample_submenu.wav"/>
+ <action function="execute" data="sleep(250)"/>
+ <action function="play-file" data="ivr/ivr-please.wav"/>
+ <action function="play-file" data="voicemail/vm-press.wav"/>
+ <action function="play-file" data="digits/4.wav"/>
+ <action function="execute" data="sleep(250)"/>
+ <!-- Menu option 5: Listen to screaming monkeys -->
+ <action function="play-file" data="ivr/ivr-to_hear_screaming_monkeys.wav"/>
+ <action function="execute" data="sleep(250)"/>
+ <action function="play-file" data="ivr/ivr-please.wav"/>
+ <action function="play-file" data="voicemail/vm-press.wav"/>
+ <action function="play-file" data="digits/5.wav"/>
+ <action function="execute" data="sleep(250)"/>
+ <!-- Menu option 9: Repeat these options -->
+ <action function="play-file" data="ivr/ivr-to_repeat_these_options.wav"/>
+ <action function="execute" data="sleep(250)"/>
+ <action function="play-file" data="ivr/ivr-please.wav"/>
+ <action function="play-file" data="voicemail/vm-press.wav"/>
+ <action function="play-file" data="digits/9.wav"/>
+ <action function="execute" data="sleep(2000)"/>
+ </match>
+ </input>
+ </macro>
+
+ <!-- The following macro is the same as demo_ivr_main_menu except it is the "short" version -->
+ <!-- The short version has all the options but not the initial greeting -->
+ <macro name="demo_ivr_main_menu_short">
+ <input pattern="(.*)">
+ <match>
+ <!-- Menu option 1: Call FreeSWITCH conference-->
+ <action function="execute" data="sleep(1000)"/>
+ <action function="play-file" data="ivr/ivr-to_call_the_freeswitch_conference.wav"/>
+ <action function="execute" data="sleep(250)"/>
+ <action function="play-file" data="ivr/ivr-please.wav"/>
+ <action function="play-file" data="voicemail/vm-press.wav"/>
+ <action function="play-file" data="digits/1.wav"/>
+ <action function="execute" data="sleep(250)"/>
+ <!-- Menu option 2: Do FreeSWITCH echo test -->
+ <action function="play-file" data="ivr/ivr-to_do_a_freeswitch_echo_test.wav"/>
+ <action function="execute" data="sleep(250)"/>
+ <action function="play-file" data="ivr/ivr-please.wav"/>
+ <action function="play-file" data="voicemail/vm-press.wav"/>
+ <action function="play-file" data="digits/2.wav"/>
+ <action function="execute" data="sleep(250)"/>
+ <!-- Menu option 3: Listen to Music on Hold -->
+ <action function="play-file" data="ivr/ivr-to_listen_to_moh.wav"/>
+ <action function="execute" data="sleep(250)"/>
+ <action function="play-file" data="ivr/ivr-please.wav"/>
+ <action function="play-file" data="voicemail/vm-press.wav"/>
+ <action function="play-file" data="digits/3.wav"/>
+ <action function="execute" data="sleep(250)"/>
+ <!-- Menu option 4: Hear a sample submenu -->
+ <action function="play-file" data="ivr/ivr-to_hear_sample_submenu.wav"/>
+ <action function="execute" data="sleep(250)"/>
+ <action function="play-file" data="ivr/ivr-please.wav"/>
+ <action function="play-file" data="voicemail/vm-press.wav"/>
+ <action function="play-file" data="digits/4.wav"/>
+ <action function="execute" data="sleep(250)"/>
+ <!-- Menu option 5: Listen to screaming monkeys -->
+ <action function="play-file" data="ivr/ivr-to_hear_screaming_monkeys.wav"/>
+ <action function="execute" data="sleep(250)"/>
+ <action function="play-file" data="ivr/ivr-please.wav"/>
+ <action function="play-file" data="voicemail/vm-press.wav"/>
+ <action function="play-file" data="digits/5.wav"/>
+ <action function="execute" data="sleep(250)"/>
+ <!-- Menu option 9: Repeat these options -->
+ <action function="play-file" data="ivr/ivr-to_repeat_these_options.wav"/>
+ <action function="execute" data="sleep(250)"/>
+ <action function="play-file" data="ivr/ivr-please.wav"/>
+ <action function="play-file" data="voicemail/vm-press.wav"/>
+ <action function="play-file" data="digits/9.wav"/>
+ <action function="execute" data="sleep(2000)"/>
+ </match>
+ </input>
+ </macro>
+
+ <!-- The following macro is the "long" greeting for the demo_ivr_sub_menu -->
+ <macro name="demo_ivr_sub_menu">
+ <input pattern="(.*)">
+ <match>
+ <action function="play-file" data="ivr/ivr-welcome_to_freeswitch.wav"/>
+ <action function="execute" data="sleep(250)"/>
+ <action function="play-file" data="ivr/ivr-sample_submenu.wav"/>
+ <action function="execute" data="sleep(250)"/>
+ <!-- Menu option *: Return to top menu -->
+ <action function="play-file" data="ivr/ivr-to_return_to_previous_menu.wav"/>
+ <action function="execute" data="sleep(250)"/>
+ <action function="play-file" data="ivr/ivr-please.wav"/>
+ <action function="play-file" data="voicemail/vm-press.wav"/>
+ <action function="play-file" data="digits/star.wav"/>
+ <action function="execute" data="sleep(250)"/>
+ </match>
+ </input>
+ </macro>
+
+ <!-- The following macro is the same as demo_ivr_sub_menu except it is the "short" version -->
+ <!-- The short version has all the options but not the initial greeting -->
+ <macro name="demo_ivr_sub_menu_short">
+ <input pattern="(.*)">
+ <match>
+ <!-- Menu option *: Return to top menu -->
+ <action function="play-file" data="ivr/ivr-to_return_to_previous_menu.wav"/>
+ <action function="execute" data="sleep(250)"/>
+ <action function="play-file" data="ivr/ivr-please.wav"/>
+ <action function="play-file" data="voicemail/vm-press.wav"/>
+ <action function="play-file" data="digits/star.wav"/>
+ <action function="execute" data="sleep(250)"/>
+ </match>
+ </input>
+ </macro>
+
+</include><!--This line will be ignored it's here to validate the xml and is optional -->
Added: freeswitch/trunk/conf/lang/ru/demo/demo.xml
==============================================================================
--- (empty file)
+++ freeswitch/trunk/conf/lang/ru/demo/demo.xml Thu Apr 9 15:20:07 2009
@@ -0,0 +1,100 @@
+<?xml version="1.0" encoding="utf-8"?>
+<include><!--This line will be ignored it's here to validate the xml and is optional -->
+
+ <macro name="saymoney">
+ <input pattern="(.*)">
+ <match>
+ <action function="say" data="$1" method="pronounced" type="currency"/>
+ </match>
+ </input>
+ </macro>
+ <macro name="msgcount">
+ <input pattern="(.*)">
+ <match>
+ <action function="execute" data="sleep(1000)"/>
+ <action function="play-file" data="voicemail/vm-you_have.wav"/>
+ <action function="say" data="$1" method="pronounced" type="items"/>
+ <action function="play-file" data="voicemail/vm-messages.wav"/>
+ <!-- or -->
+ <!--<action function="speak-text" data="you have $1 messages"/>-->
+ </match>
+ </input>
+ </macro>
+ <macro name="saydate">
+ <input pattern="(.*)">
+ <match>
+ <action function="say" data="$1" method="pronounced" type="current_date_time"/>
+ </match>
+ </input>
+ </macro>
+ <macro name="saydatetime">
+ <input pattern="(.*)">
+ <match>
+ <action function="say" data="$1" method="pronounced" type="current_date_time"/>
+ </match>
+ </input>
+ </macro>
+ <macro name="timespec">
+ <input pattern="(.*)">
+ <match>
+ <action function="say" data="$1" method="pronounced" type="time_measurement"/>
+ </match>
+ </input>
+ </macro>
+ <macro name="timespec2">
+ <input pattern="(.*)">
+ <match>
+ <action function="say" data="$1" method="pronounced" type="CURRENT_DATE_TIME"/>
+ </match>
+ </input>
+ </macro>
+ <macro name="ip-addr-interated">
+ <input pattern="(.*)">
+ <match>
+ <action function="say" data="$1" method="iterated" type="ip_address"/>
+ </match>
+ </input>
+ </macro>
+ <macro name="ip-addr">
+ <input pattern="(.*)">
+ <match>
+ <action function="say" data="$1" method="pronounced" type="ip_address"/>
+ </match>
+ </input>
+ </macro>
+ <macro name="spell">
+ <input pattern="(.*)">
+ <match>
+ <action function="say" data="$1" method="pronounced" type="name_spelled"/>
+ </match>
+ </input>
+ </macro>
+ <macro name="spell-phonetic">
+ <input pattern="(.*)">
+ <match>
+ <action function="say" data="$1" method="pronounced" type="name_phonetic"/>
+ </match>
+ </input>
+ </macro>
+ <macro name="tts-timeleft">
+ <!-- The parser will visit each <input> tag and execute the actions in <match> or <nomatch> depending on the pattern param -->
+ <!-- If the function "break" is encountered all parsing will cease -->
+ <input pattern="(\d+):(\d+)">
+ <match>
+ <action function="speak-text" data="You have $1 minutes, $2 seconds remaining $strftime(%Y-%m-%d)"/>
+ <action function="break"/>
+ </match>
+ <nomatch>
+ <action function="speak-text" data="That input was invalid."/>
+ </nomatch>
+ </input>
+ <input pattern="(\d+) min (\d+) sec">
+ <match>
+ <action function="speak-text" data="You have $1 minutes, $2 seconds remaining $strftime(%Y-%m-%d)"/>
+ </match>
+ <nomatch>
+ <action function="speak-text" data="That input was invalid."/>
+ </nomatch>
+ </input>
+ </macro>
+</include><!--This line will be ignored it's here to validate the xml and is optional -->
Added: freeswitch/trunk/conf/lang/ru/vm/sounds.xml
==============================================================================
--- (empty file)
+++ freeswitch/trunk/conf/lang/ru/vm/sounds.xml Thu Apr 9 15:20:07 2009
@@ -0,0 +1,346 @@
+<?xml version="1.0" encoding="utf-8"?>
+<include><!--This line will be ignored it's here to validate the xml and is optional -->
+ <macro name="voicemail_enter_id">
+ <input pattern="(.*)">
+ <match>
+ <action function="play-file" data="voicemail/vm-enter_id.wav"/>
+<!-- <action function="say" data="$1" method="pronounced" type="name_spelled"/>-->
+ </match>
+ </input>
+ </macro>
+
+ <macro name="voicemail_enter_pass">
+ <input pattern="(.*)">
+ <match>
+ <action function="play-file" data="voicemail/vm-enter_pass.wav"/>
+<!-- лишнее и так долго <action function="say" data="$1" method="pronounced" type="name_spelled"/>-->
+ </match>
+ </input>
+ </macro>
+
+ <macro name="voicemail_fail_auth">
+ <input pattern="(.*)">
+ <match>
+ <action function="play-file" data="voicemail/vm-fail_auth.wav"/>
+ </match>
+ </input>
+ </macro>
+
+ <macro name="voicemail_hello">
+ <input pattern="(.*)">
+ <match>
+ <action function="play-file" data="voicemail/vm-hello.wav"/>
+ </match>
+ </input>
+ </macro>
+
+ <macro name="voicemail_goodbye">
+ <input pattern="(.*)">
+ <match>
+ <action function="play-file" data="voicemail/vm-goodbye.wav"/>
+ </match>
+ </input>
+ </macro>
+
+ <macro name="voicemail_abort">
+ <input pattern="(.*)">
+ <match>
+ <action function="play-file" data="voicemail/vm-abort.wav"/>
+ </match>
+ </input>
+ </macro>
+
+ <macro name="voicemail_message_count">
+ <input pattern="^(\d+[0,2-9]1|[2-9]1|1):(.*)$"> <!--1, и всё что больше 20-ти 21,31,41 .. -->
+ <match>
+ <action function="play-file" data="voicemail/vm-you_have.wav"/>
+ <action function="say" data="$1" method="pronounced" type="MESSAGES"/>
+ <action function="play-file" data="voicemail/vm-$2.wav"/>
+ <action function="play-file" data="voicemail/vm-message.wav"/>
+ <action function="play-file" data="voicemail/vm-in_folder.wav"/>
+ </match>
+ </input>
+ <!-- от 10 до 19 и ноль --> <!-- от 5до 9 и больше 20-ти 25-29 -->
+ <input pattern="^(1[0-9]|0|\d+[0,2-9][0,5-9]|[2-9][0,5-9]|[0,5-9]):(.*)$">
+ <match>
+ <action function="play-file" data="voicemail/vm-you_have.wav"/>
+ <action function="say" data="$1" method="pronounced" type="MESSAGES"/>
+ <action function="play-file" data="voicemail/vm-$2x.wav"/>
+ <action function="play-file" data="voicemail/vm-messagex.wav"/>
+ <action function="play-file" data="voicemail/vm-in_folder.wav"/>
+ </match>
+ </input>
+ <input pattern="^(\d+[0,2-9][2-4]|[2-9][2-4]|[2-4]):(.*)$">
+ <match>
+ <action function="play-file" data="voicemail/vm-you_have.wav"/>
+ <action function="say" data="$1" method="pronounced" type="MESSAGES"/>
+ <action function="play-file" data="voicemail/vm-$2x.wav"/>
+ <action function="play-file" data="voicemail/vm-messages.wav"/>
+ <action function="play-file" data="voicemail/vm-in_folder.wav"/>
+ </match>
+ </input>
+ </macro>
+
+ <macro name="voicemail_menu">
+ <input pattern="^([0-9#*]):([0-9#*]):([0-9#*]):([0-9#*])$">
+ <match>
+ <action function="play-file" data="voicemail/vm-press.wav"/>
+ <action function="say" data="$1" method="pronounced" type="name_spelled"/>
+ <action function="play-file" data="voicemail/vm-listen_new.wav"/>
+ <action function="play-file" data="voicemail/vm-press.wav"/>
+ <action function="say" data="$2" method="pronounced" type="name_spelled"/>
+ <action function="play-file" data="voicemail/vm-listen_saved.wav"/>
+ <action function="play-file" data="voicemail/vm-press.wav"/>
+ <action function="say" data="$3" method="pronounced" type="name_spelled"/>
+ <action function="play-file" data="voicemail/vm-advanced.wav"/>
+ <action function="play-file" data="voicemail/vm-press.wav"/>
+ <action function="say" data="$4" method="pronounced" type="name_phonetic"/>
+ <action function="play-file" data="voicemail/vm-to_exit.wav"/>
+ </match>
+ </input>
+ </macro>
+
+
+ <macro name="voicemail_config_menu">
+ <input pattern="^([0-9#*]):([0-9#*]):([0-9#*]):([0-9#*]):([0-9#*])$">
+ <match>
+ <action function="play-file" data="voicemail/vm-press.wav"/>
+ <action function="say" data="$1" method="pronounced" type="name_spelled"/>
+ <action function="play-file" data="voicemail/vm-to_record_greeting.wav"/>
+ <action function="play-file" data="voicemail/vm-press.wav"/>
+ <action function="say" data="$2" method="pronounced" type="name_spelled"/>
+ <action function="play-file" data="voicemail/vm-choose_greeting.wav"/>
+ <action function="play-file" data="voicemail/vm-press.wav"/>
+ <action function="say" data="$3" method="pronounced" type="name_spelled"/>
+ <action function="play-file" data="voicemail/vm-record_name2.wav"/>
+ <action function="play-file" data="voicemail/vm-press.wav"/>
+ <action function="say" data="$4" method="pronounced" type="name_spelled"/>
+ <action function="play-file" data="voicemail/vm-change_password.wav"/>
+ <action function="play-file" data="voicemail/vm-press.wav"/>
+ <action function="say" data="$5" method="pronounced" type="name_spelled"/>
+ <action function="play-file" data="voicemail/vm-main_menu.wav"/>
+ </match>
+ </input>
+ </macro>
+
+
+ <macro name="voicemail_record_name">
+ <input pattern="^(.*)$">
+ <match>
+ <action function="play-file" data="voicemail/vm-record_name1.wav"/>
+ </match>
+ </input>
+ </macro>
+
+ <macro name="voicemail_record_file_check">
+ <input pattern="^([0-9#*]):([0-9#*]):([0-9#*])$">
+ <match>
+ <action function="play-file" data="voicemail/vm-press.wav"/>
+ <action function="say" data="$1" method="pronounced" type="name_spelled"/>
+ <action function="play-file" data="voicemail/vm-listen_to_recording.wav"/>
+ <action function="play-file" data="voicemail/vm-press.wav"/>
+ <action function="say" data="$2" method="pronounced" type="name_spelled"/>
+ <action function="play-file" data="voicemail/vm-save_recording.wav"/>
+ <action function="play-file" data="voicemail/vm-press.wav"/>
+ <action function="say" data="$3" method="pronounced" type="name_spelled"/>
+ <action function="play-file" data="voicemail/vm-rerecord.wav"/>
+ </match>
+ </input>
+ </macro>
+
+ <macro name="voicemail_record_urgent_check">
+ <input pattern="^([0-9#*]):([0-9#*])$">
+ <match>
+ <action function="play-file" data="voicemail/vm-mark-urgent.wav"/>
+ <action function="play-file" data="voicemail/vm-press.wav"/>
+ <action function="say" data="$1" method="pronounced" type="name_spelled"/>
+ <action function="play-file" data="voicemail/vm-continue.wav"/>
+ <action function="play-file" data="voicemail/vm-press.wav"/>
+ <action function="say" data="$2" method="pronounced" type="name_spelled"/>
+ </match>
+ </input>
+ </macro>
+
+ <macro name="voicemail_forward_prepend">
+ <input pattern="^([0-9#*]):([0-9#*])$">
+ <match>
+ <action function="play-file" data="voicemail/vm-forward_add_intro.wav"/>
+ <action function="play-file" data="voicemail/vm-press.wav"/>
+ <action function="say" data="$1" method="pronounced" type="name_spelled"/>
+ <action function="play-file" data="voicemail/vm-send_message_now.wav"/>
+ <action function="play-file" data="voicemail/vm-press.wav"/>
+ <action function="say" data="$2" method="pronounced" type="name_spelled"/>
+ </match>
+ </input>
+ </macro>
+
+ <macro name="voicemail_forward_message_enter_extension">
+ <input pattern="^([0-9#*])$">
+ <match>
+ <action function="play-file" data="voicemail/vm-forward_enter_ext.wav"/>
+ <action function="play-file" data="voicemail/vm-followed_by.wav"/>
+ <action function="say" data="$1" method="pronounced" type="name_spelled"/>
+ </match>
+ </input>
+ </macro>
+
+ <macro name="voicemail_invalid_extension">
+ <input pattern="^(.*)$">
+ <match>
+ <action function="play-file" data="voicemail/vm-that_was_an_invalid_ext.wav"/>
+ </match>
+ </input>
+ </macro>
+
+ <macro name="voicemail_listen_file_check">
+ <input pattern="^([0-9#*]):([0-9#*]):([0-9#*]):([0-9#*]):([0-9#*]):([0-9#*])$">
+ <match>
+ <action function="play-file" data="voicemail/vm-listen_to_recording.wav"/>
+ <action function="play-file" data="voicemail/vm-press.wav"/>
+ <action function="say" data="$1" method="pronounced" type="name_spelled"/>
+ <action function="play-file" data="voicemail/vm-save_recording.wav"/>
+ <action function="play-file" data="voicemail/vm-press.wav"/>
+ <action function="say" data="$2" method="pronounced" type="name_spelled"/>
+ <action function="play-file" data="voicemail/vm-delete_recording.wav"/>
+ <action function="play-file" data="voicemail/vm-press.wav"/>
+ <action function="say" data="$3" method="pronounced" type="name_spelled"/>
+ <action function="play-file" data="voicemail/vm-forward_to_email.wav"/>
+ <action function="play-file" data="voicemail/vm-press.wav"/>
+ <action function="say" data="$4" method="pronounced" type="name_spelled"/>
+ <action function="play-file" data="voicemail/vm-return_call.wav"/>
+ <action function="play-file" data="voicemail/vm-press.wav"/>
+ <action function="say" data="$5" method="pronounced" type="name_spelled"/>
+ <action function="play-file" data="voicemail/vm-to_forward.wav"/>
+ <action function="play-file" data="voicemail/vm-press.wav"/>
+ <action function="say" data="$6" method="pronounced" type="name_spelled"/>
+ </match>
+ </input>
+ </macro>
+
+ <macro name="voicemail_choose_greeting">
+ <input pattern="^(.*)$">
+ <match>
+ <action function="play-file" data="voicemail/vm-choose_greeting_choose.wav"/>
+ </match>
+ </input>
+ </macro>
+
+ <macro name="voicemail_choose_greeting_fail">
+ <input pattern="^(.*)$">
+ <match>
+ <action function="play-file" data="voicemail/vm-choose_greeting_fail.wav"/>
+ </match>
+ </input>
+ </macro>
+
+ <macro name="voicemail_record_greeting">
+ <input pattern="^(.*)$">
+ <match>
+ <action function="play-file" data="voicemail/vm-record_greeting.wav"/>
+ </match>
+ </input>
+ </macro>
+
+ <macro name="voicemail_record_message">
+ <input pattern="^(.*)$">
+ <match>
+ <action function="play-file" data="voicemail/vm-record_message.wav"/>
+ </match>
+ </input>
+ </macro>
+
+ <macro name="voicemail_greeting_selected">
+ <input pattern="^(\d+)$">
+ <match>
+ <action function="play-file" data="voicemail/vm-greeting.wav"/>
+ <action function="say" data="$1" method="pronounced" type="items"/>
+ <action function="play-file" data="voicemail/vm-selected.wav"/>
+ </match>
+ </input>
+ </macro>
+
+ <macro name="voicemail_play_greeting">
+ <input pattern="^(.*)$">
+ <match>
+ <action function="play-file" data="voicemail/vm-person.wav"/>
+ <action function="say" data="$1" method="pronounced" type="name_spelled"/>
+ <action function="play-file" data="voicemail/vm-not_available.wav"/>
+ </match>
+ </input>
+ </macro>
+
+ <macro name="voicemail_say_number">
+ <input pattern="^(\d+)$">
+ <match>
+ <action function="say" data="$1" method="pronounced" type="items"/>
+ </match>
+ </input>
+ </macro>
+
+ <macro name="voicemail_say_message_number">
+ <input pattern="^([a-z]+):(\d+)$">
+ <match>
+ <action function="play-file" data="voicemail/vm-$1.wav"/>
+ <action function="play-file" data="voicemail/vm-message_number.wav"/>
+ <action function="say" data="$2" method="pronounced" type="items"/>
+ </match>
+ </input>
+ </macro>
+
+ <macro name="voicemail_say_phone_number">
+ <input pattern="^(.*)$">
+ <match>
+ <action function="say" data="$1" method="pronounced" type="name_spelled"/>
+ </match>
+ </input>
+ </macro>
+
+ <macro name="voicemail_say_name">
+ <input pattern="^(.*)$">
+ <match>
+ <action function="say" data="$1" method="pronounced" type="name_spelled"/>
+ </match>
+ </input>
+ </macro>
+ <!-- Note: Update this to marked-urgent,emailed and saved once new sound files are recorded -->
+ <macro name="voicemail_ack">
+ <input pattern="^(too-small)$">
+ <match>
+ <action function="play-file" data="voicemail/vm-too-small.wav"/>
+ </match>
+ </input>
+ <input pattern="^(deleted)$">
+ <match>
+ <action function="play-file" data="voicemail/vm-message.wav"/>
+ <action function="play-file" data="voicemail/vm-$1.wav"/>
+ </match>
+ </input>
+ <input pattern="^(saved)$">
+ <match>
+ <action function="play-file" data="voicemail/vm-message.wav"/>
+ <action function="play-file" data="voicemail/vm-$1.wav"/>
+ </match>
+ </input>
+ <input pattern="^(emailed)$">
+ <match>
+ <action function="play-file" data="voicemail/vm-message.wav"/>
+ <action function="play-file" data="voicemail/vm-$1.wav"/>
+ </match>
+ </input>
+ <input pattern="^(marked-urgent)$">
+ <match>
+ <action function="play-file" data="voicemail/vm-message.wav"/>
+ <action function="play-file" data="voicemail/vm-$1.wav"/>
+ </match>
+ </input>
+ </macro>
+
+ <macro name="voicemail_say_date">
+ <input pattern="^(.*)$">
+ <match>
+ <action function="say" data="$1" method="pronounced" type="current_date_time"/>
+ </match>
+ </input>
+ </macro>
+
+</include><!--This line will be ignored it's here to validate the xml and is optional -->
Added: freeswitch/trunk/conf/lang/ru/vm/tts.xml
==============================================================================
--- (empty file)
+++ freeswitch/trunk/conf/lang/ru/vm/tts.xml Thu Apr 9 15:20:07 2009
@@ -0,0 +1,239 @@
+<include><!--This line will be ignored it's here to validate the xml and is optional -->
+ <macro name="voicemail_enter_id">
+ <input pattern="(.*)">
+ <match>
+ <action function="speak-text" data="please enter your i d, followed by $1."/>
+ </match>
+ </input>
+ </macro>
+
+ <macro name="voicemail_enter_pass">
+ <input pattern="(.*)">
+ <match>
+ <action function="speak-text" data="please enter your password, followed by $1."/>
+ </match>
+ </input>
+ </macro>
+
+ <macro name="voicemail_fail_auth">
+ <input pattern="(.*)">
+ <match>
+ <action function="speak-text" data="login incorrect."/>
+ </match>
+ </input>
+ </macro>
+
+ <macro name="voicemail_hello">
+ <input pattern="(.*)">
+ <match>
+ <action function="speak-text" data="welcome to your voicemail."/>
+ </match>
+ </input>
+ </macro>
+
+ <macro name="voicemail_goodbye">
+ <input pattern="(.*)">
+ <match>
+ <action function="speak-text" data="goodbye."/>
+ </match>
+ </input>
+ </macro>
+
+ <macro name="voicemail_abort">
+ <input pattern="(.*)">
+ <match>
+ <action function="speak-text" data="too many failed attempts."/>
+ </match>
+ </input>
+ </macro>
+
+ <macro name="voicemail_message_count">
+ <input pattern="^1:(.*)$" break_on_match="true">
+ <match>
+ <action function="speak-text" data="you have 1 $1 message in folder ${voicemail_current_folder}."/>
+ </match>
+ </input>
+ <input pattern="^(\d+):(.*)$">
+ <match>
+ <action function="speak-text" data="you have $1 $2 messages in folder ${voicemail_current_folder}."/>
+ </match>
+ </input>
+ </macro>
+
+ <macro name="voicemail_menu">
+ <input pattern="^([0-9#*]):([0-9#*]):([0-9#*]):([0-9#*])$">
+ <match>
+ <action function="speak-text"
+ data="To listen to new messages, press $1, To listen to saved messages, press $2, For advanced options, press $3, to exit, press $4."/>
+ </match>
+ </input>
+ </macro>
+
+
+ <macro name="voicemail_config_menu">
+ <input pattern="^([0-9#*]):([0-9#*]):([0-9#*]):([0-9#*]):([0-9#*])$">
+ <match>
+ <action function="speak-text"
+ data="To record a greeting, press $1, To choose a greeting, press $2, To record your name, press $3, to change your password, press $5, to return to the main menu, press $5."/>
+ </match>
+ </input>
+ </macro>
+
+
+ <macro name="voicemail_record_name">
+ <input pattern="^(.*)$">
+ <match>
+ <action function="speak-text" data="at the tone, please record your name, press any key or stop talking to end the recording."/>
+
+ </match>
+ </input>
+ </macro>
+
+ <macro name="voicemail_record_file_check">
+ <input pattern="^([0-9#*]):([0-9#*]):([0-9#*])$">
+ <match>
+ <action function="speak-text"
+ data="To listen to the recording, press $1, To save the recording, press $2, To re record, press $3."/>
+ </match>
+ </input>
+ </macro>
+
+ <macro name="voicemail_record_urgent_check">
+ <input pattern="^([0-9#*]):([0-9#*])$">
+ <match>
+ <action function="speak-text"
+ data="To mark this message urgent, press $1, To continue, press $2."/>
+ </match>
+ </input>
+ </macro>
+
+ <macro name="voicemail_invalid_extension">
+ <input pattern="^([0-9#*])$">
+ <match>
+ <action function="speak-text" data="$1 is not a valid extension."/>
+ </match>
+ </input>
+ </macro>
+
+ <macro name="voicemail_forward_message_enter_extension">
+ <input pattern="^([0-9#*])$">
+ <match>
+ <action function="speak-text" data="enter the extension you wish to forward to, then press $1"/>
+ </match>
+ </input>
+ </macro>
+
+ <macro name="voicemail_forward_prepend">
+ <input pattern="^([0-9#*])$">
+ <match>
+ <action function="speak-text" data="To record an announcement, press $1."/>
+ </match>
+ </input>
+ </macro>
+
+ <macro name="voicemail_listen_file_check">
+ <input pattern="^([0-9#*]):([0-9#*]):([0-9#*]):([0-9#*]):([0-9#*]):([0-9#*])$">
+ <match>
+ <action function="speak-text"
+ data="To listen to the recording again, press $1, To save the recording, press $2, To delete the recording, press $3, to forward the recording to your email, press $4, to call the caller now, press $5, To forward this message to another extension, press $6."/>
+ </match>
+ </input>
+ </macro>
+
+ <macro name="voicemail_choose_greeting">
+ <input pattern="^(.*)$">
+ <match>
+ <action function="speak-text" data="choose a greeting between 1 and 3."/>
+ </match>
+ </input>
+ </macro>
+
+ <macro name="voicemail_choose_greeting_fail">
+ <input pattern="^(.*)$">
+ <match>
+ <action function="speak-text" data="invalid value."/>
+ </match>
+ </input>
+ </macro>
+
+ <macro name="voicemail_record_greeting">
+ <input pattern="^(.*)$">
+ <match>
+ <action function="speak-text" data="record your greeting at the tone, press any key or stop talking to end the recording."/>
+ </match>
+ </input>
+ </macro>
+
+ <macro name="voicemail_record_message">
+ <input pattern="^(.*)$">
+ <match>
+ <action function="speak-text" data="record your message at the tone, press any key or stop talking to end the recording."/>
+ </match>
+ </input>
+ </macro>
+
+ <macro name="voicemail_greeting_selected">
+ <input pattern="^(.*)$">
+ <match>
+ <action function="speak-text" data="greeting $1 selected."/>
+ </match>
+ </input>
+ </macro>
+
+ <macro name="voicemail_play_greeting">
+ <input pattern="^(.*)$">
+ <match>
+ <action function="speak-text" data="$1 is not available."/>
+ </match>
+ </input>
+ </macro>
+
+ <macro name="voicemail_say_number">
+ <input pattern="^(.*)$">
+ <match>
+ <action function="speak-text" data="$1"/>
+ </match>
+ </input>
+ </macro>
+
+ <macro name="voicemail_say_message_number">
+ <input pattern="^([a-z]+):(.*)$">
+ <match>
+ <action function="speak-text" data="$1 message number $2."/>
+ </match>
+ </input>
+ </macro>
+
+ <macro name="voicemail_say_phone_number">
+ <input pattern="^(.*)$">
+ <match>
+ <action function="speak-text" data="$1."/>
+ </match>
+ </input>
+ </macro>
+
+ <macro name="voicemail_say_name">
+ <input pattern="^(.*)$">
+ <match>
+ <action function="speak-text" data="$1."/>
+ </match>
+ </input>
+ </macro>
+
+ <macro name="voicemail_ack">
+ <input pattern="^(.*)$">
+ <match>
+ <action function="speak-text" data="message $1"/>
+ </match>
+ </input>
+ </macro>
+
+ <macro name="voicemail_say_date">
+ <input pattern="^(.*)$">
+ <match>
+ <action function="speak-text" data="${strftime($1|%A, %B %d %Y, %I:%M %p)}"/>
+ </match>
+ </input>
+ </macro>
+
+</include><!--This line will be ignored it's here to validate the xml and is optional -->
1
0
Author: buklov
Date: Thu Apr 9 15:18:55 2009
New Revision: 12969
Log:
Russian translate
Added:
freeswitch/trunk/conf/lang/ru/demo/
freeswitch/trunk/conf/lang/ru/vm/
1
0
Author: buklov
Date: Thu Apr 9 15:15:43 2009
New Revision: 12968
Log:
Russian translate
Added:
freeswitch/trunk/conf/lang/ru/ru.xml
Added: freeswitch/trunk/conf/lang/ru/ru.xml
==============================================================================
--- (empty file)
+++ freeswitch/trunk/conf/lang/ru/ru.xml Thu Apr 9 15:15:43 2009
@@ -0,0 +1,8 @@
+<?xml version="1.0" encoding="utf-8"?>
+<include>
+ <language name="ru" sound-path="$${base_dir}/sounds/ru/Nataly" tts-engine="cepstral" tts-voice="callie">
+ <X-PRE-PROCESS cmd="include" data="demo/*.xml"/> <!-- Note: this now grabs whole subdir, previously grabbed only demo.xml -->
+ <!--voicemail_en_tts is purely implemented with tts, we have the files based one that is the default. -->
+ <X-PRE-PROCESS cmd="include" data="vm/sounds.xml"/> <!-- vm/tts.xml if you want to use tts and have cepstral -->
+ </language>
+</include>
1
0
Author: brian
Date: Thu Apr 9 15:07:37 2009
New Revision: 12967
Log:
mkdir
Added:
freeswitch/trunk/conf/lang/ru/
1
0
Author: buklov
Date: Thu Apr 9 14:56:08 2009
New Revision: 12966
Log:
first release
Added:
freeswitch/trunk/src/mod/say/mod_say_ru/mod_say_ru.c
Added: freeswitch/trunk/src/mod/say/mod_say_ru/mod_say_ru.c
==============================================================================
--- (empty file)
+++ freeswitch/trunk/src/mod/say/mod_say_ru/mod_say_ru.c Thu Apr 9 14:56:08 2009
@@ -0,0 +1,1509 @@
+/*
+ * Copyright (c) 2007, Anthony Minessale II
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ *
+ * * Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ *
+ * * Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ *
+ * * Neither the name of the original author; nor the names of any contributors
+ * may be used to endorse or promote products derived from this software
+ * without specific prior written permission.
+ *
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+ * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+ * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+ * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER
+ * OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
+ * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
+ * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
+ * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
+ * LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
+ * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ *
+ * The Initial Developer of the Original Code is
+ * Anthony Minessale II <anthmct(a)yahoo.com>
+ * Portions created by the Initial Developer are Copyright (C)
+ * the Initial Developer. All Rights Reserved.
+ *
+ * Contributor(s):
+ *
+ * Anthony Minessale II <anthmct(a)yahoo.com>
+ * Michael B. Murdock <mike(a)mmurdock.org>
+ * Oleg Dolya <oleg.dolya(a)gmail.com>
+ * Boris Buklov <buklov(a)mail.ru>
+ *
+ * mod_say_ru.c -- Say for Russian
+ *
+ */
+
+#include <switch.h>
+#include <math.h>
+#include <ctype.h>
+
+typedef enum {
+ male, //мужского пола
+ female, //женского
+ it //оно
+} sex_t;
+
+
+
+typedef enum {
+ how_much, //сколько с полом
+ when, //какого - когда -- без пола
+ what_ //какая/какой/какое с полом
+} question_t; //вопрос
+
+
+
+SWITCH_MODULE_LOAD_FUNCTION(mod_say_ru_load);
+SWITCH_MODULE_DEFINITION(mod_say_ru, mod_say_ru_load, NULL, NULL);
+
+#define say_num(num, t) { \
+ char tmp[80];\
+ switch_status_t tstatus;\
+ switch_snprintf(tmp, sizeof(tmp), "%u", (unsigned)num); \
+ if ((tstatus = ru_say_general_count(session, tmp, SST_ITEMS, t, args)) != SWITCH_STATUS_SUCCESS) {\
+ return tstatus;\
+ }}\
+
+#define say_file(...) {\
+ char tmp[80];\
+ switch_status_t tstatus;\
+ switch_snprintf(tmp, sizeof(tmp), __VA_ARGS__);\
+ if ((tstatus = switch_ivr_play_file(session, NULL, tmp, args)) != SWITCH_STATUS_SUCCESS){ \
+ return tstatus;\
+ }\
+ if (!switch_channel_ready(switch_core_session_get_channel(session))) {\
+ return SWITCH_STATUS_FALSE;\
+ }}\
+
+
+static switch_status_t ru_spell(switch_core_session_t *session, char *tosay, switch_say_type_t type, switch_say_method_t method, switch_input_args_t *args)
+{
+ char *p;
+
+ for (p = tosay; p && *p; p++) {
+ int a = tolower((int) *p);
+ if (a >= 48 && a <= 57) {
+ say_file("digits/%d.wav", a - 48);
+ } else {
+ if (type == SST_NAME_SPELLED) {
+ say_file("ascii/%d.wav", a);
+ } else if (type == SST_NAME_PHONETIC) {
+ say_file("phonetic-ascii/%d.wav", a);
+ }
+ }
+ }
+
+ return SWITCH_STATUS_SUCCESS;
+}
+
+//воспроизводить по 3 цифры
+static switch_status_t play_group( sex_t sex,question_t question, int a, int b, int c,
+ char *what,int last, switch_core_session_t *session, switch_input_args_t *args)
+{
+ switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_INFO, "play group %d %d %d sex=%d q=%d last=%d\n", a,b,c,sex,question,last);
+ if (a) {
+ if ((b==0)||(c==0)) { // если b и с равны 0 то сказать шестьсот, сестисотый, шестисотая
+ switch (question) {
+//------------------------------------------------------
+ case how_much: //сколько когда дальше нету цифр например 100 200...
+ switch (sex) { //пол
+ case male: //мужчина
+ say_file("digits/%d00.wav", a); //сто
+ if (what=="thousand") {
+ say_file("digits/thousands.wav");//тысяч
+ }
+ else if (what=="million") {
+ say_file("digits/millions.wav");//миллионов
+ }
+ //-------------
+ break;
+
+ case female: //женщина
+ say_file("digits/%d00.wav", a);//сто
+ if (what=="thousand") {
+ say_file("digits/thousands.wav");//тысяч
+ }
+ else if (what=="million") {
+ say_file("digits/millions.wav");//миллионов
+ }
+ break;
+ //-------------
+ case it: //оно
+ say_file("digits/%d00.wav", a);//сто
+ if (what=="thousand") {
+ say_file("digits/thousands.wav"); //тысяч
+ }
+ else if (what=="million") {
+ say_file("digits/millions.wav");//миллионов
+ }
+ break;
+ //-------------
+ }
+ break;
+//------------------------------------------------------
+ case what_: //какой/я/ое
+ switch (sex) { //пол
+ case male: //мужчина
+ if (what=="thousand") {
+ if (last==0) {
+ say_file("digits/h-%d00xx.wav", a);//двухсот
+ say_file("digits/h-millionx.wav");//тысячный
+ }
+ else {
+ say_file("digits/%d00.wav", a);//двести
+ say_file("digits/thousands.wav");//тысяч
+ }
+ }
+ else if (what=="million") {
+ if (last==0) {
+ say_file("digits/h-%d00xx.wav", a);//двухсот
+ say_file("digits/h-millionm.wav");//Миллионный
+ }
+ else {
+ say_file("digits/%d00.wav", a);//двести
+ say_file("digits/millions.wav");//миллионов
+ }
+ }
+ else {
+ say_file("digits/h-%d00m.wav", a);//сотый двухсотый
+ }
+ break;
+
+ case female: //женщина
+ if (what=="thousand") {
+ if (last==0) {
+ say_file("digits/h-%d00xx.wav", a);//двухсот
+ say_file("digits/h-millionf.wav");//тысячная
+ }
+ else {
+ say_file("digits/%d00.wav", a);//двести
+ say_file("digits/thousands.wav");//тысяч
+ }
+ }
+ else if (what=="million") {
+ if (last==0) {
+ say_file("digits/h-%d00xx.wav", a);//двухсот
+ say_file("digits/h-millionf.wav");//Миллионная
+ }
+ else {
+ say_file("digits/%d00.wav", a);//двести
+ say_file("digits/millions.wav");//миллионов
+ }
+ }
+ else {
+ say_file("digits/h-%d00f.wav", a);//сотая двухсотая
+ }
+ break;
+ case it: //оно
+ if (what=="thousand") {
+ if (last==0) {
+ say_file("digits/h-%d00xx.wav", a);//двухсот
+ say_file("digits/h-millionn.wav");//тысячное
+ }
+ else {
+ say_file("digits/%d00.wav", a);//двести
+ say_file("digits/thousands.wav");//тысяч
+ }
+ }
+ else if (what=="million") {
+ if (last==0) {
+ say_file("digits/h-%d00xx.wav", a);//двухсот
+ say_file("digits/h-millionn.wav");//Миллионное
+ }
+ else {
+ say_file("digits/%d00.wav", a);//двести
+ say_file("digits/millions.wav");//миллионов
+ }
+ }
+ else {
+ say_file("digits/h-%d00n.wav", a);//сотого
+ }
+ break;
+ }
+ break;
+//-------------------------------------------------------
+ case when: //какого - когда без пола
+ if (what=="thousand") {
+ if (last==0) {
+ say_file("digits/h-%d00xx.wav", a);//двухсот
+ say_file("digits/h-millionx.wav");//тысячного
+ }
+ else {
+ say_file("digits/%d00.wav", a);//двести
+ say_file("digits/thousands.wav");//тысяч
+ }
+ }
+ else if (what=="million") {
+ if (last==0) {
+ say_file("digits/h-%d00xx.wav", a);//двухсот
+ say_file("digits/h-millionx.wav");//Миллионного
+ }
+ else {
+ say_file("digits/%d00.wav", a);//двести
+ say_file("digits/millions.wav");//миллионов
+ }
+ }
+ else {
+ say_file("digits/h-%d00x.wav", a);//сотого
+ }
+ break;
+ } //end switch (question)
+ }//end if ((b==0)||(c==0))
+ else // если есть ещё цифры
+ {
+ switch (question) {
+ case how_much:
+ say_file("digits/%d00.wav", a); //просто сто и тд
+ break;
+ case what_:
+ if (last==0) {
+ say_file("digits/h-%d00xx.wav", a);
+ }
+ else {
+ say_file("digits/%d00.wav", a); //сто
+ }
+ break;
+ case when:
+ if (last==0) {
+ say_file("digits/h-%d00xx.wav", a);
+ }
+ else {
+ say_file("digits/%d00.wav", a); //сто
+ }
+ break;
+ }
+ }
+ }//end if (a)
+ if (b) // если b больше 0
+ {
+ if (b > 1) { //если цифры больше 19
+ if (c==0) { // если c == нолю 20-30-40-50
+ switch (question) {
+//------------------------------------------------------
+ case how_much: //сколько когда дальше нету цифр например 10 20...
+ switch (sex) { //пол
+ case male: //мужчина
+ say_file("digits/%d0.wav", b); //двадцать
+ if (what=="thousand") {
+ say_file("digits/thousands.wav", b); //тысяч
+ }
+ else if (what=="millon") {
+ say_file("digits/millions.wav", b); //миллионов
+ }
+ //-------------
+ break;
+
+ case female: //женщина
+ say_file("digits/%d0.wav", b);//двадцать
+ if (what=="thousand") {
+ say_file("digits/thousands.wav", b); //тысяч
+ }
+ else if (what=="millon") {
+ say_file("digits/millions.wav", b); //миллионов
+ }
+ break;
+ //-------------
+ case it: //оно
+ say_file("digits/%d0.wav", b);// двадцать
+ if (what=="thousand") {
+ say_file("digits/thousands.wav", b); //тысяч
+ }
+ else if (what=="millon") {
+ say_file("digits/millions.wav", b); //миллионов
+ }
+ break;
+ //-------------
+ }
+ break;
+//------------------------------------------------------
+ case what_: //какой/я/ое >19 и c==0 20-30-40
+ switch (sex) { //пол
+ case male: //мужчина
+ if (what=="thousand") {
+ if (last==0) {
+ say_file("digits/h-%d0xx.wav", b);//двадцати
+ say_file("digits/h-thousandm.wav", b); //тысячный
+ }
+ else {
+ say_file("digits/%d0.wav", b);//двадцать
+ say_file("digits/h-thousand.wav", b); //тысяч
+ }
+ }
+ else if (what=="million") {
+ if (last==0) {
+ say_file("digits/h-%d0xx.wav", b);//двадцати
+ say_file("digits/h-millionm.wav", b); //миллионный
+ }
+ else {
+ say_file("digits/%d0.wav", b);//двадцать
+ say_file("digits/h-thousand.wav", b); //миллионов
+ }
+ }
+ else { //без миллионов и тысяч
+ if (last==0) {
+ say_file("digits/h-%d0m.wav", b);//двадцатый
+ }
+ else {
+ say_file("digits/%d0.wav", b);//двадцать
+ }
+ }
+ break;
+ case female: //женщина
+ if (what=="thousand") {
+ if (last==0) {
+ say_file("digits/h-%d0xx.wav", b);//двадцати
+ say_file("digits/h-thousandf.wav", b); //тысячная
+ }
+ else {
+ say_file("digits/%d0.wav", b);//двадцать
+ say_file("digits/h-thousand.wav", b); //тысяч
+ }
+ }
+ else if (what=="million") {
+ if (last==0) {
+ say_file("digits/h-%d0xx.wav", b);//двадцати
+ say_file("digits/h-millionf.wav", b); //миллионная
+ }
+ else {
+ say_file("digits/%d0.wav", b);//двадцать
+ say_file("digits/h-thousand.wav", b); //миллионов
+ }
+ }
+ else { //без миллионов и тысяч
+ if (last==0) {
+ say_file("digits/h-%d0f.wav", b);//двадцатая
+ }
+ else {
+ say_file("digits/%d0.wav", b);//двадцать
+ }
+ }
+ break;
+ case it: //оно
+ if (what=="thousand") {
+ if (last==0) {
+ say_file("digits/h-%d0xx.wav", b);//двадцати
+ say_file("digits/h-thousandn.wav", b); //тысячное
+ }
+ else {
+ say_file("digits/%d0.wav", b);//двадцать
+ say_file("digits/h-thousand.wav", b); //тысяч
+ }
+ }
+ else if (what=="million") {
+ if (last==0) {
+ say_file("digits/h-%d0xx.wav", b);//двадцати
+ say_file("digits/h-millionn.wav", b); //миллионное
+ }
+ else {
+ say_file("digits/%d0.wav", b);//двадцать
+ say_file("digits/h-thousand.wav", b); //миллионов
+ }
+ }
+ else { //без миллионов и тысяч
+ if (last==0) {
+ say_file("digits/h-%d0n.wav", b);//двадцатое
+ }
+ else {
+ say_file("digits/%d0.wav", b);//двадцать
+ }
+ }
+ break;
+ }
+ break;
+//-------------------------------------------------------
+ case when: //какого - когда без пола
+ if (what=="thousand") {
+ if (last==0) {
+ say_file("digits/h-%d0xx.wav", b);//двадцати
+ say_file("digits/h-thousandx.wav", b); //тысячного
+ }
+ else {
+ say_file("digits/%d0.wav", b);//двадцать
+ say_file("digits/h-thousand.wav", b); //тысяч
+ }
+ }
+ else if (what=="million") {
+ if (last==0) {
+ say_file("digits/h-%d0xx.wav", b);//двадцати
+ say_file("digits/h-millionx.wav", b); //миллионного
+ }
+ else {
+ say_file("digits/%d0.wav", b);//двадцать
+ say_file("digits/h-thousand.wav", b); //миллионов
+ }
+ }
+ else { //без миллионов и тысяч
+ if (last==0) {
+ say_file("digits/h-%d0x.wav", b);//двадцатого
+ }
+ else {
+ say_file("digits/%d0.wav", b);//двадцать
+ }
+ }
+ break;
+ }
+ }//конец если c == нолю
+ else
+ {
+ say_file("digits/%d0.wav", b); // иначе просто двадцать .. и тд
+ }
+ }//конец если больше 19
+ else { //если цифры меньше 20
+ switch (question) {
+//------------------------------------------------------
+ case how_much: //сколько когда от 10 до 19
+ switch (sex) { //пол
+ case male: //мужчина
+ say_file("digits/%d%d.wav",b ,c); //девятнадцать
+ if (what=="thousand") {
+ say_file("digits/thousands.wav"); //тысяч
+ }
+ else if (what=="million") {
+ say_file("digits/millions.wav"); //миллионов
+ }
+ //-------------
+ break;
+ case female: //женщина
+ say_file("digits/%d%d.wav",b ,c);//девятнадцать
+ if (what=="thousand") {
+ say_file("digits/thousands.wav"); //тысяч
+ }
+ else if (what=="million") {
+ say_file("digits/millions.wav"); //миллионов
+ }
+ break;
+ //-------------
+ case it: //оно
+ say_file("digits/%d%d.wav",b ,c);// девятнадцать
+ if (what=="thousand") {
+ say_file("digits/thousands.wav"); //тысяч
+ }
+ else if (what=="million") {
+ say_file("digits/millions.wav"); //миллионов
+ }
+ break;
+ //-------------
+ }
+ break;
+//------------------------------------------------------
+ case what_: //какой/я/ое
+ switch (sex) { //пол
+ case male: //женщина
+ if (what=="thousand") {
+ if (last==0) {
+ say_file("digits/h-%d%dxx.wav", b,c);//десяти, пятнадцати ..
+ say_file("digits/h-thousandm.wav"); //тысячный
+ }
+ else {
+ say_file("digits/%d%d.wav", b,c);//девятнацать
+ say_file("digits/h-thousand.wav"); //тысяч
+ }
+ }
+ else if (what=="million") {
+ if (last==0) {
+ say_file("digits/h-%d%dxx.wav", b,c);//десяти, пятнадцати ..
+ say_file("digits/h-millionm.wav"); //миллионный
+ }
+ else {
+ say_file("digits/%d%d.wav", b,c);//девятнадцать
+ say_file("digits/h-thousand.wav"); //миллионов
+ }
+ }
+ else { //без миллионов и тысяч
+ if (last==0) {
+ say_file("digits/h-%d%dm.wav", b,c);//девятнадцатый
+ }
+ else {
+ say_file("digits/%d%d.wav");//девятнадцать
+ }
+ }
+ case female: //женщина
+ if (what=="thousand") {
+ if (last==0) {
+ say_file("digits/h-%d%dxx.wav", b,c);//десяти, пятнадцати ..
+ say_file("digits/h-thousandf.wav"); //тысячная
+ }
+ else {
+ say_file("digits/%d%d.wav", b,c);//девятнацать
+ say_file("digits/h-thousand.wav"); //тысяч
+ }
+ }
+ else if (what=="million") {
+ if (last==0) {
+ say_file("digits/h-%d%dxx.wav", b,c);//десяти, пятнадцати ..
+ say_file("digits/h-millionf.wav"); //миллионная
+ }
+ else {
+ say_file("digits/%d%d.wav", b,c);//девятнадцать
+ say_file("digits/h-thousand.wav"); //миллионов
+ }
+ }
+ else { //без миллионов и тысяч
+ if (last==0) {
+ say_file("digits/h-%d%df.wav", b,c);//девятнадцатая
+ }
+ else {
+ say_file("digits/%d%d.wav");//девятнадцать
+ }
+ }
+ break;
+ case it: //оно
+ if (what=="thousand") {
+ if (last==0) {
+ say_file("digits/h-%d%dxx.wav", b,c);//десяти, пятнадцати ..
+ say_file("digits/h-thousandn.wav"); //тысячное
+ }
+ else {
+ say_file("digits/%d%d.wav", b,c);//девятнацать
+ say_file("digits/h-thousand.wav"); //тысяч
+ }
+ }
+ else if (what=="million") {
+ if (last==0) {
+ say_file("digits/h-%d%dxx.wav", b,c);//десяти, пятнадцати ..
+ say_file("digits/h-millionn.wav"); //миллионное
+ }
+ else {
+ say_file("digits/%d%d.wav", b,c);//девятнадцать
+ say_file("digits/h-thousand.wav"); //миллионов
+ }
+ }
+ else { //без миллионов и тысяч
+ if (last==0) {
+ say_file("digits/h-%d%dn.wav", b,c);//девятнадцатое
+ }
+ else {
+ say_file("digits/%d%d.wav");//девятнадцать
+ }
+ }
+ break;
+ }
+ break;
+//-------------------------------------------------------
+ case when: //какого - когда без пола
+ if (what=="thousand") {
+ if (last==0) {
+ say_file("digits/h-%d%dxx.wav", b,c);//десяти, пятнадцати ..
+ say_file("digits/h-thousandx.wav"); //тысячного
+ }
+ else {
+ say_file("digits/%d%d.wav", b,c);//девятнацать
+ say_file("digits/h-thousand.wav"); //тысяч
+ }
+ }
+ else if (what=="million") {
+ if (last==0) {
+ say_file("digits/h-%d%dxx.wav", b,c);//десяти, пятнадцати ..
+ say_file("digits/h-millionx.wav"); //миллионного
+ }
+ else {
+ say_file("digits/%d%d.wav", b,c);//девятнадцать
+ say_file("digits/h-thousand.wav"); //миллионов
+ }
+ }
+ else { //без миллионов и тысяч
+ if (last==0) {
+ say_file("digits/h-%d%dx.wav", b,c);//девятнадцатого
+ }
+ else {
+ say_file("digits/%d%d.wav");//девятнадцать
+ }
+ }
+
+ break;
+ }//конец если c == нолю
+ c=0; //что бы не проговаривать c
+ }// конец //если цифры меньше 20
+ }//конец if (b)
+
+ switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_INFO, "play group c \n");
+
+
+
+ if ((c)||(what=="zero")) {// последняя цифра (самая сложная) или проговорить ноль , для случает когда первые цифры нули
+ if (c>2||c==0) {//0 и 3-9
+ switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_INFO, "play group c 1\n");
+
+ switch (question)
+ {
+//------------------------------------------------------
+ case how_much: //сколько 3-9
+ switch (sex)
+ { //пол
+ case male: //мужчина
+ if (what=="thousand") { //тысяч
+ if ((c>2)&&(c<5)) {
+ say_file("digits/%d.wav", c);// три - четыре
+ say_file("digits/thousands-i.wav"); //тысячи
+ }
+ else{
+ say_file("digits/%d.wav", c);// пять .. девять
+ say_file("digits/thousands.wav"); //тысяч
+ }
+ }
+ else if (what=="million") { //миллионов
+ if ((c>2)&&(c<5)) {
+ say_file("digits/%d.wav", c);// три четыре
+ say_file("digits/million-a.wav"); //миллиона
+ }
+ else{
+ say_file("digits/%d.wav", c);// пять .. девять
+ say_file("digits/millions.wav"); //миллионов
+ }
+ }
+ else {
+ say_file("digits/%d.wav", c);// три девять ноль
+ }
+ break;
+
+ case female: //женщина
+ if (what=="thousand") { //тысяч
+ if ((c>2)&&(c<5)) {
+ say_file("digits/%d.wav", c);// три - четыре
+ say_file("digits/thousands-i.wav"); //тысячи
+ }
+ else{
+ say_file("digits/%d.wav", c);// пять .. девять
+ say_file("digits/thousands.wav"); //тысяч
+ }
+ }
+ else if (what=="million") { //миллионов
+ if ((c>2)&&(c<5)) {
+ say_file("digits/%d.wav", c);// три четыре
+ say_file("digits/million-a.wav"); //миллиона
+ }
+ else{
+ say_file("digits/%d.wav", c);// пять .. девять
+ say_file("digits/millions.wav"); //миллионов
+ }
+ }
+ else {
+ say_file("digits/%d.wav", c);// три девять ноль
+ }
+ break;
+
+ //-------------
+ case it: //оно
+ if (what=="thousand") { //тысяч
+ if ((c>2)&&(c<5)) {
+ say_file("digits/%d.wav", c);// три - четыре
+ say_file("digits/thousands-i.wav"); //тысячи
+ }
+ else{
+ say_file("digits/%d.wav", c);// пять .. девять
+ say_file("digits/thousands.wav"); //тысяч
+ }
+ }
+ else if (what=="million") { //миллионов
+ if ((c>2)&&(c<5)) {
+ say_file("digits/%d.wav", c);// три четыре
+ say_file("digits/million-a.wav"); //миллиона
+ }
+ else{
+ say_file("digits/%d.wav", c);// пять .. девять
+ say_file("digits/millions.wav"); //миллионов
+ }
+ }
+ else {
+ say_file("digits/%d.wav", c);// три девять ноль
+ }
+ break;
+ }
+ break;
+//------------------------------------------------------
+ case what_: //какой/я/ое
+ switch (sex)
+ { //пол
+ case male: //мужчина
+ if (what=="thousand") {
+ if (last==0) {// если дальше нету цифр значит говорить двух, 3-х, 4-х ...
+ say_file("digits/h-%dxx.wav", c);//одна, двух, трёх
+ say_file("digits/h-thousandm.wav"); //тысячный
+ }
+ else { //если есть дальше цифры меньше 1000
+ say_file("digits/%d.wav", c);//три четыре ..
+ say_file("digits/thousand.wav"); //тысячи
+ }
+ }
+ else if (what=="million") {
+ if (last==0) {// если дальше нету цифр значит говорить двух, 3-х, 4-х ...
+ say_file("digits/h-%dxx.wav", c);//одна, двух, трёх
+ say_file("digits/h-millionm.wav"); //миллионный
+ }
+ else { //если есть дальше цифры меньше 1000
+ say_file("digits/%d.wav", c);//три четыре ..
+ say_file("digits/thousand.wav"); //миллиона
+ }
+ }//просто цифры без тысяч
+ else{
+ say_file("digits/h-%dm.wav", c);//третий нулевой ..
+ }
+ break;
+ case female: //женщина
+ if (what=="thousand") {
+ if (last==0) {// если дальше нету цифр значит говорить двух, 3-х, 4-х ...
+ say_file("digits/h-%dxx.wav", c);//одна, двух, трёх
+ say_file("digits/h-thousandf.wav"); //тысячная
+ }
+ else { //если есть дальше цифры меньше 1000
+ say_file("digits/%d.wav", c);//три четыре ..
+ say_file("digits/thousand.wav"); //тысячи
+ }
+ }
+ else if (what=="million") {
+ if (last==0) {// если дальше нету цифр значит говорить двух, 3-х, 4-х ...
+ say_file("digits/h-%dxx.wav", c);//одна, двух, трёх
+ say_file("digits/h-millionf.wav"); //миллионная
+ }
+ else { //если есть дальше цифры меньше 1000
+ say_file("digits/%d.wav", c);//три четыре ..
+ say_file("digits/thousand.wav"); //миллиона
+ }
+ }//просто цифры без тысяч
+ else{
+ say_file("digits/h-%df.wav", c);//третья нулевая ..
+ }
+ break;
+ case it: //оно
+ if (what=="thousand") {
+ if (last==0) {// если дальше нету цифр значит говорить двух, 3-х, 4-х ...
+ say_file("digits/h-%dxx.wav", c);//одна, двух, трёх
+ say_file("digits/h-thousandn.wav"); //тысячное
+ }
+ else { //если есть дальше цифры меньше 1000
+ say_file("digits/%d.wav", c);//три четыре ..
+ say_file("digits/thousand.wav"); //тысячи
+ }
+ }
+ else if (what=="million") {
+ if (last==0) {// если дальше нету цифр значит говорить двух, 3-х, 4-х ...
+ say_file("digits/h-%dxx.wav", c);//одна, двух, трёх
+ say_file("digits/h-millionn.wav"); //миллионное
+ }
+ else { //если есть дальше цифры меньше 1000
+ say_file("digits/%d.wav", c);//три четыре ..
+ say_file("digits/thousand.wav"); //миллиона
+ }
+ }//просто цифры без тысяч
+ else{
+ say_file("digits/h-%dn.wav", c);//третье нулевое ..
+ }
+ break;
+ }
+ break;
+//-------------------------------------------------------
+ case when: //какого - когда без пола
+ if (what=="thousand") {
+ if (last==0) {// если дальше нету цифр значит говорить двух, 3-х, 4-х ...
+ say_file("digits/h-%dxx.wav", c);//одна, двух, трёх
+ say_file("digits/h-thousandx.wav"); //тысячного
+ }
+ else { //если есть дальше цифры меньше 1000
+ say_file("digits/%d.wav", c);//три четыре ..
+ say_file("digits/thousand.wav"); //тысячи
+ }
+ }
+ else if (what=="million") {
+ if (last==0) {// если дальше нету цифр значит говорить двух, 3-х, 4-х ...
+ say_file("digits/h-%dxx.wav", c);//одна, двух, трёх
+ say_file("digits/h-millionx.wav"); //миллионого
+ }
+ else { //если есть дальше цифры меньше 1000
+ say_file("digits/%d.wav", c);//три четыре ..
+ say_file("digits/thousand.wav"); //миллиона
+ }
+ }//просто цифры без тысяч
+ else{
+ say_file("digits/h-%dx.wav", c);//третьего нулевого ..
+ }
+ break;
+ }//конец switch (question)
+ } //конец //0 и 3-9
+ else if ((c==2)||(c==1)) { //1 2
+ switch (question) {
+//------------------------------------------------------
+ case how_much: //
+ switch (sex)
+ { //пол
+ case male: //мужчина
+ if (what=="thousand") {
+ if (c==1) {
+ say_file("digits/%df.wav", c); // одна две
+ say_file("digits/thousand.wav"); //тысяча
+ }
+ else{
+ say_file("digits/%df.wav", c); // одна две
+ say_file("digits/thousands-i.wav"); //тысячи
+ }
+ }
+ else if (what=="million") {
+ say_file("digits/%d.wav", c); // один два
+ if (c==1) {
+ say_file("digits/million.wav", c); //миллион
+ }
+ else { //один два
+ say_file("digits/million-a.wav"); // миллиона
+ }
+ }
+ else { //просто один два
+ say_file("digits/%d.wav", c); // один два
+ }
+ break;
+ //-------------
+ case female: //женщина
+ if (what=="thousand") {
+ if (c==1) {
+ say_file("digits/%df.wav", c); // одна две
+ say_file("digits/thousand.wav"); //тысяча
+ }
+ else{
+ say_file("digits/%df.wav", c); // одна две
+ say_file("digits/thousands-i.wav"); //тысячи
+ }
+ }
+ else if (what=="million") {
+ say_file("digits/%d.wav", c); // один два
+ if (c==1) {
+ say_file("digits/million.wav"); //миллион
+ }
+ else { //один два
+ say_file("digits/million-a.wav"); // миллиона
+ }
+ }
+ else { //просто одна две
+ say_file("digits/%df.wav", c); // одна две
+ }
+ break;
+ //-------------
+ case it: //оно
+ if (what=="thousand") {
+ if (c==1) {
+ say_file("digits/%df.wav", c); // одна две
+ say_file("digits/thousand.wav"); //тысяча
+ }
+ else{
+ say_file("digits/%df.wav", c); // одна две
+ say_file("digits/thousands-i.wav"); //тысячи
+ }
+ }
+ else if (what=="million") {
+ say_file("digits/%d.wav", c); // один два
+ if (c==1) {
+ say_file("digits/million.wav"); //миллион
+ }
+ else { //один два
+ say_file("digits/million-a.wav"); // миллиона
+ }
+ }
+ else { //просто одно две
+ say_file("digits/%dn.wav", c); // одна две
+ }
+ break;
+ }
+ break;
+//------------------------------------------------------
+ case what_: //какой/я/ое
+ switch (sex)
+ { //пол
+ case male: //мужчина
+ if (what=="thousand") {
+ if (last==0) {// если дальше нету цифр значит говорить двух,одна 2-х, ...
+ if (c!=1) { //не произность одна тысячный
+ say_file("digits/h-%dxx.wav", c);//одна, двух
+ }
+ say_file("digits/h-thousandm.wav"); //тысячный
+ }
+ else { //если есть дальше цифры меньше 1000
+ say_file("digits/%df.wav", c);//одна две
+ say_file("digits/thousands-i.wav"); //тысячи
+ }
+ }
+ else if (what=="million") {
+ if (last==0) {// если дальше нету цифр значит говорить двух, 3-х, 4-х ...
+ if (c!=1) {
+ say_file("digits/h-%dxx.wav", c);//одна, двух, трёх
+ }
+ say_file("digits/h-millionm.wav"); //миллионный
+ }
+ else { //если есть дальше цифры меньше 1000
+ say_file("digits/%d.wav", c);//три четыре ..
+ say_file("digits/thousand-a.wav"); //миллиона
+ }
+ }//просто цифры без тысяч
+ else{
+ say_file("digits/h-%dm.wav", c);//третий нулевой ..
+ }
+ break;
+ case female: //женщина
+ if (what=="thousand") {
+ if (last==0) {// если дальше нету цифр значит говорить двух, 1-х, 2-х ...
+ if (c!=1) { //не произность одна тысячная
+ say_file("digits/h-%dxx.wav", c);//одна, двух
+ }
+ say_file("digits/h-thousandf.wav"); //тысячная
+ }
+ else { //если есть дальше цифры меньше 1000
+ say_file("digits/%df.wav", c);//две четыре ..
+ say_file("digits/thousands-i.wav"); //тысячи
+ }
+ }
+ else if (what=="million") {
+ if (last==0) {// если дальше нету цифр значит говорить двух, 3-х, 4-х ...
+ if (c!=1) {
+ say_file("digits/h-%dxx.wav", c);//одна, двух, трёх
+ }
+ say_file("digits/h-millionf.wav"); //миллионная
+ }
+ else { //если есть дальше цифры меньше 1000
+ say_file("digits/%d.wav", c);//три четыре ..
+ say_file("digits/thousand-a.wav"); //миллиона
+ }
+ }//просто цифры без тысяч
+ else{
+ say_file("digits/h-%df.wav", c);//третья нулевая ..
+ }
+ break;
+ case it: //оно
+ if (what=="thousand") {
+ if (last==0) {// если дальше нету цифр значит говорить двух, 1-х, 2-х ...
+ if (c!=1) { //не произность одна тысячное
+ say_file("digits/h-%dxx.wav", c);//одна, двух
+ }
+ say_file("digits/h-thousandn.wav"); //тысячное
+ }
+ else { //если есть дальше цифры меньше 1000
+ say_file("digits/%df.wav", c);//две ..
+ say_file("digits/thousands-i.wav"); //тысячи
+ }
+ }
+ else if (what=="million") {
+ if (last==0) {// если дальше нету цифр значит говорить двух, 3-х, 4-х ...
+ if (c!=1) {
+ say_file("digits/h-%dxx.wav", c);//одна, двух
+ }
+ say_file("digits/h-millionn.wav"); //миллионное
+ }
+ else { //если есть дальше цифры меньше 1000
+ say_file("digits/%d.wav", c);//три четыре ..
+ say_file("digits/thousand-a.wav"); //миллиона
+ }
+ }//просто цифры без тысяч
+ else{
+ say_file("digits/h-%dn.wav", c);//третье нулевое ..
+ }
+ break;
+ }
+ break;
+//-------------------------------------------------------
+ case when: //какого - когда без пола
+ if (what=="thousand") {
+ if (last==0) {// если дальше нету цифр значит говорить двух, 3-х, 4-х ...
+ if (c!=1) { //не произность одна тысячного
+ say_file("digits/h-%dxx.wav", c);//одна, двух
+ }
+ say_file("digits/h-thousandx.wav"); //тысячного
+ }
+ else { //если есть дальше цифры меньше 1000
+ say_file("digits/%df.wav", c);//две четыре ..
+ say_file("digits/thousands-i.wav"); //тысячи
+ }
+ }
+ else if (what=="million") {
+ if (last==0) {// если дальше нету цифр значит говорить двух, 3-х, 4-х ...
+ if (c!=1) {
+ say_file("digits/h-%dxx.wav", c);//одна, двух, трёх
+ }
+ say_file("digits/h-millionx.wav"); //миллионного
+ }
+ else { //если есть дальше цифры меньше 1000
+ say_file("digits/%d.wav", c);//три четыре ..
+ say_file("digits/thousand-a.wav"); //миллиона
+ }
+ }//просто цифры без тысяч
+ else{
+ say_file("digits/h-%dx.wav", c);//третьего нулевого ..
+ }
+ break;
+ }
+ }//else if ((c==2)||(c==1)) { //1 2
+
+ }//конец if ((c)||(what=="zero"))
+ return SWITCH_STATUS_SUCCESS;
+}
+
+
+
+
+static char *strip_commas(char *in, char *out, switch_size_t len)
+{
+ char *p = in, *q = out;
+ char *ret = out;
+ switch_size_t x = 0;
+
+ for (; p && *p; p++) {
+ if ((*p > 47 && *p < 58)) {
+ *q++ = *p;
+ } else if (*p != ',') {
+ ret = NULL;
+ break;
+ }
+
+ if (++x > len) {
+ ret = NULL;
+ break;
+ }
+ }
+
+ return ret;
+}
+
+static char *strip_nonnumerics(char *in, char *out, switch_size_t len)
+{
+ char *p = in, *q = out;
+ char *ret = out;
+ switch_size_t x = 0;
+ // valid are 0 - 9, period (.), minus (-), and plus (+) - remove all others
+ for (; p && *p; p++) {
+ if ((*p > 47 && *p < 58) || *p == '.' || *p == '-' || *p == '+') {
+ *q++ = *p;
+ }
+
+ if (++x > len) {
+ ret = NULL;
+ break;
+ }
+ }
+
+ return ret;
+}
+
+
+static switch_status_t ru_say_count(switch_core_session_t *session,
+ char *tosay, sex_t sex, question_t question, switch_input_args_t *args)
+{
+ int in;
+ int x = 0;
+ int places[9] = { 0 };
+ char sbuf[13] = "";
+
+ switch_status_t status;
+
+ switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_INFO, "ru_say_count %d %d %d other!\n", places[2], places[1], places[0]);
+
+ if (!(tosay = strip_commas(tosay, sbuf, sizeof(sbuf))) || strlen(tosay) > 9) {
+ switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "Parse Error!\n");
+ return SWITCH_STATUS_GENERR;
+ }
+
+ in = atoi(tosay);
+ int in_ = in;
+ switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_INFO, "int in=%d!\n", in);
+ if (in != 0) {
+ for (x = 8; x >= 0; x--) {
+ int num = (int) pow(10, x);
+ if ((places[(uint32_t) x] = in / num)) {
+ in -= places[(uint32_t) x] * num;
+ }
+ }
+ switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_INFO, "int in=%d \n", in);
+
+ if ((status = play_group(sex,question, places[8], places[7], places[6], "million",in%1000000, session, args)) != SWITCH_STATUS_SUCCESS) {
+ switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_INFO, "play group %d %d %d million!\n", places[8], places[7], places[6]);
+ return status;
+ }
+ if ((status = play_group(sex,question, places[5], places[4], places[3], "thousand",in_%1000,session, args)) != SWITCH_STATUS_SUCCESS) {
+ switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_INFO, "play group %d %d %d thousand!\n", places[5], places[4], places[3]);
+ return status;
+ }
+ if ((status = play_group(sex,question, places[2], places[1], places[0], NULL, 0,session, args)) != SWITCH_STATUS_SUCCESS)
+ {
+ switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_INFO, "play group %d %d %d other!\n", places[2], places[1], places[0]);
+ return status;
+ }
+ } else { //если ноль что бы и его проговаривать в правильных падежах
+ if ((status = play_group(sex,question, places[2], places[1], places[0], "zero",0, session, args)) != SWITCH_STATUS_SUCCESS)
+ {
+ switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_INFO, "play group %d %d %d other!\n", places[2], places[1], places[0]);
+ return status;
+ }
+ }
+
+ return SWITCH_STATUS_SUCCESS;
+}
+
+
+static switch_status_t ru_say_general_count(switch_core_session_t *session,
+ char *tosay, switch_say_type_t type, switch_say_method_t method, switch_input_args_t *args)
+{
+ switch_status_t status;
+ sex_t sex;
+ question_t question;
+
+ if (type== SST_MESSAGES)
+ {
+ sex=it;
+ question=how_much;
+ }
+ else if (type== SST_NUMBER||type==SST_PERSONS)
+ {
+ sex=male;
+ question=how_much;
+ }
+ else if (type== SST_ITEMS)
+ {
+ sex=male;
+ question=what_;
+ }
+ else
+ {
+ switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "Unknown Say type=[%d]\n", type);
+ return SWITCH_STATUS_FALSE;
+ }
+ status=ru_say_count(session,tosay,sex,question,args);
+ return SWITCH_STATUS_SUCCESS;
+}
+
+
+
+static switch_status_t ru_say_money(switch_core_session_t *session, char *tosay, switch_say_type_t type,
+ switch_say_method_t method,switch_input_args_t *args)
+{
+ char sbuf[16] = "";
+ char *dollars = NULL;
+ char *cents = NULL;
+ switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_INFO, " ru_say_money %s\n",tosay );
+ if (strlen(tosay) > 15 || !(tosay = strip_nonnumerics(tosay, sbuf, sizeof(sbuf)))) {
+ switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "Parse Error!\n");
+ return SWITCH_STATUS_GENERR;
+ }
+ dollars = sbuf;
+
+ if ((cents = strchr(sbuf, '.'))) {
+ *cents++ = '\0';
+ if (strlen(cents) > 2) {
+ cents[2] = '\0';
+ }
+ }
+ if (sbuf[0] == '+') {
+ dollars++;
+ }
+
+ if (sbuf[0] == '-') {
+ say_file("currency/minus.wav");
+ dollars++;
+ }
+ ru_say_count(session,dollars ,male,how_much,args);
+ int idollars = atoi(dollars)%100;
+ int idollar = atoi(dollars)%10;
+ if (idollars == 1 || (idollars > 20 && idollar == 1)) {/* рубль */
+ say_file("currency/dollar.wav");
+ }
+ else if ((idollars > 1 && idollars < 5) || (idollars > 20 && idollar > 1 && idollar < 5)) { /*рубля */
+ say_file("currency/dollar1.wav");
+ }
+ else { /*рублей */
+ say_file("currency/dollar2.wav");
+ }
+ /* Say cents */
+ switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_INFO, " %s\n",cents );
+ ru_say_count(session,cents ,female,how_much,args);
+ int icents = atoi(cents)%100;
+ int icent = atoi(cents)%10;
+ if (icents == 1 || (icents > 20 && icent == 1))
+ {
+ /* копейка */
+ say_file("currency/cent.wav");
+ }
+ else if ((icents > 1 && icents < 5) || (icents > 20 && icent > 1 && icent < 5))
+ {
+ /* копейки */
+ say_file("currency/cent1.wav");
+ }
+ else
+ {
+ /* копеек */
+ say_file("currency/cents.wav");
+ }
+ return SWITCH_STATUS_SUCCESS;
+}
+
+
+static switch_status_t ru_say_time(switch_core_session_t *session, char *tosay, switch_say_type_t type, switch_say_method_t method,
+ switch_input_args_t *args)
+{
+ int32_t t;
+ char tmp[80];
+ switch_time_t target = 0, target_now = 0;
+ switch_time_exp_t tm, tm_now;
+ uint8_t say_date = 0, say_time = 0, say_year = 0, say_month = 0, say_dow = 0, say_day = 0, say_yesterday = 0, say_today = 0;
+ switch_channel_t *channel = switch_core_session_get_channel(session);
+ const char *tz = switch_channel_get_variable(channel, "timezone");
+ switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_INFO, " ru_say_time %s type=%d method=%d\n",tosay, type,method );
+
+ if (type == SST_TIME_MEASUREMENT) {
+ int64_t hours = 0;
+ int64_t minutes = 0;
+ int64_t seconds = 0;
+ int64_t r = 0;
+
+ if (strchr(tosay, ':')) {
+ char *tme = switch_core_session_strdup(session, tosay);
+ char *p;
+
+ if ((p = strrchr(tme, ':'))) {
+ *p++ = '\0';
+ seconds = atoi(p);
+ if ((p = strchr(tme, ':'))) {
+ *p++ = '\0';
+ minutes = atoi(p);
+ if (tme) {
+ hours = atoi(tme);
+ }
+ } else {
+ minutes = atoi(tme);
+ }
+ }
+ } else {
+ if ((seconds = atol(tosay)) <= 0) {
+ seconds = (int64_t) switch_epoch_time_now(NULL);
+ }
+
+ if (seconds >= 60) {
+ minutes = seconds / 60;
+ r = seconds % 60;
+ seconds = r;
+ }
+
+ if (minutes >= 60) {
+ hours = minutes / 60;
+ r = minutes % 60;
+ minutes = r;
+ }
+ }
+
+ switch_snprintf(tmp, sizeof(tmp), "%u", (unsigned)hours);
+ ru_say_count(session,tmp ,male,how_much,args);
+ if (((hours%10) == 1) && (hours!=11)) {
+ /* час */
+ say_file("time/hour.wav");
+ }
+ else if (((hours%10>1)&&(hours%10<5)) &&((hours<12)||(hours>14))) {
+ say_file("time/hours-a.wav"); /* часа */
+ }
+ else {
+ say_file("time/hours.wav"); /* часов*/
+ }
+
+ switch_snprintf(tmp, sizeof(tmp), "%u", (unsigned)minutes); //перевести минуты в *char
+ ru_say_count(session,tmp ,female,how_much,args);
+ if (((minutes%10) == 1) && (minutes!=11)) {
+ say_file("time/minute.wav"); //минута
+ }
+ else if (((minutes%10>1)&&(minutes%10<5))&&((minutes<12)||(minutes>14))){
+ say_file("time/minutes-i.wav"); // минуты
+ }
+ else {
+ say_file("time/minutes.wav"); //минут
+ }
+
+ if (seconds!=0) {
+ switch_snprintf(tmp, sizeof(tmp), "%u", (unsigned)seconds);
+ ru_say_count(session,tmp ,female,how_much,args);
+ if (((seconds%10) == 1) && (seconds!=11)) {
+ say_file("time/second.wav"); // секунда
+ }
+ else if (((seconds%10>1)&&(seconds%10<5))&&((seconds<12)||(seconds>14))) {
+ say_file("time/seconds-i.wav"); // секуны
+ }
+ else {
+ say_file("time/seconds.wav"); //секунд
+ }
+ }
+
+ return SWITCH_STATUS_SUCCESS;
+ }
+
+ if ((t = atol(tosay)) > 0) {
+ target = switch_time_make(t, 0);
+ target_now = switch_micro_time_now();
+ } else {
+ target = switch_micro_time_now();
+ target_now = switch_micro_time_now();
+ }
+
+ if (tz) {
+ int check = atoi(tz);
+ if (check) {
+ switch_time_exp_tz(&tm, target, check);
+ switch_time_exp_tz(&tm_now, target_now, check);
+ } else {
+ switch_time_exp_tz_name(tz, &tm, target);
+ switch_time_exp_tz_name(tz, &tm_now, target_now);
+ }
+ } else {
+ switch_time_exp_lt(&tm, target);
+ switch_time_exp_lt(&tm_now, target_now);
+ }
+ switch (type) {
+ case SST_CURRENT_DATE_TIME:
+ say_date = say_time = 1;
+ break;
+ case SST_CURRENT_DATE:
+ say_date = 1;
+ break;
+ case SST_CURRENT_TIME:
+ say_time = 1;
+ break;
+ case SST_SHORT_DATE_TIME:
+ say_time = 1;
+ if (tm.tm_year != tm_now.tm_year) {
+ say_date = 1;
+ break;
+ }
+ if (tm.tm_yday == tm_now.tm_yday) {
+ say_today = 1;
+ break;
+ }
+ if (tm.tm_yday == tm_now.tm_yday - 1) {
+ say_yesterday = 1;
+ break;
+ }
+ if (tm.tm_yday >= tm_now.tm_yday - 5) {
+ say_dow = 1;
+ break;
+ }
+ if (tm.tm_mon != tm_now.tm_mon) {
+ say_month = say_day = say_dow = 1;
+ break;
+ }
+
+ say_month = say_day = say_dow = 1;
+
+ break;
+ default:
+ break;
+ }
+
+ if (say_today) {
+ say_file("time/today.wav");
+ }
+ if (say_yesterday) {
+ say_file("time/yesterday.wav");
+ }
+ if (say_dow) {
+ say_file("time/day-%d.wav", tm.tm_wday);
+ }
+ if (say_date) {
+ say_year = say_month = say_day = say_dow = 1;
+ say_today = say_yesterday = 0;
+ }
+ if (say_day) {
+ switch_snprintf(tmp, sizeof(tmp), "%u", (unsigned)tm.tm_mday);
+ ru_say_count(session,tmp ,male,when,args);
+ }
+ if (say_month) {
+ say_file("time/mon-%d.wav", tm.tm_mon);
+ }
+ if (say_year) {
+ switch_snprintf(tmp, sizeof(tmp), "%u", (unsigned)(tm.tm_year + 1900));
+ ru_say_count(session,tmp ,male,when,args);
+ say_file("time/h-year.wav");
+ }
+ if (say_month||say_year||say_date||say_dow)
+ {
+ say_file("time/at.wav");
+ }
+ if (say_time) {
+ switch_snprintf(tmp, sizeof(tmp), "%d:%d:%d",tm.tm_hour+1,tm.tm_min,tm.tm_sec);
+ ru_say_time(session, tmp, SST_TIME_MEASUREMENT, method, args);
+ }
+ return SWITCH_STATUS_SUCCESS;
+}
+
+
+
+static switch_status_t ru_say(switch_core_session_t *session, char *tosay, switch_say_type_t type, switch_say_method_t method, switch_input_args_t *args)
+{
+ switch_say_callback_t say_cb = NULL;
+
+
+ switch (type) {
+ case SST_NUMBER:
+ case SST_ITEMS:
+ case SST_PERSONS:
+ case SST_MESSAGES:
+ say_cb = ru_say_general_count;
+ break;
+ case SST_TIME_MEASUREMENT:
+ say_cb = ru_say_time;
+ break;
+
+ case SST_CURRENT_DATE:
+ say_cb = ru_say_time;
+ break;
+
+ case SST_CURRENT_TIME:
+ say_cb = ru_say_time;
+ break;
+
+ case SST_CURRENT_DATE_TIME:
+ say_cb = ru_say_time;
+ break;
+ case SST_IP_ADDRESS:
+// say_cb = ru_ip;
+ break;
+ case SST_NAME_SPELLED:
+ case SST_NAME_PHONETIC:
+ say_cb = ru_spell;
+ break;
+ case SST_CURRENCY:
+ say_cb = ru_say_money;
+ break;
+ default:
+ switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "Unknown Say type=[%d]\n", type);
+ break;
+ }
+ if (say_cb) {
+ return say_cb(session, tosay, type, method, args);
+ }
+ return SWITCH_STATUS_FALSE;
+}
+
+
+
+SWITCH_MODULE_LOAD_FUNCTION(mod_say_ru_load)
+{
+ switch_say_interface_t *say_interface;
+ /* connect my internal structure to the blank pointer passed to me */
+ *module_interface = switch_loadable_module_create_module_interface(pool, modname);
+ say_interface = switch_loadable_module_create_interface(*module_interface, SWITCH_SAY_INTERFACE);
+ say_interface->interface_name = "ru";
+ say_interface->say_function = ru_say;
+
+ /* indicate that the module should continue to be loaded */
+ return SWITCH_STATUS_SUCCESS;
+}
+
+/* For Emacs:
+ * Local Variables:
+ * mode:c
+ * indent-tabs-mode:t
+ * tab-width:4
+ * c-basic-offset:4
+ * End:
+ * For VIM:
+ * vim:set softtabstop=4 shiftwidth=4 tabstop=4:
+ */
1
0
Author: brian
Date: Thu Apr 9 14:45:01 2009
New Revision: 12965
Log:
mkdir
Added:
freeswitch/trunk/src/mod/say/mod_say_ru/
1
0
09 Apr '09
Author: brian
Date: Thu Apr 9 14:38:15 2009
New Revision: 12964
Log:
extra paren
Modified:
freeswitch/trunk/src/mod/endpoints/mod_portaudio/mod_portaudio.c
Modified: freeswitch/trunk/src/mod/endpoints/mod_portaudio/mod_portaudio.c
==============================================================================
--- freeswitch/trunk/src/mod/endpoints/mod_portaudio/mod_portaudio.c (original)
+++ freeswitch/trunk/src/mod/endpoints/mod_portaudio/mod_portaudio.c Thu Apr 9 14:38:15 2009
@@ -1294,7 +1294,7 @@
return SWITCH_STATUS_SUCCESS;
}
- if (!switch_core_codec_ready(&globals.read_codec))) {
+ if (!switch_core_codec_ready(&globals.read_codec)) {
if (switch_core_codec_init(&globals.read_codec,
"L16",
NULL, sample_rate, codec_ms, 1, SWITCH_CODEC_FLAG_ENCODE | SWITCH_CODEC_FLAG_DECODE, NULL,
1
0
Author: cypromis
Date: Thu Apr 9 12:48:06 2009
New Revision: 12963
Log:
deleted non existant old config files
added new config files
got rif of xml_ldap since the openldap build breaks on centos
some minor cleanups
builds fine with mock
Modified:
freeswitch/trunk/freeswitch.spec
Modified: freeswitch/trunk/freeswitch.spec
==============================================================================
--- freeswitch/trunk/freeswitch.spec (original)
+++ freeswitch/trunk/freeswitch.spec Thu Apr 9 12:48:06 2009
@@ -319,8 +319,8 @@
LOGGERS_MODULES="loggers/mod_console loggers/mod_logfile loggers/mod_syslog"
SAY_MODULES="say/mod_say_en say/mod_say_de say/mod_say_fr"
TIMERS_MODULES=
-DISABLED_MODULES="applications/mod_soundtouch languages/mod_spidermonkey_skel ast_tts/mod_cepstral asr_tts/mod_lumenvox directories/mod_ldap event_handlers/mod_event_test event_handlers/mod_radius_cdr event_handlers/mod_zeroconf languages/mod_managed languages/mod_java say/mod_say_it say/mod_say_es say/mod_say_nl"
-XML_INT_MODULES="xml_int/mod_xml_rpc xml_int/mod_xml_curl xml_int/mod_xml_cdr xml_int/mod_xml_ldap"
+DISABLED_MODULES="applications/mod_soundtouch languages/mod_spidermonkey_skel ast_tts/mod_cepstral asr_tts/mod_lumenvox event_handlers/mod_event_test event_handlers/mod_radius_cdr event_handlers/mod_zeroconf languages/mod_managed languages/mod_java say/mod_say_it say/mod_say_es say/mod_say_nl"
+XML_INT_MODULES="xml_int/mod_xml_rpc xml_int/mod_xml_curl xml_int/mod_xml_cdr "
MYMODULES="$PASSTHRU_CODEC_MODULES $SPIDERMONKEY_MODULES $APPLICATIONS_MODULES $ASR_TTS_MODULES $CODECS_MODULES $DIALPLANS_MODULES $DIRECTORIES_MODULES $ENDPOINTS_MODULES $EVENT_HANDLERS_MODULES $FORMATS_MODULES $LANGUAGES_MODULES $LOGGERS_MODULES $SAY_MODULES $TIMERS_MODULES $XML_INT_MODULES"
export MODULES=$MYMODULES
@@ -387,7 +387,7 @@
%{__install} -D -m 744 build/freeswitch.init.suse $RPM_BUILD_ROOT/etc/init.d/freeswitch
%else
# On RedHat like
-%{__install} -D -o root -g root -m 0755 build/freeswitch.init.redhat $RPM_BUILD_ROOT/etc/init.d/freeswitch
+%{__install} -D -m 0755 build/freeswitch.init.redhat $RPM_BUILD_ROOT/etc/init.d/freeswitch
%endif
# On SuSE make /usr/sbin/rcfreeswitch a link to /etc/init.d/freeswitch
%if 0%{?suse_version} > 100
@@ -457,7 +457,6 @@
%config(noreplace) %attr(0640, freeswitch, daemon) %{prefix}/conf/*.xml
%config(noreplace) %attr(0640, freeswitch, daemon) %{prefix}/conf/m3ua.conf
%config(noreplace) %attr(0640, freeswitch, daemon) %{prefix}/conf/extensions.conf
-%config(noreplace) %attr(0640, freeswitch, daemon) %{prefix}/conf/cmudict.0.6d
%config(noreplace) %attr(0640, freeswitch, daemon) %{prefix}/conf/autoload_configs/acl.conf.xml
%config(noreplace) %attr(0640, freeswitch, daemon) %{prefix}/conf/autoload_configs/alsa.conf.xml
%config(noreplace) %attr(0640, freeswitch, daemon) %{prefix}/conf/autoload_configs/conference.conf.xml
@@ -496,6 +495,7 @@
%config(noreplace) %attr(0640, freeswitch, daemon) %{prefix}/conf/autoload_configs/lcr.conf.xml
%config(noreplace) %attr(0640, freeswitch, daemon) %{prefix}/conf/autoload_configs/opal.conf.xml
%config(noreplace) %attr(0640, freeswitch, daemon) %{prefix}/conf/autoload_configs/unicall.conf.xml
+%config(noreplace) %attr(0640, freeswitch, daemon) %{prefix}/conf/autoload_configs/memcache.conf.xml
%config(noreplace) %attr(0640, freeswitch, daemon) %{prefix}/conf/dialplan/*.xml
%config(noreplace) %attr(0640, freeswitch, daemon) %{prefix}/conf/dialplan/default/*.xml
%config(noreplace) %attr(0640, freeswitch, daemon) %{prefix}/conf/dialplan/public/*.xml
@@ -505,7 +505,7 @@
%config(noreplace) %attr(0640, freeswitch, daemon) %{prefix}/conf/sip_profiles/internal/*.xml
%config(noreplace) %attr(0640, freeswitch, daemon) %{prefix}/conf/sip_profiles/external/*.xml
%config(noreplace) %attr(0640, freeswitch, daemon) %{prefix}/conf/jingle_profiles/*.xml
-%config(noreplace) %attr(0640, freeswitch, daemon) %{prefix}/grammar/Makefile
+%config(noreplace) %attr(0640, freeswitch, daemon) %{prefix}/grammar/default.dic
%config(noreplace) %attr(0640, freeswitch, daemon) %{prefix}/grammar/model/communicator/*
%config(noreplace) %attr(0640, freeswitch, daemon) %{prefix}/grammar/model/wsj1/*
%config(noreplace) %attr(0640, freeswitch, daemon) %{prefix}/htdocs/*
@@ -566,7 +566,6 @@
%{prefix}/mod/mod_stress.so
%{prefix}/mod/mod_yaml.so
%{prefix}/mod/mod_shout.so
-%{prefix}/mod/mod_xml_ldap.so
%{prefix}/mod/mod_fax.so
%{prefix}/mod/mod_soundtouch.so
%{prefix}/mod/mod_vmd.so
@@ -630,7 +629,7 @@
%files python
%defattr(-,freeswitch,daemon)
%{prefix}/mod/mod_python*.so*
-%attr(0644, root, bin) /usr/lib/python2.4/site-packages/freeswitch.py
+%attr(0644, root, bin) /usr/lib/python2.4/site-packages/freeswitch.py*
%dir %attr(0750, freeswitch, daemon) %{prefix}/conf/autoload_configs
%config(noreplace) %attr(0640, freeswitch, daemon) %{prefix}/conf/autoload_configs/python.conf.xml
@@ -784,7 +783,6 @@
- added mod/mod_stress.so
- added mod_yaml.so
- added mod_shout.so
-- added mod_xml_ldap.so
- added rpms or all sounds
- openzap is now its own rpm
- added french
1
0