@@ -44,10 +44,10 @@ void Start()
44
44
//TestCreateSession("en-US_BroadbandModel");
45
45
46
46
// test GetCustomizations
47
- TestGetCustomizations ( ) ;
47
+ // TestGetCustomizations();
48
48
49
49
// test create, get and delete customizations
50
- TestCreateCustomization ( ) ;
50
+ // TestCreateCustomization();
51
51
}
52
52
53
53
private void TestGetModels ( )
@@ -125,31 +125,31 @@ private void TestAddCustomCorpus(string customizationID, string corpusName, bool
125
125
private void TestGetCustomWords ( )
126
126
{
127
127
Log . Debug ( "ExampleSpeechToText" , "Attempting to get custom words." ) ;
128
- m_SpeechToText . GetCustomWords ( OnGetCustomWords , m_CreatedCustomizationID ) ;
128
+ m_SpeechToText . GetCustomWords ( HandleGetCustomWords , m_CreatedCustomizationID ) ;
129
129
}
130
130
131
131
private void TestAddCustomWordsPath ( string customizationID , string wordsJsonPath )
132
132
{
133
133
Log . Debug ( "ExampleSpeechToText" , "Attempting to add custom words in customization {0} using Words json path {1}" , customizationID , wordsJsonPath ) ;
134
- m_SpeechToText . AddCustomWords ( OnAddCustomWords , customizationID , wordsJsonPath ) ;
134
+ m_SpeechToText . AddCustomWords ( HandleAddCustomWords , customizationID , wordsJsonPath ) ;
135
135
}
136
136
137
137
private void TestAddCustomWordsWordsObject ( string customizationID , Words words )
138
138
{
139
139
Log . Debug ( "ExampleSpeechToText" , "Attempting to add custom words in customization {0} using Words object" , customizationID ) ;
140
- m_SpeechToText . AddCustomWords ( OnAddCustomWords , customizationID , words ) ;
140
+ m_SpeechToText . AddCustomWords ( HandleAddCustomWords , customizationID , words ) ;
141
141
}
142
142
143
143
private void TestDeleteCustomWord ( string customizationID , string word )
144
144
{
145
145
Log . Debug ( "ExampleSpeechToText" , "Attempting to delete custom word {1} in customization {0}" , customizationID , word ) ;
146
- m_SpeechToText . DeleteCustomWord ( OnDeleteCustomWord , customizationID , word ) ;
146
+ m_SpeechToText . DeleteCustomWord ( HandleDeleteCustomWord , customizationID , word ) ;
147
147
}
148
148
149
149
private void TestGetCustomWord ( string customizationID , string word )
150
150
{
151
151
Log . Debug ( "ExampleSpeechToText" , "Attempting to get custom word {1} in customization {0}" , customizationID , word ) ;
152
- m_SpeechToText . GetCustomWord ( OnGetCustomWord , customizationID , word ) ;
152
+ m_SpeechToText . GetCustomWord ( HandleGetCustomWord , customizationID , word ) ;
153
153
}
154
154
155
155
@@ -203,7 +203,7 @@ private void HandleOnRecognize (SpeechRecognitionEvent result)
203
203
foreach ( var alt in res . alternatives )
204
204
{
205
205
string text = alt . transcript ;
206
- Debug . Log ( string . Format ( "{0} ({1}, {2:0.00})\n " , text , res . final ? "Final" : "Interim" , alt . confidence ) ) ;
206
+ Log . Debug ( "ExampleSpeechToText" , string . Format ( "{0} ({1}, {2:0.00})\n " , text , res . final ? "Final" : "Interim" , alt . confidence ) ) ;
207
207
}
208
208
}
209
209
}
@@ -402,7 +402,7 @@ private void HandleAddCustomCorpus(bool success, string customData)
402
402
}
403
403
}
404
404
405
- private void OnGetCustomWords ( WordsList wordList , string customData )
405
+ private void HandleGetCustomWords ( WordsList wordList , string customData )
406
406
{
407
407
if ( ! string . IsNullOrEmpty ( customData ) )
408
408
Log . Debug ( "ExampleSpeechToText" , "custom data: {0}" , customData ) ;
@@ -425,7 +425,7 @@ private void OnGetCustomWords(WordsList wordList, string customData)
425
425
}
426
426
}
427
427
428
- private void OnAddCustomWords ( bool success , string customData )
428
+ private void HandleAddCustomWords ( bool success , string customData )
429
429
{
430
430
if ( ! string . IsNullOrEmpty ( customData ) )
431
431
Log . Debug ( "ExampleSpeechToText" , "custom data: {0}" , customData ) ;
@@ -441,7 +441,7 @@ private void OnAddCustomWords(bool success, string customData)
441
441
}
442
442
}
443
443
444
- private void OnDeleteCustomWord ( bool success , string customData )
444
+ private void HandleDeleteCustomWord ( bool success , string customData )
445
445
{
446
446
if ( ! string . IsNullOrEmpty ( customData ) )
447
447
Log . Debug ( "ExampleSpeechToText" , "custom data: {0}" , customData ) ;
@@ -457,7 +457,7 @@ private void OnDeleteCustomWord(bool success, string customData)
457
457
}
458
458
}
459
459
460
- private void OnGetCustomWord ( WordData word , string customData )
460
+ private void HandleGetCustomWord ( WordData word , string customData )
461
461
{
462
462
if ( ! string . IsNullOrEmpty ( customData ) )
463
463
Log . Debug ( "ExampleSpeechToText" , "custom data: {0}" , customData ) ;
0 commit comments