Home
last modified time | relevance | path

Searched refs:keyphrase (Results 1 – 5 of 5) sorted by relevance

/frameworks/base/core/java/android/hardware/soundtrigger/
DKeyphraseMetadata.java30 public final String keyphrase; field in KeyphraseMetadata
34 public KeyphraseMetadata(int id, String keyphrase, ArraySet<Locale> supportedLocales, in KeyphraseMetadata() argument
37 this.keyphrase = keyphrase; in KeyphraseMetadata()
44 return "id=" + id + ", keyphrase=" + keyphrase + ", supported-locales=" + supportedLocales in toString()
52 return keyphrase.isEmpty() || keyphrase.equalsIgnoreCase(phrase); in supportsPhrase()
DKeyphraseEnrollmentInfo.java261 public Intent getManageKeyphraseIntent(int action, String keyphrase, Locale locale) { in getManageKeyphraseIntent() argument
267 if (getKeyphraseMetadata(keyphrase, locale) != null) { in getManageKeyphraseIntent()
270 .putExtra(EXTRA_VOICE_KEYPHRASE_HINT_TEXT, keyphrase) in getManageKeyphraseIntent()
288 public KeyphraseMetadata getKeyphraseMetadata(String keyphrase, Locale locale) { in getKeyphraseMetadata() argument
296 if (keyphraseMetadata.supportsPhrase(keyphrase) in getKeyphraseMetadata()
/frameworks/base/tests/SoundTriggerTests/src/android/hardware/soundtrigger/
DSoundTriggerTest.java41 Keyphrase keyphrase = new Keyphrase(1, 0, "en-US", "hello", null); in testKeyphraseParcelUnparcel_noUsers() local
45 keyphrase.writeToParcel(parcel, 0); in testKeyphraseParcelUnparcel_noUsers()
52 assertEquals(keyphrase.id, unparceled.id); in testKeyphraseParcelUnparcel_noUsers()
54 assertEquals(keyphrase.locale, unparceled.locale); in testKeyphraseParcelUnparcel_noUsers()
55 assertEquals(keyphrase.text, unparceled.text); in testKeyphraseParcelUnparcel_noUsers()
60 Keyphrase keyphrase = new Keyphrase(1, 0, "en-US", "hello", new int[0]); in testKeyphraseParcelUnparcel_zeroUsers() local
64 keyphrase.writeToParcel(parcel, 0); in testKeyphraseParcelUnparcel_zeroUsers()
71 assertEquals(keyphrase.id, unparceled.id); in testKeyphraseParcelUnparcel_zeroUsers()
72 assertTrue(Arrays.equals(keyphrase.users, unparceled.users)); in testKeyphraseParcelUnparcel_zeroUsers()
73 assertEquals(keyphrase.locale, unparceled.locale); in testKeyphraseParcelUnparcel_zeroUsers()
[all …]
/frameworks/base/tests/VoiceEnrollment/src/com/android/test/voiceenrollment/
DEnrollmentUtil.java175 Keyphrase keyphrase = soundModel.keyphrases[0]; in verifyKeyphraseSoundModel() local
176 if (keyphrase.id <= 0) { in verifyKeyphraseSoundModel()
180 if (keyphrase.recognitionModes < 0) { in verifyKeyphraseSoundModel()
184 if (keyphrase.locale == null) { in verifyKeyphraseSoundModel()
188 if (keyphrase.text == null) { in verifyKeyphraseSoundModel()
192 if (keyphrase.users == null || keyphrase.users.length == 0) { in verifyKeyphraseSoundModel()
/frameworks/base/core/java/android/service/voice/
DVoiceInteractionService.java268 String keyphrase, Locale locale, AlwaysOnHotwordDetector.Callback callback) { in createAlwaysOnHotwordDetector() argument
275 mHotwordDetector = new AlwaysOnHotwordDetector(keyphrase, locale, callback, in createAlwaysOnHotwordDetector()