Merge "Limit GetModelState API to generic sound models (ie music detector)" into qt-dev

am: 58ac2ae2cb

Change-Id: I3c44bbfff4971431af726fe9aabcfe6e179639e6
This commit is contained in:
Michael Dooley
2019-05-23 23:16:39 -07:00
committed by android-build-merger

View File

@@ -558,18 +558,15 @@ public class SoundTriggerService extends SystemService {
return ret;
}
switch (soundModel.type) {
case SoundModel.TYPE_KEYPHRASE:
ret = mSoundTriggerHelper.getKeyphraseModelState(soundModel.uuid);
break;
case SoundModel.TYPE_GENERIC_SOUND:
ret = mSoundTriggerHelper.getGenericModelState(soundModel.uuid);
break;
default:
Slog.e(TAG, "Unknown model type");
// SoundModel.TYPE_KEYPHRASE is not supported to increase privacy.
Slog.e(TAG, "Unsupported model type, " + soundModel.type);
sEventLogger.log(new SoundTriggerLogger.StringEvent(
"getModelState(): Unknown model type"));
"getModelState(): Unsupported model type, "
+ soundModel.type));
break;
}