Back to project page sdl_tester_android.
The source code is released under:
Copyright (c) 2014, Ford Motor Company All rights reserved. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are m...
If you think the Android project sdl_tester_android listed in this page is inappropriate, such as containing malicious code/tools or violating the copyright, please email info at java2s dot com, thanks.
package com.livio.sdl.enums; /*from w w w . j a v a 2 s. c o m*/ import com.smartdevicelink.proxy.rpc.enums.InteractionMode; /** * Represents different types of interaction modes that the user can utilize * when performing an interaction on a choice set list. * * @see InteractionMode * * @author Mike Burke * */ public enum SdlInteractionMode { /** * Represents perform interactions that can only be controlled manually by button click events. */ MANUAL_ONLY("Click events"), /** * Represents perform interactions that can only be controlled by voice-rec events. */ VOICE_REC_ONLY("Voice-rec events"), /** * Represents perform interactions that can be controlled by click events and voice-rec events. */ BOTH("Click and voice-rec events"), ; private final String friendlyName; private SdlInteractionMode(String str){ this.friendlyName = str; } /** * Translates an input SdlInteractionMode to its associated InteractionMode object. * * @param from The SdlInteractionMode to translate * @return The InteractionMode object associated with the input SdlInteractionMode object */ public static InteractionMode translateToLegacy(SdlInteractionMode from){ switch(from){ case MANUAL_ONLY: return InteractionMode.MANUAL_ONLY; case VOICE_REC_ONLY: return InteractionMode.VR_ONLY; case BOTH: return InteractionMode.BOTH; default: return null; } } /** * Translates an input InteractionMode to its associated SdlInteractionMode object. * * @param from The InteractionMode to translate * @return The SdlInteractionMode object associated with the input InteractionMode object */ public static SdlInteractionMode translateFromLegacy(InteractionMode from){ switch(from){ case MANUAL_ONLY: return MANUAL_ONLY; case VR_ONLY: return VOICE_REC_ONLY; case BOTH: return BOTH; default: return null; } } @Override public String toString(){ return friendlyName; } }